26 class FindManySpeedTestProducer;
46 ,
nHits_{
p.get<
size_t>(
"nHits")}
52 produces<std::vector<arttest::Hit>>();
53 produces<std::vector<arttest::Track>>();
54 produces<art::Assns<arttest::Track, arttest::Hit>>();
60 auto vh_pid = e.
getProductID<std::vector<arttest::Hit>>();
61 auto vt_pid = e.
getProductID<std::vector<arttest::Track>>();
64 auto hits = std::make_unique<std::vector<arttest::Hit>>(
nHits_);
65 std::iota(hits->begin(), hits->end(), 0ul);
66 e.
put(std::move(hits));
69 auto tracks = std::make_unique<std::vector<arttest::Track>>(
nTracks_);
74 auto assns = std::make_unique<art::Assns<arttest::Hit, arttest::Track>>();
76 std::uniform_int_distribution<size_t> udist(0,
nHits_);
77 auto pdice = std::bind(pdist,
gen_);
78 auto udice = std::bind(udist,
gen_);
81 for (
size_t iTrack = 0; iTrack !=
nTracks_; ++iTrack) {
84 for (
size_t i = 0, nHitsTrack = pdice();
i != nHitsTrack; ++
i) {
88 e.
put(std::move(assns));
ProductID getProductID(std::string const &instance_name="") const
void produce(art::Event &e) override
#define DEFINE_ART_MODULE(klass)
EDProductGetter const * productGetter(ProductID const pid) const
FindManySpeedTestProducer(fhicl::ParameterSet const &p)
ProductID put(std::unique_ptr< PROD > &&edp, FullSemantic< Level::Run > const semantic)
size_t const pmHitsPerTrack_