CMS 3D CMS Logo

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

#include <CombinedHitPairGeneratorForPhotonConversion.h>

Public Types

typedef LayerHitMapCache LayerCacheType
 

Public Member Functions

void clearCache ()
 
 CombinedHitPairGeneratorForPhotonConversion (const edm::ParameterSet &cfg, edm::ConsumesCollector &iC)
 
const OrderedHitPairsrun (const ConversionRegion &convRegion, const TrackingRegion &region, const edm::Event &ev, const edm::EventSetup &es)
 

Private Member Functions

void hitPairs (const ConversionRegion &convRegion, const TrackingRegion &reg, OrderedHitPairs &result, const edm::Event &ev, const edm::EventSetup &es)
 

Private Attributes

uint32_t maxHitPairsPerTrackAndGenerator
 
std::unique_ptr< HitPairGeneratorFromLayerPairForPhotonConversiontheGenerator
 
LayerCacheType theLayerCache
 
unsigned int theMaxElement
 
OrderedHitPairs thePairs
 
edm::EDGetTokenT< SeedingLayerSetsHitstheSeedingLayerToken
 

Detailed Description

Hides set of HitPairGeneratorFromLayerPairForPhotonConversion generators.

Definition at line 28 of file CombinedHitPairGeneratorForPhotonConversion.h.

Member Typedef Documentation

◆ LayerCacheType

Constructor & Destructor Documentation

◆ CombinedHitPairGeneratorForPhotonConversion()

CombinedHitPairGeneratorForPhotonConversion::CombinedHitPairGeneratorForPhotonConversion ( const edm::ParameterSet cfg,
edm::ConsumesCollector iC 
)

Definition at line 15 of file CombinedHitPairGeneratorForPhotonConversion.cc.

References looper::cfg, maxHitPairsPerTrackAndGenerator, theGenerator, theLayerCache, and theMaxElement.

17  : theSeedingLayerToken(iC.consumes<SeedingLayerSetsHits>(cfg.getParameter<edm::InputTag>("SeedingLayers"))) {
18  theMaxElement = cfg.getParameter<unsigned int>("maxElement");
19  maxHitPairsPerTrackAndGenerator = cfg.getParameter<unsigned int>("maxHitPairsPerTrackAndGenerator");
20  theGenerator = std::make_unique<HitPairGeneratorFromLayerPairForPhotonConversion>(
22 }
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
std::unique_ptr< HitPairGeneratorFromLayerPairForPhotonConversion > theGenerator

Member Function Documentation

◆ clearCache()

void CombinedHitPairGeneratorForPhotonConversion::clearCache ( )

◆ hitPairs()

void CombinedHitPairGeneratorForPhotonConversion::hitPairs ( const ConversionRegion convRegion,
const TrackingRegion reg,
OrderedHitPairs result,
const edm::Event ev,
const edm::EventSetup es 
)
private

Definition at line 35 of file CombinedHitPairGeneratorForPhotonConversion.cc.

References cms::cuda::assert(), makeMEIFBenchmarkPlots::ev, mps_fire::i, hgcalTBTopologyTester_cfi::layers, nano_mu_digi_cff::region, mps_fire::result, theGenerator, and theSeedingLayerToken.

Referenced by run().

39  {
41  ev.getByToken(theSeedingLayerToken, hlayers);
42  const SeedingLayerSetsHits& layers = *hlayers;
43  assert(layers.numberOfLayersInSet() == 2);
44 
45  for (SeedingLayerSetsHits::LayerSetIndex i = 0; i < layers.size(); ++i) {
46  theGenerator->hitPairs(convRegion, region, result, layers[i], ev, es);
47  }
48 }
unsigned short LayerSetIndex
assert(be >=bs)
std::unique_ptr< HitPairGeneratorFromLayerPairForPhotonConversion > theGenerator

◆ run()

const OrderedHitPairs & CombinedHitPairGeneratorForPhotonConversion::run ( const ConversionRegion convRegion,
const TrackingRegion region,
const edm::Event ev,
const edm::EventSetup es 
)

Definition at line 24 of file CombinedHitPairGeneratorForPhotonConversion.cc.

References makeMEIFBenchmarkPlots::ev, hitPairs(), nano_mu_digi_cff::region, and thePairs.

27  {
28  if (thePairs.capacity() == 0)
29  thePairs.reserve(localRA.upper());
30  thePairs.clear();
31  hitPairs(convRegion, region, thePairs, ev, es);
32  return thePairs;
33 }
void hitPairs(const ConversionRegion &convRegion, const TrackingRegion &reg, OrderedHitPairs &result, const edm::Event &ev, const edm::EventSetup &es)

Member Data Documentation

◆ maxHitPairsPerTrackAndGenerator

uint32_t CombinedHitPairGeneratorForPhotonConversion::maxHitPairsPerTrackAndGenerator
private

◆ theGenerator

std::unique_ptr<HitPairGeneratorFromLayerPairForPhotonConversion> CombinedHitPairGeneratorForPhotonConversion::theGenerator
private

◆ theLayerCache

LayerCacheType CombinedHitPairGeneratorForPhotonConversion::theLayerCache
private

◆ theMaxElement

unsigned int CombinedHitPairGeneratorForPhotonConversion::theMaxElement
private

◆ thePairs

OrderedHitPairs CombinedHitPairGeneratorForPhotonConversion::thePairs
private

Definition at line 59 of file CombinedHitPairGeneratorForPhotonConversion.h.

Referenced by clearCache(), and run().

◆ theSeedingLayerToken

edm::EDGetTokenT<SeedingLayerSetsHits> CombinedHitPairGeneratorForPhotonConversion::theSeedingLayerToken
private

Definition at line 51 of file CombinedHitPairGeneratorForPhotonConversion.h.

Referenced by hitPairs().