CMS 3D CMS Logo

PedeLabelerBase.h
Go to the documentation of this file.
1 #ifndef Alignment_MillePedeAlignmentAlgorithm_PedeLabelerBase_h
2 #define Alignment_MillePedeAlignmentAlgorithm_PedeLabelerBase_h
3 
16 
21 
23 
24 #include <vector>
25 
26 class Alignable;
27 class AlignableTracker;
28 class AlignableMuon;
29 class AlignableExtras;
31 
32 /***************************************
33 ****************************************/
34 class PedeLabelerBase {
35 public:
39 
40  class TopLevelAlignables {
41  public:
43  : aliTracker_(aliTracker), aliMuon_(aliMuon), aliExtras_(extras) {}
47  };
48 
51  virtual ~PedeLabelerBase() {}
53  virtual void addCalibrations(const std::vector<IntegratedCalibrationBase *> &iCals);
54 
58  virtual unsigned int alignableLabel(Alignable *alignable) const = 0;
63  virtual unsigned int alignableLabelFromParamAndInstance(Alignable *alignable,
64  unsigned int param,
65  unsigned int instance) const = 0;
66  virtual unsigned int lasBeamLabel(unsigned int lasBeamId) const = 0;
68  virtual unsigned int parameterLabel(unsigned int aliLabel, unsigned int parNum) const = 0;
71  virtual unsigned int parameterLabel(Alignable *alignable,
72  unsigned int parNum,
74  const TrajectoryStateOnSurface &tsos) const = 0;
76  virtual bool hasSplitParameters(Alignable *alignable) const = 0;
78  virtual unsigned int numberOfParameterInstances(Alignable *alignable, int param = -1) const = 0;
80  virtual unsigned int maxNumberOfParameterInstances() const = 0;
82  unsigned int parameterInstanceOffset() const { return theParamInstanceOffset; }
83 
85  virtual unsigned int paramNumFromLabel(unsigned int paramLabel) const = 0;
87  virtual unsigned int alignableLabelFromLabel(unsigned int label) const = 0;
90  virtual Alignable *alignableFromLabel(unsigned int label) const = 0;
93  virtual unsigned int lasBeamIdFromLabel(unsigned int label) const = 0;
96  virtual std::pair<IntegratedCalibrationBase *, unsigned int> calibrationParamFromLabel(unsigned int label) const;
97 
98  virtual const RunRange &runRangeFromLabel(unsigned int label) const { return theOpenRunRange; }
101  virtual unsigned int firstFreeLabel() const;
102 
104  virtual unsigned int calibrationLabel(const IntegratedCalibrationBase *calib, unsigned int paramNum) const;
108 
109  static const unsigned int theMaxNumParam;
110  static const unsigned int theParamInstanceOffset;
111  static const unsigned int theMinLabel;
112 
113 protected:
116  virtual unsigned int firstNonAlignableLabel() const;
117 
119  const AlignableObjectId &objectIdProvider() const { return alignableObjectId_; }
120 
122 
123 private:
126 
128  std::vector<std::pair<IntegratedCalibrationBase *, unsigned int> > theCalibrationLabels;
129 };
130 
131 #endif
PedeLabelerBase::parameterInstanceOffset
unsigned int parameterInstanceOffset() const
offset in labels between consecutive parameter instances of Alignable*s
Definition: PedeLabelerBase.h:81
PedeLabelerBase::~PedeLabelerBase
virtual ~PedeLabelerBase()
Definition: PedeLabelerBase.h:50
AlignableObjectId
Allows conversion between type and name, and vice-versa.
Definition: AlignableObjectId.h:13
PedeLabelerBase::alignableFromLabel
virtual Alignable * alignableFromLabel(unsigned int label) const =0
TrajectoryStateOnSurface.h
PedeLabelerBase::lasBeamLabel
virtual unsigned int lasBeamLabel(unsigned int lasBeamId) const =0
PedeLabelerBase::paramNumFromLabel
virtual unsigned int paramNumFromLabel(unsigned int paramLabel) const =0
parameter number, 0 <= .. < theMaxNumParam, belonging to unique parameter label
PedeLabelerBase::alignableObjectId_
const AlignableObjectId alignableObjectId_
Definition: PedeLabelerBase.h:124
PedeLabelerBase::firstNonAlignableLabel
virtual unsigned int firstNonAlignableLabel() const
Definition: PedeLabelerBase.cc:70
PedeLabelerBase::alignableLabelFromLabel
virtual unsigned int alignableLabelFromLabel(unsigned int label) const =0
alignable label from parameter label (works also for alignable label...)
PedeLabelerBase::alignableTracker
const AlignableTracker * alignableTracker() const
Definition: PedeLabelerBase.h:104
align::RunRange
std::pair< RunNumber, RunNumber > RunRange
Definition: Utilities.h:38
PedeLabelerBase::theCalibrationLabels
std::vector< std::pair< IntegratedCalibrationBase *, unsigned int > > theCalibrationLabels
pairs of calibrations and their first label
Definition: PedeLabelerBase.h:127
PedeLabelerBase::runRangeFromLabel
virtual const RunRange & runRangeFromLabel(unsigned int label) const
Definition: PedeLabelerBase.h:97
Time.h
align::RunNumber
cond::RealTimeType< cond::runnumber >::type RunNumber
Definition: Utilities.h:37
Alignable
Definition: Alignable.h:27
IntegratedCalibrationBase
Definition: IntegratedCalibrationBase.h:40
PedeLabelerBase::TopLevelAlignables::aliTracker_
AlignableTracker * aliTracker_
Definition: PedeLabelerBase.h:43
PedeLabelerBase::alignableLabel
virtual unsigned int alignableLabel(Alignable *alignable) const =0
config
Definition: config.py:1
TrajectoryStateOnSurface
Definition: TrajectoryStateOnSurface.h:16
PedeLabelerBase::numberOfParameterInstances
virtual unsigned int numberOfParameterInstances(Alignable *alignable, int param=-1) const =0
returns the number of instances for a given parameter
PedeLabelerBase::maxNumberOfParameterInstances
virtual unsigned int maxNumberOfParameterInstances() const =0
returns the maximum number of instances for any parameter of an Alignable*
PedeLabelerBase::lasBeamIdFromLabel
virtual unsigned int lasBeamIdFromLabel(unsigned int label) const =0
PedeLabelerBase::alignableLabelFromParamAndInstance
virtual unsigned int alignableLabelFromParamAndInstance(Alignable *alignable, unsigned int param, unsigned int instance) const =0
AlignableTracker
Definition: AlignableTracker.h:17
PedeLabelerBase::RunRanges
align::RunRanges RunRanges
Definition: PedeLabelerBase.h:37
PedeLabelerBase::TopLevelAlignables
Definition: PedeLabelerBase.h:39
AlignableExtras
Definition: AlignableExtras.h:19
PedeLabelerBase::topLevelAlignables_
const TopLevelAlignables topLevelAlignables_
Definition: PedeLabelerBase.h:123
PedeLabelerBase::RunRange
align::RunRange RunRange
Definition: PedeLabelerBase.h:36
calib
Definition: CalibElectron.h:12
PedeLabelerBase::objectIdProvider
const AlignableObjectId & objectIdProvider() const
Return tracker alignable object ID provider derived from the tracker's geometry.
Definition: PedeLabelerBase.h:118
PedeLabelerBase::TopLevelAlignables::TopLevelAlignables
TopLevelAlignables(AlignableTracker *aliTracker, AlignableMuon *aliMuon, AlignableExtras *extras)
Definition: PedeLabelerBase.h:41
edm::ParameterSet
Definition: ParameterSet.h:47
PedeLabelerBase::theMaxNumParam
static const unsigned int theMaxNumParam
Definition: PedeLabelerBase.h:108
AlignableMuon
Constructor of the full muon geometry.
Definition: AlignableMuon.h:38
PedeLabelerBase::PedeLabelerBase
PedeLabelerBase(const TopLevelAlignables &alignables, const edm::ParameterSet &config)
constructor from three Alignables (null pointers allowed )
Definition: PedeLabelerBase.cc:28
PedeLabelerBase::addCalibrations
virtual void addCalibrations(const std::vector< IntegratedCalibrationBase * > &iCals)
tell labeler to treat also integrated calibrations
Definition: PedeLabelerBase.cc:101
PedeLabelerBase
Definition: PedeLabelerBase.h:33
Utilities.h
PedeLabelerBase::TopLevelAlignables::aliMuon_
AlignableMuon * aliMuon_
Definition: PedeLabelerBase.h:44
PedeLabelerBase::TopLevelAlignables::aliExtras_
AlignableExtras * aliExtras_
Definition: PedeLabelerBase.h:45
PedeLabelerBase::hasSplitParameters
virtual bool hasSplitParameters(Alignable *alignable) const =0
returns true if the alignable has parameters that are split into various bins
volumeBasedMagneticField_160812_cfi.paramLabel
paramLabel
Definition: volumeBasedMagneticField_160812_cfi.py:37
instance
static PFTauRenderPlugin instance
Definition: PFTauRenderPlugin.cc:70
AlignableObjectId.h
PedeLabelerBase::theParamInstanceOffset
static const unsigned int theParamInstanceOffset
Definition: PedeLabelerBase.h:109
dumpTauVariables_cfi.eventInfo
eventInfo
add run, event number and lumi section
Definition: dumpTauVariables_cfi.py:12
PedeLabelerBase::theMinLabel
static const unsigned int theMinLabel
Definition: PedeLabelerBase.h:110
PedeLabelerBase::parameterLabel
virtual unsigned int parameterLabel(unsigned int aliLabel, unsigned int parNum) const =0
returns the label for a given alignable parameter number combination
align::RunRanges
std::vector< RunRange > RunRanges
Definition: Utilities.h:39
AlignmentAlgorithmBase.h
Interface/Base class for alignment algorithms, each alignment algorithm has to be derived from this c...
PedeLabelerBase::alignableExtras
const AlignableExtras * alignableExtras() const
Definition: PedeLabelerBase.h:106
PedeLabelerBase::RunNumber
align::RunNumber RunNumber
Definition: PedeLabelerBase.h:35
ParameterSet.h
PedeLabelerBase::theOpenRunRange
const RunRange theOpenRunRange
Definition: PedeLabelerBase.h:120
PedeLabelerBase::calibrationParamFromLabel
virtual std::pair< IntegratedCalibrationBase *, unsigned int > calibrationParamFromLabel(unsigned int label) const
Definition: PedeLabelerBase.cc:37
PedeLabelerBase::calibrationLabel
virtual unsigned int calibrationLabel(const IntegratedCalibrationBase *calib, unsigned int paramNum) const
label for parameter 'paramNum' (counted from 0) of an integrated calibration
Definition: PedeLabelerBase.cc:75
PedeLabelerBase::alignableMuon
const AlignableMuon * alignableMuon() const
Definition: PedeLabelerBase.h:105
label
const char * label
Definition: PFTauDecayModeTools.cc:11
AlignmentAlgorithmBase::EventInfo
define event information passed to algorithms
Definition: AlignmentAlgorithmBase.h:72
PedeLabelerBase::firstFreeLabel
virtual unsigned int firstFreeLabel() const
Definition: PedeLabelerBase.cc:59