CMS 3D CMS Logo

MomentumDependentPedeLabeler.h
Go to the documentation of this file.
1 #ifndef MomentumDEPENDENTPEDELABELER_H
2 #define MomentumDEPENDENTPEDELABELER_H
3 
16 #include <vector>
17 #include <map>
18 
20 
23 
24 /***************************************
25 ****************************************/
27 {
28  public:
29 
32  const edm::ParameterSet& config);
35 
39  unsigned int alignableLabel(Alignable *alignable) const override;
44  unsigned int alignableLabelFromParamAndInstance(Alignable *alignable,
45  unsigned int param,
46  unsigned int instance) const override;
47  unsigned int lasBeamLabel(unsigned int lasBeamId) const override;
49  unsigned int parameterLabel(unsigned int aliLabel, unsigned int parNum) const override;
52  unsigned int parameterLabel(Alignable *alignable, unsigned int parNum,
54  const TrajectoryStateOnSurface &tsos) const override;
56  bool hasSplitParameters(Alignable *alignable) const override;
58  unsigned int numberOfParameterInstances(Alignable *alignable, int param=-1) const override;
59  unsigned int maxNumberOfParameterInstances() const override { return theMaxNumberOfParameterInstances; }
60 
62  unsigned int paramNumFromLabel(unsigned int paramLabel) const override;
64  unsigned int alignableLabelFromLabel(unsigned int label) const override;
67  Alignable* alignableFromLabel(unsigned int label) const override;
70  unsigned int lasBeamIdFromLabel(unsigned int label) const override;
71 
72  private:
73  typedef std::map <Alignable*, unsigned int> AlignableToIdMap;
75  typedef std::pair <float,float> MomentumRange;
76  typedef std::vector <MomentumRange> MomentumRangeVector;
77  typedef std::map <unsigned int, MomentumRangeVector> MomentumRangeParamMap;
78  typedef std::map <Alignable*, MomentumRangeParamMap> AlignableToMomentumRangeMap;
80  typedef std::map <unsigned int, Alignable*> IdToAlignableMap;
81  typedef std::map <unsigned int, unsigned int> UintUintMap;
82 
83  std::vector<std::string> decompose(const std::string &s, std::string::value_type delimiter) const;
84  std::vector<unsigned int> convertParamSel(const std::string &selString) const;
85  unsigned int buildMomentumDependencyMap(AlignableTracker *aliTracker, AlignableMuon* aliMuon,
86  AlignableExtras *extras,
87  const edm::ParameterSet &config);
88 
90  unsigned int buildMap(const align::Alignables&);
92  unsigned int buildReverseMap();
93 
94  // data members
95  AlignableToIdMap theAlignableToIdMap;
96  AlignableToMomentumRangeMap theAlignableToMomentumRangeMap;
97  IdToAlignableMap theIdToAlignableMap;
98  UintUintMap theLasBeamToLabelMap;
99  UintUintMap theLabelToLasBeamMap;
100  const MomentumRange theOpenMomentumRange;
102 };
103 
104 #endif
unsigned int parameterLabel(unsigned int aliLabel, unsigned int parNum) const override
returns the label for a given alignable parameter number combination
unsigned int alignableLabelFromParamAndInstance(Alignable *alignable, unsigned int param, unsigned int instance) const override
std::map< Alignable *, MomentumRangeParamMap > AlignableToMomentumRangeMap
std::map< Alignable *, unsigned int > AlignableToIdMap
static PFTauRenderPlugin instance
std::vector< std::string > decompose(const std::string &s, std::string::value_type delimiter) const
UintUintMap theLabelToLasBeamMap
labels for las beams
unsigned int paramNumFromLabel(unsigned int paramLabel) const override
parameter number, 0 <= .. < theMaxNumParam, belonging to unique parameter label
std::pair< float, float > MomentumRange
Definition: config.py:1
MomentumDependentPedeLabeler(const PedeLabelerBase::TopLevelAlignables &alignables, const edm::ParameterSet &config)
constructor from three Alignables (null pointers allowed )
define event information passed to algorithms
AlignableToMomentumRangeMap::value_type AlignableToMomentumRangePair
unsigned int lasBeamLabel(unsigned int lasBeamId) const override
std::map< unsigned int, unsigned int > UintUintMap
std::map< unsigned int, Alignable * > IdToAlignableMap
unsigned int buildMap(const align::Alignables &)
returns size of map
unsigned int alignableLabel(Alignable *alignable) const override
Return 32-bit unique label for alignable, 0 indicates failure.
unsigned int lasBeamIdFromLabel(unsigned int label) const override
UintUintMap theLasBeamToLabelMap
reverse map
unsigned int buildReverseMap()
returns size of map
bool hasSplitParameters(Alignable *alignable) const override
returns true if the alignable has parameters that are split into various bins
Alignable * alignableFromLabel(unsigned int label) const override
std::map< unsigned int, MomentumRangeVector > MomentumRangeParamMap
std::vector< Alignable * > Alignables
Definition: Utilities.h:32
std::vector< MomentumRange > MomentumRangeVector
unsigned int numberOfParameterInstances(Alignable *alignable, int param=-1) const override
returns the number of instances for a given parameter
unsigned int buildMomentumDependencyMap(AlignableTracker *aliTracker, AlignableMuon *aliMuon, AlignableExtras *extras, const edm::ParameterSet &config)
const MomentumRange theOpenMomentumRange
reverse of the above
eventInfo
add run, event number and lumi section
std::vector< unsigned int > convertParamSel(const std::string &selString) const
Constructor of the full muon geometry.
Definition: AlignableMuon.h:37
unsigned int alignableLabelFromLabel(unsigned int label) const override
alignable label from parameter label (works also for alignable label...)
AlignableToMomentumRangeMap theAlignableToMomentumRangeMap
providing unique ID for alignable, space for param IDs
unsigned int maxNumberOfParameterInstances() const override
returns the maximum number of instances for any parameter of an Alignable*
AlignableToIdMap::value_type AlignableToIdPair
IdToAlignableMap theIdToAlignableMap
providing unique ID for alignable, space for param IDs