36 template <
class T>
T sqr(
T t) {
return t*
t;}
42 produces<L3MuonTrajectorySeedCollection>();
74 auto result = std::make_unique<L3MuonTrajectorySeedCollection>();
83 LogDebug(
"TSGFromL1Muon")<<l1muon->size()<<
" l1 muons to seed from.";
85 L1MuonParticleCollection::const_iterator muItr = l1muon->begin();
86 L1MuonParticleCollection::const_iterator muEnd = l1muon->end();
87 for (
size_t iL1 = 0; muItr < muEnd; ++muItr, ++iL1) {
89 if (muItr->gmtMuonCand().empty())
continue;
97 typedef std::vector<std::unique_ptr<TrackingRegion> > Regions;
99 for (Regions::const_iterator ir=regions.begin(); ir != regions.end(); ++ir) {
105 unsigned int nSets = candidates.
size();
106 for (
unsigned int ic= 0; ic <nSets; ic++) {
109 std::vector<const TrackingRecHit *> trh;
110 for (
unsigned int i= 0, nHits = hits.
size();
i< nHits; ++
i) trh.push_back( hits[
i]->hit() );
114 if (!track)
continue;
116 if (!
filter(track, trh) ) {
delete track;
continue; }
121 for (L1MuonSeedsMerger::TracksAndHits::const_iterator it = tracks.begin();
122 it != tracks.end(); ++it) {
136 LogDebug(
"TSGFromL1Muon")<<
result->size()<<
" seeds to the event.";
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
edm::ParameterSet theConfig
TSGFromL1Muon(const edm::ParameterSet &cfg)
~TSGFromL1Muon() override
bool getByToken(EDGetToken token, Handle< PROD > &result) const
std::pair< const reco::Track *, SeedingHitSet > TrackAndHits
void produce(edm::Event &ev, const edm::EventSetup &es) override
std::unique_ptr< L1MuonPixelTrackFitter > theFitter
OrderedHitsGenerator * theHitGenerator
TrajectorySeed trajectorySeed() const
std::unique_ptr< L1MuonRegionProducer > theRegionProducer
edm::EDGetTokenT< PixelTrackFilter > theFilterToken
virtual const OrderedSeedingHits & run(const TrackingRegion ®, const edm::Event &ev, const edm::EventSetup &es)=0
std::vector< TrackAndHits > TracksAndHits
L1MuonSeedsMerger * theMerger
edm::InputTag theSourceTag
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
virtual void resolve(TracksAndHits &) const
virtual unsigned int size() const =0
void beginRun(const edm::Run &run, const edm::EventSetup &es) override
edm::EDGetTokenT< l1extra::L1MuonParticleCollection > theSourceToken
unsigned int size() const
T get(const Candidate &c)