34 theFitterToken(iC.consumes<
PixelFitter>(cfg.getParameter<
edm::InputTag>(
"Fitter"))),
35 theCleanerName(cfg.getParameter<
std::
string>(
"Cleaner"))
38 if(filterTag.
label() !=
"") {
58 const auto& hitSets = *hhitSets;
62 const auto& fitter = *hfitter;
71 std::vector<const TrackingRecHit *>
hits;hits.reserve(4);
72 for(
const auto& regionHitSets: hitSets) {
77 auto nHits = tuplet.size(); hits.resize(nHits);
78 for (
unsigned int iHit = 0; iHit < nHits; ++iHit) hits[iHit] = tuplet[iHit];
81 std::unique_ptr<reco::Track>
track = fitter.run(hits, region);
85 if (!(*filter)(track.get(),
hits)) {
91 tracks.emplace_back(track.release(), tuplet);
99 const auto& cleaner = *hcleaner;
101 cleaner.cleanTracks(tracks);
T getParameter(std::string const &) const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
pixeltrackfitting::TracksWithTTRHs clean(const pixeltrackfitting::TracksWithTTRHs &initialT_TTRHs) const
edm::EDGetTokenT< PixelTrackFilter > theFilterToken
std::vector< TrackWithTTRHs > TracksWithTTRHs
std::string theCleanerName
PixelTrackReconstruction(const edm::ParameterSet &conf, edm::ConsumesCollector &&iC)
~PixelTrackReconstruction()
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void run(pixeltrackfitting::TracksWithTTRHs &tah, edm::Event &ev, const edm::EventSetup &es)
T const * product() const
bool isUninitialized() const
static void fillDescriptions(edm::ParameterSetDescription &desc)
edm::EDGetTokenT< RegionsSeedingHitSets > theHitSetsToken
edm::EDGetTokenT< PixelFitter > theFitterToken