CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
PixelTrackProducer.cc
Go to the documentation of this file.
1 #include <vector>
2 
16 
20 #include "storeTracks.h"
21 
24 
25 namespace edm {
26  class Event;
27  class EventSetup;
28  class ParameterSet;
30 } // namespace edm
31 class TrackerTopology;
32 
33 using namespace pixeltrackfitting;
34 using edm::ParameterSet;
35 
37 public:
39  : theReconstruction(cfg, consumesCollector()), htTopoToken_(esConsumes()) {
40  edm::LogInfo("PixelTrackProducer") << " construction...";
41  produces<reco::TrackCollection>();
42  produces<TrackingRecHitCollection>();
43  produces<reco::TrackExtraCollection>();
44  }
45 
46  ~PixelTrackProducer() override = default;
47 
48  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions) {
50 
51  desc.add<std::string>("passLabel", "pixelTracks"); // What is this? It is not used anywhere in this code.
53 
54  descriptions.add("pixelTracks", desc);
55  }
56 
57  void produce(edm::Event& ev, const edm::EventSetup& es) override {
58  LogDebug("PixelTrackProducer, produce") << "event# :" << ev.id();
59 
61  theReconstruction.run(tracks, ev, es);
62  auto htTopo = es.getData(htTopoToken_);
63 
64  // store tracks
65  storeTracks(ev, tracks, htTopo);
66  }
67 
68 private:
71 };
72 
tuple cfg
Definition: looper.py:296
void storeTracks(Ev &ev, const TWH &tracksWithHits, const TrackerTopology &ttopo)
Definition: storeTracks.h:19
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
auto const & tracks
cannot be loose
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
bool getData(T &iHolder) const
Definition: EventSetup.h:122
std::vector< TrackWithTTRHs > TracksWithTTRHs
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > htTopoToken_
void produce(edm::Event &ev, const edm::EventSetup &es) override
ParameterDescriptionBase * add(U const &iLabel, T const &value)
Log< level::Info, false > LogInfo
void add(std::string const &label, ParameterSetDescription const &psetDescription)
PixelTrackReconstruction theReconstruction
edm::EventID id() const
Definition: EventBase.h:59
static void fillDescriptions(edm::ParameterSetDescription &desc)
PixelTrackProducer(const edm::ParameterSet &cfg)
ESGetTokenH3DDVariant esConsumes(std::string const &Reccord, edm::ConsumesCollector &)
Definition: DeDxTools.cc:283
#define LogDebug(id)