10#include <arich/modules/arichRateCal/ARICHRateCalModule.h>
11#include <arich/dataobjects/ARICHThParam.h>
12#include <arich/dataobjects/ARICHRawDigit.h>
13#include <arich/dataobjects/ARICHInfo.h>
16#include <framework/dataobjects/EventMetaData.h>
17#include <framework/datastore/StoreArray.h>
18#include <framework/datastore/StoreObjPtr.h>
85 B2WARNING(
"dth is set to 0");
87 for (
int i = 0; i < 100; i++) {
88 h_rate2D[i] =
new TH2F(Form(
"h_rate2D_%d", i), Form(
"MRG#%d;Channel ID; Vth [mV]", i), 144 * 6, -0.5, -0.5 + 144 * 6,
107 int runno = evtmetadata->getRun();
117 if (!arichinfo->getthscan_mode())
return;
118 double vth_thscan = arichinfo->getvth_thscan();
122 int runno = evtmetadata->getRun();
127 for (
auto& rawdigit : rawdigits) {
128 const int mrgid = rawdigit.getBoardId();
131 std::vector<ARICHRawDigit::FEBDigit>& febs(rawdigit.getFEBs());
132 for (
auto& feb : febs) {
133 const int febno = feb.febno;
134 std::vector<ARICHRawDigit::FEBDigit::ChannelDigit>& channels(feb());
135 for (
auto& channel : channels) {
136 if (channel.val > 0) {
138 double vth =
m_internalmode ? vth_thscan * 1000 : param.getVth() * 1000 ;
139 h_rate2D[mrgid]->Fill(channel.chno + febno * 144, vth);
int m_evt_count
event counter
TH2 * h_rate2D[100]
2D histogram
int m_nrun
number of scan runs
bool m_internalmode
whether internal thscan mode is requested
std::string m_daqdb
daqdb config name
int m_nevents
number of events per run
bool m_debugmode
whether debug mode is requested
int m_run_count
run counter
ARICHThParam class for storing photon hit information.
HistoModule.h is supposed to be used instead of Module.h for the modules with histogram definitions t...
virtual void terminate() override
Function to terminate module.
void setDescription(const std::string &description)
Sets the description of the module.
void setPropertyFlags(unsigned int propertyFlags)
Sets the flags for the module properties.
@ c_ParallelProcessingCertified
This module can be run in parallel processing mode safely (All I/O must be done through the data stor...
bool isRequired(const std::string &name="")
Ensure this array/object has been registered previously.
Accessor to arrays stored in the data store.
Type-safe access to single objects in the data store.
virtual void initialize() override
Initialize the Module.
virtual void event() override
Event processor.
ARICHRateCalModule()
Constructor.
virtual void beginRun() override
Called when entering a new run.
virtual ~ARICHRateCalModule()
Destructor.
virtual void defineHisto() override
Definition of the histograms.
void addParam(const std::string &name, T ¶mVariable, const std::string &description, const T &defaultValue)
Adds a new parameter to the module.
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
Abstract base class for different kinds of events.