Belle II Software development
CDCCalibrationCollector.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 <cdc/geometry/CDCGeometryPar.h>
12#include <calibration/CalibrationCollectorModule.h>
13
14#include <mdst/dataobjects/Track.h>
15#include <mdst/dataobjects/TrackFitResult.h>
16
17#include <tracking/dataobjects/RecoTrack.h>
18#include <tracking/trackFindingCDC/eventdata/tracks/CDCTrack.h>
19#include <tracking/trackFindingCDC/rootification/StoreWrappedObjPtr.h>
20#include <tracking/trackFindingCDC/topology/CDCWire.h>
21
22#include <framework/dataobjects/EventT0.h>
23#include <framework/datastore/StoreArray.h>
24
25#include <Math/Vector3D.h>
26#include <string>
27
28namespace Belle2 {
33 namespace CDC {
34
39
40 public:
41
46
51
55 void prepare() override;
56
57
62 void collect() override;
63
67 void finish() override;
68
69 private:
70
71
75 void harvest(Belle2::RecoTrack* track);
79 void buildEfficiencies(std::vector<unsigned short> wireHits, const Helix helixFit);
83 const TrackFindingCDC::CDCWire& getIntersectingWire(const ROOT::Math::XYZVector& xyz, const TrackFindingCDC::CDCWireLayer& layer,
84 const Helix& helixFit) const;
85
93 std::string m_trackArrayName;
94 std::string m_cdcHitArrayName;
95 std::string m_cdcTrackVectorName = "CDCTrackVector";
96 std::string m_recoTrackArrayName ;
99 std::string m_treeName;
100 std::string m_effTreeName;
102 Float_t weight;
103 Float_t alpha;
104 Float_t theta;
105 UShort_t adc;
106 Float_t t;
107 Float_t t_fit;
108 Float_t evtT0;
109 Float_t x_mea;
110 Float_t x_u;
111 Float_t x_b;
112 UChar_t lay;
113 UShort_t IWire;
114 Float_t Pval;
115 Float_t ndf;
116 Float_t d0;
117 Float_t z0;
118 Float_t phi0;
119 Float_t tanL;
120 Float_t omega;
121 double m_minimumPt = 0;
122 double m_minimumNDF = 0;
125 bool m_bField = true;
126 bool m_storeTrackParams = true;
128 bool m_isCosmic = false;
129 bool m_effStudy = false;
131 unsigned short wireID;
132 unsigned short layerID;
133 float z;
134 bool isFound;
135 };
136 }
138}
Collect hit information for cdc calibration with CAF.
StoreObjPtr< EventT0 > m_eventTimeStoreObject
Event t0 object.
std::string m_recoTrackArrayName
Belle2::RecoTrack StoreArray nam.e.
bool m_calExpectedDriftTime
Calculate expected drift time from x_fit or not.
double m_minimumNDF
minimum NDF required for track
std::string m_effTreeName
Name of efficiency tree for the output file.
std::string m_cdcTrackVectorName
Belle2::CDCTrack vectorpointer name.
bool m_storeTrackParams
Store Track parameter or not.
TrackFindingCDC::StoreWrappedObjPtr< std::vector< TrackFindingCDC::CDCTrack > > m_CDCTracks
CDC tracks.
StoreArray< TrackFitResult > m_TrackFitResults
Track fit results.
void harvest(Belle2::RecoTrack *track)
collect hit information of fitted track.
std::string m_cdcHitArrayName
Belle2::CDCHit StoreArray name.
Float_t theta
Entrance Polar angle of hit (degree).
std::string m_relRecoTrackTrackName
Relation between RecoTrack and Belle2:Track.
unsigned short wireID
wireID for hit-level wire monitoring
void collect() override
Event action, collect information for calibration.
bool m_isCosmic
true when we process cosmic events, else false (collision).
Float_t t_fit
Drift time calculated from x_fit.
bool m_eventT0Extraction
use Event T0 extract t0 or not.
void buildEfficiencies(std::vector< unsigned short > wireHits, const Helix helixFit)
fills efficiency objects
bool m_bField
fit incase no magnetic Field of not, if false, NDF=4 in cal P-value
std::string m_trackArrayName
Belle2::Track StoreArray name.
void prepare() override
Initializes the Module.
Float_t x_u
X_fit for unbiased track fit.
std::string m_trackFitResultArrayName
Belle2::TrackFitResult StoreArray name.
unsigned short layerID
layerID for hit-level wire monitoring
Float_t x_mea
measure drift length (signed by left right).
const TrackFindingCDC::CDCWire & getIntersectingWire(const ROOT::Math::XYZVector &xyz, const TrackFindingCDC::CDCWireLayer &layer, const Helix &helixFit) const
extrapolates the helix fit to a given layer and finds the wire which it would be hitting
std::string m_treeName
Name of tree for the output file.
Float_t alpha
Entrance Azimuthal angle of hit (degree).
double m_minimumPt
minimum pt required for track
bool m_effStudy
When true module collects info only necessary for wire eff study.
float z
z of hit fot hit-level wire monitoring
bool isFound
flag for a hit that has been found near a track as expected by extrapolation
Helix parameter class.
Definition: Helix.h:48
Calibration collector module base class.
This is the Reconstruction Event-Data Model Track.
Definition: RecoTrack.h:79
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
Class representing a sense wire layer in the central drift chamber.
Definition: CDCWireLayer.h:42
Class representing a sense wire in the central drift chamber.
Definition: CDCWire.h:58
This class is for convenience access and registration of objects, that are stored inside the StoreWra...
Abstract base class for different kinds of events.