77 std::unique_ptr<art::Assns<recob::Track, recob::Hit, recob::TrackHitMeta>> assn(
new art::Assns<recob::Track, recob::Hit, recob::TrackHitMeta>);
78 std::unique_ptr<std::vector<recob::Hit>> outHits(
new std::vector<recob::Hit>);
81 art::PtrMaker<recob::Hit> hitPtrMaker{
e};
84 art::Handle<std::vector<recob::Track>> track_handle;
87 std::vector<art::Ptr<recob::Track>>
tracks;
88 art::fill_ptr_vector(tracks, track_handle);
90 art::FindManyP<recob::Hit, recob::TrackHitMeta> fmHits(tracks,
e,
fTrackLabel);
92 for (
unsigned i = 0; i < tracks.size(); i++) {
96 const std::vector<art::Ptr<recob::Hit>> &trkHits = fmHits.at(i);
97 const std::vector<const recob::TrackHitMeta*> &trkHitMetas = fmHits.data(i);
99 for (
unsigned i_hit = 0; i_hit < trkHits.size(); i_hit++) {
104 bool badhit = (meta.
Index() == std::numeric_limits<unsigned int>::max()) ||
108 outHits->push_back(hit);
109 art::Ptr<recob::Hit> thisHitPtr = hitPtrMaker(outHits->size()-1);
111 assn->addSingle(tracks[i], thisHitPtr, meta);
117 e.put(std::move(outHits));
118 e.put(std::move(assn));
ClusterModuleLabel join with tracks
bool HasValidPoint(size_t i) const
process_name use argoneut_mc_hitfinder track
art::InputTag fTrackLabel
2D representation of charge deposited in the TDC/wire plane
Track from a non-cascading particle.A recob::Track consists of a recob::TrackTrajectory, plus additional members relevant for a "fitted" track: