Belle II Software development
TOPCommonT0CalibratorModule.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#include <framework/core/Module.h>
12#include <framework/datastore/StoreArray.h>
13#include <framework/datastore/StoreObjPtr.h>
14#include <mdst/dataobjects/Track.h>
15#include <tracking/dataobjects/ExtHit.h>
16#include <top/dataobjects/TOPDigit.h>
17#include <top/dataobjects/TOPRecBunch.h>
18#include <top/utilities/TrackSelector.h>
19#include <top/utilities/Chi2MinimumFinder1D.h>
20#include <top/reconstruction_cpp/PDFConstructor.h>
21
22#include <framework/database/DBObjPtr.h>
23#include <top/dbobjects/TOPCalCommonT0.h>
24
25#include <string>
26
27#include <TFile.h>
28#include <TTree.h>
29#include <TH1F.h>
30#include <TH2F.h>
31
32namespace Belle2 {
37
42
43 public:
44
49
54 virtual void initialize() override;
55
59 virtual void event() override;
60
65 virtual void terminate() override;
66
67 private:
68
74
78 enum {c_numModules = 16,
79 c_numSets = 32,
80 };
81
82 // steering parameters
84 double m_timeRange;
85 double m_sigmaSmear;
86 std::string m_sample;
88 double m_deltaEcms;
89 double m_dr;
90 double m_dz;
91 double m_minZ;
92 double m_maxZ;
93 std::string m_outFileName;
94 std::string m_pdfOption;
95
96 // procedure
100 double m_bunchTimeSep = 0;
101
102 // datastore objects
107
108 // database
110
111 // output root file
112 TFile* m_file = 0;
113
114 // control histograms
115 TH1F m_hits1D;
116 TH2F m_hits2D;
117
118 // tree and its variables
119 TTree* m_tree = 0;
120 int m_moduleID = 0;
121 int m_numPhotons = 0;
122 float m_x = 0;
123 float m_y = 0;
124 float m_z = 0;
125 float m_p = 0;
126 float m_theta = 0;
127 float m_phi = 0;
128 float m_pocaR = 0;
129 float m_pocaZ = 0;
130 float m_pocaX = 0;
131 float m_pocaY = 0;
132 float m_cmsE = 0;
133 int m_charge = 0;
134 int m_PDG = 0;
135
136 };
137
139} // Belle2 namespace
140
Class for accessing objects in the database.
Definition DBObjPtr.h:21
Module()
Constructor.
Definition Module.cc:30
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
StoreObjPtr< TOPRecBunch > m_recBunch
reconstructed bunch
TOP::Chi2MinimumFinder1D m_finders[c_numSets]
finders
TTree * m_tree
TTree containing selected track parameters etc.
TOP::TrackSelector m_selector
track selection utility
double m_sigmaSmear
additional smearing of PDF in [ns]
int m_PDG
track MC truth (simulated data only)
DBObjPtr< TOPCalCommonT0 > m_commonT0
common T0 calibration constants
float m_phi
track: extrapolated hit momentum in local (module) frame
double m_minMomentum
minimal track momentum if sample is "cosmics"
int m_numBins
number of bins to which search region is divided
int m_numPhotons
number of photons in this slot
double m_maxZ
maximal local z of extrapolated hit
int m_moduleID
slot to which the track is extrapolated to
TOP::PDFConstructor::EPDFOption m_PDFOption
PDF option.
double m_minZ
minimal local z of extrapolated hit
float m_p
track: extrapolated hit momentum in local (module) frame
StoreArray< Track > m_tracks
collection of tracks
double m_deltaEcms
c.m.s energy window if sample is "dimuon" or "bhabha"
@ c_numSets
number of statistically independent subsamples
double m_timeRange
time range in which to search for the minimum [ns]
float m_y
track: extrapolated hit coordinate in local (module) frame
StoreArray< TOPDigit > m_digits
collection of digits
StoreArray< ExtHit > m_extHits
collection of extrapolated hits
std::string m_outFileName
Root output file name containing results.
double m_bunchTimeSep
time between two bunches
TH1F m_hits1D
number of photon hits in a slot
float m_z
track: extrapolated hit coordinate in local (module) frame
float m_x
track: extrapolated hit coordinate in local (module) frame
float m_theta
track: extrapolated hit momentum in local (module) frame
Minimum finder using tabulated chi^2 values in one dimension.
EPDFOption
Signal PDF construction options.
@ c_Rough
no dependence on y
Utility for the track selection - used in various calibration modules.
virtual void initialize() override
Initialize the Module.
virtual void event() override
Event processor.
virtual void terminate() override
Termination action.
bool isRunningOffsetSubtracted()
Checks if running offset is subtracted in TOPDigits.
Abstract base class for different kinds of events.