Belle II Software  release-05-01-25
FlavorTaggerInfoMap.h
1 /**************************************************************************
2  * BASF2 (Belle Analysis Framework 2) *
3  * Copyright(C) 2015 - Belle II Collaboration *
4  * *
5  * Author: The Belle II Collaboration *
6  * Contributors: Fernando Abudinen *
7  * *
8  * This software is provided "as is" without any warranty. *
9  **************************************************************************/
10 
11 #pragma once
12 
13 #include <framework/datastore/RelationsObject.h>
14 #include <analysis/dataobjects/Particle.h>
15 
16 #include <map>
17 #include <string>
18 
19 namespace Belle2 {
25  // forward declarations
26 
27  class Track;
28 
40  class FlavorTaggerInfoMap : public RelationsObject {
41 
42  public:
43 
49  m_targetTrackLevel( {}),
50  m_probTrackLevel({}),
52  m_probEventLevel({}),
53  m_qpCategory({}),
54  m_hasTrueTarget({}),
55  m_isTrueCategory({}),
57  m_B0Probability(-2),
59  {}
60 
61 
77  void setTargetTrackLevel(const std::string& category, const Belle2::Track* track);
78 
84  void setProbTrackLevel(const std::string& category, float probability);
85 
92  void setTargetEventLevel(const std::string& category, const Belle2::Track* track);
93 
100  void setProbEventLevel(const std::string& category, float probability);
101 
108  void setQpCategory(const std::string& category, float qr);
109 
115  void setHasTrueTarget(const std::string& category, float isTrue);
116 
122  void setIsTrueCategory(const std::string& category, float isTrue);
123 
128  void setQrCombined(float qr);
129 
134  void setB0Probability(float B0Probability);
135 
140  void setB0barProbability(float B0barProbability);
141 
142 
143 
148  std::map<std::string, const Belle2::Track*> getTargetTrackLevel();
149 
154  std::map<std::string, float> getProbTrackLevel();
155 
160  std::map<std::string, const Belle2::Track*> getTargetEventLevel();
161 
166  std::map<std::string, float> getProbEventLevel();
167 
172  std::map<std::string, float> getQpCategory();
173 
178  std::map<std::string, float> getHasTrueTarget();
179 
184  std::map<std::string, float> getIsTrueCategory();
185 
190  float getQrCombined();
191 
196  float getB0Probability();
197 
202  float getB0barProbability();
203 
204 
205  private:
206 
207  // persistent data members
208 
209  // Track, Event and Combiner Level Flavor Tagger Info
210 
211  std::map<std::string, const Belle2::Track*>
213  std::map<std::string, float>
215  std::map<std::string, const Belle2::Track*>
217  std::map<std::string, float>
219  std::map<std::string, float>
221  std::map<std::string, float>
223  std::map<std::string, float>
226  float m_qrCombined;
227  float m_B0Probability;
231  };
232 
233 
235 } // end namespace Belle2
236 
Belle2::FlavorTaggerInfoMap::m_B0Probability
float m_B0Probability
Direct Output of the Combiner: Probability of being a B0.
Definition: FlavorTaggerInfoMap.h:235
Belle2::FlavorTaggerInfoMap::getTargetEventLevel
std::map< std::string, const Belle2::Track * > getTargetEventLevel()
get map containing the category name and the corresponding pointer to the track with highest category...
Definition: FlavorTaggerInfoMap.cc:90
Belle2::FlavorTaggerInfoMap::setProbTrackLevel
void setProbTrackLevel(const std::string &category, float probability)
Map filler: Set the category name and the corresponding highest target track probability.
Definition: FlavorTaggerInfoMap.cc:26
Belle2::FlavorTaggerInfoMap::setB0Probability
void setB0Probability(float B0Probability)
Saves the B0Probability output of the Combiner.
Definition: FlavorTaggerInfoMap.cc:65
Belle2::FlavorTaggerInfoMap::m_isTrueCategory
std::map< std::string, float > m_isTrueCategory
map containing the category name and a float value which is 1 if the corresponding category tags the ...
Definition: FlavorTaggerInfoMap.h:232
Belle2::FlavorTaggerInfoMap
This class stores the Flavor Tagger information for a specific method and particle filled in the Flav...
Definition: FlavorTaggerInfoMap.h:48
Belle2::FlavorTaggerInfoMap::setQpCategory
void setQpCategory(const std::string &category, float qr)
Map filler: Set the category name and the corresponding qr Output, i.e.
Definition: FlavorTaggerInfoMap.cc:44
Belle2::RelationsInterface::ClassDef
ClassDef(RelationsInterface, 0)
defines interface for accessing relations of objects in StoreArray.
Belle2::FlavorTaggerInfoMap::m_qpCategory
std::map< std::string, float > m_qpCategory
map containing the category name and the corresponding qr Output, i.e.
Definition: FlavorTaggerInfoMap.h:228
Belle2::FlavorTaggerInfoMap::getB0Probability
float getB0Probability()
Probability of being a B0.
Definition: FlavorTaggerInfoMap.cc:120
Belle2::FlavorTaggerInfoMap::setB0barProbability
void setB0barProbability(float B0barProbability)
Saves the B0barProbability output of the Combiner.
Definition: FlavorTaggerInfoMap.cc:71
Belle2::FlavorTaggerInfoMap::setTargetEventLevel
void setTargetEventLevel(const std::string &category, const Belle2::Track *track)
Map filler: Set the category name and the pointer of the track with the highest category probability ...
Definition: FlavorTaggerInfoMap.cc:32
Belle2::FlavorTaggerInfoMap::getQrCombined
float getQrCombined()
qr Output of the Combiner.
Definition: FlavorTaggerInfoMap.cc:115
Belle2::FlavorTaggerInfoMap::setProbEventLevel
void setProbEventLevel(const std::string &category, float probability)
Map filler: Set the category name and the highest category probability for the corresponding category...
Definition: FlavorTaggerInfoMap.cc:38
Belle2::FlavorTaggerInfoMap::m_probEventLevel
std::map< std::string, float > m_probEventLevel
map containing the category name and the corresponding highest category probability in Event Level
Definition: FlavorTaggerInfoMap.h:226
Belle2::FlavorTaggerInfoMap::getQpCategory
std::map< std::string, float > getQpCategory()
get map containing the category name and the corresponding qr Output
Definition: FlavorTaggerInfoMap.cc:100
Belle2::FlavorTaggerInfoMap::getProbEventLevel
std::map< std::string, float > getProbEventLevel()
get map containing the category name and the corresponding highest category probability in Event Leve...
Definition: FlavorTaggerInfoMap.cc:95
Belle2::FlavorTaggerInfoMap::m_hasTrueTarget
std::map< std::string, float > m_hasTrueTarget
map containing the category name and a float value which is 1 if the corresponding category has a tar...
Definition: FlavorTaggerInfoMap.h:230
Belle2::FlavorTaggerInfoMap::setIsTrueCategory
void setIsTrueCategory(const std::string &category, float isTrue)
Map filler: Set the category name and the corresponding truth MC value.
Definition: FlavorTaggerInfoMap.cc:54
Belle2::FlavorTaggerInfoMap::getB0barProbability
float getB0barProbability()
Probability of being a B0bar.
Definition: FlavorTaggerInfoMap.cc:125
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::FlavorTaggerInfoMap::m_targetTrackLevel
std::map< std::string, const Belle2::Track * > m_targetTrackLevel
map containing the category name and the corresponding pointer to the track with highest target proba...
Definition: FlavorTaggerInfoMap.h:220
Belle2::FlavorTaggerInfoMap::m_probTrackLevel
std::map< std::string, float > m_probTrackLevel
map containing the category name and thecorresponding highest target track probability in Track Level
Definition: FlavorTaggerInfoMap.h:222
Belle2::FlavorTaggerInfoMap::getIsTrueCategory
std::map< std::string, float > getIsTrueCategory()
get map containing the category truth.
Definition: FlavorTaggerInfoMap.cc:110
Belle2::RelationsObject
RelationsInterface< TObject > RelationsObject
Provides interface for getting/adding relations to objects in StoreArrays.
Definition: RelationsObject.h:443
Belle2::FlavorTaggerInfoMap::m_qrCombined
float m_qrCombined
qr Output of the Combiner.
Definition: FlavorTaggerInfoMap.h:234
Belle2::FlavorTaggerInfoMap::setHasTrueTarget
void setHasTrueTarget(const std::string &category, float isTrue)
Map filler: Set the category name and the corresponding MC target truth value.
Definition: FlavorTaggerInfoMap.cc:49
Belle2::Track
Class that bundles various TrackFitResults.
Definition: Track.h:35
Belle2::FlavorTaggerInfoMap::m_B0barProbability
float m_B0barProbability
Direct Output of the Combiner: Probability of being a B0bar).
Definition: FlavorTaggerInfoMap.h:236
Belle2::FlavorTaggerInfoMap::m_targetEventLevel
std::map< std::string, const Belle2::Track * > m_targetEventLevel
map containing the category name and the corresponding pointer to the track with highest category pro...
Definition: FlavorTaggerInfoMap.h:224
Belle2::FlavorTaggerInfoMap::FlavorTaggerInfoMap
FlavorTaggerInfoMap()
Default constructor.
Definition: FlavorTaggerInfoMap.h:56
Belle2::FlavorTaggerInfoMap::setTargetTrackLevel
void setTargetTrackLevel(const std::string &category, const Belle2::Track *track)
SETTERS The setters are expected to fill a map whose element corresponds to the probabilities and tra...
Definition: FlavorTaggerInfoMap.cc:20
Belle2::FlavorTaggerInfoMap::getTargetTrackLevel
std::map< std::string, const Belle2::Track * > getTargetTrackLevel()
get map containing the category name and the corresponding pointer to the track with highest target p...
Definition: FlavorTaggerInfoMap.cc:80
Belle2::FlavorTaggerInfoMap::getProbTrackLevel
std::map< std::string, float > getProbTrackLevel()
get map containing the category name and thecorresponding highest target track probability in Track L...
Definition: FlavorTaggerInfoMap.cc:85
Belle2::FlavorTaggerInfoMap::getHasTrueTarget
std::map< std::string, float > getHasTrueTarget()
get map containing the category truth.
Definition: FlavorTaggerInfoMap.cc:105
Belle2::FlavorTaggerInfoMap::setQrCombined
void setQrCombined(float qr)
Saves qr Output of the Combiner.
Definition: FlavorTaggerInfoMap.cc:59