CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
L1TMuonOverlapPhase1TrackProducer.cc
Go to the documentation of this file.
7 
12 
19 
20 #include <algorithm>
21 #include <iostream>
22 #include <memory>
23 
25  : muStubsInputTokens(
26  {consumes<L1MuDTChambPhContainer>(edmParameterSet.getParameter<edm::InputTag>("srcDTPh")),
27  consumes<L1MuDTChambThContainer>(edmParameterSet.getParameter<edm::InputTag>("srcDTTh")),
28  consumes<CSCCorrelatedLCTDigiCollection>(edmParameterSet.getParameter<edm::InputTag>("srcCSC")),
29  consumes<RPCDigiCollection>(edmParameterSet.getParameter<edm::InputTag>("srcRPC"))}),
30  omtfParamsEsToken(esConsumes<L1TMuonOverlapParams, L1TMuonOverlapParamsRcd, edm::Transition::BeginRun>()),
31  muonGeometryTokens({esConsumes<RPCGeometry, MuonGeometryRecord, edm::Transition::BeginRun>(),
32  esConsumes<CSCGeometry, MuonGeometryRecord, edm::Transition::BeginRun>(),
33  esConsumes<DTGeometry, MuonGeometryRecord, edm::Transition::BeginRun>()}),
34  magneticFieldEsToken(esConsumes<MagneticField, IdealMagneticFieldRecord, edm::Transition::BeginRun>()),
35  propagatorEsToken(esConsumes<Propagator, TrackingComponentsRecord, edm::Transition::BeginRun>(
36  edm::ESInputTag("", "SteppingHelixPropagatorAlong"))),
37  //propagatorEsToken(esConsumes<Propagator, TrackingComponentsRecord, edm::Transition::BeginRun>(edmParameterSet.getParameter<edm::ESInputTag>("propagatorTag"))),
38  omtfReconstruction(edmParameterSet, muStubsInputTokens) {
39  produces<l1t::RegionalMuonCandBxCollection>("OMTF");
40 
41  if (edmParameterSet.exists("simTracksTag"))
42  mayConsume<edm::SimTrackContainer>(edmParameterSet.getParameter<edm::InputTag>("simTracksTag"));
43  if (edmParameterSet.exists("simVertexesTag"))
44  mayConsume<edm::SimVertexContainer>(edmParameterSet.getParameter<edm::InputTag>("simVertexesTag"));
45  if (edmParameterSet.exists("trackingParticleTag"))
46  mayConsume<TrackingParticleCollection>(edmParameterSet.getParameter<edm::InputTag>("trackingParticleTag"));
47 
48  if (edmParameterSet.exists("rpcSimHitsInputTag"))
49  mayConsume<edm::PSimHitContainer>(edmParameterSet.getParameter<edm::InputTag>("rpcSimHitsInputTag"));
50  if (edmParameterSet.exists("cscSimHitsInputTag"))
51  mayConsume<edm::PSimHitContainer>(edmParameterSet.getParameter<edm::InputTag>("cscSimHitsInputTag"));
52  if (edmParameterSet.exists("dtSimHitsInputTag"))
53  mayConsume<edm::PSimHitContainer>(edmParameterSet.getParameter<edm::InputTag>("dtSimHitsInputTag"));
54 
55  if (edmParameterSet.exists("rpcDigiSimLinkInputTag"))
57  edmParameterSet.getParameter<edm::InputTag>("rpcDigiSimLinkInputTag"));
58  if (edmParameterSet.exists("cscStripDigiSimLinksInputTag"))
60  edmParameterSet.getParameter<edm::InputTag>("cscStripDigiSimLinksInputTag"));
61  if (edmParameterSet.exists("dtDigiSimLinksInputTag"))
63  edmParameterSet.getParameter<edm::InputTag>("dtDigiSimLinksInputTag"));
64 }
79 }
83  std::ostringstream str;
84 
85  std::unique_ptr<l1t::RegionalMuonCandBxCollection> candidates = omtfReconstruction.reconstruct(iEvent, evSetup);
86 
87  iEvent.put(std::move(candidates), "OMTF");
88 }
edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > magneticFieldEsToken
needed by tools/CandidateSimMuonMatcher.h
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
Definition: Event.h:133
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
muonGeometryTokens({esConsumes< RPCGeometry, MuonGeometryRecord, edm::Transition::BeginRun >(), esConsumes< CSCGeometry, MuonGeometryRecord, edm::Transition::BeginRun >(), esConsumes< DTGeometry, MuonGeometryRecord, edm::Transition::BeginRun >()})
edm::ESGetToken< Propagator, TrackingComponentsRecord > propagatorEsToken
void produce(edm::Event &, const edm::EventSetup &) override
void beginRun(edm::Run const &run, edm::EventSetup const &iSetup) override
int iEvent
Definition: GenABIO.cc:224
std::unique_ptr< l1t::RegionalMuonCandBxCollection > reconstruct(const edm::Event &, const edm::EventSetup &)
void beginRun(edm::Run const &, edm::EventSetup const &)
def move
Definition: eostools.py:511
omtfReconstruction(edmParameterSet, muStubsInputTokens)
edm::ESGetToken< L1TMuonOverlapParams, L1TMuonOverlapParamsRcd > omtfParamsEsToken
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
propagatorEsToken(esConsumes< Propagator, TrackingComponentsRecord, edm::Transition::BeginRun >(edm::ESInputTag("","SteppingHelixPropagatorAlong")))
L1TMuonOverlapPhase1TrackProducer(const edm::ParameterSet &)
omtfParamsEsToken(esConsumes< L1TMuonOverlapParams, L1TMuonOverlapParamsRcd, edm::Transition::BeginRun >())
#define str(s)
Definition: Run.h:45
magneticFieldEsToken(esConsumes< MagneticField, IdealMagneticFieldRecord, edm::Transition::BeginRun >())
A container for a generic type of digis indexed by some index, implemented with a map&lt;IndexType...