Belle II Software development
BeamBkgMixerModule.cc
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9// Own header.
10#include <background/modules/BeamBkgMixer/BeamBkgMixerModule.h>
11
12// framework - DataStore
13#include <framework/datastore/DataStore.h>
14#include <framework/datastore/StoreArray.h>
15#include <framework/datastore/StoreObjPtr.h>
16
17// framework aux
18#include <framework/core/ModuleParam.templateDetails.h>
19#include <framework/logging/Logger.h>
20
21// SimHits
22#include <pxd/dataobjects/PXDSimHit.h>
23#include <svd/dataobjects/SVDSimHit.h>
24#include <cdc/dataobjects/CDCSimHit.h>
25#include <top/dataobjects/TOPSimHit.h>
26#include <arich/dataobjects/ARICHSimHit.h>
27#include <ecl/dataobjects/ECLHit.h>
28#include <klm/dataobjects/KLMSimHit.h>
29#include <simulation/dataobjects/BeamBackHit.h>
30
31// MetaData
32#include <framework/dataobjects/BackgroundInfo.h>
33
34// Root
35#include <TFile.h>
36#include <TRandom3.h>
37
38//std::find
39#include <algorithm>
40
41using namespace std;
42using namespace Belle2;
43
44//-----------------------------------------------------------------
45// Register module
46//-----------------------------------------------------------------
47
48REG_MODULE(BeamBkgMixer);
49
50//-----------------------------------------------------------------
51// Implementation
52//-----------------------------------------------------------------
53
55{
56 // set module description (e.g. insert text)
57 setDescription("Beam background mixer at SimHit level that uses beam background"
58 " simulation output directly (collision files) and not ROF files. "
59 "Each background event is shifted in time randomly within "
60 "a time window specified with minTime and maxTime.");
61
62 // Add parameters
63 addParam("backgroundFiles", m_backgroundFiles,
64 "List of background (collision) files (wildcards not allowed - "
65 "use python glob.glob() to expand to list of files)");
66 addParam("minTime", m_minTime,
67 "Time window lower edge in nano seconds", -1000.0);
68 addParam("maxTime", m_maxTime,
69 "Time window upper edge in nano seconds", 800.0);
70 addParam("overallScaleFactor", m_overallScaleFactor,
71 "Overall factor to scale rates of backgrounds", 1.0);
72 addParam("scaleFactors", m_scaleFactors,
73 "Factors to scale rates of backgrounds. "
74 "Possible tag names: " + m_bgTypes.getBGTypes(),
76 addParam("components", m_components,
77 "Detector components to be included, empty list means all components",
79 addParam("wrapAround", m_wrapAround,
80 "if true wrap around events passing time window upper edge", true);
81 addParam("minTimeECL", m_minTimeECL,
82 "Time window lower edge for ECL in nano seconds", -17600.0);
83 addParam("maxTimeECL", m_maxTimeECL,
84 "Time window upper edge for ECL in nano seconds", 8500.0);
85 addParam("minTimePXD", m_minTimePXD,
86 "Time window lower edge for PXD in nano seconds", -10000.0);
87 addParam("maxTimePXD", m_maxTimePXD,
88 "Time window upper edge for PXD in nano seconds", 10000.0);
89
90 addParam("beambackhits", m_BeamBackHits,
91 "If true also add the BeamBackHits collection for the selected "
92 "subdetectors to the output file", false);
93
94 addParam("maxEdepECL", m_maxEdepECL,
95 "maximal deposited energy of ECLHit to accept BG event for mixing"
96 "(0 means accept all events)", 1.0);
97
98 addParam("cacheSize", m_cacheSize,
99 "file cache size in Mbytes. If negative, use root default", 0);
100}
101
102
104{
105
106 // included components
107
108 std::vector<std::string> components = m_components;
109 m_PXD = isComponentIncluded(components, "PXD");
110 m_SVD = isComponentIncluded(components, "SVD");
111 m_CDC = isComponentIncluded(components, "CDC");
112 m_TOP = isComponentIncluded(components, "TOP");
113 m_ARICH = isComponentIncluded(components, "ARICH");
114 m_ECL = isComponentIncluded(components, "ECL");
115 m_KLM = isComponentIncluded(components, "KLM");
116
117 // ignore these ones
118
119 isComponentIncluded(components, "MagneticField2d");
120 isComponentIncluded(components, "MagneticField3d");
121 isComponentIncluded(components, "MagneticField");
122 isComponentIncluded(components, "MagneticFieldConstant4LimitedRCDC");
123 isComponentIncluded(components, "MagneticFieldConstant4LimitedRSVD");
124 isComponentIncluded(components, "BeamPipe");
125 isComponentIncluded(components, "Cryostat");
126 isComponentIncluded(components, "FarBeamLine");
127 isComponentIncluded(components, "HeavyMetalShield");
128 isComponentIncluded(components, "COIL");
129 isComponentIncluded(components, "STR");
130 isComponentIncluded(components, "VXDService");
131
132 if (!components.empty()) {
133 std::string str;
134 for (unsigned i = 0; i < components.size(); ++i) str = str + " " + components[i];
135 B2WARNING("Unknown components:" << str);
136 }
137
138 // check files and append them to sample container
139
140 for (const auto& file : m_backgroundFiles) {
141
142 // wildcarding is not allowed anymore
143 if (TString(file.c_str()).Contains("*")) {
144 B2ERROR(file << ": wildcards are not allowed");
145 continue;
146 }
147
148 // check the file existence
149 TFile* f = TFile::Open(file.c_str(), "READ");
150 if (!f) {
151 B2ERROR(file << ": file not found");
152 continue;
153 }
154 if (!f->IsOpen()) {
155 B2ERROR(file << ": can't open file");
156 continue;
157 }
158 f->Close();
159
160 TChain persistent("persistent");
161 int nFiles = persistent.Add(file.c_str());
162 if (nFiles == 0) {
163 B2ERROR(file << ": no such files");
164 continue;
165 }
166 if (persistent.GetEntries() == 0) {
167 B2ERROR(file << ": tree 'persistent' has no entries");
168 continue;
169 }
170
171 TObject* bkgMetaData = 0; // Note: allocation left to root
172 TBranch* branchBMD = persistent.GetBranch("BackgroundMetaData");
173 if (!branchBMD) {
174 B2ERROR(file << ": branch 'BackgroundMetaData' not found");
175 continue;
176 }
177 branchBMD->SetAddress(&bkgMetaData);
178
179 std::vector<BackgroundMetaData::BG_TAG> tags;
180 std::vector<std::string> types;
181 std::vector<BackgroundMetaData::EFileType> fileTypes;
182 double realTime = 0;
183 for (unsigned k = 0; k < persistent.GetEntries(); k++) {
184 persistent.GetEntry(k);
185 const BackgroundMetaData* bgMD = static_cast<BackgroundMetaData*>(bkgMetaData);
186 tags.push_back(bgMD->getBackgroundTag());
187 types.push_back(bgMD->getBackgroundType());
188 fileTypes.push_back(bgMD->getFileType());
189 realTime += bgMD->getRealTime();
190 }
191 if (realTime <= 0) {
192 B2ERROR(file << ": invalid realTime: " << realTime);
193 continue;
194 }
195 for (unsigned i = 1; i < tags.size(); ++i) {
196 if (tags[i] != tags[0]) {
197 B2ERROR(file << ": files with mixed background types not supported");
198 continue;
199 }
200 }
201 for (unsigned i = 1; i < fileTypes.size(); ++i) {
202 if (fileTypes[i] != fileTypes[0]) {
203 B2ERROR(file << ": files with mixed file types not supported");
204 continue;
205 }
206 }
207
208 appendSample(tags[0], types[0], file, realTime, fileTypes[0]);
209
210 }
211
212
213 // set scale factors
214
215 for (auto scaleFactor : m_scaleFactors) {
216 std::string type = std::get<0>(scaleFactor);
217 if (m_bgTypes.getTag(type) == 0)
218 B2ERROR("Unknown beam background type found in 'scaleFactors': " << type << "\n"
219 "Possible are: " + m_bgTypes.getBGTypes());
220 for (auto& bkg : m_backgrounds) {
221 if (bkg.tag == m_bgTypes.getTag(type))
222 bkg.scaleFactor *= std::get<1>(scaleFactor);
223 }
224 }
225
226 // open files for reading SimHits
227
228 for (auto& bkg : m_backgrounds) {
229
230 // define TChain for reading SimHits
231 bkg.tree.reset(new TChain("tree"));
232 for (unsigned i = 0; i < bkg.fileNames.size(); ++i) {
233 bkg.numFiles += bkg.tree->Add(bkg.fileNames[i].c_str());
234 }
235
236 bkg.numEvents = bkg.tree->GetEntries();
237 bkg.rate = bkg.numEvents / bkg.realTime * bkg.scaleFactor;
238
239 if (m_cacheSize >= 0) bkg.tree->SetCacheSize(m_cacheSize * 1024 * 1024);
240
241 if (m_PXD and bkg.tree->GetBranch("PXDSimHits"))
242 bkg.tree->SetBranchAddress("PXDSimHits", &m_simHits.PXD);
243 if (m_SVD and bkg.tree->GetBranch("SVDSimHits"))
244 bkg.tree->SetBranchAddress("SVDSimHits", &m_simHits.SVD);
245 if (m_CDC and bkg.tree->GetBranch("CDCSimHits"))
246 bkg.tree->SetBranchAddress("CDCSimHits", &m_simHits.CDC);
247 if (m_TOP and bkg.tree->GetBranch("TOPSimHits"))
248 bkg.tree->SetBranchAddress("TOPSimHits", &m_simHits.TOP);
249 if (m_ARICH and bkg.tree->GetBranch("ARICHSimHits"))
250 bkg.tree->SetBranchAddress("ARICHSimHits", &m_simHits.ARICH);
251 if (m_ECL and bkg.tree->GetBranch("ECLHits"))
252 bkg.tree->SetBranchAddress("ECLHits", &m_simHits.ECL);
253 if (m_KLM and bkg.tree->GetBranch("KLMSimHits"))
254 bkg.tree->SetBranchAddress("KLMSimHits", &m_simHits.KLM);
255
256 if (m_BeamBackHits and bkg.tree->GetBranch("BeamBackHits"))
257 bkg.tree->SetBranchAddress("BeamBackHits", &m_simHits.BeamBackHits);
258
259 // print INFO
260 std::string unit(" ns");
261 double realTime = bkg.realTime;
262 if (realTime >= 1000.0) {realTime /= 1000.0; unit = " us";}
263 if (realTime >= 1000.0) {realTime /= 1000.0; unit = " ms";}
264 if (realTime >= 1000.0) {realTime /= 1000.0; unit = " s";}
265
266 B2INFO("BeamBkgMixer: " << bkg.type <<
267 " tag=" << bkg.tag <<
268 " files=" << bkg.numFiles <<
269 " events=" << bkg.numEvents <<
270 " realTime=" << realTime << unit <<
271 " scaleFactor=" << bkg.scaleFactor <<
272 " rate=" << bkg.rate * 1000 << " MHz");
273 }
274
275
276 // SimHits registration
277
278 StoreArray<PXDSimHit> pxdSimHits;
279 if (m_PXD) pxdSimHits.registerInDataStore();
280
281 StoreArray<SVDSimHit> svdSimHits;
282 if (m_SVD) svdSimHits.registerInDataStore();
283
284 StoreArray<CDCSimHit> cdcSimHits;
285 if (m_CDC) cdcSimHits.registerInDataStore();
286
287 StoreArray<TOPSimHit> topSimHits;
288 if (m_TOP) topSimHits.registerInDataStore();
289
290 StoreArray<ARICHSimHit> arichSimHits;
291 if (m_ARICH) arichSimHits.registerInDataStore();
292
293 StoreArray<ECLHit> eclHits;
294 if (m_ECL) eclHits.registerInDataStore();
295
296 StoreArray<KLMSimHit> klmSimHits;
297 if (m_KLM) klmSimHits.registerInDataStore();
298
299 StoreArray<BeamBackHit> beamBackHits;
300 if (m_BeamBackHits) beamBackHits.registerInDataStore();
301
302
303 // add BackgroundInfo to persistent tree
304
306 bkgInfo.registerInDataStore();
307 bkgInfo.create();
308 bkgInfo->setMethod(BackgroundInfo::c_Mixing);
309 bkgInfo->setComponents(m_components);
310 bkgInfo->setMinTime(m_minTime);
311 bkgInfo->setMaxTime(m_maxTime);
312 bkgInfo->setMinTimeECL(m_minTimeECL);
313 bkgInfo->setMaxTimeECL(m_maxTimeECL);
314 bkgInfo->setMinTimePXD(m_minTimePXD);
315 bkgInfo->setMaxTimePXD(m_maxTimePXD);
316 bkgInfo->setWrapAround(m_wrapAround);
317 bkgInfo->setMaxEdepECL(m_maxEdepECL);
318 for (const auto& bkg : m_backgrounds) {
320 descr.tag = bkg.tag;
321 descr.type = bkg.type;
322 descr.fileType = bkg.fileType;
323 descr.fileNames = bkg.fileNames;
324 descr.realTime = bkg.realTime;
325 descr.numEvents = bkg.numEvents;
326 descr.scaleFactor = bkg.scaleFactor;
327 descr.rate = bkg.rate;
328 descr.reused = 0;
329 bkgInfo->appendBackgroundDescr(descr);
330 }
331
332}
333
335{
336 StoreArray<PXDSimHit> pxdSimHits;
337 StoreArray<SVDSimHit> svdSimHits;
338 StoreArray<CDCSimHit> cdcSimHits;
339 StoreArray<TOPSimHit> topSimHits;
340 StoreArray<ARICHSimHit> arichSimHits;
341 StoreArray<ECLHit> eclHits;
342 StoreArray<KLMSimHit> klmSimHits;
343 StoreArray<BeamBackHit> beamBackHits;
345
346 for (auto& bkg : m_backgrounds) {
347
348 if (bkg.fileType != BackgroundMetaData::c_Usual) continue;
349
350 double mean = bkg.rate * (m_maxTime - m_minTime);
351 int nev = gRandom->Poisson(mean);
352
353 for (int iev = 0; iev < nev; iev++) {
354 double timeShift = gRandom->Rndm() * (m_maxTime - m_minTime) + m_minTime;
355 bkg.tree->GetEntry(bkg.eventCount);
356
357 if (acceptEvent(m_simHits.ECL)) {
358 addSimHits(pxdSimHits, m_simHits.PXD, timeShift, m_minTime, m_maxTime);
359 addSimHits(svdSimHits, m_simHits.SVD, timeShift, m_minTime, m_maxTime);
360 addSimHits(cdcSimHits, m_simHits.CDC, timeShift, m_minTime, m_maxTime);
361 addSimHits(topSimHits, m_simHits.TOP, timeShift, m_minTime, m_maxTime);
362 addSimHits(arichSimHits, m_simHits.ARICH, timeShift, m_minTime, m_maxTime);
363 addSimHits(eclHits, m_simHits.ECL, timeShift, m_minTime, m_maxTime);
364 addSimHits(klmSimHits, m_simHits.KLM, timeShift, m_minTime, m_maxTime);
365 addBeamBackHits(beamBackHits, m_simHits.BeamBackHits, timeShift,
367 } else {
368 iev--;
369 std::string message = "BeamBkgMixer: event " + to_string(bkg.eventCount)
370 + " of " + bkg.type + " rejected due to large energy deposit in ECL";
371 m_rejected[message] += 1;
373 if (m_rejectedCount < 10) {
374 B2INFO("BeamBkgMixer: event rejected due to large energy deposit in ECL");
375 } else if (m_rejectedCount == 10) {
376 B2INFO("BeamBkgMixer: event rejected due to large energy deposit in ECL "
377 << "(message will be suppressed now)");
378 }
379 }
380
381 bkg.eventCount++;
382 if (bkg.eventCount >= bkg.numEvents) {
383 bkg.eventCount = 0;
384 std::string message = "BeamBkgMixer: events of " + bkg.type + " will be reused";
385 m_reused[message] += 1;
386 if (m_reused[message] == 1) B2INFO(message);
387 bkgInfo->incrementReusedCounter(bkg.index);
388 }
389 }
390 }
391
392
393 for (auto& bkg : m_backgrounds) {
394
395 if (bkg.fileType != BackgroundMetaData::c_ECL) continue;
396
397 double mean = bkg.rate * (m_maxTimeECL - m_minTimeECL);
398 int nev = gRandom->Poisson(mean);
399
400 for (int iev = 0; iev < nev; iev++) {
401 double timeShift = gRandom->Rndm() * (m_maxTimeECL - m_minTimeECL) + m_minTimeECL;
402 if (timeShift > m_minTime and timeShift < m_maxTime) continue;
403 bkg.tree->GetEntry(bkg.eventCount);
404
405 if (acceptEvent(m_simHits.ECL)) {
406 double minTime = m_minTimeECL;
407 double maxTime = m_maxTimeECL;
408 if (timeShift <= m_minTime) {
409 maxTime = m_minTime;
410 } else {
411 minTime = m_maxTime;
412 }
413 addSimHits(eclHits, m_simHits.ECL, timeShift, minTime, maxTime);
414 } else {
415 iev--;
416 std::string message = "BeamBkgMixer: event " + to_string(bkg.eventCount)
417 + " of " + bkg.type + " rejected due to large energy deposit in ECL";
418 m_rejected[message] += 1;
420 if (m_rejectedCount < 10) {
421 B2INFO("BeamBkgMixer: event rejected due to large energy deposit in ECL");
422 } else if (m_rejectedCount == 10) {
423 B2INFO("BeamBkgMixer: event rejected due to large energy deposit in ECL "
424 << "(message will be suppressed now)");
425 }
426 }
427
428 bkg.eventCount++;
429 if (bkg.eventCount >= bkg.numEvents) {
430 bkg.eventCount = 0;
431 std::string message = "BeamBkgMixer: events of " + bkg.type + " will be reused";
432 m_reused[message] += 1;
433 if (m_reused[message] == 1) B2INFO(message);
434 bkgInfo->incrementReusedCounter(bkg.index);
435 }
436 }
437
438 }
439
440
441 for (auto& bkg : m_backgrounds) {
442
443 if (bkg.fileType != BackgroundMetaData::c_PXD) continue;
444
445 double mean = bkg.rate * (m_maxTimePXD - m_minTimePXD);
446 int nev = gRandom->Poisson(mean);
447
448 for (int iev = 0; iev < nev; iev++) {
449 double timeShift = gRandom->Rndm() * (m_maxTimePXD - m_minTimePXD) + m_minTimePXD;
450 if (timeShift > m_minTime and timeShift < m_maxTime) continue;
451 bkg.tree->GetEntry(bkg.eventCount);
452
453 double minTime = m_minTimePXD;
454 double maxTime = m_maxTimePXD;
455 if (timeShift <= m_minTime) {
456 maxTime = m_minTime;
457 } else {
458 minTime = m_maxTime;
459 }
460 addSimHits(pxdSimHits, m_simHits.PXD, timeShift, minTime, maxTime);
461
462 bkg.eventCount++;
463 if (bkg.eventCount >= bkg.numEvents) {
464 bkg.eventCount = 0;
465 std::string message = "BeamBkgMixer: events of " + bkg.type + " will be reused";
466 m_reused[message] += 1;
467 if (m_reused[message] == 1) B2INFO(message);
468 bkgInfo->incrementReusedCounter(bkg.index);
469 }
470 }
471
472 }
473
474}
475
476
478{
479
480 B2INFO("BeamBkgMixer - reused samples:");
481 for (const auto& message : m_reused) {
482 B2INFO(message.first << "(occurred " << message.second << " times)");
483 }
484 B2INFO("BeamBkgMixer - rejected events:");
485 for (const auto& message : m_rejected) {
486 B2INFO(message.first << "(occurred " << message.second << " times)");
487 }
488
489 for (auto& bkg : m_backgrounds) {
490 bkg.tree.reset();
491 }
492
493}
494
495
496bool BeamBkgMixerModule::isComponentIncluded(std::vector<std::string>& components,
497 const std::string& component)
498{
499 if (m_components.empty()) return true;
500 auto iterator = std::find(components.begin(), components.end(), component);
501 if (iterator != components.end()) {
502 components.erase(iterator);
503 return true;
504 }
505 return false;
506}
507
508
510 const std::string& type,
511 const std::string& fileName,
512 double realTime,
514{
515 for (auto& bkg : m_backgrounds) {
516 if (tag == bkg.tag and fileType == bkg.fileType) {
517 bkg.fileNames.push_back(fileName);
518 bkg.realTime += realTime;
519 return;
520 }
521 }
522 std::string ftype = type;
523 if (fileType == BackgroundMetaData::c_ECL) ftype += "(ECL)";
524 if (fileType == BackgroundMetaData::c_PXD) ftype += "(PXD)";
525 unsigned index = m_backgrounds.size();
526 m_backgrounds.push_back(BkgFiles(tag, ftype, fileName, realTime,
527 m_overallScaleFactor, fileType, index));
528}
529
530
531bool BeamBkgMixerModule::acceptEvent(TClonesArray* cloneArrayECL)
532{
533 if (!cloneArrayECL) return true;
534 if (m_maxEdepECL == 0) return true;
535
536 int numEntries = cloneArrayECL->GetEntriesFast();
537 for (int i = 0; i < numEntries; i++) {
538 const ECLHit* simHit = static_cast<ECLHit*>(cloneArrayECL->AddrAt(i));
539 if (simHit->getEnergyDep() > m_maxEdepECL) return false;
540 }
541 return true;
542}
Metadata information about the beam background file.
EFileType
Enum for BG file types.
float getRealTime() const
Returns real time that corresponds to this background sample.
EFileType getFileType() const
Returns file type.
const std::string & getBackgroundType() const
Returns the type of background.
BG_TAG
Enum for background tags.
BG_TAG getBackgroundTag() const
Returns background tag value.
std::map< std::string, int > m_reused
messages: rejused events
double m_maxEdepECL
maximal allowed deposited energy in ECL
std::vector< BkgFiles > m_backgrounds
container for background samples
double m_maxTimeECL
maximal time shift of background event for ECL
std::map< std::string, int > m_rejected
messages: rejected events
bool isComponentIncluded(std::vector< std::string > &components, const std::string &component)
Returns true if a component is found in components or the list is empty.
bool m_ECL
true if found in m_components
std::vector< std::string > m_components
detector components
void addBeamBackHits(StoreArray< HIT > &hits, TClonesArray *cloneArray, double timeShift, double minTime, double maxTime)
functions that add BeamBackHits to those in the DataStore
double m_minTimePXD
minimal time shift of background event for PXD
bool m_PXD
true if found in m_components
void addSimHits(StoreArray< SIMHIT > &simHits, TClonesArray *cloneArray, double timeShift, double minTime, double maxTime)
functions that add background SimHits to those in the DataStore
background::BeamBGTypes m_bgTypes
defined BG types
std::vector< std::string > m_backgroundFiles
names of beam background files
virtual void initialize() override
Initialize the Module.
bool m_CDC
true if found in m_components
double m_maxTime
maximal time shift of background event
virtual void event() override
Event processor.
double m_minTime
minimal time shift of background event
bool m_wrapAround
if true wrap around events in the tail after maxTime
double m_maxTimePXD
maximal time shift of background event for PXD
int m_rejectedCount
counter for suppressing "rejected event" messages
virtual void terminate() override
Termination action.
BkgHits m_simHits
input event buffer
int m_cacheSize
file cache size in Mbytes
bool m_BeamBackHits
if true add also background hits
bool m_ARICH
true if found in m_components
double m_overallScaleFactor
overall scale factor
void appendSample(BackgroundMetaData::BG_TAG bkgTag, const std::string &bkgType, const std::string &fileName, double realTime, BackgroundMetaData::EFileType fileTyp)
appends background sample to m_backgrounds
bool acceptEvent(TClonesArray *cloneArrayECL)
Checks for deposited energy of ECLHits and returns true if Edep < m_maxEdepECL.
double m_minTimeECL
minimal time shift of background event for ECL
std::vector< std::tuple< std::string, double > > m_scaleFactors
scale factors
bool m_KLM
true if found in m_components
bool m_SVD
true if found in m_components
bool m_TOP
true if found in m_components
@ c_Persistent
Object is available during entire execution time.
Definition DataStore.h:60
Class to store simulated hits which equate to average of ECLSImHit on crystals input for digitization...
Definition ECLHit.h:25
double getEnergyDep() const
Get deposit energy.
Definition ECLHit.h:70
void setDescription(const std::string &description)
Sets the description of the module.
Definition Module.cc:214
Module()
Constructor.
Definition Module.cc:30
bool registerInDataStore(DataStore::EStoreFlags storeFlags=DataStore::c_WriteOut)
Register the object/array in the DataStore.
bool create(bool replace=false)
Create a default object in the data store.
Accessor to arrays stored in the data store.
Definition StoreArray.h:113
Type-safe access to single objects in the data store.
Definition StoreObjPtr.h:96
void addParam(const std::string &name, T &paramVariable, const std::string &description, const T &defaultValue)
Adds a new parameter to the module.
Definition Module.h:559
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
Definition Module.h:649
Abstract base class for different kinds of events.
STL namespace.
Structure for background description.
structure to hold samples of a particular background type