15 #include "art_root_io/TFileDirectory.h" 16 #include "art_root_io/TFileService.h" 22 #include "canvas/Persistency/Common/FindManyP.h" 57 fMinSP(pset.get<
unsigned short> (
"MinSP")),
83 std::vector< art::Ptr< recob::SpacePoint > > splist;
87 unsigned short nsp = splist.size();
91 std::vector<std::vector<art::Ptr<recob::Hit>>> sp2Hit(nsp);
92 for (
size_t spIdx = 0; spIdx < sp2Hit.size(); ++spIdx) {
93 sp2Hit[spIdx] = fmp.at(spIdx);
97 std::unique_ptr< std::vector<cvn::SparsePixelMap> >
98 pmCol(
new std::vector<cvn::SparsePixelMap>);
103 pmCol->push_back(map);
104 mf::LogInfo(
"CVNSparseMapper3D") <<
"Created sparse pixel map from " 105 << nsp <<
" spacepoints and " << map.
GetNPixels(0) <<
" hits.";
Handle< PROD > getHandle(SelectorBase const &) const
MaybeLogger_< ELseverityLevel::ELsev_info, false > LogInfo
unsigned short fMinSP
Minimum number of spacepoints to be converted to pixel map.
EDProducer(fhicl::ParameterSet const &pset)
Utility class for truth labels.
CVNSparseMapper3D(fhicl::ParameterSet const &pset)
#define DEFINE_ART_MODULE(klass)
std::vector< unsigned int > GetNPixels() const
ProductID put(std::unique_ptr< PROD > &&edp, std::string const &instance={})
PixelMapProducer for CVN.
PixelMapProducer fProducer
PixelMapProducer does the heavy lifting.
Sparse pixel map for CVN.
void fill_ptr_vector(std::vector< Ptr< T >> &ptrs, H const &h)
SparsePixelMap CreateSparseMap3D(detinfo::DetectorClocksData const &clockData, std::vector< art::Ptr< recob::SpacePoint > > &sp, std::vector< std::vector< art::Ptr< recob::Hit >>> &hit)
Producer algorithm for PixelMap, input to CVN neural net.
void produce(art::Event &evt)
std::string fPixelMapLabel
Instance label for spacepoint pixelmaps.
std::string fSPModuleLabel
Module label for reconstructed spacepoints.