test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes | Private Types | Private Attributes
InitialClusteringStepBase Class Referenceabstract

#include <InitialClusteringStepBase.h>

Inheritance diagram for InitialClusteringStepBase:
Basic2DGenericTopoClusterizer

Public Member Functions

 _algoName (conf.getParameter< std::string >("algoName"))
 
virtual void buildClusters (const edm::Handle< reco::PFRecHitCollection > &, const std::vector< bool > &mask, const std::vector< bool > &seeds, reco::PFClusterCollection &)=0
 
 InitialClusteringStepBase (const edm::ParameterSet &conf)
 
 InitialClusteringStepBase (const ICSB &)=delete
 
std::ostream & operator<< (std::ostream &o)
 
ICSBoperator= (const ICSB &)=delete
 
void reset ()
 
virtual void update (const edm::EventSetup &)
 
virtual ~InitialClusteringStepBase ()
 

Protected Member Functions

reco::PFRecHitRef makeRefhit (const edm::Handle< reco::PFRecHitCollection > &h, const unsigned i) const
 

Protected Attributes

const std::unordered_map
< std::string, int > 
_layerMap
 
unsigned _nClustersFound
 
unsigned _nSeeds
 
std::unordered_map< int,
std::pair< double, double > > 
_thresholds
 

Private Types

typedef InitialClusteringStepBase ICSB
 

Private Attributes

const std::string _algoName
 

Detailed Description

Definition at line 20 of file InitialClusteringStepBase.h.

Member Typedef Documentation

Definition at line 21 of file InitialClusteringStepBase.h.

Constructor & Destructor Documentation

InitialClusteringStepBase::InitialClusteringStepBase ( const edm::ParameterSet conf)
inline

Definition at line 23 of file InitialClusteringStepBase.h.

References PFLayer::ECAL_BARREL, PFLayer::ECAL_ENDCAP, PFLayer::HCAL_BARREL1, PFLayer::HCAL_BARREL2, PFLayer::HCAL_ENDCAP, PFLayer::HF_EM, PFLayer::HF_HAD, PFLayer::NONE, PFLayer::PS1, and PFLayer::PS2.

23  :
24  _nSeeds(0), _nClustersFound(0),
25  _layerMap({ {"PS2",(int)PFLayer::PS2},
26  {"PS1",(int)PFLayer::PS1},
27  {"ECAL_ENDCAP",(int)PFLayer::ECAL_ENDCAP},
28  {"ECAL_BARREL",(int)PFLayer::ECAL_BARREL},
29  {"NONE",(int)PFLayer::NONE},
30  {"HCAL_BARREL1",(int)PFLayer::HCAL_BARREL1},
31  {"HCAL_BARREL2_RING0",(int)PFLayer::HCAL_BARREL2},
32  {"HCAL_BARREL2_RING1",100*(int)PFLayer::HCAL_BARREL2},
33  {"HCAL_ENDCAP",(int)PFLayer::HCAL_ENDCAP},
34  {"HF_EM",(int)PFLayer::HF_EM},
35  {"HF_HAD",(int)PFLayer::HF_HAD} }),
const std::unordered_map< std::string, int > _layerMap
virtual InitialClusteringStepBase::~InitialClusteringStepBase ( )
inlinevirtual

Definition at line 56 of file InitialClusteringStepBase.h.

56 { }
InitialClusteringStepBase::InitialClusteringStepBase ( const ICSB )
delete

Member Function Documentation

InitialClusteringStepBase::_algoName ( conf.getParameter< std::string >  "algoName")
inline

Definition at line 36 of file InitialClusteringStepBase.h.

References _layerMap, _thresholds, mps_splice::entry, Exception, edm::ParameterSet::getParameterSetVector(), TrackValidation_cff::pset, and AlCaHLTBitMon_QueryRunRegistry::string.

36  {
37  const std::vector<edm::ParameterSet>& thresholds =
38  conf.getParameterSetVector("thresholdsByDetector");
39  for( const auto& pset : thresholds ) {
40  const std::string& det = pset.getParameter<std::string>("detector");
41  const double& thresh_E =
42  pset.getParameter<double>("gatheringThreshold");
43  const double& thresh_pT =
44  pset.getParameter<double>("gatheringThresholdPt");
45  const double thresh_pT2 = thresh_pT*thresh_pT;
46  auto entry = _layerMap.find(det);
47  if( entry == _layerMap.end() ) {
48  throw cms::Exception("InvalidDetectorLayer")
49  << "Detector layer : " << det << " is not in the list of recognized"
50  << " detector layers!";
51  }
52  _thresholds.emplace(_layerMap.find(det)->second,
53  std::make_pair(thresh_E,thresh_pT2));
54  }
55  }
const std::unordered_map< std::string, int > _layerMap
list entry
Definition: mps_splice.py:62
std::unordered_map< int, std::pair< double, double > > _thresholds
virtual void InitialClusteringStepBase::buildClusters ( const edm::Handle< reco::PFRecHitCollection > &  ,
const std::vector< bool > &  mask,
const std::vector< bool > &  seeds,
reco::PFClusterCollection  
)
pure virtual
reco::PFRecHitRef InitialClusteringStepBase::makeRefhit ( const edm::Handle< reco::PFRecHitCollection > &  h,
const unsigned  i 
) const
inlineprotected

Definition at line 78 of file InitialClusteringStepBase.h.

Referenced by Basic2DGenericTopoClusterizer::buildClusters().

79  {
80  return reco::PFRecHitRef(h,i);
81  }
int i
Definition: DBlmapReader.cc:9
edm::Ref< PFRecHitCollection > PFRecHitRef
persistent reference to PFRecHit objects
Definition: PFRecHitFwd.h:15
std::ostream& InitialClusteringStepBase::operator<< ( std::ostream &  o)
inline

Definition at line 68 of file InitialClusteringStepBase.h.

References _algoName, _nClustersFound, _nSeeds, and connectstrParser::o.

68  {
69  o << "InitialClusteringStep with algo \"" << _algoName
70  << "\" located " << _nSeeds << " seeds and built "
71  << _nClustersFound << " clusters from those seeds. ";
72  return o;
73  }
ICSB& InitialClusteringStepBase::operator= ( const ICSB )
delete
void InitialClusteringStepBase::reset ( void  )
inline
virtual void InitialClusteringStepBase::update ( const edm::EventSetup )
inlinevirtual

Definition at line 61 of file InitialClusteringStepBase.h.

Referenced by progressbar.ProgressBar::__next__(), MatrixUtil.Matrix::__setitem__(), MatrixUtil.Steps::__setitem__(), 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(), 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().

61 { }

Member Data Documentation

const std::string InitialClusteringStepBase::_algoName
private

Definition at line 88 of file InitialClusteringStepBase.h.

Referenced by operator<<().

const std::unordered_map<std::string,int> InitialClusteringStepBase::_layerMap
protected

Definition at line 83 of file InitialClusteringStepBase.h.

Referenced by _algoName().

unsigned InitialClusteringStepBase::_nClustersFound
protected

Definition at line 82 of file InitialClusteringStepBase.h.

Referenced by operator<<(), and reset().

unsigned InitialClusteringStepBase::_nSeeds
protected

Definition at line 82 of file InitialClusteringStepBase.h.

Referenced by operator<<(), and reset().

std::unordered_map<int,std::pair<double,double> > InitialClusteringStepBase::_thresholds
protected