Belle II Software  release-08-01-10
eclee5x5CollectorModule.h
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 
9 #pragma once
10 
11 /* ECL headers. */
12 #include <ecl/geometry/ECLNeighbours.h>
13 
14 /* Basf2 headers. */
15 #include <analysis/utility/PCmsLabTransform.h>
16 #include <calibration/CalibrationCollectorModule.h>
17 #include <framework/database/DBObjPtr.h>
18 #include <framework/datastore/StoreArray.h>
19 
20 namespace Belle2 {
25  class ECLCrystalCalib;
26  class TRGSummary;
27  class EventMetaData;
28  class ECLCluster;
29  class ECLCalDigit;
30  class ECLDigit;
31 
32 
35 
36  public:
37 
40 
42  void prepare() override;
43 
45  void collect() override;
46 
47  private:
51  double m_minE0;
52  double m_minE1;
53  double m_maxdThetaSum;
54  double m_dPhiScale;
55  double m_maxTime;
57  bool m_requireL1;
67  double m_thetaLabMin = 0.;
68  double m_thetaLabMax = 0.;
69  std::vector<float> m_dPhiMin;
70  std::vector<float> m_dPhiMax;
71  bool storeCalib = true;
72  std::vector<float> EperCrys;
75  double m_sqrts = 10.58;
76  std::vector<int> m_thetaID;
80  std::vector<float> Expee5x5E;
81  std::vector<float> Expee5x5Sigma;
85  std::vector<float> ElectronicsCalib;
89  std::vector<float> ee5x5Calib;
94  std::vector<float> meandPhi;
95  std::vector<float> widthdPhi;
97  };
99 }
Calibration collector module base class.
Class for accessing objects in the database.
Definition: DBObjPtr.h:21
Class to get the neighbours for a given cell id.
Definition: ECLNeighbours.h:25
Class to hold Lorentz transformations from/to CMS and boost vector.
Accessor to arrays stored in the data store.
Definition: StoreArray.h:113
Type-safe access to single objects in the data store.
Definition: StoreObjPtr.h:96
Calibration collector module that uses e+e- --> e+e- to do ECL single crystal energy calibration.
DBObjPtr< ECLCrystalCalib > m_selectdPhiData
dPhi cut
StoreArray< ECLDigit > m_eclDigitArray
Required input array of ECLDigits.
std::vector< float > widthdPhi
width of requirement on dPhi from DB object
std::vector< float > Expee5x5E
vector of energies obtained from DB object
bool m_requireL1
require events to satisfy a level 1 trigger (false)
DBObjPtr< ECLCrystalCalib > m_ECLExpee5x5E
Expected energies from database.
double m_maxTime
maximum cluster time diff abs(t1-t0)/dt99 (10)
eclee5x5CollectorModule()
Constructor: Sets the description, the properties and the parameters of the module.
double m_maxdThetaSum
abs(theta0* + theta1* - 180 deg) must be less than less (2 deg)
StoreArray< ECLCluster > m_eclClusterArray
Required arrays.
StoreObjPtr< TRGSummary > m_TRGResults
dataStore TRGSummary
bool storeCalib
force the input calibration constants to be saved first event
double m_minE0
minimum energy of cluster 0: E*0/sqrts (0.45)
std::vector< float > EperCrys
Energy for each crystal from ECLDigit or ECLCalDigit (GeV)
std::vector< int > m_thetaID
thetaID of each crystal
ECL::ECLNeighbours * m_eclNeighbours5x5
Neighbour map of 25 crystals.
bool m_useCalDigits
use eclCalDigit to determine MC deposited energy (false)
std::vector< float > Expee5x5Sigma
vector of sigmaE obtained from DB object
std::vector< float > m_dPhiMin
minimum dPhi* as a function of thetaID
std::vector< float > m_dPhiMax
maximum dPhi* as a function of thetaID
void collect() override
Select events and crystals and accumulate histograms.
StoreObjPtr< EventMetaData > m_evtMetaData
dataStore EventMetaData
std::vector< float > ElectronicsCalib
vector obtained from DB object
StoreArray< ECLCalDigit > m_eclCalDigitArray
Required input array of ECLCalDigits.
double m_thetaLabMax
m_thetaLabMaxDeg converted to radians
std::vector< float > meandPhi
mean requirement on dPhi from DB object
double m_sqrts
sqrt s from m_boostrotate
void prepare() override
Define histograms and read payloads from DB.
std::vector< float > ee5x5Calib
vector obtained from DB object
double m_thetaLabMin
Some other useful quantities.
DBObjPtr< ECLCrystalCalib > m_selectdPhiMC
DB object for MC.
double m_thetaLabMaxDeg
maximum ecl cluster theta in lab (150 degrees)
DBObjPtr< ECLCrystalCalib > m_ee5x5Calib
Existing single crystal calibration from DB; will be updated by CAF.
double m_thetaLabMinDeg
Parameters to control the job.
PCmsLabTransform m_boostrotate
boost from COM to lab and visa versa
double m_dPhiScale
scale dPhi* cut by this factor (1)
double m_minE1
minimum energy of cluster 1: E*1/sqrts (0.40)
DBObjPtr< ECLCrystalCalib > m_ElectronicsCalib
Electronics calibration from database.
Abstract base class for different kinds of events.