61                                {
   62 
   65 
   68  string                   detectorFile;
   72  int                      analysis_level;
   73  
   74 
   75  try {
   76 
   78 
   82 
   84 
   85    zap[
'f'] = 
make_field(inputFile      , 
"input file "    );
 
   87    zap[
'a'] = 
make_field(detectorFile   , 
"detector file"  );  
 
   89    zap[
'L'] = 
make_field(analysis_level , 
"analysis level")  = 0, 1, 2;
 
   90    
   91    zap(argc,argv);
   92  }
   93  catch(const exception &error) {
   94    ERROR(error.what() << endl);
 
   95  }
   96 
   98 
   99  try {
  101  }
  103    FATAL( 
"FATAL ERROR. Could not open detector file '" << detectorFile << 
"'." << endl);
 
  104  }
  105  
  106  if(analysis_level == 1){
  107    cout << "ANALYSIS OF ALL AVAILABLE PMTs INFORMATION. It may take a while!" << endl;
  108  } else if (analysis_level == 2){
  109    cout << "BASIC ANALYSIS AT TRIGGER AND RECONSTRUCTION LEVEL." << endl;
  110  } else {
  111    cout << "JRUNANALYZER RUNNING WITH A REDUCED NUMBER OF PLOTS." << endl;
  112  }
  113  
  115  
  117 
  118  try{
  120  }catch(const exception&){}
  121  
  123 
  125 
  127 
  129 
  130  cout << "START\n";
  131  
  133 
  135 
  136  if (p == NULL) {
  137    FATAL(
"WRONG FILE TYPE");
 
  138  }
  139  
  140  TFile* out = p->getFile();
  141 
  142  cout << out->GetName() << endl;
  143 
  145 
  147    
  149 
  151    
  154      
  156      
  158 
  159      break;
  160    }
  161  }
  162 
  165                         buffer.DAQ.livetime_s, 
  166                         buffer.livetime.numberOfSeconds);
  167    
  169    
  170  JRunAnalyzer Analyzer (inputFile, 
detector, out, numberOfTimeslices, numberOfSummaryslices, numberOfEvents, analysis_level);
 
  171 
  172  cout << "read events\n";
  173  Analyzer.readEvents                        ();
  174  cout << "read summarydata\n";
  175  Analyzer.readSummaryData                   ();
  176  cout << "read timeslices\n";
  182  
  183  if(analysis_level == 2){
  184    cout << "read reconstructed events\n";
  185    Analyzer.readRecoEvents                  ();
  186  }
  187  
  188  Analyzer.writeToFile(out, analysis_level);
  189 
  191}
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
 
#define gmake_property(A)
macros to convert (template) parameter to JPropertiesElement object
 
Utility class to parse parameter values.
 
Utility class to parse command line options.
 
Class dedicated to the analysis of KM3NeT runs.
 
Template definition for direct access of elements in ROOT TChain.
 
int getDetectorID() const
Get detector identifier.
 
int getRunNumber() const
Get run number.
 
JTriggerCounter_t next()
Increment trigger counter.
 
void copy(const Head &from, JHead &to)
Copy header from from to to.
 
void load(const std::string &file_name, JDetector &detector)
Load detector from input file.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
 
bool putObject(TDirectory &dir, const TObject &object)
Write object to ROOT directory.
 
double getLivetime(const std::string &file_name)
Get data taking live time.
 
Head getHeader(const JMultipleFileScanner_t &file_list)
Get Monte Carlo header.
 
KM3NeT DAQ data structures and auxiliaries.
 
The Head class reflects the header of Monte-Carlo event files, which consists of keys (also referred ...
 
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
 
Auxiliary class for defining the range of iterations of objects.
 
static counter_type max()
Get maximum counter value.
 
Timeslice data structure for L0 data.
 
Timeslice data structure for L1 data.
 
Timeslice data structure for L2 data.
 
Timeslice data structure for SN data.