CMS 3D CMS Logo

Functions
PPSAlignmentConfiguration.cc File Reference
#include "CondFormats/PPSObjects/interface/PPSAlignmentConfiguration.h"
#include <iostream>
#include <cmath>
#include <iomanip>

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &os, const PPSAlignmentConfiguration::RPConfig &rc)
 
std::ostream & operator<< (std::ostream &os, const PPSAlignmentConfiguration::SectorConfig &sc)
 
std::ostream & operator<< (std::ostream &os, const PPSAlignmentConfiguration::Binning &b)
 
std::ostream & operator<< (std::ostream &os, const PPSAlignmentConfiguration &c)
 

Function Documentation

◆ operator<<() [1/4]

std::ostream& operator<< ( std::ostream &  os,
const PPSAlignmentConfiguration::RPConfig rc 
)

Definition at line 135 of file PPSAlignmentConfiguration.cc.

References alignBH_cfg::fixed, PPSAlignmentConfiguration::RPConfig::id_, PPSAlignmentConfiguration::RPConfig::name_, l1tGTMenu_BTagSeeds_cff::os, PPSAlignmentConfiguration::RPConfig::position_, PPSAlignmentConfiguration::RPConfig::sh_x_, PPSAlignmentConfiguration::RPConfig::slope_, PPSAlignmentConfiguration::RPConfig::x_max_fit_mode_, PPSAlignmentConfiguration::RPConfig::x_min_fit_mode_, PPSAlignmentConfiguration::RPConfig::x_slice_min_, PPSAlignmentConfiguration::RPConfig::x_slice_n_, PPSAlignmentConfiguration::RPConfig::x_slice_w_, PPSAlignmentConfiguration::RPConfig::y_cen_add_, PPSAlignmentConfiguration::RPConfig::y_max_fit_mode_, and PPSAlignmentConfiguration::RPConfig::y_width_mult_.

135  {
136  os << std::fixed << std::setprecision(3);
137  os << " " << rc.name_ << ", id = " << rc.id_ << ", position = " << rc.position_ << ":\n";
138  os << " slope = " << rc.slope_ << ", sh_x = " << rc.sh_x_ << "\n";
139  os << " x_min_fit_mode = " << rc.x_min_fit_mode_ << ", x_max_fit_mode = " << rc.x_max_fit_mode_ << "\n";
140  os << " y_max_fit_mode = " << rc.y_max_fit_mode_ << "\n";
141  os << " y_cen_add = " << rc.y_cen_add_ << ", y_width_mult = " << rc.y_width_mult_ << "\n";
142  os << std::setprecision(2);
143  os << " x slices: min = " << rc.x_slice_min_ << ", w = " << rc.x_slice_w_ << ", n = " << rc.x_slice_n_;
144 
145  return os;
146 }

◆ operator<<() [2/4]

std::ostream& operator<< ( std::ostream &  os,
const PPSAlignmentConfiguration::SectorConfig sc 
)

Definition at line 148 of file PPSAlignmentConfiguration.cc.

References PPSAlignmentConfiguration::SectorConfig::cut_h_a_, PPSAlignmentConfiguration::SectorConfig::cut_h_apply_, PPSAlignmentConfiguration::SectorConfig::cut_h_c_, PPSAlignmentConfiguration::SectorConfig::cut_h_si_, PPSAlignmentConfiguration::SectorConfig::cut_v_a_, PPSAlignmentConfiguration::SectorConfig::cut_v_apply_, PPSAlignmentConfiguration::SectorConfig::cut_v_c_, PPSAlignmentConfiguration::SectorConfig::cut_v_si_, alignBH_cfg::fixed, PPSAlignmentConfiguration::SectorConfig::name_, l1tGTMenu_BTagSeeds_cff::os, PPSAlignmentConfiguration::SectorConfig::rp_F_, PPSAlignmentConfiguration::SectorConfig::rp_N_, and PPSAlignmentConfiguration::SectorConfig::slope_.

148  {
149  os << std::fixed << std::setprecision(3);
150  os << sc.name_ << ":\n";
151  os << sc.rp_N_ << "\n" << sc.rp_F_ << "\n";
152  os << std::setprecision(3);
153  os << " slope = " << sc.slope_ << "\n";
154  os << " cut_h: apply = " << std::boolalpha << sc.cut_h_apply_ << ", a = " << sc.cut_h_a_ << ", c = " << sc.cut_h_c_
155  << ", si = " << sc.cut_h_si_ << "\n";
156  os << " cut_v: apply = " << std::boolalpha << sc.cut_v_apply_ << ", a = " << sc.cut_v_a_ << ", c = " << sc.cut_v_c_
157  << ", si = " << sc.cut_v_si_ << "\n";
158 
159  return os;
160 }

◆ operator<<() [3/4]

std::ostream& operator<< ( std::ostream &  os,
const PPSAlignmentConfiguration::Binning b 
)

Definition at line 162 of file PPSAlignmentConfiguration.cc.

References b, and l1tGTMenu_BTagSeeds_cff::os.

162  {
163  os << " bin_size_x = " << b.bin_size_x_ << ", n_bins_x = " << b.n_bins_x_ << "\n";
164  os << " pixel_x_offset = " << b.pixel_x_offset_ << "\n";
165  os << " n_bins_y = " << b.n_bins_y_ << ", y_min = " << b.y_min_ << ", y_max = " << b.y_max_ << "\n";
166  os << " diff far-near:"
167  << "\n";
168  os << " n_bins_x = " << b.diffFN_n_bins_x_ << ", x_min = " << b.diffFN_x_min_
169  << ", x_max = " << b.diffFN_x_max_ << "\n";
170  os << " slice plots:"
171  << "\n";
172  os << " n_bins_x = " << b.slice_n_bins_x_ << ", x_min = " << b.slice_x_min_ << ", x_max = " << b.slice_x_max_
173  << "\n";
174  os << " n_bins_y = " << b.slice_n_bins_y_ << ", y_min = " << b.slice_y_min_ << ", y_max = " << b.slice_y_max_;
175 
176  return os;
177 }
double b
Definition: hdecay.h:120

◆ operator<<() [4/4]

std::ostream& operator<< ( std::ostream &  os,
const PPSAlignmentConfiguration c 
)

Definition at line 179 of file PPSAlignmentConfiguration.cc.

References DummyCfis::c, mps_fire::i, l1tGTMenu_BTagSeeds_cff::os, and AlCaHLTBitMon_ParallelJobs::p.

179  {
180  os << "* " << c.sectorConfig45_ << "\n\n";
181  os << "* " << c.sectorConfig56_ << "\n\n";
182 
183  std::map<unsigned int, std::string> rpTags = {{c.sectorConfig45_.rp_F_.id_, c.sectorConfig45_.rp_F_.name_},
184  {c.sectorConfig45_.rp_N_.id_, c.sectorConfig45_.rp_N_.name_},
185  {c.sectorConfig56_.rp_N_.id_, c.sectorConfig56_.rp_N_.name_},
186  {c.sectorConfig56_.rp_F_.id_, c.sectorConfig56_.rp_F_.name_}};
187 
188  os << "* x alignment shift step\n";
189  os << " x_ali_sh_step = " << c.x_ali_sh_step_ << "\n\n";
190 
191  os << "* mode graph parameters\n";
192  os << " y_mode_sys_unc = " << c.y_mode_sys_unc_ << "\n";
193  os << " chiSqThreshold = " << c.chiSqThreshold_ << "\n";
194  os << " y_mode_unc_max_valid = " << c.y_mode_unc_max_valid_ << "\n";
195  os << " y_mode_max_valid = " << c.y_mode_max_valid_ << "\n\n";
196 
197  os << "* selection\n";
198  os << " min_RP_tracks_size = " << c.minRPTracksSize_ << "\n";
199  os << " max_RP_tracks_size = " << c.maxRPTracksSize_ << "\n\n";
200 
201  os << "* cuts\n";
202  os << " n_si = " << c.n_si_ << "\n\n";
203 
204  os << "* matching\n" << std::setprecision(3);
205 
206  os << " shift ranges:\n";
207  for (const auto& p : c.matchingShiftRanges_)
208  os << " RP " << rpTags[p.first] << " (" << std::setw(3) << p.first << "): sh_min = " << p.second.x_min_
209  << ", sh_max = " << p.second.x_max_ << "\n";
210 
211  os << " reference points:\n";
212  for (const auto& pm : c.matchingReferencePoints_) {
213  os << " " << std::setw(3) << pm.first << ": ";
214  for (unsigned int i = 0; i < pm.second.size(); i++) {
215  const auto& p = pm.second[i];
216  if (i % 5 == 0 && i > 0)
217  os << "\n ";
218  os << "(" << std::setw(6) << p.x_ << " +- " << p.ex_ << ", " << std::setw(6) << p.y_ << " +- " << p.ey_ << "), ";
219  }
220  os << "\n";
221  }
222 
223  os << "\n"
224  << "* alignment_x_meth_o\n";
225  for (const auto& p : c.alignment_x_meth_o_ranges_)
226  os << " RP " << rpTags[p.first] << " (" << std::setw(3) << p.first << "): sh_min = " << p.second.x_min_
227  << ", sh_max = " << p.second.x_max_ << "\n";
228  os << " fit_profile_min_bin_entries = " << c.fitProfileMinBinEntries_ << "\n";
229  os << " fit_profile_min_N_reasonable = " << c.fitProfileMinNReasonable_ << "\n";
230  os << " meth_o_graph_min_N = " << c.methOGraphMinN_ << "\n";
231  os << " meth_o_unc_fit_range = " << c.methOUncFitRange_ << "\n";
232 
233  os << "\n"
234  << "* alignment_x_relative\n";
235  for (const auto& p : c.alignment_x_relative_ranges_)
236  if (p.first == c.sectorConfig45_.rp_N_.id_ || p.first == c.sectorConfig56_.rp_N_.id_) { // only near RPs
237  os << " RP " << rpTags[p.first] << " (" << std::setw(3) << p.first << "): sh_min = " << p.second.x_min_
238  << ", sh_max = " << p.second.x_max_ << "\n";
239  }
240  os << " near_far_min_entries = " << c.nearFarMinEntries_ << "\n";
241 
242  os << "\n"
243  << "* alignment_y\n";
244  for (const auto& p : c.alignment_y_ranges_)
245  os << " RP " << rpTags[p.first] << " (" << std::setw(3) << p.first << "): sh_min = " << p.second.x_min_
246  << ", sh_max = " << p.second.x_max_ << "\n";
247  os << " mode_graph_min_N = " << c.modeGraphMinN_ << "\n";
248  os << " mult_sel_proj_y_min_entries = " << c.multSelProjYMinEntries_ << "\n";
249 
250  os << "\n"
251  << "* binning\n";
252  os << c.binning_ << "\n";
253 
254  if (!c.extraParams_.empty()) {
255  os << "\n";
256  os << "extra_params:\n";
257  for (size_t i = 0; i < c.extraParams_.size(); i++) {
258  os << std::setw(5) << i << ": " << c.extraParams_[i] << "\n";
259  }
260  }
261 
262  return os;
263 }