CMS 3D CMS Logo

PPSAlignmentConfiguration.h
Go to the documentation of this file.
1 /****************************************************************************
2 * Authors:
3 * Jan Kašpar (jan.kaspar@gmail.com)
4 * Mateusz Kocot (mateuszkocot99@gmail.com)
5 ****************************************************************************/
6 
7 #ifndef CondFormats_PPSObjects_PPSAlignmentConfiguration_h
8 #define CondFormats_PPSObjects_PPSAlignmentConfiguration_h
9 
11 
12 #include <vector>
13 #include <string>
14 #include <map>
15 
17 public:
18  // Auxiliary structures
19  struct PointErrors {
20  double x_;
21  double y_;
22  double ex_; // error x
23  double ey_; // error y
24 
26  };
27 
28  struct SelectionRange {
29  double x_min_;
30  double x_max_;
31 
33  };
34 
35  struct RPConfig {
37  unsigned int id_;
39  double slope_;
40  double sh_x_;
41 
44  double y_cen_add_;
45  double y_width_mult_;
46 
49 
51  };
52 
53  struct SectorConfig {
56  double slope_;
57 
60 
63 
65  };
66 
67  struct Binning {
68  double bin_size_x_; // mm
69  unsigned int n_bins_x_;
70 
72 
73  unsigned int n_bins_y_;
74  double y_min_, y_max_;
75 
76  unsigned int diffFN_n_bins_x_;
78 
81 
83  };
84 
85  // Getters
86  const SectorConfig& sectorConfig45() const;
87  const SectorConfig& sectorConfig56() const;
88 
89  double x_ali_sh_step() const;
90 
91  double y_mode_sys_unc() const;
92  double chiSqThreshold() const;
93  double y_mode_unc_max_valid() const;
94  double y_mode_max_valid() const;
95 
96  double minRPTracksSize() const;
97  double maxRPTracksSize() const;
98  double n_si() const;
99 
100  const std::map<unsigned int, std::vector<PointErrors>>& matchingReferencePoints() const;
101  const std::map<unsigned int, SelectionRange>& matchingShiftRanges() const;
102 
103  const std::map<unsigned int, SelectionRange>& alignment_x_meth_o_ranges() const;
104  unsigned int fitProfileMinBinEntries() const;
105  unsigned int fitProfileMinNReasonable() const;
106  unsigned int methOGraphMinN() const;
107  double methOUncFitRange() const;
108 
109  const std::map<unsigned int, SelectionRange>& alignment_x_relative_ranges() const;
110  unsigned int nearFarMinEntries() const;
111 
112  const std::map<unsigned int, SelectionRange>& alignment_y_ranges() const;
113  unsigned int modeGraphMinN() const;
114  unsigned int multSelProjYMinEntries() const;
115 
116  const Binning& binning() const;
117 
118  const std::vector<double>& extraParams() const;
119 
120  // Setters
123 
124  void setX_ali_sh_step(double x_ali_sh_step);
125 
126  void setY_mode_sys_unc(double y_mode_sys_unc);
127  void setChiSqThreshold(double chiSqThreshold);
130 
131  void setMinRPTracksSize(unsigned int minRPTracksSize);
132  void setMaxRPTracksSize(unsigned int maxRPTracksSize);
133  void setN_si(double n_si);
134 
135  void setMatchingReferencePoints(std::map<unsigned int, std::vector<PointErrors>>& matchingReferencePoints);
136  void setMatchingShiftRanges(std::map<unsigned int, SelectionRange>& matchingShiftRanges);
137 
138  void setAlignment_x_meth_o_ranges(std::map<unsigned int, SelectionRange>& alignment_x_meth_o_ranges);
141  void setMethOGraphMinN(unsigned int methOGraphMinN);
143 
144  void setAlignment_x_relative_ranges(std::map<unsigned int, SelectionRange>& alignment_x_relative_ranges);
145  void setNearFarMinEntries(unsigned int nearFarMinEntries);
146 
147  void setAlignment_y_ranges(std::map<unsigned int, SelectionRange>& alignment_y_ranges);
148  void setModeGraphMinN(unsigned int modeGraphMinN);
150 
151  void setBinning(Binning& binning);
152 
153  void setExtraParams(std::vector<double>& extraParams);
154 
155  // << operator
156  friend std::ostream& operator<<(std::ostream& os, const PPSAlignmentConfiguration& c);
157 
158 private:
160 
161  double x_ali_sh_step_; // mm
162 
167 
168  unsigned int minRPTracksSize_;
169  unsigned int maxRPTracksSize_;
170  double n_si_;
171 
172  std::map<unsigned int, std::vector<PointErrors>> matchingReferencePoints_;
173  std::map<unsigned int, SelectionRange> matchingShiftRanges_;
174 
175  std::map<unsigned int, SelectionRange> alignment_x_meth_o_ranges_;
178  unsigned int methOGraphMinN_;
179  double methOUncFitRange_; // mm
180 
181  std::map<unsigned int, SelectionRange> alignment_x_relative_ranges_;
182  unsigned int nearFarMinEntries_;
183 
184  std::map<unsigned int, SelectionRange> alignment_y_ranges_;
185  unsigned int modeGraphMinN_;
187 
189 
190  std::vector<double> extraParams_;
191 
193 };
194 
195 std::ostream& operator<<(std::ostream& os, const PPSAlignmentConfiguration::RPConfig& rc);
196 std::ostream& operator<<(std::ostream& os, const PPSAlignmentConfiguration::SectorConfig& sc);
197 std::ostream& operator<<(std::ostream& os, const PPSAlignmentConfiguration::Binning& b);
198 
199 #endif
std::ostream & operator<<(std::ostream &os, const PPSAlignmentConfiguration::RPConfig &rc)
const std::map< unsigned int, SelectionRange > & alignment_x_meth_o_ranges() const
void setSectorConfig56(SectorConfig &sectorConfig56)
void setMethOGraphMinN(unsigned int methOGraphMinN)
const std::map< unsigned int, SelectionRange > & alignment_y_ranges() const
void setFitProfileMinNReasonable(unsigned int fitProfileMinNReasonable)
std::map< unsigned int, SelectionRange > alignment_x_relative_ranges_
const std::map< unsigned int, SelectionRange > & matchingShiftRanges() const
std::map< unsigned int, SelectionRange > matchingShiftRanges_
void setY_mode_unc_max_valid(double y_mode_unc_max_valid)
void setAlignment_x_relative_ranges(std::map< unsigned int, SelectionRange > &alignment_x_relative_ranges)
void setY_mode_max_valid(double y_mode_max_valid)
void setAlignment_y_ranges(std::map< unsigned int, SelectionRange > &alignment_y_ranges)
unsigned int multSelProjYMinEntries() const
const SectorConfig & sectorConfig45() const
void setMatchingReferencePoints(std::map< unsigned int, std::vector< PointErrors >> &matchingReferencePoints)
const std::map< unsigned int, std::vector< PointErrors > > & matchingReferencePoints() const
void setMatchingShiftRanges(std::map< unsigned int, SelectionRange > &matchingShiftRanges)
void setFitProfileMinBinEntries(unsigned int fitProfileMinBinEntries)
void setNearFarMinEntries(unsigned int nearFarMinEntries)
std::map< unsigned int, std::vector< PointErrors > > matchingReferencePoints_
void setAlignment_x_meth_o_ranges(std::map< unsigned int, SelectionRange > &alignment_x_meth_o_ranges)
void setMultSelProjYMinEntries(unsigned int multSelProjYMinEntries)
void setX_ali_sh_step(double x_ali_sh_step)
const std::map< unsigned int, SelectionRange > & alignment_x_relative_ranges() const
std::map< unsigned int, SelectionRange > alignment_x_meth_o_ranges_
void setMethOUncFitRange(double methOUncFitRange)
void setY_mode_sys_unc(double y_mode_sys_unc)
void setChiSqThreshold(double chiSqThreshold)
double b
Definition: hdecay.h:118
const SectorConfig & sectorConfig56() const
#define COND_SERIALIZABLE
Definition: Serializable.h:39
unsigned int fitProfileMinBinEntries() const
void setModeGraphMinN(unsigned int modeGraphMinN)
unsigned int fitProfileMinNReasonable() const
void setMinRPTracksSize(unsigned int minRPTracksSize)
void setSectorConfig45(SectorConfig &sectorConfig45)
void setExtraParams(std::vector< double > &extraParams)
friend std::ostream & operator<<(std::ostream &os, const PPSAlignmentConfiguration &c)
std::map< unsigned int, SelectionRange > alignment_y_ranges_
unsigned int nearFarMinEntries() const
const std::vector< double > & extraParams() const
void setMaxRPTracksSize(unsigned int maxRPTracksSize)