17 LogDebug(
"ME0SegmentBuilder")<<
"ME0SegmentBuilder algorithm name: " << algoName;
32 LogDebug(
"ME0SegmentBuilder")<<
"Total number of rechits in this event: " << recHits->size();
38 std::map<uint32_t, std::vector<ME0RecHit*> > ensembleRH;
47 ME0DetId id(it2->me0Id().region(),1,it2->me0Id().chamber(),it2->me0Id().roll());
48 std::vector<ME0RecHit* >
pp = ensembleRH[
id.rawId()];
49 pp.push_back(it2->clone());
50 ensembleRH[
id.rawId()]=
pp;
53 for(
auto enIt=ensembleRH.begin(); enIt != ensembleRH.end(); ++enIt) {
56 std::map<uint32_t,const ME0EtaPartition* > ens;
60 for(
auto rechit = enIt->second.begin(); rechit != enIt->second.end(); ++rechit) {
61 me0RecHits.push_back(*rechit);
69 std::vector<ME0Segment> segv =
algo->
run(ensemble, me0RecHits);
71 LogDebug(
"ME0SegmentBuilder") <<
"found " << segv.size() <<
" segments in chamber " << mid;
74 oc.put(mid, segv.begin(), segv.end());
T getParameter(std::string const &) const
ME0SegmentAlgorithm * algo
virtual std::vector< ME0Segment > run(const ME0Ensemble &ensemble, const std::vector< const ME0RecHit * > &rechits)=0
std::pair< const ME0EtaPartition *, std::map< uint32_t, const ME0EtaPartition * > > ME0Ensemble
ME0SegmentBuilder(const edm::ParameterSet &)
const ME0EtaPartition * etaPartition(ME0DetId id) const
Return a etaPartition given its id.
void setGeometry(const ME0Geometry *g)
void build(const ME0RecHitCollection *rechits, ME0SegmentCollection &oc)
~ME0SegmentBuilder()
Destructor.
const ME0Geometry * geom_
T get(const Candidate &c)