CMS 3D CMS Logo

List of all members | Classes | Public Member Functions | Private Types | Private Attributes
DTVDriftCalibration Class Reference

#include <DTVDriftCalibration.h>

Inheritance diagram for DTVDriftCalibration:
edm::EDAnalyzer edm::EDConsumerBase

Classes

class  cellInfo
 

Public Member Functions

void analyze (const edm::Event &event, const edm::EventSetup &eventSetup) override
 
 DTVDriftCalibration (const edm::ParameterSet &pset)
 Constructor. More...
 
void endJob () override
 
 ~DTVDriftCalibration () override
 Destructor. More...
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Types

typedef DTTMax::TMax TMax
 
enum  TMaxGranularity { byChamber, bySL, byPartition }
 

Private Attributes

bool debug
 
std::string digiLabel
 
bool findVDriftAndT0
 
h2DSegmh2DSegmRPhi
 
h2DSegmh2DSegmRZ
 
h4DSegmh4DSegmAllCh
 
TH1F * hChi2
 
dtcalibration::Histograms histograms_
 
std::unique_ptr< DTSegmentSelectorselect_
 
std::string theCalibChamber
 
edm::ParameterSet theCalibFilePar
 
TFile * theFile
 
std::unique_ptr< DTMeanTimerFittertheFitter
 
TMaxGranularity theGranularity
 
edm::EDGetTokenT< DTRecSegment4DCollectiontheRecHits4DToken
 
std::unique_ptr< DTTTrigBaseSynctheSync
 
std::string theVDriftOutputFile
 
std::map< DTWireId, cellInfo * > theWireIdAndCellMap
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 

Detailed Description

No description available.

Author
M. Giunta

Definition at line 33 of file DTVDriftCalibration.h.

Member Typedef Documentation

◆ TMax

Definition at line 52 of file DTVDriftCalibration.h.

Member Enumeration Documentation

◆ TMaxGranularity

Enumerator
byChamber 
bySL 
byPartition 

Definition at line 84 of file DTVDriftCalibration.h.

Constructor & Destructor Documentation

◆ DTVDriftCalibration()

DTVDriftCalibration::DTVDriftCalibration ( const edm::ParameterSet pset)

Constructor.

Definition at line 42 of file DTVDriftCalibration.cc.

43  : // Get the synchronizer
44  theSync{DTTTrigSyncFactory::get()->create(pset.getParameter<string>("tTrigMode"),
45  pset.getParameter<ParameterSet>("tTrigModeConfig"))}
46 
47 {
49  select_ = std::make_unique<DTSegmentSelector>(pset, collector);
50 
51  // The name of the 4D rec hits collection
52  theRecHits4DToken = (consumes<DTRecSegment4DCollection>(pset.getParameter<InputTag>("recHits4DLabel")));
53 
54  // The root file which will contain the histos
55  string rootFileName = pset.getUntrackedParameter<string>("rootFileName");
56  theFile = new TFile(rootFileName.c_str(), "RECREATE");
57  theFile->cd();
58 
59  debug = pset.getUntrackedParameter<bool>("debug", false);
60 
61  theFitter = std::make_unique<DTMeanTimerFitter>(theFile);
62  if (debug)
63  theFitter->setVerbosity(1);
64 
65  hChi2 = new TH1F("hChi2", "Chi squared tracks", 100, 0, 100);
66  h2DSegmRPhi = new h2DSegm("SLRPhi");
67  h2DSegmRZ = new h2DSegm("SLRZ");
68  h4DSegmAllCh = new h4DSegm("AllCh");
70 
71  findVDriftAndT0 = pset.getUntrackedParameter<bool>("fitAndWrite", false);
72 
73  // Chamber/s to calibrate
74  theCalibChamber = pset.getUntrackedParameter<string>("calibChamber", "All");
75 
76  // the txt file which will contain the calibrated constants
77  theVDriftOutputFile = pset.getUntrackedParameter<string>("vDriftFileName");
78 
79  // get parameter set for DTCalibrationMap constructor
80  theCalibFilePar = pset.getUntrackedParameter<ParameterSet>("calibFileConfig");
81 
82  // the granularity to be used for tMax
83  string tMaxGranularity = pset.getUntrackedParameter<string>("tMaxGranularity", "bySL");
84 
85  // Enforce it to be by SL since rest is not implemented
86  if (tMaxGranularity != "bySL") {
87  LogError("Calibration") << "[DTVDriftCalibration] tMaxGranularity will be fixed to bySL.";
88  tMaxGranularity = "bySL";
89  }
90  // Initialize correctly the enum which specify the granularity for the calibration
91  if (tMaxGranularity == "bySL") {
93  } else if (tMaxGranularity == "byChamber") {
95  } else if (tMaxGranularity == "byPartition") {
97  } else
98  throw cms::Exception("Configuration")
99  << "[DTVDriftCalibration] Check parameter tMaxGranularity: " << tMaxGranularity << " option not available";
100 
101  LogVerbatim("Calibration") << "[DTVDriftCalibration]Constructor called!";
102 }

References get, and muonDTDigis_cfi::pset.

◆ ~DTVDriftCalibration()

DTVDriftCalibration::~DTVDriftCalibration ( )
override

Destructor.

Definition at line 104 of file DTVDriftCalibration.cc.

104  {
105  theFile->Close();
106  LogVerbatim("Calibration") << "[DTVDriftCalibration]Destructor called!";
107 }

References theFile.

Member Function Documentation

◆ analyze()

void DTVDriftCalibration::analyze ( const edm::Event event,
const edm::EventSetup eventSetup 
)
overridevirtual

Implements edm::EDAnalyzer.

Definition at line 109 of file DTVDriftCalibration.cc.

109  {
110  LogTrace("Calibration") << "--- [DTVDriftCalibration] Event analysed #Run: " << event.id().run()
111  << " #Event: " << event.id().event();
112  theFile->cd();
113  DTChamberId chosenChamberId;
114 
115  if (theCalibChamber != "All") {
116  stringstream linestr;
117  int selWheel, selStation, selSector;
118  linestr << theCalibChamber;
119  linestr >> selWheel >> selStation >> selSector;
120  chosenChamberId = DTChamberId(selWheel, selStation, selSector);
121  LogTrace("Calibration") << "chosen chamber " << chosenChamberId;
122  }
123 
124  // Get the DT Geometry
125  ESHandle<DTGeometry> dtGeom;
126  eventSetup.get<MuonGeometryRecord>().get(dtGeom);
127 
128  // Get the rechit collection from the event
129  Handle<DTRecSegment4DCollection> all4DSegments;
130  event.getByToken(theRecHits4DToken, all4DSegments);
131 
132  // Get the map of noisy channels
133  /*ESHandle<DTStatusFlag> statusMap;
134  if(checkNoisyChannels) {
135  eventSetup.get<DTStatusFlagRcd>().get(statusMap);
136  }*/
137 
138  // Set the event setup in the Synchronizer
139  theSync->setES(eventSetup);
140 
141  // Loop over segments by chamber
143  for (chamberIdIt = all4DSegments->id_begin(); chamberIdIt != all4DSegments->id_end(); ++chamberIdIt) {
144  // Get the chamber from the setup
145  const DTChamber* chamber = dtGeom->chamber(*chamberIdIt);
146  LogTrace("Calibration") << "Chamber Id: " << *chamberIdIt;
147 
148  // Calibrate just the chosen chamber/s
149  if ((theCalibChamber != "All") && ((*chamberIdIt) != chosenChamberId))
150  continue;
151 
152  // Get the range for the corresponding ChamberId
153  DTRecSegment4DCollection::range range = all4DSegments->get((*chamberIdIt));
154 
155  // Loop over the rechits of this DetUnit
156  for (DTRecSegment4DCollection::const_iterator segment = range.first; segment != range.second; ++segment) {
157  if (!(*segment).hasZed() && !(*segment).hasPhi()) {
158  LogError("Calibration") << "4D segment without Z and Phi segments";
159  continue;
160  }
161 
162  LogTrace("Calibration") << "Segment local pos (in chamber RF): " << (*segment).localPosition()
163  << "\nSegment global pos: " << chamber->toGlobal((*segment).localPosition());
164 
165  if (!((*select_)(*segment, event, eventSetup)))
166  continue;
167 
168  LocalPoint phiSeg2DPosInCham;
169  LocalVector phiSeg2DDirInCham;
170  map<DTSuperLayerId, vector<DTRecHit1D> > hitsBySLMap;
171  if ((*segment).hasPhi()) {
172  const DTChamberRecSegment2D* phiSeg = (*segment).phiSegment(); // phiSeg lives in the chamber RF
173  phiSeg2DPosInCham = phiSeg->localPosition();
174  phiSeg2DDirInCham = phiSeg->localDirection();
175  vector<DTRecHit1D> phiHits = phiSeg->specificRecHits();
176  for (vector<DTRecHit1D>::const_iterator hit = phiHits.begin(); hit != phiHits.end(); ++hit) {
177  DTWireId wireId = (*hit).wireId();
178  DTSuperLayerId slId = wireId.superlayerId();
179  hitsBySLMap[slId].push_back(*hit);
180  }
181  }
182  // Get the Theta 2D segment and plot the angle in the chamber RF
183  LocalVector zSeg2DDirInCham;
184  LocalPoint zSeg2DPosInCham;
185  if ((*segment).hasZed()) {
186  const DTSLRecSegment2D* zSeg = (*segment).zSegment(); // zSeg lives in the SL RF
187  const DTSuperLayer* sl = chamber->superLayer(zSeg->superLayerId());
188  zSeg2DPosInCham = chamber->toLocal(sl->toGlobal((*zSeg).localPosition()));
189  zSeg2DDirInCham = chamber->toLocal(sl->toGlobal((*zSeg).localDirection()));
190  hitsBySLMap[zSeg->superLayerId()] = zSeg->specificRecHits();
191  }
192 
193  LocalPoint segment4DLocalPos = (*segment).localPosition();
194  LocalVector segment4DLocalDir = (*segment).localDirection();
195  double chiSquare = ((*segment).chi2() / (*segment).degreesOfFreedom());
196 
197  hChi2->Fill(chiSquare);
198  if ((*segment).hasPhi())
199  h2DSegmRPhi->Fill(phiSeg2DPosInCham.x(), phiSeg2DDirInCham.x() / phiSeg2DDirInCham.z());
200  if ((*segment).hasZed())
201  h2DSegmRZ->Fill(zSeg2DPosInCham.y(), zSeg2DDirInCham.y() / zSeg2DDirInCham.z());
202 
203  if ((*segment).hasZed() && (*segment).hasPhi())
204  h4DSegmAllCh->Fill(segment4DLocalPos.x(),
205  segment4DLocalPos.y(),
206  atan(segment4DLocalDir.x() / segment4DLocalDir.z()) * 180. / Geom::pi(),
207  atan(segment4DLocalDir.y() / segment4DLocalDir.z()) * 180. / Geom::pi(),
208  180 - segment4DLocalDir.theta() * 180. / Geom::pi());
209  else if ((*segment).hasPhi())
210  h4DSegmAllCh->Fill(segment4DLocalPos.x(),
211  atan(segment4DLocalDir.x() / segment4DLocalDir.z()) * 180. / Geom::pi());
212  else if ((*segment).hasZed())
213  LogWarning("Calibration") << "4d segment with only Z";
214 
215  //loop over the segments
216  for (map<DTSuperLayerId, vector<DTRecHit1D> >::const_iterator slIdAndHits = hitsBySLMap.begin();
217  slIdAndHits != hitsBySLMap.end();
218  ++slIdAndHits) {
219  if (slIdAndHits->second.size() < 3)
220  continue;
221  DTSuperLayerId slId = slIdAndHits->first;
222 
223  // Create the DTTMax, that computes the 4 TMax
224  DTTMax slSeg(slIdAndHits->second,
225  *(chamber->superLayer(slIdAndHits->first)),
226  chamber->toGlobal((*segment).localDirection()),
227  chamber->toGlobal((*segment).localPosition()),
228  *theSync,
229  histograms_);
230 
231  if (theGranularity == bySL) {
232  vector<const TMax*> tMaxes = slSeg.getTMax(slId);
233  DTWireId wireId(slId, 0, 0);
234  theFile->cd();
235  cellInfo* cell = theWireIdAndCellMap[wireId];
236  if (cell == nullptr) {
237  TString name = (((((TString) "TMax" + (long)slId.wheel()) + (long)slId.station()) + (long)slId.sector()) +
238  (long)slId.superLayer());
239  cell = new cellInfo(name);
240  theWireIdAndCellMap[wireId] = cell;
241  }
242  cell->add(tMaxes);
243  cell->update(); // FIXME to reset the counter to avoid triple counting, which actually is not used...
244  } else {
245  LogWarning("Calibration") << "[DTVDriftCalibration] ###Warning: the chosen granularity is not implemented "
246  "yet, only bySL available!";
247  }
248  // to be implemented: granularity different from bySL
249 
250  // else if (theGranularity == byPartition) {
251  // // Use the custom granularity defined by partition();
252  // // in this case, add() should be called once for each Tmax of each layer
253  // // and triple counting should be avoided within add()
254  // vector<cellInfo*> cells;
255  // for (int i=1; i<=4; i++) {
256  // const DTTMax::InfoLayer* iLayer = slSeg.getInfoLayer(i);
257  // if(iLayer == 0) continue;
258  // cellInfo * cell = partition(iLayer->idWire);
259  // cells.push_back(cell);
260  // vector<const TMax*> tMaxes = slSeg.getTMax(iLayer->idWire);
261  // cell->add(tMaxes);
262  // }
263  // //reset the counter to avoid triple counting
264  // for (vector<cellInfo*>::const_iterator i = cells.begin();
265  // i!= cells.end(); i++) {
266  // (*i)->update();
267  // }
268  // }
269  }
270  }
271  }
272 }

References DTVDriftCalibration::cellInfo::add(), bySL, relativeConstraints::chamber, DTGeometry::chamber(), simKBmtfDigis_cfi::chiSquare, h4DSegm::Fill(), h2DSegm::Fill(), edm::EventSetup::get(), get, DTTMax::getTMax(), h2DSegmRPhi, h2DSegmRZ, h4DSegmAllCh, hChi2, histograms_, DTRecSegment2D::localDirection(), DTRecSegment2D::localPosition(), LogTrace, genParticles_cff::map, Skims_PA_cff::name, Geom::pi(), FastTimerService_cff::range, DTChamberId::sector(), select_, DTRecSegment2D::specificRecHits(), DTChamberId::station(), DTSuperLayerId::superLayer(), DTSLRecSegment2D::superLayerId(), DTLayerId::superlayerId(), theCalibChamber, theFile, theGranularity, theRecHits4DToken, theSync, PV3DBase< T, PVType, FrameType >::theta(), theWireIdAndCellMap, GeomDet::toGlobal(), DTVDriftCalibration::cellInfo::update(), DTChamberId::wheel(), PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

◆ endJob()

void DTVDriftCalibration::endJob ( void  )
overridevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 274 of file DTVDriftCalibration.cc.

274  {
275  theFile->cd();
276  gROOT->GetList()->Write();
277  h2DSegmRPhi->Write();
278  h2DSegmRZ->Write();
279  h4DSegmAllCh->Write();
280  hChi2->Write();
281  // Instantiate a DTCalibrationMap object if you want to calculate the calibration constants
282  DTCalibrationMap calibValuesFile(theCalibFilePar);
283  // Create the object to be written to DB
284  DTMtime* mTime = new DTMtime();
285 
286  // write the TMax histograms of each SL to the root file
287  if (theGranularity == bySL) {
288  for (map<DTWireId, cellInfo*>::const_iterator wireCell = theWireIdAndCellMap.begin();
289  wireCell != theWireIdAndCellMap.end();
290  ++wireCell) {
291  cellInfo* cell = theWireIdAndCellMap[(*wireCell).first];
292  hTMaxCell* cellHists = cell->getHists();
293  theFile->cd();
294  cellHists->Write();
295  if (findVDriftAndT0) { // if TRUE: evaluate calibration constants from TMax hists filled in this job
296  // evaluate v_drift and sigma from the TMax histograms
297  DTWireId wireId = (*wireCell).first;
298  vector<float> newConstants;
299  TString N = (((((TString) "TMax" + (long)wireId.wheel()) + (long)wireId.station()) + (long)wireId.sector()) +
300  (long)wireId.superLayer());
301  vector<float> vDriftAndReso = theFitter->evaluateVDriftAndReso(N);
302 
303  // Don't write the constants for the SL if the vdrift was not computed
304  if (vDriftAndReso.front() == -1)
305  continue;
306  const DTCalibrationMap::CalibConsts* oldConstants = calibValuesFile.getConsts(wireId);
307  if (oldConstants != nullptr) {
308  newConstants.push_back((*oldConstants)[0]);
309  newConstants.push_back((*oldConstants)[1]);
310  newConstants.push_back((*oldConstants)[2]);
311  } else {
312  newConstants.push_back(-1);
313  newConstants.push_back(-1);
314  newConstants.push_back(-1);
315  }
316  for (int ivd = 0; ivd <= 5; ivd++) {
317  // 0=vdrift, 1=reso, 2=(3deltat0-2deltat0), 3=(2deltat0-1deltat0),
318  // 4=(1deltat0-0deltat0), 5=deltat0 from hists with max entries,
319  newConstants.push_back(vDriftAndReso[ivd]);
320  }
321 
322  calibValuesFile.addCell(calibValuesFile.getKey(wireId), newConstants);
323 
324  // vdrift is cm/ns , resolution is cm
325  mTime->set((wireId.layerId()).superlayerId(), vDriftAndReso[0], vDriftAndReso[1], DTVelocityUnits::cm_per_ns);
326  LogTrace("Calibration") << " SL: " << (wireId.layerId()).superlayerId() << " vDrift = " << vDriftAndReso[0]
327  << " reso = " << vDriftAndReso[1];
328  }
329  }
330  }
331 
332  // to be implemented: granularity different from bySL
333 
334  // if(theGranularity == "byChamber") {
335  // const vector<DTChamber*> chambers = dMap.chambers();
336 
337  // // Loop over all chambers
338  // for(vector<MuBarChamber*>::const_iterator chamber = chambers.begin();
339  // chamber != chambers.end(); chamber ++) {
340  // MuBarChamberId chamber_id = (*chamber)->id();
341  // MuBarDigiParameters::Key wire_id(chamber_id, 0, 0, 0);
342  // vector<float> newConstants;
343  // vector<float> vDriftAndReso = evaluateVDriftAndReso(wire_id, f);
344  // const CalibConsts* oldConstants = digiParams.getConsts(wire_id);
345  // if(oldConstants !=0) {
346  // newConstants = *oldConstants;
347  // newConstants.push_back(vDriftAndReso[0]);
348  // newConstants.push_back(vDriftAndReso[1]);
349  // newConstants.push_back(vDriftAndReso[2]);
350  // newConstants.push_back(vDriftAndReso[3]);
351  // } else {
352  // newConstants.push_back(-1);
353  // newConstants.push_back(-1);
354  // newConstants.push_back(vDriftAndReso[0]);
355  // newConstants.push_back(vDriftAndReso[1]);
356  // newConstants.push_back(vDriftAndReso[2]);
357  // newConstants.push_back(vDriftAndReso[3]);
358  // }
359  // digiParams.addCell(wire_id, newConstants);
360  // }
361  // }
362 
363  // Write values to a table
364  calibValuesFile.writeConsts(theVDriftOutputFile);
365 
366  LogVerbatim("Calibration") << "[DTVDriftCalibration]Writing vdrift object to DB!";
367 
368  // Write the vdrift object to DB
369  string record = "DTMtimeRcd";
370  DTCalibDBUtils::writeToDB<DTMtime>(record, mTime);
371 }

References DTCalibrationMap::addCell(), bySL, DTVelocityUnits::cm_per_ns, findVDriftAndT0, DTCalibrationMap::getConsts(), DTVDriftCalibration::cellInfo::getHists(), DTCalibrationMap::getKey(), h2DSegmRPhi, h2DSegmRZ, h4DSegmAllCh, hChi2, DTWireId::layerId(), LogTrace, N, GlobalPosition_Frontier_DevDB_cff::record, DTChamberId::sector(), DTMtime::set(), DTChamberId::station(), DTSuperLayerId::superLayer(), theCalibFilePar, theFile, theFitter, theGranularity, theVDriftOutputFile, theWireIdAndCellMap, DTChamberId::wheel(), h4DSegm::Write(), h2DSegm::Write(), hTMaxCell::Write(), and DTCalibrationMap::writeConsts().

Referenced by o2olib.O2ORunMgr::executeJob().

Member Data Documentation

◆ debug

bool DTVDriftCalibration::debug
private

◆ digiLabel

std::string DTVDriftCalibration::digiLabel
private

Definition at line 94 of file DTVDriftCalibration.h.

◆ findVDriftAndT0

bool DTVDriftCalibration::findVDriftAndT0
private

Definition at line 104 of file DTVDriftCalibration.h.

Referenced by endJob().

◆ h2DSegmRPhi

h2DSegm* DTVDriftCalibration::h2DSegmRPhi
private

Definition at line 77 of file DTVDriftCalibration.h.

Referenced by analyze(), and endJob().

◆ h2DSegmRZ

h2DSegm* DTVDriftCalibration::h2DSegmRZ
private

Definition at line 76 of file DTVDriftCalibration.h.

Referenced by analyze(), and endJob().

◆ h4DSegmAllCh

h4DSegm* DTVDriftCalibration::h4DSegmAllCh
private

Definition at line 78 of file DTVDriftCalibration.h.

Referenced by analyze(), and endJob().

◆ hChi2

TH1F* DTVDriftCalibration::hChi2
private

Definition at line 75 of file DTVDriftCalibration.h.

Referenced by analyze(), and endJob().

◆ histograms_

dtcalibration::Histograms DTVDriftCalibration::histograms_
private

Definition at line 54 of file DTVDriftCalibration.h.

Referenced by analyze().

◆ select_

std::unique_ptr<DTSegmentSelector> DTVDriftCalibration::select_
private

Definition at line 49 of file DTVDriftCalibration.h.

Referenced by analyze().

◆ theCalibChamber

std::string DTVDriftCalibration::theCalibChamber
private

Definition at line 131 of file DTVDriftCalibration.h.

Referenced by analyze().

◆ theCalibFilePar

edm::ParameterSet DTVDriftCalibration::theCalibFilePar
private

Definition at line 119 of file DTVDriftCalibration.h.

Referenced by endJob().

◆ theFile

TFile* DTVDriftCalibration::theFile
private

Definition at line 97 of file DTVDriftCalibration.h.

Referenced by analyze(), endJob(), and ~DTVDriftCalibration().

◆ theFitter

std::unique_ptr<DTMeanTimerFitter> DTVDriftCalibration::theFitter
private

Definition at line 100 of file DTVDriftCalibration.h.

Referenced by endJob().

◆ theGranularity

TMaxGranularity DTVDriftCalibration::theGranularity
private

Definition at line 85 of file DTVDriftCalibration.h.

Referenced by analyze(), and endJob().

◆ theRecHits4DToken

edm::EDGetTokenT<DTRecSegment4DCollection> DTVDriftCalibration::theRecHits4DToken
private

Definition at line 88 of file DTVDriftCalibration.h.

Referenced by analyze().

◆ theSync

std::unique_ptr<DTTTrigBaseSync> DTVDriftCalibration::theSync
private

Definition at line 116 of file DTVDriftCalibration.h.

Referenced by analyze().

◆ theVDriftOutputFile

std::string DTVDriftCalibration::theVDriftOutputFile
private

Definition at line 107 of file DTVDriftCalibration.h.

Referenced by endJob().

◆ theWireIdAndCellMap

std::map<DTWireId, cellInfo*> DTVDriftCalibration::theWireIdAndCellMap
private

Definition at line 110 of file DTVDriftCalibration.h.

Referenced by analyze(), and endJob().

DTVDriftCalibration::theFile
TFile * theFile
Definition: DTVDriftCalibration.h:97
Vector3DBase< float, LocalTag >
DTSLRecSegment2D
Definition: DTSLRecSegment2D.h:15
DTSuperLayerId
Definition: DTSuperLayerId.h:12
FastTimerService_cff.range
range
Definition: FastTimerService_cff.py:34
hTMaxCell::Write
void Write()
Definition: vDriftHistos.h:463
simKBmtfDigis_cfi.chiSquare
chiSquare
Definition: simKBmtfDigis_cfi.py:21
PV3DBase::x
T x() const
Definition: PV3DBase.h:59
DTSLRecSegment2D::superLayerId
DTSuperLayerId superLayerId() const
The id of the superlayer on which reside the segment.
Definition: DTSLRecSegment2D.cc:24
PV3DBase::theta
Geom::Theta< T > theta() const
Definition: PV3DBase.h:72
DTChamber
Definition: DTChamber.h:24
DTVDriftCalibration::findVDriftAndT0
bool findVDriftAndT0
Definition: DTVDriftCalibration.h:104
DTVDriftCalibration::histograms_
dtcalibration::Histograms histograms_
Definition: DTVDriftCalibration.h:54
GlobalPosition_Frontier_DevDB_cff.record
record
Definition: GlobalPosition_Frontier_DevDB_cff.py:10
h4DSegm
Definition: vDriftHistos.h:11
h2DSegm::Write
void Write()
Definition: vDriftHistos.h:96
DTVDriftCalibration::theRecHits4DToken
edm::EDGetTokenT< DTRecSegment4DCollection > theRecHits4DToken
Definition: DTVDriftCalibration.h:88
edm::EDConsumerBase::consumesCollector
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
Definition: EDConsumerBase.cc:46
DTMtime
Definition: DTMtime.h:68
DTSuperLayer
Definition: DTSuperLayer.h:24
DTSuperLayerId::superLayer
int superLayer() const
Return the superlayer number.
Definition: DTSuperLayerId.h:39
edm::Handle< DTRecSegment4DCollection >
edm::RangeMap::id_iterator
identifier iterator
Definition: RangeMap.h:130
DTMtime::set
int set(int wheelId, int stationId, int sectorId, int slId, float mTime, float mTrms, DTTimeUnits::type unit)
Definition: DTMtime.cc:168
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
h2DSegm
Definition: vDriftHistos.h:70
DTVDriftCalibration::theCalibChamber
std::string theCalibChamber
Definition: DTVDriftCalibration.h:131
DTGeometry::chamber
const DTChamber * chamber(const DTChamberId &id) const
Return a DTChamber given its id.
Definition: DTGeometry.cc:90
DTTMax
Definition: DTTMax.h:32
DTVDriftCalibration::theSync
std::unique_ptr< DTTTrigBaseSync > theSync
Definition: DTVDriftCalibration.h:116
PV3DBase::z
T z() const
Definition: PV3DBase.h:61
DTVDriftCalibration::h2DSegmRZ
h2DSegm * h2DSegmRZ
Definition: DTVDriftCalibration.h:76
edm::EventSetup::get
T get() const
Definition: EventSetup.h:80
DTCalibrationMap::CalibConsts
std::vector< float > CalibConsts
Definition: DTCalibrationMap.h:62
DTWireId
Definition: DTWireId.h:12
DTVDriftCalibration::debug
bool debug
Definition: DTVDriftCalibration.h:91
DTVDriftCalibration::h4DSegmAllCh
h4DSegm * h4DSegmAllCh
Definition: DTVDriftCalibration.h:78
edm::ESHandle< DTGeometry >
N
#define N
Definition: blowfish.cc:9
DTVDriftCalibration::byPartition
Definition: DTVDriftCalibration.h:84
Geom::pi
constexpr double pi()
Definition: Pi.h:31
Point3DBase< float, LocalTag >
DTVDriftCalibration::h2DSegmRPhi
h2DSegm * h2DSegmRPhi
Definition: DTVDriftCalibration.h:77
DTVDriftCalibration::hChi2
TH1F * hChi2
Definition: DTVDriftCalibration.h:75
GeomDet::toGlobal
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
Definition: GeomDet.h:49
h2DSegm::Fill
void Fill(float pos, float localAngle)
Definition: vDriftHistos.h:91
edm::ParameterSet
Definition: ParameterSet.h:47
DTVelocityUnits::cm_per_ns
Definition: DTVelocityUnits.h:32
dtcalibration::Histograms::bookHistos
void bookHistos()
Definition: Histogram.h:35
edm::RangeMap::const_iterator
C::const_iterator const_iterator
constant access iterator type
Definition: RangeMap.h:43
PV3DBase::y
T y() const
Definition: PV3DBase.h:60
DTRecSegment2D::localPosition
LocalPoint localPosition() const override
local position in SL frame
Definition: DTRecSegment2D.h:84
DTChamberRecSegment2D
Definition: DTChamberRecSegment2D.h:31
DTVDriftCalibration::theGranularity
TMaxGranularity theGranularity
Definition: DTVDriftCalibration.h:85
hTMaxCell
Definition: vDriftHistos.h:111
h4DSegm::Write
void Write()
Definition: vDriftHistos.h:51
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
get
#define get
DTChamberId::sector
int sector() const
Definition: DTChamberId.h:49
edm::RangeMap::range
std::pair< const_iterator, const_iterator > range
iterator range
Definition: RangeMap.h:50
h4DSegm::Fill
void Fill(float x, float y, float phi, float theta, float impact)
Definition: vDriftHistos.h:40
edm::LogVerbatim
Log< level::Info, true > LogVerbatim
Definition: MessageLogger.h:128
Exception
Definition: hltDiff.cc:246
DTLayerId::superlayerId
DTSuperLayerId superlayerId() const
Return the corresponding SuperLayerId.
Definition: DTLayerId.h:45
DTRecSegment2D::specificRecHits
std::vector< DTRecHit1D > specificRecHits() const
Access to specific components.
Definition: DTRecSegment2D.cc:104
relativeConstraints.chamber
chamber
Definition: relativeConstraints.py:53
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
DTCalibrationMap
Definition: DTCalibrationMap.h:37
CSCSkim_cfi.rootFileName
rootFileName
Definition: CSCSkim_cfi.py:9
DTVDriftCalibration::bySL
Definition: DTVDriftCalibration.h:84
DTWireId::layerId
DTLayerId layerId() const
Return the corresponding LayerId.
Definition: DTWireId.h:45
DTRecSegment2D::localDirection
LocalVector localDirection() const override
the local direction in SL frame
Definition: DTRecSegment2D.h:90
genParticles_cff.map
map
Definition: genParticles_cff.py:11
DTChamberId
Definition: DTChamberId.h:14
LogTrace
#define LogTrace(id)
Definition: MessageLogger.h:224
DTVDriftCalibration::theWireIdAndCellMap
std::map< DTWireId, cellInfo * > theWireIdAndCellMap
Definition: DTVDriftCalibration.h:110
DTVDriftCalibration::theCalibFilePar
edm::ParameterSet theCalibFilePar
Definition: DTVDriftCalibration.h:119
event
Definition: event.py:1
DTVDriftCalibration::theFitter
std::unique_ptr< DTMeanTimerFitter > theFitter
Definition: DTVDriftCalibration.h:100
MuonGeometryRecord
Definition: MuonGeometryRecord.h:34
DTVDriftCalibration::byChamber
Definition: DTVDriftCalibration.h:84
DTChamberId::wheel
int wheel() const
Return the wheel number.
Definition: DTChamberId.h:39
edm::InputTag
Definition: InputTag.h:15
edm::ConsumesCollector
Definition: ConsumesCollector.h:45
DTChamberId::station
int station() const
Return the station number.
Definition: DTChamberId.h:42
hit
Definition: SiStripHitEffFromCalibTree.cc:88
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
DTVDriftCalibration::select_
std::unique_ptr< DTSegmentSelector > select_
Definition: DTVDriftCalibration.h:49
DTVDriftCalibration::theVDriftOutputFile
std::string theVDriftOutputFile
Definition: DTVDriftCalibration.h:107