CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
SeedingLayerSetsBuilder Class Reference

#include <SeedingLayerSetsBuilder.h>

Classes

struct  LayerSpec
 

Public Types

using SeedingLayerId = std::tuple< GeomDetEnumerators::SubDetector, TrackerDetSide, int >
 

Public Member Functions

std::unique_ptr
< SeedingLayerSetsHits
hits (const edm::Event &ev, const edm::EventSetup &es)
 
std::vector< SeedingLayerIdlayers () const
 
const std::vector
< SeedingLayerSetsHits::LayerSetIndex > & 
layerSetIndices () const
 
std::unique_ptr
< SeedingLayerSetsHits
makeSeedingLayerSetsHitsforFastSim (const edm::Event &ev, const edm::EventSetup &es)
 
unsigned short numberOfLayers () const
 
unsigned short numberOfLayerSets () const
 
 SeedingLayerSetsBuilder (const edm::ParameterSet &cfg, edm::ConsumesCollector &iC, const edm::InputTag &fastsimHitTag)
 
 SeedingLayerSetsBuilder (const edm::ParameterSet &cfg, edm::ConsumesCollector &iC)
 
 SeedingLayerSetsBuilder (const edm::ParameterSet &cfg, edm::ConsumesCollector &&iC)
 
SeedingLayerSetsLooper seedingLayerSetsLooper () const
 
 ~SeedingLayerSetsBuilder ()
 

Static Public Member Functions

static void fillDescriptions (edm::ParameterSetDescription &desc)
 
static std::vector
< std::vector< std::string > > 
layerNamesInSets (const std::vector< std::string > &namesPSet)
 
static SeedingLayerId nameToEnumId (const std::string &name)
 

Private Member Functions

edm::ParameterSet layerConfig (const std::string &nameLayer, const edm::ParameterSet &cfg) const
 
void updateEventSetup (const edm::EventSetup &es)
 

Private Attributes

edm::EDGetTokenT
< FastTrackerRecHitCollection
fastSimrecHitsToken_
 
edm::ESWatcher
< TrackerRecoGeometryRecord
geometryWatcher_
 
std::vector< const DetLayer * > theLayerDets
 
std::vector< std::string > theLayerNames
 
std::vector< LayerSpectheLayers
 
std::vector
< SeedingLayerSetsHits::LayerSetIndex
theLayerSetIndices
 
unsigned short theNumberOfLayersInSet
 
std::vector< const
TransientTrackingRecHitBuilder * > 
theTTRHBuilders
 
const edm::ESGetToken
< GeometricSearchTracker,
TrackerRecoGeometryRecord
trackerToken_
 
edm::ESGetToken
< TrackerTopology,
TrackerTopologyRcd
trackerTopologyToken_
 
edm::ESWatcher
< TransientRecHitRecord
trhWatcher_
 

Detailed Description

Definition at line 35 of file SeedingLayerSetsBuilder.h.

Member Typedef Documentation

Definition at line 37 of file SeedingLayerSetsBuilder.h.

Constructor & Destructor Documentation

SeedingLayerSetsBuilder::SeedingLayerSetsBuilder ( const edm::ParameterSet cfg,
edm::ConsumesCollector iC,
const edm::InputTag fastsimHitTag 
)

Definition at line 182 of file SeedingLayerSetsBuilder.cc.

References edm::ConsumesCollector::consumes(), edm::ConsumesCollector::esConsumes(), fastSimrecHitsToken_, and trackerTopologyToken_.

185  : SeedingLayerSetsBuilder(cfg, iC) {
188 }
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
SeedingLayerSetsBuilder(const edm::ParameterSet &cfg, edm::ConsumesCollector &iC, const edm::InputTag &fastsimHitTag)
edm::EDGetTokenT< FastTrackerRecHitCollection > fastSimrecHitsToken_
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyToken_
SeedingLayerSetsBuilder::SeedingLayerSetsBuilder ( const edm::ParameterSet cfg,
edm::ConsumesCollector iC 
)

Definition at line 191 of file SeedingLayerSetsBuilder.cc.

References Exception, spr::find(), newFWLiteAna::found, edm::ParameterSet::getParameter(), layerConfig(), phase1PixelTopology::layerName, layerNamesInSets(), SiStripPI::max, str, AlCaHLTBitMon_QueryRunRegistry::string, theLayerDets, theLayerNames, theLayers, theLayerSetIndices, theNumberOfLayersInSet, and theTTRHBuilders.

192  : trackerToken_(iC.esConsumes()) {
193  std::vector<std::string> namesPset = cfg.getParameter<std::vector<std::string> >("layerList");
194  std::vector<std::vector<std::string> > layerNamesInSets = this->layerNamesInSets(namesPset);
195  // debug printout of layers
196  typedef std::vector<std::string>::const_iterator IS;
197  typedef std::vector<std::vector<std::string> >::const_iterator IT;
198  std::ostringstream str;
199  // The following should not be set to cout
200  // for (IT it = layerNamesInSets.begin(); it != layerNamesInSets.end(); it++) {
201  // str << "SET: ";
202  // for (IS is = it->begin(); is != it->end(); is++) str << *is <<" ";
203  // str << std::endl;
204  // }
205  // std::cout << str.str() << std::endl;
206  if (layerNamesInSets.empty())
208  else
209  theNumberOfLayersInSet = layerNamesInSets[0].size();
210 
211  for (IT it = layerNamesInSets.begin(); it != layerNamesInSets.end(); it++) {
212  if (it->size() != theNumberOfLayersInSet)
213  throw cms::Exception("Configuration")
214  << "Assuming all SeedingLayerSets to have same number of layers. LayerSet " << (it - layerNamesInSets.begin())
215  << " has " << it->size() << " while 0th has " << theNumberOfLayersInSet;
216  for (const std::string& layerName : *it) {
217  auto found = std::find(theLayerNames.begin(), theLayerNames.end(), layerName);
218  unsigned short layerIndex = 0;
219  if (found != theLayerNames.end()) {
220  layerIndex = found - theLayerNames.begin();
221  } else {
223  throw cms::Exception("Assert")
224  << "Too many layers in " << __FILE__ << ":" << __LINE__
225  << ", we may have to enlarge the index type from unsigned short to unsigned int";
226  }
227 
228  layerIndex = theLayers.size();
229  theLayers.emplace_back(theLayerNames.size(), layerName, layerConfig(layerName, cfg), iC);
230  theLayerNames.push_back(layerName);
231  }
232  theLayerSetIndices.push_back(layerIndex);
233  }
234  }
235  theLayerDets.resize(theLayers.size());
236  theTTRHBuilders.resize(theLayers.size());
237 
238  // debug printout
239  // The following should not be set to cout
240  //for(const LayerSpec& layer: theLayers) {
241  // std::cout << layer.print(theLayerNames) << std::endl;
242  //}
243 }
std::vector< const DetLayer * > theLayerDets
constexpr char const * layerName[numberOfLayers]
std::vector< LayerSpec > theLayers
std::vector< std::string > theLayerNames
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
std::vector< SeedingLayerSetsHits::LayerSetIndex > theLayerSetIndices
std::vector< LinkConnSpec >::const_iterator IT
std::vector< const TransientTrackingRecHitBuilder * > theTTRHBuilders
const edm::ESGetToken< GeometricSearchTracker, TrackerRecoGeometryRecord > trackerToken_
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
#define str(s)
edm::ParameterSet layerConfig(const std::string &nameLayer, const edm::ParameterSet &cfg) const
static std::vector< std::vector< std::string > > layerNamesInSets(const std::vector< std::string > &namesPSet)
SeedingLayerSetsBuilder::SeedingLayerSetsBuilder ( const edm::ParameterSet cfg,
edm::ConsumesCollector &&  iC 
)

Definition at line 189 of file SeedingLayerSetsBuilder.cc.

190  : SeedingLayerSetsBuilder(cfg, iC) {}
SeedingLayerSetsBuilder(const edm::ParameterSet &cfg, edm::ConsumesCollector &iC, const edm::InputTag &fastsimHitTag)
SeedingLayerSetsBuilder::~SeedingLayerSetsBuilder ( )

Definition at line 245 of file SeedingLayerSetsBuilder.cc.

245 {}

Member Function Documentation

void SeedingLayerSetsBuilder::fillDescriptions ( edm::ParameterSetDescription desc)
static

Definition at line 247 of file SeedingLayerSetsBuilder.cc.

References edm::ParameterSetDescription::add(), relativeConstraints::empty, and edm::ParameterSetDescription::setAllowAnything().

Referenced by SeedingLayersEDProducer::fillDescriptions(), and PixelInactiveAreaTrackingRegionsSeedingLayersProducer::fillDescriptions().

247  {
249  empty.setAllowAnything(); // for now accept any parameter in the PSets, consider improving later
250 
251  desc.add<std::vector<std::string> >("layerList", {});
252  desc.add<edm::ParameterSetDescription>("BPix", empty);
253  desc.add<edm::ParameterSetDescription>("FPix", empty);
254  desc.add<edm::ParameterSetDescription>("TIB", empty);
255  desc.add<edm::ParameterSetDescription>("TID", empty);
256  desc.add<edm::ParameterSetDescription>("TOB", empty);
257  desc.add<edm::ParameterSetDescription>("TEC", empty);
258  desc.add<edm::ParameterSetDescription>("MTIB", empty);
259  desc.add<edm::ParameterSetDescription>("MTID", empty);
260  desc.add<edm::ParameterSetDescription>("MTOB", empty);
261  desc.add<edm::ParameterSetDescription>("MTEC", empty);
262 }
void setAllowAnything()
allow any parameter label/value pairs
ParameterDescriptionBase * add(U const &iLabel, T const &value)
std::unique_ptr< SeedingLayerSetsHits > SeedingLayerSetsBuilder::hits ( const edm::Event ev,
const edm::EventSetup es 
)

Definition at line 362 of file SeedingLayerSetsBuilder.cc.

References phase1PixelTopology::layer, runTheMatrix::ret, theLayerDets, theLayerNames, theLayers, theLayerSetIndices, theNumberOfLayersInSet, theTTRHBuilders, and updateEventSetup().

Referenced by SeedingLayersEDProducer::produce(), and PixelInactiveAreaTrackingRegionsSeedingLayersProducer::produce().

362  {
363  updateEventSetup(es);
364 
365  auto ret = std::make_unique<SeedingLayerSetsHits>(
367 
368  for (auto& layer : theLayers) {
369  ret->addHits(
370  layer.nameIndex,
371  layer.extractor->hits((const TkTransientTrackingRecHitBuilder&)(*theTTRHBuilders[layer.nameIndex]), ev, es));
372  }
373  ret->shrink_to_fit();
374  return ret;
375 }
std::vector< const DetLayer * > theLayerDets
tuple ret
prodAgent to be discontinued
std::vector< LayerSpec > theLayers
std::vector< std::string > theLayerNames
constexpr std::array< uint8_t, layerIndexSize > layer
void updateEventSetup(const edm::EventSetup &es)
std::vector< SeedingLayerSetsHits::LayerSetIndex > theLayerSetIndices
std::vector< const TransientTrackingRecHitBuilder * > theTTRHBuilders
edm::ParameterSet SeedingLayerSetsBuilder::layerConfig ( const std::string &  nameLayer,
const edm::ParameterSet cfg 
) const
private

Definition at line 264 of file SeedingLayerSetsBuilder.cc.

References edm::ParameterSet::exists(), edm::ParameterSet::getParameter(), mergeVDriftHistosByStation::name, and mps_fire::result.

Referenced by SeedingLayerSetsBuilder().

265  {
267 
268  for (string::size_type iEnd = nameLayer.size(); iEnd > 0; --iEnd) {
269  string name = nameLayer.substr(0, iEnd);
270  if (cfg.exists(name))
271  return cfg.getParameter<edm::ParameterSet>(name);
272  }
273  edm::LogError("SeedingLayerSetsBuilder")
274  << "configuration for layer: " << nameLayer << " not found, job will probably crash!";
275  return result;
276 }
bool exists(std::string const &parameterName) const
checks if a parameter exists
Log< level::Error, false > LogError
uint16_t size_type
tuple result
Definition: mps_fire.py:311
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
vector< vector< string > > SeedingLayerSetsBuilder::layerNamesInSets ( const std::vector< std::string > &  namesPSet)
static

Definition at line 278 of file SeedingLayerSetsBuilder.cc.

References phase1PixelTopology::layer, geometryCSVtoXML::line, and mps_fire::result.

Referenced by MTVHistoProducerAlgoForTracker::MTVHistoProducerAlgoForTracker(), and SeedingLayerSetsBuilder().

278  {
279  std::vector<std::vector<std::string> > result;
280  for (std::vector<std::string>::const_iterator is = namesPSet.begin(); is < namesPSet.end(); ++is) {
281  vector<std::string> layersInSet;
282  string line = *is;
283  string::size_type pos = 0;
284  while (pos != string::npos) {
285  pos = line.find('+');
286  string layer = line.substr(0, pos);
287  layersInSet.push_back(layer);
288  line = line.substr(pos + 1, string::npos);
289  }
290  result.push_back(layersInSet);
291  }
292  return result;
293 }
uint16_t size_type
constexpr std::array< uint8_t, layerIndexSize > layer
tuple result
Definition: mps_fire.py:311
std::vector< SeedingLayerSetsBuilder::SeedingLayerId > SeedingLayerSetsBuilder::layers ( ) const

Definition at line 353 of file SeedingLayerSetsBuilder.cc.

References phase1PixelTopology::layer, numberOfLayers(), runTheMatrix::ret, and theLayers.

353  {
354  std::vector<SeedingLayerId> ret;
355  ret.reserve(numberOfLayers());
356  for (const auto& layer : theLayers) {
357  ret.emplace_back(layer.subdet, layer.side, layer.idLayer);
358  }
359  return ret;
360 }
tuple ret
prodAgent to be discontinued
std::vector< LayerSpec > theLayers
constexpr std::array< uint8_t, layerIndexSize > layer
unsigned short numberOfLayers() const
const std::vector<SeedingLayerSetsHits::LayerSetIndex>& SeedingLayerSetsBuilder::layerSetIndices ( ) const
inline

Definition at line 57 of file SeedingLayerSetsBuilder.h.

References theLayerSetIndices.

57 { return theLayerSetIndices; }
std::vector< SeedingLayerSetsHits::LayerSetIndex > theLayerSetIndices
std::unique_ptr< SeedingLayerSetsHits > SeedingLayerSetsBuilder::makeSeedingLayerSetsHitsforFastSim ( const edm::Event ev,
const edm::EventSetup es 
)

Definition at line 377 of file SeedingLayerSetsBuilder.cc.

References b, Barrel, TrackingRecHit::clone(), fastSimrecHitsToken_, edm::Event::getByToken(), edm::EventSetup::getData(), GeomDetEnumerators::invalidDet, phase1PixelTopology::layer, eostools::move(), NegEndcap, GeomDetEnumerators::PixelBarrel, PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, GeomDetEnumerators::PixelEndcap, PosEndcap, TrackerTopology::pxbLayer(), TrackerTopology::pxfDisk(), TrackerTopology::pxfSide(), runTheMatrix::ret, theLayerDets, theLayerNames, theLayers, theLayerSetIndices, theNumberOfLayersInSet, trackerTopologyToken_, and updateEventSetup().

378  {
379  updateEventSetup(es);
380 
382  ev.getByToken(fastSimrecHitsToken_, fastSimrechits_); //using FastSim RecHits
383  const TrackerTopology* const tTopo = &es.getData(trackerTopologyToken_);
385 
386  auto ret = std::make_unique<SeedingLayerSetsHits>(
388 
389  for (auto& layer : theLayers) {
390  layerhits_.clear();
391  for (auto& rh : *fastSimrechits_) {
394  int idLayer = 0;
395  if ((rh.det()->geographicalId()).subdetId() == PixelSubdetector::PixelBarrel) {
397  side = TrackerDetSide::Barrel;
398  idLayer = tTopo->pxbLayer(rh.det()->geographicalId());
399  } else if ((rh.det()->geographicalId()).subdetId() == PixelSubdetector::PixelEndcap) {
401  idLayer = tTopo->pxfDisk(rh.det()->geographicalId());
402  if (tTopo->pxfSide(rh.det()->geographicalId()) == 1)
404  else
406  }
407 
408  if (layer.subdet == subdet && layer.side == side && layer.idLayer == idLayer) {
409  BaseTrackerRecHit const& b(rh);
410  auto ptrHit = (BaseTrackerRecHit*)(b.clone());
411  layerhits_.emplace_back(ptrHit);
412  } else
413  continue;
414  }
415  ret->addHits(layer.nameIndex, std::move(layerhits_));
416  }
417  ret->shrink_to_fit();
418  return ret;
419 }
std::vector< const DetLayer * > theLayerDets
tuple ret
prodAgent to be discontinued
std::vector< LayerSpec > theLayers
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:539
edm::EDGetTokenT< FastTrackerRecHitCollection > fastSimrecHitsToken_
std::vector< std::string > theLayerNames
unsigned int pxfDisk(const DetId &id) const
TrackerDetSide
Definition: TrackerDetSide.h:4
constexpr std::array< uint8_t, layerIndexSize > layer
bool getData(T &iHolder) const
Definition: EventSetup.h:128
void updateEventSetup(const edm::EventSetup &es)
def move
Definition: eostools.py:511
std::vector< SeedingLayerSetsHits::LayerSetIndex > theLayerSetIndices
unsigned int pxbLayer(const DetId &id) const
double b
Definition: hdecay.h:118
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyToken_
unsigned int pxfSide(const DetId &id) const
std::vector< HitPointer > OwnedHits
SeedingLayerSetsBuilder::SeedingLayerId SeedingLayerSetsBuilder::nameToEnumId ( const std::string &  name)
static

Definition at line 31 of file SeedingLayerSetsBuilder.cc.

References Barrel, GeomDetEnumerators::invalidDet, NegEndcap, GeomDetEnumerators::PixelBarrel, GeomDetEnumerators::PixelEndcap, PosEndcap, GeomDetEnumerators::TEC, GeomDetEnumerators::TIB, GeomDetEnumerators::TID, and GeomDetEnumerators::TOB.

Referenced by SeedingLayerSetsBuilder::LayerSpec::LayerSpec(), and MTVHistoProducerAlgoForTracker::MTVHistoProducerAlgoForTracker().

31  {
34  int idLayer = 0;
35 
36  size_t index;
37  //
38  // BPIX
39  //
40  if ((index = name.find("BPix")) != string::npos) {
43  idLayer = atoi(name.substr(index + 4, 1).c_str());
44  }
45  //
46  // FPIX
47  //
48  else if ((index = name.find("FPix")) != string::npos) {
50  idLayer = atoi(name.substr(index + 4).c_str());
51  if (name.find("pos") != string::npos) {
53  } else {
55  }
56  }
57  //
58  // TIB
59  //
60  else if ((index = name.find("TIB")) != string::npos) {
61  subdet = GeomDetEnumerators::TIB;
63  idLayer = atoi(name.substr(index + 3, 1).c_str());
64  }
65  //
66  // TID
67  //
68  else if ((index = name.find("TID")) != string::npos) {
69  subdet = GeomDetEnumerators::TID;
70  idLayer = atoi(name.substr(index + 3, 1).c_str());
71  if (name.find("pos") != string::npos) {
73  } else {
75  }
76  }
77  //
78  // TOB
79  //
80  else if ((index = name.find("TOB")) != string::npos) {
81  subdet = GeomDetEnumerators::TOB;
83  idLayer = atoi(name.substr(index + 3, 1).c_str());
84  }
85  //
86  // TEC
87  //
88  else if ((index = name.find("TEC")) != string::npos) {
89  subdet = GeomDetEnumerators::TEC;
90  idLayer = atoi(name.substr(index + 3, 1).c_str());
91  if (name.find("pos") != string::npos) {
93  } else {
95  }
96  }
97  return std::make_tuple(subdet, side, idLayer);
98 }
TrackerDetSide
Definition: TrackerDetSide.h:4
unsigned short SeedingLayerSetsBuilder::numberOfLayers ( ) const
inline

Definition at line 48 of file SeedingLayerSetsBuilder.h.

References theLayers.

Referenced by layers().

48 { return theLayers.size(); }
std::vector< LayerSpec > theLayers
unsigned short SeedingLayerSetsBuilder::numberOfLayerSets ( ) const
inline

Definition at line 49 of file SeedingLayerSetsBuilder.h.

References theLayerSetIndices, and theNumberOfLayersInSet.

49  {
51  }
std::vector< SeedingLayerSetsHits::LayerSetIndex > theLayerSetIndices
SeedingLayerSetsLooper SeedingLayerSetsBuilder::seedingLayerSetsLooper ( ) const
inline

Definition at line 53 of file SeedingLayerSetsBuilder.h.

References theLayerSetIndices, and theNumberOfLayersInSet.

53  {
55  }
std::vector< SeedingLayerSetsHits::LayerSetIndex > theLayerSetIndices
void SeedingLayerSetsBuilder::updateEventSetup ( const edm::EventSetup es)
private

Definition at line 295 of file SeedingLayerSetsBuilder.cc.

References GeometricSearchTracker::barrelLayers(), edm::ESWatcher< T >::check(), Exception, geometryWatcher_, edm::EventSetup::getData(), phase1PixelTopology::layer, GeometricSearchTracker::negForwardLayers(), GeometricSearchTracker::negTecLayers(), GeometricSearchTracker::negTidLayers(), GeomDetEnumerators::PixelBarrel, GeomDetEnumerators::PixelEndcap, PosEndcap, GeometricSearchTracker::posForwardLayers(), GeometricSearchTracker::posTecLayers(), GeometricSearchTracker::posTidLayers(), GeomDetEnumerators::TEC, theLayerDets, theLayerNames, theLayers, theTTRHBuilders, GeomDetEnumerators::TIB, GeometricSearchTracker::tibLayers(), GeomDetEnumerators::TID, GeomDetEnumerators::TOB, GeometricSearchTracker::tobLayers(), trackerToken_, and trhWatcher_.

Referenced by hits(), and makeSeedingLayerSetsHitsforFastSim().

295  {
296  // We want to evaluate both in the first invocation (to properly
297  // initialize ESWatcher), and this way we avoid one branch compared
298  // to || (should be tiny effect)
299  if (!(geometryWatcher_.check(es) | trhWatcher_.check(es)))
300  return;
301 
302  const GeometricSearchTracker& tracker = es.getData(trackerToken_);
303 
304  const std::vector<BarrelDetLayer const*>& bpx = tracker.barrelLayers();
305  const std::vector<BarrelDetLayer const*>& tib = tracker.tibLayers();
306  const std::vector<BarrelDetLayer const*>& tob = tracker.tobLayers();
307 
308  const std::vector<ForwardDetLayer const*>& fpx_pos = tracker.posForwardLayers();
309  const std::vector<ForwardDetLayer const*>& tid_pos = tracker.posTidLayers();
310  const std::vector<ForwardDetLayer const*>& tec_pos = tracker.posTecLayers();
311 
312  const std::vector<ForwardDetLayer const*>& fpx_neg = tracker.negForwardLayers();
313  const std::vector<ForwardDetLayer const*>& tid_neg = tracker.negTidLayers();
314  const std::vector<ForwardDetLayer const*>& tec_neg = tracker.negTecLayers();
315 
316  for (const auto& layer : theLayers) {
317  const DetLayer* detLayer = nullptr;
318  int index = layer.idLayer - 1;
319 
320  if (layer.subdet == GeomDetEnumerators::PixelBarrel) {
321  detLayer = bpx[index];
322  } else if (layer.subdet == GeomDetEnumerators::PixelEndcap) {
323  if (layer.side == TrackerDetSide::PosEndcap) {
324  detLayer = fpx_pos[index];
325  } else {
326  detLayer = fpx_neg[index];
327  }
328  } else if (layer.subdet == GeomDetEnumerators::TIB) {
329  detLayer = tib[index];
330  } else if (layer.subdet == GeomDetEnumerators::TID) {
331  if (layer.side == TrackerDetSide::PosEndcap) {
332  detLayer = tid_pos[index];
333  } else {
334  detLayer = tid_neg[index];
335  }
336  } else if (layer.subdet == GeomDetEnumerators::TOB) {
337  detLayer = tob[index];
338  } else if (layer.subdet == GeomDetEnumerators::TEC) {
339  if (layer.side == TrackerDetSide::PosEndcap) {
340  detLayer = tec_pos[index];
341  } else {
342  detLayer = tec_neg[index];
343  }
344  } else {
345  throw cms::Exception("Configuration") << "Did not find DetLayer for layer " << theLayerNames[layer.nameIndex];
346  }
347 
348  theLayerDets[layer.nameIndex] = detLayer;
349  theTTRHBuilders[layer.nameIndex] = &es.getData(layer.hitBuilderToken);
350  }
351 }
std::vector< const DetLayer * > theLayerDets
std::vector< ForwardDetLayer const * > const & posForwardLayers() const
std::vector< LayerSpec > theLayers
edm::ESWatcher< TrackerRecoGeometryRecord > geometryWatcher_
std::vector< std::string > theLayerNames
std::vector< BarrelDetLayer const * > const & tobLayers() const
constexpr std::array< uint8_t, layerIndexSize > layer
bool getData(T &iHolder) const
Definition: EventSetup.h:128
std::vector< ForwardDetLayer const * > const & negForwardLayers() const
std::vector< const TransientTrackingRecHitBuilder * > theTTRHBuilders
edm::ESWatcher< TransientRecHitRecord > trhWatcher_
std::vector< BarrelDetLayer const * > const & tibLayers() const
const edm::ESGetToken< GeometricSearchTracker, TrackerRecoGeometryRecord > trackerToken_
std::vector< ForwardDetLayer const * > const & posTecLayers() const
std::vector< ForwardDetLayer const * > const & negTidLayers() const
bool check(const edm::EventSetup &iSetup)
Definition: ESWatcher.h:57
std::vector< ForwardDetLayer const * > const & posTidLayers() const
std::vector< ForwardDetLayer const * > const & negTecLayers() const
std::vector< BarrelDetLayer const * > const & barrelLayers() const

Member Data Documentation

edm::EDGetTokenT<FastTrackerRecHitCollection> SeedingLayerSetsBuilder::fastSimrecHitsToken_
private
edm::ESWatcher<TrackerRecoGeometryRecord> SeedingLayerSetsBuilder::geometryWatcher_
private

Definition at line 71 of file SeedingLayerSetsBuilder.h.

Referenced by updateEventSetup().

std::vector<const DetLayer*> SeedingLayerSetsBuilder::theLayerDets
private
std::vector<std::string> SeedingLayerSetsBuilder::theLayerNames
private
std::vector<LayerSpec> SeedingLayerSetsBuilder::theLayers
private
std::vector<SeedingLayerSetsHits::LayerSetIndex> SeedingLayerSetsBuilder::theLayerSetIndices
private
unsigned short SeedingLayerSetsBuilder::theNumberOfLayersInSet
private
std::vector<const TransientTrackingRecHitBuilder*> SeedingLayerSetsBuilder::theTTRHBuilders
private

Definition at line 103 of file SeedingLayerSetsBuilder.h.

Referenced by hits(), SeedingLayerSetsBuilder(), and updateEventSetup().

const edm::ESGetToken<GeometricSearchTracker, TrackerRecoGeometryRecord> SeedingLayerSetsBuilder::trackerToken_
private

Definition at line 74 of file SeedingLayerSetsBuilder.h.

Referenced by updateEventSetup().

edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> SeedingLayerSetsBuilder::trackerTopologyToken_
private
edm::ESWatcher<TransientRecHitRecord> SeedingLayerSetsBuilder::trhWatcher_
private

Definition at line 72 of file SeedingLayerSetsBuilder.h.

Referenced by updateEventSetup().