31 std::vector<const sim::SimChannel*> sccol;
32 evt.
getView(moduleLabel, sccol);
37 for (
auto itr = sccol.begin(); itr != sccol.end(); ++itr) {
40 const auto& idemap = (*itr)->TDCIDEMap();
43 for (
auto mitr = idemap.begin(); mitr != idemap.end(); mitr++) {
49 const std::vector<sim::IDE>& ide = (*mitr).second;
50 for (
size_t i = 0; i < ide.size(); ++i) {
55 voxList.
Add(larVoxelID, ide[i].numElectrons / lgp->
GeVToElectrons(), ide[i].trackID);
58 (*voxList.
find(larVoxelID)).
second.SetVoxelID(larVoxelID);
76 const std::vector<sim::SimPhotons>& pmt(*pmtHandle);
83 for (
auto itr = pmt.begin(); itr != pmt.end(); ++itr) {
85 int ch = (*itr).OpChannel();
87 if (pmtList.find(ch) == pmtList.end()) {
92 new_photons.reserve((*itr).size());
93 pmtList.insert(std::pair<int, sim::SimPhotons>(ch, new_photons));
97 for (
auto pitr = (*itr).begin(); pitr != (*itr).end(); ++pitr)
Store parameters for running LArG4.
static sim::LArVoxelList GetLArVoxelList(const art::Event &evt, std::string moduleLabel)
All information of a photon entering the sensitive optical detector volume.
void SetChannel(int ch)
Sets the optical detector channel number this object is associated to.
bool getByLabel(std::string const &label, std::string const &instance, Handle< PROD > &result) const
fInnerVessel push_back(Point(-578.400000, 0.000000, 0.000000))
iterator find(const key_type &key)
Code to link reconstructed objects back to the MC truth information.
Collection of photons which recorded on one channel.
int trigger_offset(DetectorClocksData const &data)
void Add(const key_type &key, const double &energy)
std::size_t getView(std::string const &moduleLabel, std::string const &productInstanceName, std::string const &processName, std::vector< ELEMENT const * > &result) const
second_as<> second
Type of time stored in seconds, in double precision.
double sampling_rate(DetectorClocksData const &data)
Returns the period of the TPC readout electronics clock.
Collection of sim::SimPhotons, indexed by channel number.
double GeVToElectrons() const
static sim::SimPhotonsCollection GetSimPhotonsCollection(const art::Event &evt, std::string moduleLabel)