31 int main(
int argc,
char **argv)
39 JLimit_t& numberOfEvents = inputFile.getLimit();
45 JParser<> zap(
"Program to plot snapshot data.");
47 zap[
'f'] =
make_field(inputFile,
"input file.");
49 zap[
'n'] =
make_field(numberOfEvents) = JLimit::max();
50 zap[
'a'] =
make_field(detectorFile,
"detector file.") =
"";
55 catch(
const exception& error) {
56 FATAL(error.what() << endl);
62 if (detectorFile !=
"") {
79 TH1D h0(
"h0", NULL, 250, -0.5, 499.5);
80 TH1D h1(
"h1", NULL, 250, -0.5, 499.5);
90 int number_of_hits = 0;
111 DEBUG(
"Number of snapshot hits " << event->size<
JDAQSnapshotHit>() <<
' ' << number_of_hits << endl);
114 h1.Fill((
double) number_of_hits);
int main(int argc, char **argv)
Data structure for detector geometry and calibration.
General purpose messaging.
#define DEBUG(A)
Message macros.
Direct access to module in detector data structure.
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Scanning of objects from a single file according a format that follows from the extension of each fil...
ROOT TTree parameter settings of various packages.
Router for direct addressing of module data in detector data structure.
const JModule & getModule(const JObjectID &id) const
Get module parameters.
bool hasModule(const JObjectID &id) const
Has module.
const JPMT & getPMT(const int index) const
Get PMT.
Utility class to parse command line options.
Object reading from a list of files.
virtual const pointer_type & next() override
Get next element.
virtual bool hasNext() override
Check availability of next element.
counter_type getCounter() const
Get counter.
File router for fast addressing of summary data.
void update(const JDAQHeader &header)
Update router.
bool hasSummaryFrame(const JDAQModuleIdentifier &module) const
Has summary frame.
const JDAQSummaryFrame & getSummaryFrame() const
Get default summary frame.
int getModuleID() const
Get module identifier.
Data storage class for rate measurements of all PMTs in one module.
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 getDAQStatus(const JDAQFrameStatus &frame, const JStatus &status)
Test status of DAQ.
bool getPMTStatus(const JStatus &status)
Test status of PMT.
KM3NeT DAQ data structures and auxiliaries.
Auxiliary class for handling status.
int getStatus() const
Get status.
Auxiliary class for defining the range of iterations of objects.