 |
Belle II Software
release-05-02-19
|
15 #include <framework/core/Module.h>
16 #include <framework/datastore/StoreArray.h>
17 #include <framework/datastore/StoreObjPtr.h>
18 #include <framework/dataobjects/EventMetaData.h>
19 #include <framework/gearbox/Const.h>
20 #include <framework/logging/Logger.h>
21 #include <framework/utilities/FileSystem.h>
22 #include <framework/gearbox/Unit.h>
23 #include <framework/database/DBObjPtr.h>
26 #include <mdst/dataobjects/Track.h>
29 #include <ecl/dataobjects/ECLShower.h>
30 #include <ecl/dataobjects/ECLPidLikelihood.h>
31 #include <ecl/dbobjects/ECLChargedPidPDFs.h>
63 class ECLChargedPIDModule :
public Module {
102 virtual void event()
override;
109 virtual void endRun()
override;
131 DBObjPtr<ECLChargedPidPDFs>
m_pdfs;
160 std::unordered_map<ECLChargedPidPDFs::InputVar, double>
m_variables {
188 inline int linIndex(
int i,
int j,
int m)
201 void transfoGaussDecorr(
const unsigned int pdg,
const int charge,
const double& p,
const double& theta,
202 std::vector<double>& variables);
208 double getPdfVal(
const double& x,
const TF1* pdf);
213 static constexpr
double c_sqrt2 = 1.41421356237309504880;
StoreArray< Track > m_tracks
Array of Track objects.
@ c_Z51
Zernike moment 51.
StoreArray< ECLPidLikelihood > m_eclPidLikelihoods
Array of ECLPidLikelihood objects.
double getPdfVal(const double &x, const TF1 *pdf)
Extract the PDF value for a given variable from the TF1 object.
int linIndex(int i, int j, int m)
Get the index corresponding to element i,j in a linearised n*m array.
virtual void initialize() override
Use this to initialize resources or memory your module needs.
virtual ~ECLChargedPIDModule()
Destructor, use to clean up anything you created in the constructor.
void checkPdfsDB()
Check the PDFs payload for consistency everytime they change in the database.
virtual void beginRun() override
Called once before a new run begins.
virtual void event() override
Called once for each event.
DBObjPtr< ECLChargedPidPDFs > m_pdfs
Interface to get the DB payload for ECL charged PID PDFs.
Abstract base class for different kinds of events.
@ c_LAT
Lateral shower shape.
static constexpr double c_dummyLogL
Dummy value of Log Likelihood for a particle hypothesis.
std::unordered_map< ECLChargedPidPDFs::InputVar, double > m_variables
Map to contain ECL shower observables.
static constexpr double c_sqrt2
Defintion of sqrt(2)
virtual void terminate() override
Clean up anything you created in initialize().
@ c_Z40
Zernike moment 40.
ECLChargedPIDModule()
Constructor, for setting module description and parameters.
void transfoGaussDecorr(const unsigned int pdg, const int charge, const double &p, const double &theta, std::vector< double > &variables)
Transform input variables according to:
@ c_E
Energy of maxE shower.
virtual void endRun() override
Called once when a run ends.
@ c_DeltaL
DeltaL (track depth)
bool m_applyClusterTimingSel
Apply cluster timing selection.
StoreObjPtr< EventMetaData > m_eventMetaData
The event information.