18 virtual void endJob() ;
49 produces<reco::TrackCollection>();
51 produces<TrackingRecHitCollection>();
52 produces<reco::TrackExtraCollection>();
54 produces<std::vector<Trajectory> >();
55 produces<TrajTrackAssociationCollection>();
84 unique_ptr<TrackExtraCollection> selTrackExtras(copyExtras_ ?
new TrackExtraCollection() :
nullptr);
85 unique_ptr<vector<Trajectory> > outputTJ(
new vector<Trajectory> );
99 iEvent.
getByToken(trajTag,TrajectoryCollection);
106 for( ; it != lastAssoc; ++it ) {
109 bool goodTk = (itc->quality(trackQuality_));
113 auto const &
track =(*itc);
115 selTracks->push_back(
track );
116 outputTJ->push_back( *traj );
121 for (; irhit!=lasthit; ++irhit) {
122 selHits->push_back((*irhit)->clone() );
130 unsigned nTracks = selTracks->size();
137 selTrackExtras->reserve(nTracks);
141 auto const & aTrack = (*selTracks)[
index];
142 selTrackExtras->emplace_back(aTrack.outerPosition(),
143 aTrack.outerMomentum(),
145 aTrack.innerPosition(),
146 aTrack.innerMomentum(),
148 aTrack.outerStateCovariance(),
150 aTrack.innerStateCovariance(),
152 aTrack.seedDirection(),
156 auto & aTrackExtra = selTrackExtras->back();
158 auto nHits = aTrack.recHitsSize();
159 aTrackExtra.setHits(theRecoHitsProd, hits, nHits);
161 selTrackExtras->push_back(aTrackExtra);
168 (*selTracks)[
index].setExtra(theTrackExtraRef);
177 nTracks = theRecoTracks->size();
181 trajTrackMap->insert(trajRef,tkRef);
T getParameter(std::string const &) const
reco::TrackBase::TrackQuality trackQuality_
T getUntrackedParameter(std::string const &, T const &) const
const unsigned int nTracks(const reco::Vertex &sv)
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
friend struct const_iterator
const_iterator end() const
last iterator over the map (read only)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
TrackQuality
track quality
void produce(edm::Event &, const edm::EventSetup &) override
std::vector< Track > TrackCollection
collection of Tracks
edm::EDGetTokenT< std::vector< Trajectory > > trajTag
key_type key() const
Accessor for product key.
~QualityFilter() override
#define DEFINE_FWK_MODULE(type)
edm::EDGetTokenT< TrajTrackAssociationCollection > tassTag
edm::AssociationMap< edm::OneToOne< std::vector< Trajectory >, reco::TrackCollection, unsigned short > > TrajTrackAssociationCollection
RefProd< PROD > getRefBeforePut()
std::vector< TrackExtra > TrackExtraCollection
collection of TrackExtra objects
edm::OwnVector< TrackingRecHit > TrackingRecHitCollection
collection of TrackingRecHits
std::vector< Trajectory > TrajectoryCollection
const_iterator begin() const
first iterator over the map (read only)
QualityFilter(const edm::ParameterSet &)