35 #include "Utilities/AssociationUtil.h" 99 std::vector<art::Ptr<rb::CellHit > > hitlist;
100 for(
unsigned int i = 0;
i < hitcol->size(); ++
i){
102 hitlist.push_back(hit);
108 std::vector< rb::Cluster > oldSlices = *oldSlicesHandle;
112 std::vector< rb::Cluster > newSlices = *newSlicesHandle;
115 assert(newSlices.size() == oldSlices.size());
117 for(
size_t iSlc = 0; iSlc < oldSlices.size(); ++iSlc){
118 if(!newSlices[iSlc].IsNoise())
120 assert(newSlices[iSlc].NCell() == oldSlices[iSlc].NCell());
122 for(
size_t iHit = 0; iHit < oldSlices[iSlc].NCell(); ++iHit){
123 assert(*oldSlices[iSlc].Cell(iHit) == *newSlices[iSlc].Cell(iHit));
134 for(
size_t i = 0;
i< hitlist.size(); ++
i)
136 for(
size_t j = 0;
j< hitlist.size(); ++
j)
139 assert(!(*(hitlist[
i]) == *(hitlist[
j])) &&
" CalHits are not unique!");
145 for (
auto it = newSlices.begin();
it != newSlices.end(); ++
it)
149 for(
size_t i = 0;
i < cells.
size(); ++
i)
151 for(
size_t j = 0;
j < cells.
size(); ++
j)
154 if(*(cells[
i]) == *(cells[
j]))
156 std::cout << i <<
" " << cells[
i]->Cell() <<
" " << cells[
i]->Plane() <<
" " <<
157 cells[
i]->PE() <<
" " << cells[
i]->TDC() <<
std::endl;
159 std::cout <<
j <<
" " << cells[
j]->Cell() <<
" " << cells[
j]->Plane() <<
" " <<
160 cells[
j]->PE() <<
" " << cells[
j]->TDC() <<
std::endl;
163 assert(!(*(cells[i]) == *(cells[
j])) &&
" Cells are not unique");
DEFINE_ART_MODULE(TestTMapFile)
T get(std::string const &key) const
EDAnalyzer(Table< Config > const &config)
std::string fCellHitInput
std::string fOldSlicerLabel
bool getByLabel(std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
assert(nhit_max >=nhit_nbins)
void analyze(const art::Event &evt)
Class to help Slicer4D manage the collection of hits.
void reconfigure(const fhicl::ParameterSet &pset)
IdenticalSlicerAna(fhicl::ParameterSet const &pset)
std::string fNewSlicerLabel