44 cout <<
"[DTRecSegment2DProducer] Constructor called" << endl;
46 produces<DTRecSegment2DCollection>();
49 string theAlgoName = pset.
getParameter<
string>(
"Reco2DAlgoName");
50 if(
debug)
cout <<
"the Reco2D AlgoName is " << theAlgoName << endl;
58 cout <<
"[DTRecSegment2DProducer] Destructor called" << endl;
66 cout <<
"[DTRecSegment2DProducer] produce called" << endl;
71 theAlgo->setES(setup);
75 event.getByToken(recHits1DToken_, allHits);
78 auto segments = std::make_unique<DTRecSegment2DCollection>();
81 DTRecHitCollection::id_iterator dtLayerIt;
83 for (dtLayerIt = allHits->id_begin(); dtLayerIt != allHits->id_end(); ++dtLayerIt){
87 if (SLId==oldSlId)
continue;
90 if(
debug)
cout <<
"Reconstructing the 2D segments in "<< SLId << endl;
99 vector<DTRecHit1DPair> pairs(range.first,range.second);
101 if(
debug)
cout <<
"Number of 1D-RecHit pairs " << pairs.size() << endl;
103 if(
debug)
cout <<
"Start the 2D-segments Reco "<< endl;
105 if(
debug)
cout <<
"Number of Reconstructed segments: " << segs.
size() << endl;
107 if (segs.
size() > 0 )
108 segments->put(SLId, segs.
begin(),segs.
end());
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
std::pair< const_iterator, const_iterator > range
iterator range
static std::pair< DTLayerId, DTSuperLayerIdComparator > layersBySuperLayer(DTSuperLayerId slId)
Access by SL objects written into a RangeMap by layer.
def setup(process, global_tag, zero_tesla=False)
DTSuperLayerId superlayerId() const
Return the corresponding SuperLayerId.
const DTSuperLayer * superLayer(DTSuperLayerId id) const
Return a DTSuperLayer given its id.
virtual ~DTRecSegment2DProducer()
Destructor.
DTRecSegment2DProducer(const edm::ParameterSet &)
Constructor.
virtual void produce(edm::Event &event, const edm::EventSetup &setup)
The method which produces the 2D-segments.
T get(const Candidate &c)