Belle II Software  release-08-01-10
SVDSpacePointQICalibrationModule.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 
14 #include <tracking/dataobjects/RecoTrack.h>
15 #include <svd/dataobjects/SVDCluster.h>
16 
17 #include <string>
18 
19 #include <TH2.h>
20 
21 namespace Belle2 {
34 
35  public:
38 
39 
40 
45  virtual void initialize() override;
46 
47 
49  virtual void event() override;
50 
51 
53  virtual void terminate() override;
54 
55 
56 
57  protected:
58 
59  void calculateProb(TH2F* signal, TH2F* background, TH2F* probability);
60  void calculateError(TH2F* signal, TH2F* background, TH2F* error);
62  // Data members
63  std::string m_svdClustersName;
64  std::string m_recoTracksName;
71  int m_binSize = 50;
73  int m_maxClusterSize = 5;
74  bool m_useLegacyNaming = true;
76  std::string m_outputFileName = "";
78  std::string m_nameOfInstance =
79  "";
80  //for setting up histograms
81 
82 
83  std::map<std::string, TH2F* > signalHistMap;
84  std::map<std::string, TH2F*> backgroundHistMap;
86  };
88 } // end namespace Belle2
Base class for Modules.
Definition: Module.h:72
Imports Clusters of the SVD detector and converts them to spacePoints.
std::string m_svdClustersName
SVDCluster collection name.
std::string m_nameOfInstance
allows the user to set an identifier for this module.
virtual void initialize() override
Init the module.
StoreArray< SVDCluster > m_svdClusters
the storeArray for svdClusters as member, is faster than recreating link for each event
void calculateError(TH2F *signal, TH2F *background, TH2F *error)
compute error
std::map< std::string, TH2F * > backgroundHistMap
map for background histograms
std::string m_recoTracksName
RecoTracks collection name.
std::map< std::string, TH2F * > signalHistMap
map of signal histograms
int m_maxClusterSize
max numnber of strips the PDF are separated into
StoreArray< RecoTrack > m_recoTracks
RecoTrack store array.
void calculateProb(TH2F *signal, TH2F *background, TH2F *probability)
compute probability
int m_binSize
number of bins in charge distribution
Abstract base class for different kinds of events.