CbmRoot
Loading...
Searching...
No Matches
CbmMcbm2019TimeWinEventBuilderAlgo Class Reference

#include <CbmMcbm2019TimeWinEventBuilderAlgo.h>

Collaboration diagram for CbmMcbm2019TimeWinEventBuilderAlgo:
[legend]

Public Member Functions

 CbmMcbm2019TimeWinEventBuilderAlgo ()
 CBM headers.
 
 CbmMcbm2019TimeWinEventBuilderAlgo (const CbmMcbm2019TimeWinEventBuilderAlgo &)=delete
 
CbmMcbm2019TimeWinEventBuilderAlgo operator= (const CbmMcbm2019TimeWinEventBuilderAlgo &)=delete
 
 ~CbmMcbm2019TimeWinEventBuilderAlgo ()
 
Bool_t InitAlgo ()
 
void ProcessTs ()
 
void Finish ()
 
void SetFillHistos (Bool_t var)
 
void ResetHistograms (Bool_t bResetTime=kTRUE)
 
void SetReferenceDetector (ECbmModuleId refDet, ECbmDataType dataTypeIn, std::string sNameIn, UInt_t uTriggerMinDigisIn=0, Int_t iTriggerMaxDigisIn=-1, Double_t fdTimeWinBegIn=-100, Double_t fdTimeWinEndIn=100)
 
void AddDetector (ECbmModuleId selDet, ECbmDataType dataTypeIn, std::string sNameIn, UInt_t uTriggerMinDigisIn=0, Int_t iTriggerMaxDigisIn=-1, Double_t fdTimeWinBegIn=-100, Double_t fdTimeWinEndIn=100)
 
void SetReferenceDetector (EventBuilderDetector refDetIn)
 
void AddDetector (EventBuilderDetector selDet)
 
void RemoveDetector (EventBuilderDetector selDet)
 
void SetTriggerMinNumber (ECbmModuleId selDet, UInt_t uVal)
 
void SetTriggerMaxNumber (ECbmModuleId selDet, Int_t iVal)
 
void SetTriggerWindow (ECbmModuleId selDet, Double_t dWinBeg, Double_t dWinEnd)
 
void SetTsParameters (Double_t dTsStartTime, Double_t dTsLength, Double_t dTsOverLength)
 
void SetEventOverlapMode (EOverlapMode mode)
 Control flags.
 
void SetIgnoreTsOverlap (Bool_t bFlagIn=kTRUE)
 
void ChangeMuchBeamtimeDigiFlag (Bool_t bFlagIn=kFALSE)
 
void AddHistoToVector (TNamed *pointer, std::string sFolder="")
 For monitor algos.
 
std::vector< std::pair< TNamed *, std::string > > GetHistoVector ()
 
void AddCanvasToVector (TCanvas *pointer, std::string sFolder="")
 
std::vector< std::pair< TCanvas *, std::string > > GetCanvasVector ()
 
std::vector< CbmEvent * > & GetEventVector ()
 Data output access.
 
void ClearEventVector ()
 

Private Member Functions

Bool_t CheckDataAvailable (EventBuilderDetector &det)
 Internal methods.
 
void InitTs ()
 
void BuildEvents ()
 
void CreateHistograms ()
 
void FillHistos ()
 
template<class DigiSeed >
void LoopOnSeeds ()
 
void CheckSeed (Double_t dSeedTime, UInt_t uSeedDigiIdx)
 
template<class DigiCheck >
void SearchMatches (Double_t dSeedTime, EventBuilderDetector &detMatch)
 
void AddDigiToEvent (EventBuilderDetector &det, Int_t uIdx)
 
Bool_t HasTrigger (CbmEvent *)
 
Bool_t CheckTriggerConditions (CbmEvent *event, EventBuilderDetector &det)
 
void UpdateTimeWinBoundariesExtrema ()
 
void UpdateWidestTimeWinRange ()
 
 ClassDefNV (CbmMcbm2019TimeWinEventBuilderAlgo, 1)
 Save previous event last digi time information.
 

Private Attributes

Bool_t fbIgnoreTsOverlap = kFALSE
 
Bool_t fbFillHistos {kTRUE}
 Ignore data in Overlap part of the TS.
 
Bool_t fbUseMuchBeamtimeDigi = kTRUE
 Switch ON/OFF filling of histograms.
 
EOverlapMode fOverMode {EOverlapMode::AllowOverlap}
 Event building mode and detectors selection.
 
EventBuilderDetector fRefDet = EventBuilderDetector(ECbmModuleId::kBmon, ECbmDataType::kBmonDigi, "Bmon")
 
std::vector< EventBuilderDetectorfvDets
 
Double_t fdEarliestTimeWinBeg = kdDefaultTimeWinBeg
 
Double_t fdLatestTimeWinEnd = kdDefaultTimeWinEnd
 
Double_t fdWidestTimeWinRange = kdDefaultTimeWinEnd - kdDefaultTimeWinBeg
 
Double_t fdTsStartTime = -1
 
Double_t fdTsLength = -1
 
Double_t fdTsOverLength = -1
 
CbmDigiManagerfDigiMan = nullptr
 
const std::vector< CbmTofDigi > * fBmonDigiVec = nullptr
 
TClonesArray * fTimeSliceMetaDataArray = nullptr
 
const TimesliceMetaDatapTsMetaData = nullptr
 
CbmEventfCurrentEvent = nullptr
 Data ouptut.
 
std::vector< CbmEvent * > fEventVector = {}
 pointer to the event which is currently build
 
std::vector< std::pair< TNamed *, std::string > > fvpAllHistoPointers
 vector with all created events
 
std::vector< std::pair< TCanvas *, std::string > > fvpAllCanvasPointers
 Vector of pointers to histograms + optional folder name.
 
TH1 * fhEventTime = nullptr
 Vector of pointers to canvases + optional folder name.
 
TH1 * fhEventDt = nullptr
 histogram with the seed time of the events
 
TH1 * fhEventSize = nullptr
 histogram with the interval in seed time of consecutive events
 
TH2 * fhNbDigiPerEvtTime = nullptr
 histogram with the nb of all digis in the event
 
std::vector< TH2 * > fvhNbDigiPerEvtTimeDet
 histogram with the nb of all digis per event vs seed time of the events
 
UInt_t fuCurEv = 0
 histograms with the nb of digis in each detector per event vs seed time of the events
 
UInt_t fuErrors = 0
 Event Counter.
 
UInt_t fuNrTs = 0
 Error Counter.
 
Double_t fdPrevEvtTime = 0.
 Timeslice Counter.
 
Double_t fdPrevEvtEndTime = 0.
 Save previous time information.
 

Static Private Attributes

static constexpr Double_t kdDefaultTimeWinBeg = -100.0
 Constants.
 
static constexpr Double_t kdDefaultTimeWinEnd = 100.0
 

Detailed Description

Definition at line 99 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Constructor & Destructor Documentation

◆ CbmMcbm2019TimeWinEventBuilderAlgo() [1/2]

CbmMcbm2019TimeWinEventBuilderAlgo::CbmMcbm2019TimeWinEventBuilderAlgo ( )

CBM headers.

Default constructor

FAIRROOT headers FAIRSOFT headers (geant, boost, ...) C/C++ headers

Definition at line 35 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

◆ CbmMcbm2019TimeWinEventBuilderAlgo() [2/2]

CbmMcbm2019TimeWinEventBuilderAlgo::CbmMcbm2019TimeWinEventBuilderAlgo ( const CbmMcbm2019TimeWinEventBuilderAlgo & )
delete

◆ ~CbmMcbm2019TimeWinEventBuilderAlgo()

CbmMcbm2019TimeWinEventBuilderAlgo::~CbmMcbm2019TimeWinEventBuilderAlgo ( )

Destructor

Definition at line 38 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

Member Function Documentation

◆ AddCanvasToVector()

void CbmMcbm2019TimeWinEventBuilderAlgo::AddCanvasToVector ( TCanvas * pointer,
std::string sFolder = "" )
inline

Definition at line 156 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

References fvpAllCanvasPointers.

◆ AddDetector() [1/2]

void CbmMcbm2019TimeWinEventBuilderAlgo::AddDetector ( ECbmModuleId selDet,
ECbmDataType dataTypeIn,
std::string sNameIn,
UInt_t uTriggerMinDigisIn = 0,
Int_t iTriggerMaxDigisIn = -1,
Double_t fdTimeWinBegIn = -100,
Double_t fdTimeWinEndIn = 100 )

FIXME: Deprecated method to be removed later. For now create temp object.

Definition at line 696 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References AddDetector().

Referenced by AddDetector(), CbmMcbm2019TimeWinEventBuilderTask::AddDetector(), and CbmDeviceMcbmEventBuilderWin::InitTask().

◆ AddDetector() [2/2]

void CbmMcbm2019TimeWinEventBuilderAlgo::AddDetector ( EventBuilderDetector selDet)

Loop on selection detectors

Update the variables storing the earliest and latest time window boundaries

Update the variable storing the size if widest time window for overlap detection

Definition at line 746 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References fRefDet, fvDets, EventBuilderDetector::sName, UpdateTimeWinBoundariesExtrema(), and UpdateWidestTimeWinRange().

◆ AddDigiToEvent()

void CbmMcbm2019TimeWinEventBuilderAlgo::AddDigiToEvent ( EventBuilderDetector & det,
Int_t uIdx )
private

◆ AddHistoToVector()

void CbmMcbm2019TimeWinEventBuilderAlgo::AddHistoToVector ( TNamed * pointer,
std::string sFolder = "" )
inline

For monitor algos.

Definition at line 151 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

References fvpAllHistoPointers.

Referenced by CreateHistograms().

◆ BuildEvents()

void CbmMcbm2019TimeWinEventBuilderAlgo::BuildEvents ( )
private

Call LoopOnSeed with proper template argument

Definition at line 163 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References EventBuilderDetector::detId, fbUseMuchBeamtimeDigi, fRefDet, kBmon, kMuch, kPsd, kRich, kSts, kTof, kTrd, LoopOnSeeds(), and EventBuilderDetector::sName.

Referenced by ProcessTs().

◆ ChangeMuchBeamtimeDigiFlag()

void CbmMcbm2019TimeWinEventBuilderAlgo::ChangeMuchBeamtimeDigiFlag ( Bool_t bFlagIn = kFALSE)
inline

◆ CheckDataAvailable()

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::CheckDataAvailable ( EventBuilderDetector & det)
private

◆ CheckSeed()

void CbmMcbm2019TimeWinEventBuilderAlgo::CheckSeed ( Double_t dSeedTime,
UInt_t uSeedDigiIdx )
private

If previous event valid and event overlap not allowed, check if we are in overlap and react accordingly

Within overlap range

No overlap allowed => reject

Merge overlap mode => do nothing and go on filling current event

In allow overlap mode => reject only if reference det is in overlap to avoid cloning events due to single seed cluster

Out of overlap range or in overlap allowed mode => store previous event if not empty and create new one

TODO: store start time of current event ?

If window open for reference detector, search for other reference Digis matching it Otherwise only add the current seed

Also add the seed if the window starts after the seed

Search for matches for each detector in selection list

Check if event is filling trigger conditions and clear it if not

In case of NoOverlap or MergeOverlap, we can and should start checking the next window from end of current window in order to save CPU and avoid duplicating

Update reference detector

Loop on selection detectors

delete does NOT set a pointer to nullptr...

Definition at line 283 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References AddDigiToEvent(), AllowOverlap, EventBuilderDetector::detId, fbUseMuchBeamtimeDigi, fCurrentEvent, fdPrevEvtEndTime, fdPrevEvtTime, EventBuilderDetector::fdTimeWinBeg, EventBuilderDetector::fdTimeWinEnd, fdWidestTimeWinRange, fEventVector, fOverMode, fRefDet, fuCurEv, EventBuilderDetector::fuEndIndex, EventBuilderDetector::fuStartIndex, fvDets, EventBuilderDetector::GetTimeWinRange(), HasTrigger(), kBmon, kMuch, kPsd, kRich, kSts, kTof, kTrd, MergeOverlap, NoOverlap, SearchMatches(), CbmEvent::SetEndTime(), and EventBuilderDetector::sName.

Referenced by LoopOnSeeds().

◆ CheckTriggerConditions()

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::CheckTriggerConditions ( CbmEvent * event,
EventBuilderDetector & det )
private

Check if both Trigger conditions disabled for this detector

Check if detector present

FIXME: special case to be removed once Bmon supported by DigiManager

Check trigger rejection by minimal number or absence

Check trigger rejection by maximal number

Definition at line 547 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References EventBuilderDetector::dataType, EventBuilderDetector::detId, fBmonDigiVec, fDigiMan, EventBuilderDetector::fiTriggerMaxDigis, EventBuilderDetector::fuTriggerMinDigis, CbmDigiManager::IsPresent(), kBmon, and EventBuilderDetector::sName.

Referenced by HasTrigger().

◆ ClassDefNV()

CbmMcbm2019TimeWinEventBuilderAlgo::ClassDefNV ( CbmMcbm2019TimeWinEventBuilderAlgo ,
1  )
private

Save previous event last digi time information.

◆ ClearEventVector()

void CbmMcbm2019TimeWinEventBuilderAlgo::ClearEventVector ( )

Need to delete the object the pointer points to first

Definition at line 111 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References counter, and fEventVector.

Referenced by CbmMcbm2019TimeWinEventBuilderTask::FillOutput(), and CbmDeviceMcbmEventBuilderWin::HandleData().

◆ CreateHistograms()

void CbmMcbm2019TimeWinEventBuilderAlgo::CreateHistograms ( )
private

FIXME: Disable clang formatting for histograms declaration for now

Loop on selection detectors

In case name not provided, do not create the histo to avoid name conflicts!

FIXME: Re-enable clang formatting after histograms declaration

Definition at line 590 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References AddHistoToVector(), fhEventDt, fhEventSize, fhEventTime, fhNbDigiPerEvtTime, fvDets, and fvhNbDigiPerEvtTimeDet.

Referenced by InitAlgo().

◆ FillHistos()

void CbmMcbm2019TimeWinEventBuilderAlgo::FillHistos ( )
private

Loop on selection detectors

Definition at line 645 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References fEventVector, fhEventDt, fhEventSize, fhEventTime, fhNbDigiPerEvtTime, fvDets, and fvhNbDigiPerEvtTimeDet.

Referenced by ProcessTs().

◆ Finish()

void CbmMcbm2019TimeWinEventBuilderAlgo::Finish ( )

Finish called at the end of the run

Definition at line 124 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References fuErrors.

Referenced by CbmMcbm2019TimeWinEventBuilderTask::Finish().

◆ GetCanvasVector()

std::vector< std::pair< TCanvas *, std::string > > CbmMcbm2019TimeWinEventBuilderAlgo::GetCanvasVector ( )
inline

◆ GetEventVector()

std::vector< CbmEvent * > & CbmMcbm2019TimeWinEventBuilderAlgo::GetEventVector ( )
inline

◆ GetHistoVector()

std::vector< std::pair< TNamed *, std::string > > CbmMcbm2019TimeWinEventBuilderAlgo::GetHistoVector ( )
inline

◆ HasTrigger()

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::HasTrigger ( CbmEvent * event)
private

Check first reference detector

Loop on selection detectors

All Ok, trigger is there

Definition at line 531 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References CheckTriggerConditions(), fRefDet, and fvDets.

Referenced by CheckSeed().

◆ InitAlgo()

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::InitAlgo ( )

Initiliazation at the beginning of a run

Check if reference detector data are available

Check if data for detectors in selection list are available

Access the TS metadata to know TS start time if needed

Definition at line 41 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References CheckDataAvailable(), CreateHistograms(), fbFillHistos, fbUseMuchBeamtimeDigi, fDigiMan, fdTsLength, fdTsOverLength, fdTsStartTime, fRefDet, fTimeSliceMetaDataArray, fvDets, CbmDigiManager::Init(), CbmDigiManager::Instance(), and CbmDigiManager::UseMuchBeamTimeDigi().

Referenced by CbmMcbm2019TimeWinEventBuilderTask::Init(), and CbmDeviceMcbmEventBuilderWin::InitTask().

◆ InitTs()

void CbmMcbm2019TimeWinEventBuilderAlgo::InitTs ( )
private

Reset TS based variables (analysis per TS = no building over the border) Reference detector

Loop on detectors in selection list

Definition at line 150 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References fRefDet, EventBuilderDetector::fuEndIndex, EventBuilderDetector::fuStartIndex, and fvDets.

Referenced by ProcessTs().

◆ LoopOnSeeds()

template<class DigiSeed >
void CbmMcbm2019TimeWinEventBuilderAlgo::LoopOnSeeds ( )
private

Access the TS metadata if needed to know TS start time and overlap size

Print warning in first TS if time window borders out of potential overlap

Define an acceptance window for the seeds in order to use the overlap part of the TS to avoid incomplete events

Loop on size of vector

Loop on size of vector

Check Seed and build event if needed

Loop on size of vector

Check that _entry is not out of range

Check if seed in acceptance window

Check Seed and build event if needed

Definition at line 207 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References CheckSeed(), EventBuilderDetector::detId, dTsStartTime, fbIgnoreTsOverlap, fBmonDigiVec, fdEarliestTimeWinBeg, fDigiMan, fdLatestTimeWinEnd, fdTsLength, fdTsOverLength, fdTsStartTime, fdWidestTimeWinRange, fRefDet, fTimeSliceMetaDataArray, fuNrTs, CbmDigiManager::Get(), CbmDigiManager::GetNofDigis(), TimesliceMetaData::GetOverlapDuration(), TimesliceMetaData::GetOverlapStartTime(), TimesliceMetaData::GetStartTime(), kBmon, and pTsMetaData.

Referenced by BuildEvents().

◆ operator=()

CbmMcbm2019TimeWinEventBuilderAlgo CbmMcbm2019TimeWinEventBuilderAlgo::operator= ( const CbmMcbm2019TimeWinEventBuilderAlgo & )
delete

◆ ProcessTs()

void CbmMcbm2019TimeWinEventBuilderAlgo::ProcessTs ( )

Executed for each TS.

Store last event with trigger if not done by other seed

TODO: store start time of current event ?

Prevent building over TS edge

Definition at line 85 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References BuildEvents(), fbFillHistos, fCurrentEvent, fdPrevEvtEndTime, fEventVector, FillHistos(), fuCurEv, fuNrTs, InitTs(), and CbmEvent::SetEndTime().

Referenced by CbmMcbm2019TimeWinEventBuilderTask::Exec(), and CbmDeviceMcbmEventBuilderWin::HandleData().

◆ RemoveDetector()

void CbmMcbm2019TimeWinEventBuilderAlgo::RemoveDetector ( EventBuilderDetector selDet)

◆ ResetHistograms()

void CbmMcbm2019TimeWinEventBuilderAlgo::ResetHistograms ( Bool_t bResetTime = kTRUE)

◆ SearchMatches()

template<class DigiCheck >
void CbmMcbm2019TimeWinEventBuilderAlgo::SearchMatches ( Double_t dSeedTime,
EventBuilderDetector & detMatch )
private

This algo relies on time sorted vectors for the selected detectors

Check the Digis until out of window

Loop on size of vector

Loop on size of vector

Check if within time window, update start/stop indices if needed

Store as end the first digi out of window to avoid double counting in case of merged overlap event mode

catch the case where we reach the end of the vector before being out of the time window

Loop on size of vector

Check that _entry is not out of range

Check if within time window, update start/stop indices if needed

Store as end the first digi out of window to avoid double counting in case of merged overlap event mode

catch the case where we reach the end of the vector before being out of the time window

Update the StartIndex and EndIndex for the next event seed

Definition at line 446 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References AddDigiToEvent(), EventBuilderDetector::detId, fBmonDigiVec, fDigiMan, fdPrevEvtEndTime, EventBuilderDetector::fdTimeWinBeg, EventBuilderDetector::fdTimeWinEnd, EventBuilderDetector::fuEndIndex, EventBuilderDetector::fuStartIndex, CbmDigiManager::Get(), CbmDigiManager::GetNofDigis(), kBmon, and EventBuilderDetector::sName.

Referenced by CheckSeed().

◆ SetEventOverlapMode()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetEventOverlapMode ( EOverlapMode mode)
inline

◆ SetFillHistos()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetFillHistos ( Bool_t var)
inline

◆ SetIgnoreTsOverlap()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetIgnoreTsOverlap ( Bool_t bFlagIn = kTRUE)
inline

◆ SetReferenceDetector() [1/2]

void CbmMcbm2019TimeWinEventBuilderAlgo::SetReferenceDetector ( ECbmModuleId refDet,
ECbmDataType dataTypeIn,
std::string sNameIn,
UInt_t uTriggerMinDigisIn = 0,
Int_t iTriggerMaxDigisIn = -1,
Double_t fdTimeWinBegIn = -100,
Double_t fdTimeWinEndIn = 100 )

FIXME: Deprecated method to be removed later. For now create temp object.

Definition at line 686 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References SetReferenceDetector().

Referenced by CbmDeviceMcbmEventBuilderWin::InitTask(), SetReferenceDetector(), and CbmMcbm2019TimeWinEventBuilderTask::SetReferenceDetector().

◆ SetReferenceDetector() [2/2]

void CbmMcbm2019TimeWinEventBuilderAlgo::SetReferenceDetector ( EventBuilderDetector refDetIn)

Loop on selection detectors

Update the variables storing the earliest and latest time window boundaries

Update the variable storing the size if widest time window for overlap detection

Definition at line 707 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References fRefDet, fvDets, RemoveDetector(), EventBuilderDetector::sName, UpdateTimeWinBoundariesExtrema(), and UpdateWidestTimeWinRange().

◆ SetTriggerMaxNumber()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetTriggerMaxNumber ( ECbmModuleId selDet,
Int_t iVal )

◆ SetTriggerMinNumber()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetTriggerMinNumber ( ECbmModuleId selDet,
UInt_t uVal )

◆ SetTriggerWindow()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetTriggerWindow ( ECbmModuleId selDet,
Double_t dWinBeg,
Double_t dWinEnd )

Check if valid time window: end strictly after beginning

Check first if reference detector

Loop on selection detectors

Update the variables storing the earliest and latest time window boundaries

Update the variable storing the size if widest time window for overlap detection

Definition at line 838 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References EventBuilderDetector::detId, EventBuilderDetector::fdTimeWinBeg, EventBuilderDetector::fdTimeWinEnd, fRefDet, fvDets, UpdateTimeWinBoundariesExtrema(), and UpdateWidestTimeWinRange().

Referenced by CbmDeviceMcbmEventBuilderWin::InitTask(), and CbmMcbm2019TimeWinEventBuilderTask::SetTriggerWindow().

◆ SetTsParameters()

void CbmMcbm2019TimeWinEventBuilderAlgo::SetTsParameters ( Double_t dTsStartTime,
Double_t dTsLength,
Double_t dTsOverLength )
inline

◆ UpdateTimeWinBoundariesExtrema()

void CbmMcbm2019TimeWinEventBuilderAlgo::UpdateTimeWinBoundariesExtrema ( )
private

Initialize with reference detector

Loop on selection detectors

Definition at line 876 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References fdEarliestTimeWinBeg, fdLatestTimeWinEnd, EventBuilderDetector::fdTimeWinBeg, EventBuilderDetector::fdTimeWinEnd, fRefDet, and fvDets.

Referenced by AddDetector(), SetReferenceDetector(), and SetTriggerWindow().

◆ UpdateWidestTimeWinRange()

void CbmMcbm2019TimeWinEventBuilderAlgo::UpdateWidestTimeWinRange ( )
private

Initialize with reference detector

Loop on selection detectors

Definition at line 888 of file CbmMcbm2019TimeWinEventBuilderAlgo.cxx.

References EventBuilderDetector::fdTimeWinBeg, EventBuilderDetector::fdTimeWinEnd, fdWidestTimeWinRange, fRefDet, and fvDets.

Referenced by AddDetector(), SetReferenceDetector(), and SetTriggerWindow().

Member Data Documentation

◆ fbFillHistos

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::fbFillHistos {kTRUE}
private

Ignore data in Overlap part of the TS.

Definition at line 194 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by InitAlgo(), ProcessTs(), and SetFillHistos().

◆ fbIgnoreTsOverlap

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::fbIgnoreTsOverlap = kFALSE
private

User parameters Control flags

Definition at line 193 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by LoopOnSeeds(), and SetIgnoreTsOverlap().

◆ fBmonDigiVec

const std::vector<CbmTofDigi>* CbmMcbm2019TimeWinEventBuilderAlgo::fBmonDigiVec = nullptr
private

◆ fbUseMuchBeamtimeDigi

Bool_t CbmMcbm2019TimeWinEventBuilderAlgo::fbUseMuchBeamtimeDigi = kTRUE
private

Switch ON/OFF filling of histograms.

Definition at line 195 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by BuildEvents(), ChangeMuchBeamtimeDigiFlag(), CheckSeed(), and InitAlgo().

◆ fCurrentEvent

CbmEvent* CbmMcbm2019TimeWinEventBuilderAlgo::fCurrentEvent = nullptr
private

Data ouptut.

Definition at line 225 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by AddDigiToEvent(), CheckSeed(), and ProcessTs().

◆ fdEarliestTimeWinBeg

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdEarliestTimeWinBeg = kdDefaultTimeWinBeg
private

◆ fDigiMan

CbmDigiManager* CbmMcbm2019TimeWinEventBuilderAlgo::fDigiMan = nullptr
private

Data input FIXME: usage of CbmDigiManager in FairMq context?!? => Maybe by registering vector (or vector reference) to ioman in Device?

Definition at line 219 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CheckDataAvailable(), CheckTriggerConditions(), InitAlgo(), LoopOnSeeds(), and SearchMatches().

◆ fdLatestTimeWinEnd

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdLatestTimeWinEnd = kdDefaultTimeWinEnd
private

◆ fdPrevEvtEndTime

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdPrevEvtEndTime = 0.
private

Save previous time information.

Definition at line 256 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CheckSeed(), ProcessTs(), and SearchMatches().

◆ fdPrevEvtTime

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdPrevEvtTime = 0.
private

Timeslice Counter.

Definition at line 255 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CheckSeed().

◆ fdTsLength

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdTsLength = -1
private

Definition at line 213 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by InitAlgo(), LoopOnSeeds(), and SetTsParameters().

◆ fdTsOverLength

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdTsOverLength = -1
private

Definition at line 214 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by InitAlgo(), LoopOnSeeds(), and SetTsParameters().

◆ fdTsStartTime

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdTsStartTime = -1
private

Definition at line 212 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by InitAlgo(), LoopOnSeeds(), and SetTsParameters().

◆ fdWidestTimeWinRange

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::fdWidestTimeWinRange = kdDefaultTimeWinEnd - kdDefaultTimeWinBeg
private

◆ fEventVector

std::vector<CbmEvent*> CbmMcbm2019TimeWinEventBuilderAlgo::fEventVector = {}
private

pointer to the event which is currently build

Definition at line 226 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CheckSeed(), ClearEventVector(), FillHistos(), GetEventVector(), and ProcessTs().

◆ fhEventDt

TH1* CbmMcbm2019TimeWinEventBuilderAlgo::fhEventDt = nullptr
private

histogram with the seed time of the events

Definition at line 245 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CreateHistograms(), FillHistos(), and ResetHistograms().

◆ fhEventSize

TH1* CbmMcbm2019TimeWinEventBuilderAlgo::fhEventSize = nullptr
private

histogram with the interval in seed time of consecutive events

Definition at line 246 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CreateHistograms(), FillHistos(), and ResetHistograms().

◆ fhEventTime

TH1* CbmMcbm2019TimeWinEventBuilderAlgo::fhEventTime = nullptr
private

Vector of pointers to canvases + optional folder name.

Definition at line 244 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CreateHistograms(), FillHistos(), and ResetHistograms().

◆ fhNbDigiPerEvtTime

TH2* CbmMcbm2019TimeWinEventBuilderAlgo::fhNbDigiPerEvtTime = nullptr
private

histogram with the nb of all digis in the event

Definition at line 247 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CreateHistograms(), FillHistos(), and ResetHistograms().

◆ fOverMode

EOverlapMode CbmMcbm2019TimeWinEventBuilderAlgo::fOverMode {EOverlapMode::AllowOverlap}
private

Event building mode and detectors selection.

Switch between MUCH digi classes

Definition at line 197 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CheckSeed(), and SetEventOverlapMode().

◆ fRefDet

◆ fTimeSliceMetaDataArray

TClonesArray* CbmMcbm2019TimeWinEventBuilderAlgo::fTimeSliceMetaDataArray = nullptr
private

Definition at line 221 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by InitAlgo(), and LoopOnSeeds().

◆ fuCurEv

UInt_t CbmMcbm2019TimeWinEventBuilderAlgo::fuCurEv = 0
private

histograms with the nb of digis in each detector per event vs seed time of the events

Internal state variables

Definition at line 252 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CheckSeed(), and ProcessTs().

◆ fuErrors

UInt_t CbmMcbm2019TimeWinEventBuilderAlgo::fuErrors = 0
private

Event Counter.

Definition at line 253 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by Finish().

◆ fuNrTs

UInt_t CbmMcbm2019TimeWinEventBuilderAlgo::fuNrTs = 0
private

Error Counter.

Definition at line 254 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by LoopOnSeeds(), and ProcessTs().

◆ fvDets

◆ fvhNbDigiPerEvtTimeDet

std::vector<TH2*> CbmMcbm2019TimeWinEventBuilderAlgo::fvhNbDigiPerEvtTimeDet
private
Initial value:
=
{}

histogram with the nb of all digis per event vs seed time of the events

Definition at line 248 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by CreateHistograms(), FillHistos(), and ResetHistograms().

◆ fvpAllCanvasPointers

std::vector<std::pair<TCanvas*, std::string> > CbmMcbm2019TimeWinEventBuilderAlgo::fvpAllCanvasPointers
private

Vector of pointers to histograms + optional folder name.

Definition at line 242 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by AddCanvasToVector(), and GetCanvasVector().

◆ fvpAllHistoPointers

std::vector<std::pair<TNamed*, std::string> > CbmMcbm2019TimeWinEventBuilderAlgo::fvpAllHistoPointers
private

vector with all created events

Monitoring histograms => Pointers should be filled with TH1*, TH2*, TProfile*, ... ==> To check if object N is of type T, use "T ObjectPointer = dynamic_cast<T>( fvpAllHistoPointers[N].first );" and check for nullptr ==> To get back the original class name use "fvpAllHistoPointers[N].first->ClassName()" which returns a const char * (e.g. "TH1I") ===> Usage example with feeding a THttpServer: ===> #include "TH2.h" ===> std::string sClassName = vHistos[ uHisto ].first.ClassName(); ===> if( !strncmp( sClassName, "TH1", 3 ) ) ===> server->Register( vHistos[ uHisto ].second.data(), dynamic_cast< TH1 * >(vHistos[ uHisto ].first) ); ===> else if( !strncmp( sClassName, "TH2", 3 ) ) ===> server->Register( vHistos[ uHisto ].second.data(), dynamic_cast< TH2 * >(vHistos[ uHisto ].first) );

Definition at line 240 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by AddHistoToVector(), and GetHistoVector().

◆ kdDefaultTimeWinBeg

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::kdDefaultTimeWinBeg = -100.0
staticconstexprprivate

Constants.

Definition at line 188 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

◆ kdDefaultTimeWinEnd

Double_t CbmMcbm2019TimeWinEventBuilderAlgo::kdDefaultTimeWinEnd = 100.0
staticconstexprprivate

Definition at line 189 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

◆ pTsMetaData

const TimesliceMetaData* CbmMcbm2019TimeWinEventBuilderAlgo::pTsMetaData = nullptr
private

Definition at line 222 of file CbmMcbm2019TimeWinEventBuilderAlgo.h.

Referenced by LoopOnSeeds().


The documentation for this class was generated from the following files: