CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
ticl::SeedingRegionByTracks Class Referencefinal

#include <SeedingRegionByTracks.h>

Inheritance diagram for ticl::SeedingRegionByTracks:
ticl::SeedingRegionAlgoBase

Public Member Functions

void initialize (const edm::EventSetup &es) override
 
void makeRegions (const edm::Event &ev, const edm::EventSetup &es, std::vector< TICLSeedingRegion > &result) override
 
 SeedingRegionByTracks (const edm::ParameterSet &conf, edm::ConsumesCollector &sumes)
 
 ~SeedingRegionByTracks () override
 
- Public Member Functions inherited from ticl::SeedingRegionAlgoBase
 SeedingRegionAlgoBase (const edm::ParameterSet &conf, edm::ConsumesCollector &sumes)
 
virtual ~SeedingRegionAlgoBase ()
 

Private Member Functions

void buildFirstLayers ()
 

Private Attributes

edm::ESHandle< MagneticFieldbfield_
 
const StringCutObjectSelector< reco::TrackcutTk_
 
std::unique_ptr< GeomDetfirstDisk_ [2]
 
const HGCalDDDConstantshgcons_
 
std::once_flag initializeGeometry_
 
edm::ESHandle< Propagatorpropagator_
 
const std::string propName_
 
edm::EDGetTokenT< reco::TrackCollectiontracks_token_
 

Static Private Attributes

static const std::string detectorName_ = "HGCalEESensitive"
 

Additional Inherited Members

- Public Types inherited from ticl::SeedingRegionAlgoBase
enum  VerbosityLevel {
  None = 0, Basic, Advanced, Expert,
  Guru
}
 
- Protected Attributes inherited from ticl::SeedingRegionAlgoBase
int algo_verbosity_
 
int algoId_
 

Detailed Description

Definition at line 29 of file SeedingRegionByTracks.h.

Constructor & Destructor Documentation

◆ SeedingRegionByTracks()

SeedingRegionByTracks::SeedingRegionByTracks ( const edm::ParameterSet conf,
edm::ConsumesCollector sumes 
)

Definition at line 16 of file SeedingRegionByTracks.cc.

17  : SeedingRegionAlgoBase(conf, sumes),
19  cutTk_(conf.getParameter<std::string>("cutTk")),
20  propName_(conf.getParameter<std::string>("propagator")) {}

◆ ~SeedingRegionByTracks()

SeedingRegionByTracks::~SeedingRegionByTracks ( )
override

Definition at line 22 of file SeedingRegionByTracks.cc.

22 {}

Member Function Documentation

◆ buildFirstLayers()

void SeedingRegionByTracks::buildFirstLayers ( )
private

Definition at line 60 of file SeedingRegionByTracks.cc.

60  {
61  float zVal = hgcons_->waferZ(1, true);
62  std::pair<double, double> rMinMax = hgcons_->rangeR(zVal, true);
63 
64  for (int iSide = 0; iSide < 2; ++iSide) {
65  float zSide = (iSide == 0) ? (-1. * zVal) : zVal;
66  firstDisk_[iSide] =
67  std::make_unique<GeomDet>(Disk::build(Disk::PositionType(0, 0, zSide),
69  SimpleDiskBounds(rMinMax.first, rMinMax.second, zSide - 0.5, zSide + 0.5))
70  .get());
71  }
72 }

References Disk::build(), firstDisk_, hgcons_, HGCalDDDConstants::rangeR(), and HGCalDDDConstants::waferZ().

Referenced by initialize().

◆ initialize()

void SeedingRegionByTracks::initialize ( const edm::EventSetup es)
overridevirtual

◆ makeRegions()

void SeedingRegionByTracks::makeRegions ( const edm::Event ev,
const edm::EventSetup es,
std::vector< TICLSeedingRegion > &  result 
)
overridevirtual

Implements ticl::SeedingRegionAlgoBase.

Definition at line 35 of file SeedingRegionByTracks.cc.

37  {
39  ev.getByToken(tracks_token_, tracks_h);
40  edm::ProductID trkId = tracks_h.id();
41  auto bFieldProd = bfield_.product();
42  const Propagator &prop = (*propagator_);
43 
44  int nTracks = tracks_h->size();
45  for (int i = 0; i < nTracks; ++i) {
46  const reco::Track &tk = (*tracks_h)[i];
47  if (!cutTk_((tk))) {
48  continue;
49  }
50 
52  int iSide = int(tk.eta() > 0);
53  TrajectoryStateOnSurface tsos = prop.propagate(fts, firstDisk_[iSide]->surface());
54  if (tsos.isValid()) {
55  result.emplace_back(tsos.globalPosition(), tsos.globalMomentum(), iSide, i, trkId);
56  }
57  }
58 }

References bfield_, cutTk_, reco::TrackBase::eta(), ev, firstDisk_, mps_fire::i, edm::HandleBase::id(), createfilelist::int, nTracks(), trajectoryStateTransform::outerFreeState(), edm::ESHandle< T >::product(), Propagator::propagate(), mps_fire::result, and tracks_token_.

Member Data Documentation

◆ bfield_

edm::ESHandle<MagneticField> ticl::SeedingRegionByTracks::bfield_
private

Definition at line 48 of file SeedingRegionByTracks.h.

Referenced by initialize(), and makeRegions().

◆ cutTk_

const StringCutObjectSelector<reco::Track> ticl::SeedingRegionByTracks::cutTk_
private

Definition at line 44 of file SeedingRegionByTracks.h.

Referenced by makeRegions().

◆ detectorName_

const std::string ticl::SeedingRegionByTracks::detectorName_ = "HGCalEESensitive"
inlinestaticprivate

Definition at line 45 of file SeedingRegionByTracks.h.

Referenced by initialize().

◆ firstDisk_

std::unique_ptr<GeomDet> ticl::SeedingRegionByTracks::firstDisk_[2]
private

Definition at line 49 of file SeedingRegionByTracks.h.

Referenced by buildFirstLayers(), and makeRegions().

◆ hgcons_

const HGCalDDDConstants* ticl::SeedingRegionByTracks::hgcons_
private

Definition at line 43 of file SeedingRegionByTracks.h.

Referenced by buildFirstLayers(), and initialize().

◆ initializeGeometry_

std::once_flag ticl::SeedingRegionByTracks::initializeGeometry_
private

Definition at line 42 of file SeedingRegionByTracks.h.

◆ propagator_

edm::ESHandle<Propagator> ticl::SeedingRegionByTracks::propagator_
private

Definition at line 46 of file SeedingRegionByTracks.h.

Referenced by initialize().

◆ propName_

const std::string ticl::SeedingRegionByTracks::propName_
private

Definition at line 47 of file SeedingRegionByTracks.h.

Referenced by initialize().

◆ tracks_token_

edm::EDGetTokenT<reco::TrackCollection> ticl::SeedingRegionByTracks::tracks_token_
private

Definition at line 41 of file SeedingRegionByTracks.h.

Referenced by makeRegions().

edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
TkRotation< float >
nTracks
const unsigned int nTracks(const reco::Vertex &sv)
Definition: TemplatedVertexArbitrator.h:44
mps_fire.i
i
Definition: mps_fire.py:355
trajectoryStateTransform::outerFreeState
FreeTrajectoryState outerFreeState(const reco::Track &tk, const MagneticField *field, bool withErr=true)
Definition: TrajectoryStateTransform.cc:98
ticl::SeedingRegionByTracks::buildFirstLayers
void buildFirstLayers()
Definition: SeedingRegionByTracks.cc:60
Disk::build
static DiskPointer build(Args &&... args)
Definition: BoundDisk.h:38
ticl::SeedingRegionByTracks::propName_
const std::string propName_
Definition: SeedingRegionByTracks.h:47
HGCalDDDConstants::waferZ
double waferZ(int layer, bool reco) const
Definition: HGCalDDDConstants.cc:1367
ticl::SeedingRegionByTracks::bfield_
edm::ESHandle< MagneticField > bfield_
Definition: SeedingRegionByTracks.h:48
edm::Handle< reco::TrackCollection >
IdealMagneticFieldRecord
Definition: IdealMagneticFieldRecord.h:11
SimpleDiskBounds
Definition: SimpleDiskBounds.h:11
Propagator
Definition: Propagator.h:44
TrajectoryStateOnSurface
Definition: TrajectoryStateOnSurface.h:16
edm::EventSetup::get
T get() const
Definition: EventSetup.h:73
ticl::SeedingRegionByTracks::hgcons_
const HGCalDDDConstants * hgcons_
Definition: SeedingRegionByTracks.h:43
reco::Track
Definition: Track.h:27
edm::ESHandle
Definition: DTSurvey.h:22
edm::ConsumesCollector::consumes
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
Definition: ConsumesCollector.h:49
Point3DBase< float, GlobalTag >
HGCalDDDConstants::rangeR
std::pair< double, double > rangeR(double z, bool reco) const
Definition: HGCalDDDConstants.cc:934
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
reco::TrackBase::eta
double eta() const
pseudorapidity of momentum vector
Definition: TrackBase.h:623
createfilelist.int
int
Definition: createfilelist.py:10
Propagator::propagate
TrajectoryStateOnSurface propagate(STA const &state, SUR const &surface) const
Definition: Propagator.h:50
get
#define get
ticl::SeedingRegionByTracks::tracks_token_
edm::EDGetTokenT< reco::TrackCollection > tracks_token_
Definition: SeedingRegionByTracks.h:41
ticl::SeedingRegionByTracks::propagator_
edm::ESHandle< Propagator > propagator_
Definition: SeedingRegionByTracks.h:46
ticl::SeedingRegionByTracks::firstDisk_
std::unique_ptr< GeomDet > firstDisk_[2]
Definition: SeedingRegionByTracks.h:49
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
ticl::SeedingRegionByTracks::cutTk_
const StringCutObjectSelector< reco::Track > cutTk_
Definition: SeedingRegionByTracks.h:44
FreeTrajectoryState
Definition: FreeTrajectoryState.h:27
ev
bool ev
Definition: Hydjet2Hadronizer.cc:95
ticl::SeedingRegionAlgoBase::SeedingRegionAlgoBase
SeedingRegionAlgoBase(const edm::ParameterSet &conf, edm::ConsumesCollector &sumes)
Definition: SeedingRegionAlgoBase.h:23
mps_fire.result
result
Definition: mps_fire.py:303
ticl::SeedingRegionByTracks::detectorName_
static const std::string detectorName_
Definition: SeedingRegionByTracks.h:45
edm::HandleBase::id
ProductID id() const
Definition: HandleBase.cc:13
edm::InputTag
Definition: InputTag.h:15
reco::TrackCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition: TrackFwd.h:14
edm::ProductID
Definition: ProductID.h:27
IdealGeometryRecord
Definition: IdealGeometryRecord.h:27
TrackingComponentsRecord
Definition: TrackingComponentsRecord.h:12