23#ifndef RestProcess_TRestBenchMarkProcess
24#define RestProcess_TRestBenchMarkProcess
28#include "TRestEventProcess.h"
41 static std::thread* fMonitorThread;
42 static int fMonitorFlag;
44 static float fMemUsageInMB;
45 static float fReadingInMBs;
46 static float fProcessSpeedInHz;
47 static int fLastEventNumber;
48 static ULong64_t fStartTime;
52 void SysMonitorFunc(
int pid,
double refreshRate = 1);
70 const char* GetProcessName()
const override {
return "BenchMarkProcess"; }
A system performance monitor process for event flow rate, reading speed, cpu stress,...
static float fCPUUsageInPct
//0: return, 1: run
RESTValue GetOutputEvent() const override
Get pointer to output event. Must be implemented in the derived class.
TRestEvent * ProcessEvent(TRestEvent *inputEvent) override
Process one event.
void InitProcess() override
To be executed at the beginning of the run (outside event loop)
void PrintMetadata() override
Implemented it in the derived metadata class to print out specific metadata information.
void Initialize() override
Making default settings.
void EndProcess() override
To be executed at the end of the run (outside event loop)
RESTValue GetInputEvent() const override
Get pointer to input event. Must be implemented in the derived class.
A base class for any REST event process.
A base class for any REST event.