CMS 3D CMS Logo

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

#include <CombinedHitQuadrupletGeneratorForPhotonConversion.h>

Public Types

typedef LayerHitMapCache LayerCacheType
 

Public Member Functions

void clearLayerCache ()
 
 CombinedHitQuadrupletGeneratorForPhotonConversion (const edm::ParameterSet &cfg, edm::ConsumesCollector &iC)
 
 CombinedHitQuadrupletGeneratorForPhotonConversion (const CombinedHitQuadrupletGeneratorForPhotonConversion &cb)=delete
 
void hitPairs (const TrackingRegion &, OrderedHitPairs &, const edm::Event &, const edm::EventSetup &)
 
const OrderedHitPairsrun (const TrackingRegion &region, const edm::Event &ev, const edm::EventSetup &es)
 
 ~CombinedHitQuadrupletGeneratorForPhotonConversion ()
 

Private Attributes

std::unique_ptr< HitQuadrupletGeneratorFromLayerPairForPhotonConversiontheGenerator
 
LayerCacheType theLayerCache
 
const unsigned int theMaxElement
 
OrderedHitPairs thePairs
 
edm::EDGetTokenT< SeedingLayerSetsHitstheSeedingLayerToken
 

Detailed Description

Hides set of HitQuadrupletGeneratorFromLayerPairForPhotonConversion generators.

Definition at line 28 of file CombinedHitQuadrupletGeneratorForPhotonConversion.h.

Member Typedef Documentation

◆ LayerCacheType

Constructor & Destructor Documentation

◆ CombinedHitQuadrupletGeneratorForPhotonConversion() [1/2]

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

Definition at line 7 of file CombinedHitQuadrupletGeneratorForPhotonConversion.cc.

References theGenerator, theLayerCache, and theMaxElement.

9  : theSeedingLayerToken(iC.consumes<SeedingLayerSetsHits>(cfg.getParameter<edm::InputTag>("SeedingLayers"))),
10  theMaxElement(cfg.getParameter<unsigned int>("maxElement")) {
11  theGenerator =
12  std::make_unique<HitQuadrupletGeneratorFromLayerPairForPhotonConversion>(0, 1, &theLayerCache, theMaxElement);
13 }
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
std::unique_ptr< HitQuadrupletGeneratorFromLayerPairForPhotonConversion > theGenerator

◆ CombinedHitQuadrupletGeneratorForPhotonConversion() [2/2]

CombinedHitQuadrupletGeneratorForPhotonConversion::CombinedHitQuadrupletGeneratorForPhotonConversion ( const CombinedHitQuadrupletGeneratorForPhotonConversion cb)
delete

◆ ~CombinedHitQuadrupletGeneratorForPhotonConversion()

CombinedHitQuadrupletGeneratorForPhotonConversion::~CombinedHitQuadrupletGeneratorForPhotonConversion ( )

Definition at line 15 of file CombinedHitQuadrupletGeneratorForPhotonConversion.cc.

15 {}

Member Function Documentation

◆ clearLayerCache()

void CombinedHitQuadrupletGeneratorForPhotonConversion::clearLayerCache ( )
inline

◆ hitPairs()

void CombinedHitQuadrupletGeneratorForPhotonConversion::hitPairs ( const TrackingRegion region,
OrderedHitPairs result,
const edm::Event ev,
const edm::EventSetup es 
)

Definition at line 25 of file CombinedHitQuadrupletGeneratorForPhotonConversion.cc.

References cms::cuda::assert(), LayerHitMapCache::clear(), makeMEIFBenchmarkPlots::ev, mps_fire::i, hgcalTopologyTester_cfi::layers, HLT_2022v12_cff::region, mps_fire::result, SeedingLayerSetsHits::size(), theGenerator, theLayerCache, and theSeedingLayerToken.

Referenced by run().

28  {
29  size_t maxHitQuadruplets = 1000000;
31  ev.getByToken(theSeedingLayerToken, hlayers);
32  const SeedingLayerSetsHits& layers = *hlayers;
33  assert(layers.numberOfLayersInSet() == 2);
34 
35  for (SeedingLayerSetsHits::LayerSetIndex i = 0; i < hlayers->size() && result.size() < maxHitQuadruplets; ++i) {
36  theGenerator->hitPairs(region, result, layers[i]);
37  }
39 }
unsigned short LayerSetIndex
unsigned short size() const
Get the number of SeedingLayerSets.
assert(be >=bs)
std::unique_ptr< HitQuadrupletGeneratorFromLayerPairForPhotonConversion > theGenerator

◆ run()

const OrderedHitPairs & CombinedHitQuadrupletGeneratorForPhotonConversion::run ( const TrackingRegion region,
const edm::Event ev,
const edm::EventSetup es 
)

Member Data Documentation

◆ theGenerator

std::unique_ptr<HitQuadrupletGeneratorFromLayerPairForPhotonConversion> CombinedHitQuadrupletGeneratorForPhotonConversion::theGenerator
private

◆ theLayerCache

LayerCacheType CombinedHitQuadrupletGeneratorForPhotonConversion::theLayerCache
private

◆ theMaxElement

const unsigned int CombinedHitQuadrupletGeneratorForPhotonConversion::theMaxElement
private

◆ thePairs

OrderedHitPairs CombinedHitQuadrupletGeneratorForPhotonConversion::thePairs
private

Definition at line 52 of file CombinedHitQuadrupletGeneratorForPhotonConversion.h.

Referenced by run().

◆ theSeedingLayerToken

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

Definition at line 46 of file CombinedHitQuadrupletGeneratorForPhotonConversion.h.

Referenced by hitPairs().