artdaq
v3_02_00
|
This class manages MonitoredQuantity instances for the *Core classes. More...
#include <artdaq/Application/StatisticsHelper.hh>
Public Member Functions | |
StatisticsHelper () | |
StatisticsHelper default constructor. | |
StatisticsHelper (StatisticsHelper const &)=delete | |
Copy Constructor is deleted. | |
virtual | ~StatisticsHelper ()=default |
Default Destructor. | |
StatisticsHelper & | operator= (StatisticsHelper const &)=delete |
Copy Assignment operator is deleted. More... | |
void | addMonitoredQuantityName (std::string const &statKey) |
Add a MonitoredQuantity name to the list. More... | |
void | addSample (std::string const &statKey, double value) const |
Add a sample to the MonitoredQuantity with the given name. More... | |
bool | createCollectors (fhicl::ParameterSet const &pset, int defaultReportIntervalFragments, double defaultReportIntervalSeconds, double defaultMonitorWindow, std::string const &primaryStatKeyName) |
Create MonitoredQuantity objects for all names registered with the StatisticsHelper. More... | |
void | resetStatistics () |
Reset all MonitoredQuantity instances. | |
bool | readyToReport (size_t currentCount) |
Determine if the reporting interval conditions have been met. More... | |
bool | statsRollingWindowHasMoved () |
Determine if the MonitoredQuantity "recent" window has changed since the last time this function was called. More... | |
This class manages MonitoredQuantity instances for the *Core classes.
Definition at line 16 of file StatisticsHelper.hh.
void artdaq::StatisticsHelper::addMonitoredQuantityName | ( | std::string const & | statKey | ) |
Add a MonitoredQuantity name to the list.
statKey | Name of the MonitoredQuantity to be added |
Definition at line 15 of file StatisticsHelper.cc.
void artdaq::StatisticsHelper::addSample | ( | std::string const & | statKey, |
double | value | ||
) | const |
Add a sample to the MonitoredQuantity with the given name.
statKey | Name of the MonitoredQuantity |
value | Value to record in the MonitoredQuantity |
Definition at line 20 of file StatisticsHelper.cc.
bool artdaq::StatisticsHelper::createCollectors | ( | fhicl::ParameterSet const & | pset, |
int | defaultReportIntervalFragments, | ||
double | defaultReportIntervalSeconds, | ||
double | defaultMonitorWindow, | ||
std::string const & | primaryStatKeyName | ||
) |
Create MonitoredQuantity objects for all names registered with the StatisticsHelper.
pset | ParameterSet used to configure reporting |
defaultReportIntervalFragments | Default reporting interval in Fragments |
defaultReportIntervalSeconds | Default reporting interval in Seconds |
defaultMonitorWindow | Default monitoring window |
primaryStatKeyName | The primary (default) MonitoredQuantity |
StatisitcsHelper accpets the following Parameters: "reporting_interval_fragments" (Default given above): The reporting interval in Fragments "reporting_interval_seconds" (Default given above): The reporting interval in Seconds "monitor_window" (Default given above): The monitoring window for the MonitoredQuantity "monitor_binsize" (Default: 1 + ((monitorWindow - 1) / 100)): The monitoring bin size for the MonitoredQuantity
Definition at line 29 of file StatisticsHelper.cc.
|
delete |
Copy Assignment operator is deleted.
bool artdaq::StatisticsHelper::readyToReport | ( | size_t | currentCount | ) |
Determine if the reporting interval conditions have been met.
currentCount | Current Fragment count |
Definition at line 74 of file StatisticsHelper.cc.
bool artdaq::StatisticsHelper::statsRollingWindowHasMoved | ( | ) |
Determine if the MonitoredQuantity "recent" window has changed since the last time this function was called.
Definition at line 91 of file StatisticsHelper.cc.