23#ifndef RestCore_TRestEventRateAnalysisProcess
24#define RestCore_TRestEventRateAnalysisProcess
26#include "TRestEventProcess.h"
59 RESTMetadata <<
"Rate analysis is on under single thread mode" <<
RESTendl;
61 RESTMetadata <<
"Rate analysis is off due to multi-thread" <<
RESTendl;
67 const char* GetProcessName()
const override {
return "eventRateAnalysis"; }
A base class for any REST event process.
void BeginPrintProcess()
[name, cut range]
A pure analysis process used to calculate event rates and other time observables.
TRestEvent * fEvent
A pointer to the input event.
void InitProcess() override
Process initialization.
RESTValue GetInputEvent() const override
Get pointer to input event. Must be implemented in the derived class.
void Initialize() override
Function to initialize input/output event members and define the section name.
~TRestEventRateAnalysisProcess()
Default destructor.
std::vector< Double_t > fPreviousEventTime
It keeps a historic list of timestamps of the previous N events. Now fixed to N=10 events.
TRestEvent * ProcessEvent(TRestEvent *inputEvent) override
The main processing event function.
void PrintMetadata() override
Implemented it in the derived metadata class to print out specific metadata information.
Double_t fFirstEventTime
It registers the timestamp from the first event to calculate time from start observables.
bool fRateAnalysis
It indicates whether to add rate observables which is correct only under single thread run.
TRestEventRateAnalysisProcess()
Default constructor.
RESTValue GetOutputEvent() const override
Get pointer to output event. Must be implemented in the derived class.
A base class for any REST event.