Go to the documentation of this file.
   47 int main(
int argc, 
char **argv)
 
   53   JLimit_t&              numberOfEvents = inputFile.getLimit();
 
   60   int                    preTriggerThreshold;
 
   68     JParser<> zap(
"Example program test supernova triggers.");
 
   72     zap[
'n'] = 
make_field(numberOfEvents)      = JLimit::max();
 
   76     zap[
'C'] = 
make_field(selector)            = getROOTClassSelection<JDAQTimesliceTypes_t>();
 
   79     zap[
't'] = 
make_field(preTriggerThreshold) = 4;
 
   83   catch(
const exception &error) {
 
   84     FATAL(error.what() << endl);
 
  106   pts->configure(inputFile);
 
  118   TH1D* h_vtr = 
new TH1D(
"VetoTimeRange",
"VetoTimeRange", 10000, 0, 10000);
 
  124   for (; evIn.hasNext(); ) {
 
  126     STATUS(
"event: " << setw(10) << evIn.getCounter() << 
'\r'); 
DEBUG(endl);
 
  130     JVeto vp(*event, hitRouter);
 
  132     triggeredEvents[
event->getFrameIndex()].push_back(vp);
 
  138   STATUS(triggeredEvents.size() << 
" JDAQEvents loaded in veto buffer." << endl);
 
  153   JManager_t SNTH(
new TH1D(
"SNT_F%", NULL, 100, 0.0, 100));
 
  155   JManager_t MUL(
new TH1D(
"MUL_F%", NULL, 1 + 31, -0.5, 31 + 1 - 0.5));
 
  157   const int nStages = 5;
 
  164   for ( ; pts->hasNext() && counter != inputFile.getLimit(); ++counter) {
 
  166     STATUS(
"timeslice: " << setw(10) << counter << 
'\r'); 
DEBUG(endl);
 
  172     JDataSN preTrigger(TMax_ns, preTriggerThreshold); 
 
  174     preTrigger(timeslice, moduleRouter);
 
  184     if (triggeredEvents.count(fIndex)) { 
 
  185       veto = triggeredEvents.at(fIndex);
 
  194     int rawCount = count_if(preTrigger.begin(), preTrigger.end(), trgOp);
 
  198     trgHistory[0].push_back(rawCount);
 
  200     for (
int i = 0; i < 3; i++) {
 
  201       trgHistory[i + 1].push_back(trgCount[i]);
 
  204     trgHistory[4].push_back(trigger.
getModules().size());
 
  212   for (
int i = 0; i < nStages; i++) {
 
  213     for (
unsigned j = 0; 
j < trgHistory[i].size(); 
j++) {
 
  214       SNTH[i]->Fill(trgHistory[i][
j]);
 
  
SN filter based on multiplicity selection optional suppression of multi-module coincidences.
 
Auxiliary class to select JTreeScanner based on ROOT class name.
 
Auxiliary class to apply the supernova trigger to SN data.
 
Auxiliary class for defining the range of iterations of objects.
 
Auxiliary class for a type holder.
 
void load(const JString &file_name, JDetector &detector)
Load detector from input file.
 
Auxiliary class to manage a set of vetoes.
 
int getFrameIndex() const
Get frame index.
 
Utility class to parse command line options.
 
Auxiliary class to manage set of compatible ROOT objects (e.g.
 
double getLength()
Get length of veto time range.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
 
void setVeto(JVetoSet &vt)
 
Auxiliary class to select ROOT class based on class name.
 
Template definition for direct access of elements in ROOT TChain.
 
JModuleSet getModules(JRange< int > A=JRange< int >(6, 10))
Get triggered modules after track veto.
 
Auxiliary interface for direct access of elements in ROOT TChain.
 
Router for direct addressing of module data in detector data structure.
 
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
 
#define DEBUG(A)
Message macros.
 
Auxiliary class to define a veto time window on a set of optical modules.
 
KM3NeT DAQ data structures and auxiliaries.
 
vector< int > benchmark(JRange< int > A=JRange< int >(6, 10))
Benchmark different trigger steps.
 
Long64_t counter_type
Type definition for counter.
 
int main(int argc, char **argv)
 
Auxiliary class to build the supernova trigger dataset.
 
Simple wrapper around JModuleRouter class for direct addressing of PMT data in detector data structur...