CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
DTVDriftCalibration::cellInfo Class Reference

Public Member Functions

void add (const std::vector< const TMax * > &tMaxes)
 
 cellInfo (const TString &name)
 
hTMaxCellgetHists ()
 
void update ()
 
 ~cellInfo ()
 

Private Member Functions

 cellInfo ()
 
 cellInfo (const cellInfo &)
 

Private Attributes

std::vector
< dttmaxenums::TMaxCells
addedCells
 
hTMaxCellhistos
 

Detailed Description

Definition at line 57 of file DTVDriftCalibration.h.

Constructor & Destructor Documentation

DTVDriftCalibration::cellInfo::cellInfo ( const TString &  name)
inline

Definition at line 59 of file DTVDriftCalibration.h.

References histos.

DTVDriftCalibration::cellInfo::~cellInfo ( )
inline

Definition at line 63 of file DTVDriftCalibration.h.

References histos.

63  {
64  delete histos;
65  }
DTVDriftCalibration::cellInfo::cellInfo ( )
inlineprivate

Definition at line 72 of file DTVDriftCalibration.h.

72 {};
DTVDriftCalibration::cellInfo::cellInfo ( const cellInfo )
inlineprivate

Definition at line 73 of file DTVDriftCalibration.h.

73 {};

Member Function Documentation

void DTVDriftCalibration::cellInfo::add ( const std::vector< const TMax * > &  tMaxes)

Definition at line 397 of file DTVDriftCalibration.cc.

References addedCells, dttmaxenums::c123, dttmaxenums::c124, dttmaxenums::c134, dttmaxenums::c234, gather_cfg::cout, hTMaxCell::Fill(), spr::find(), histos, dttmaxenums::noR, dttmaxenums::notInit, and tree::t.

Referenced by DTVDriftCalibration::analyze(), and counter.Counter::register().

397  {
398  vector<const TMax*> tMaxes = _tMaxes;
399  float tmax123 = -1.;
400  float tmax124 = -1.;
401  float tmax134 = -1.;
402  float tmax234 = -1.;
403  SigmaFactor s124 = noR;
404  SigmaFactor s134 = noR;
405  unsigned t0_123 = 0;
406  unsigned t0_124 = 0;
407  unsigned t0_134 = 0;
408  unsigned t0_234 = 0;
409  unsigned hSubGroup = 0;
410  for (vector<const TMax*>::const_iterator it=tMaxes.begin(); it!=tMaxes.end();
411  ++it) {
412  if(*it == 0) {
413  continue;
414  }
415  else {
416  //FIXME check cached,
417  if (addedCells.size()==4 ||
418  find(addedCells.begin(), addedCells.end(), (*it)->cells)
419  != addedCells.end()) {
420  continue;
421  }
422  addedCells.push_back((*it)->cells);
423  SigmaFactor sigma = (*it)->sigma;
424  float t = (*it)->t;
425  TMaxCells cells = (*it)->cells;
426  unsigned t0Factor = (*it)->t0Factor;
427  hSubGroup = (*it)->hSubGroup;
428  if(t < 0.) continue;
429  switch(cells) {
430  case notInit : cout << "Error: no cell type assigned to TMax" << endl; break;
431  case c123 : tmax123 =t; t0_123 = t0Factor; break;
432  case c124 : tmax124 =t; s124 = sigma; t0_124 = t0Factor; break;
433  case c134 : tmax134 =t; s134 = sigma; t0_134 = t0Factor; break;
434  case c234 : tmax234 =t; t0_234 = t0Factor; break;
435  }
436  }
437  }
438  //add entries to the TMax histograms
439  histos->Fill(tmax123, tmax124, tmax134, tmax234, s124, s134, t0_123,
440  t0_124, t0_134, t0_234, hSubGroup);
441 }
tuple t
Definition: tree.py:139
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:7
void Fill(float tmax123, float tmax124, float tmax134, float tmax234, dttmaxenums::SigmaFactor s124, dttmaxenums::SigmaFactor s134, unsigned t0_123, unsigned t0_124, unsigned t0_134, unsigned t0_234, unsigned hSubGroup)
Definition: vDriftHistos.h:220
tuple cout
Definition: gather_cfg.py:121
std::vector< dttmaxenums::TMaxCells > addedCells
hTMaxCell* DTVDriftCalibration::cellInfo::getHists ( )
inline

Definition at line 69 of file DTVDriftCalibration.h.

References histos.

Referenced by DTVDriftCalibration::endJob().

69 {return histos;}
void DTVDriftCalibration::cellInfo::update ( )
inline

Definition at line 68 of file DTVDriftCalibration.h.

References addedCells.

Referenced by progressbar.ProgressBar::__next__(), MatrixUtil.Matrix::__setitem__(), MatrixUtil.Steps::__setitem__(), python.seqvaluedict.seqdict::__setslice__(), DTVDriftCalibration::analyze(), Vispa.Gui.VispaWidget.VispaWidget::autosize(), Vispa.Views.LineDecayView.LineDecayContainer::createObject(), Vispa.Views.LineDecayView.LineDecayContainer::deselectAllObjects(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::deselectAllWidgets(), Vispa.Gui.VispaWidget.VispaWidget::enableAutosizing(), python.seqvaluedict.seqdict::extend(), progressbar.ProgressBar::finish(), Vispa.Gui.MenuWidget.MenuWidget::leaveEvent(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::mouseMoveEvent(), Vispa.Gui.MenuWidget.MenuWidget::mouseMoveEvent(), Vispa.Views.LineDecayView.LineDecayContainer::mouseMoveEvent(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::mouseReleaseEvent(), Vispa.Views.LineDecayView.LineDecayContainer::objectMoved(), MatrixUtil.Steps::overwrite(), Vispa.Views.LineDecayView.LineDecayContainer::removeObject(), Vispa.Gui.ConnectableWidget.ConnectableWidget::removePorts(), Vispa.Gui.FindDialog.FindDialog::reset(), Vispa.Gui.PortConnection.PointToPointConnection::select(), Vispa.Gui.VispaWidget.VispaWidget::select(), Vispa.Views.LineDecayView.LineDecayContainer::select(), Vispa.Gui.VispaWidget.VispaWidget::setText(), Vispa.Gui.VispaWidget.VispaWidget::setTitle(), Vispa.Gui.ZoomableWidget.ZoomableWidget::setZoom(), Vispa.Views.LineDecayView.LineDecayContainer::setZoom(), and Vispa.Gui.PortConnection.PointToPointConnection::updateConnection().

68 {addedCells.clear();}
std::vector< dttmaxenums::TMaxCells > addedCells

Member Data Documentation

std::vector<dttmaxenums::TMaxCells> DTVDriftCalibration::cellInfo::addedCells
private

Definition at line 73 of file DTVDriftCalibration.h.

Referenced by add(), and update().

hTMaxCell* DTVDriftCalibration::cellInfo::histos
private