9#include <cdc/calibration/DeadBoardAlgorithm.h>
10#include <framework/logging/Logger.h>
20 " -------------------------- Dead Board Detection Algorithm -------------------------\n"
29 B2ERROR(
"Histogram " <<
m_histName <<
" not found");
34 <<
", nbins = " << hBoardIDs->GetNbinsX()
35 <<
", entries = " << hBoardIDs->GetEntries());
37 for (
int ibin = 1; ibin <= hBoardIDs->GetNbinsX(); ++ibin) {
38 const double content = hBoardIDs->GetBinContent(ibin);
41 const int boardID =
static_cast<int>(std::lround(hBoardIDs->GetXaxis()->GetBinCenter(ibin)));
46 B2INFO(
"Dead board candidate found: boardID = " << boardID
48 <<
", content = " << content);
55 B2INFO(
"Total dead boards found: " <<
m_badBoardList->getEntries());
64 B2INFO(
"ExpRun used for DB Geometry : " << exprun.first <<
" " << exprun.second);
Database object for bad boards.
DeadBoardAlgorithm()
Constructor.
float m_threshold
dead-board threshold
std::string m_histName
input histogram name
void detectDeadBoards()
Detect dead boards from histogram.
CDCBadBoards * m_badBoardList
bad-board list to be saved
EResult calibrate() override
Run algorithm on data.
void saveCalibration(TClonesArray *data, const std::string &name)
Store DBArray payload with given name with default IOV.
static void updateDBObjPtrs(const unsigned int event, const int run, const int experiment)
Updates any DBObjPtrs by calling update(event) for DBStore.
void setDescription(const std::string &description)
Set algorithm description (in constructor)
const std::vector< Calibration::ExpRun > & getRunList() const
Get the list of runs for which calibration is called.
EResult
The result of calibration.
@ c_OK
Finished successfully =0 in Python.
CalibrationAlgorithm(const std::string &collectorModuleName)
Constructor - sets the prefix for collected objects (won't be accesses until execute(....
std::shared_ptr< T > getObjectPtr(const std::string &name, const std::vector< Calibration::ExpRun > &requestedRuns)
Get calibration data object by name and list of runs, the Merge function will be called to generate t...
Abstract base class for different kinds of events.