52 using namespace KM3NETDAQ;
61 bool reuse_parameters;
67 JParser<> zap(
"Auxiliary program to re-process time slice data.");
71 zap[
'n'] =
make_field(numberOfEvents) = JLimit::max();
75 zap[
'C'] =
make_field(selector,
"timeslice selector, e.g. JDAQTimesliceL1.") = getROOTClassSelection<JDAQTimesliceTypes_t>();
80 catch(
const exception &error) {
81 FATAL(error.what() << endl);
90 DEBUG(
"Reset time [ms] " <<
getRTS() * 1e-6 << endl);
102 if (reuse_parameters) {
108 NOTICE(
"Set trigger parameters from input." << endl);
111 FATAL(
"No trigger parameters from input." << endl);
119 if (
parameters.writeSummary()) {
WARNING(
"Discard writeSummary option during reprocesing of data." << endl); }
150 for ( ;
in.hasNext() && counter != inputFile.getLimit(); ++counter) {
152 STATUS(
"event: " << setw(10) << counter <<
'\r');
DEBUG(endl);
156 DEBUG(*timeslice << endl);
158 timesliceRouter.configure(*timeslice);
165 for (JDAQTimeslice::const_iterator super_frame = timeslice->begin(); super_frame != timeslice->end(); ++super_frame) {
167 if (moduleRouter.hasModule(super_frame->getModuleID())) {
171 const JModule& module = moduleRouter.getModule(super_frame->getModuleID());
172 JSuperFrame2D_t& buffer = JSuperFrame2D_t::demultiplex(*super_frame, module);
176 buffer.applyHighRateVeto(
parameters.highRateVeto_Hz);
180 timesliceL0.push_back(JSuperFrame1D_t(buffer));
184 timesliceL1.push_back(JSuperFrame1D_t(super_frame->getDAQChronometer(),
185 super_frame->getModuleIdentifier(),
188 buildL1(*timesliceL0.rbegin(), back_inserter(*timesliceL1.rbegin()));
192 timesliceL2.push_back(JSuperFrame1D_t(super_frame->getDAQChronometer(),
193 super_frame->getModuleIdentifier(),
196 buildL2(buffer, *timesliceL1.rbegin(), back_inserter(*timesliceL2.rbegin()));
200 timesliceSN.push_back(JSuperFrame1D_t(super_frame->getDAQChronometer(),
201 super_frame->getModuleIdentifier(),
204 buildSN(buffer, *timesliceL1.rbegin(), back_inserter(*timesliceSN.rbegin()));
Utility class to parse command line options.
Data structure for a composite optical module.
Router for fast addressing of hits in KM3NETDAQ::JDAQTimeslice data structure as a function of the op...
Auxiliary class to select ROOT class based on class name.
Router for direct addressing of module data in detector data structure.
*fatal Wrong number of arguments esac JCookie sh typeset Z DETECTOR typeset Z SOURCE_RUN typeset Z TARGET_RUN set_variable PARAMETERS_FILE $WORKDIR parameters
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
Long64_t counter_type
Type definition for counter.
Auxiliary class for multiplexing object iterators.
1-dimensional frame with time calibrated data from one optical module.
void setDAQLongprint(const bool option)
Set DAQ print option.
Auxiliary class for defining the range of iterations of objects.
double getMaximalDistance(const JDetector &detector)
Get maximal distance between modules in detector.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
double getFrameTime()
Get frame time duration.
const JDAQChronometer & getDAQChronometer() const
Get DAQ chronometer.
const JPosition3D & getPosition() const
Get position.
void load(const std::string &file_name, JDetector &detector)
Load detector from input file.
Auxiliary class to build JDAQTimeslice for L1 timeslice.
double getRTS()
Get TDC dynamic range.
then usage $script< input_file >< detector_file > fi set_variable OUTPUT_DIR set_variable SELECTOR JDAQTimesliceL1 set_variable DEBUG case set_variable DEBUG
2-dimensional frame with time calibrated data from one optical module.
Object reading from a list of files.
const JLimit & getLimit() const
Get limit.
do set_variable DETECTOR_TXT $WORKDIR detector
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
JTriggerParameters getTriggerParameters(const JMultipleFileScanner_t &file_list)
Get trigger parameters.
Time slice with calibrated data.