57 _inputexist(1) , _configid(0) , _geomid(0) , _t0id(0) , _ttrigid(0) {
65 std::cout <<
"**** Initialization of DTTrigger ****" << std::endl;
67 std::cout <<
"DTTrig::DTTrig creating synchronizer" << std::endl;
92 for(
int iwh=-2;iwh<=2;iwh++){
93 for(
int ise=1;ise<=12;ise++){
95 std::cout <<
"calling sectcollid wh sc " << iwh <<
" " << ise << std::endl;}
99 std::cout <<
"DTTrig::createTUs: Sector Collector unit already exists"<<std::endl;
117 std::cout <<
" DTTrig::createTUs new SC sc = " << sc
118 <<
" at scid.sector() " << scid.
sector()
119 <<
" at scid.wheel() " << scid.
wheel()
128 for (std::vector<DTChamber*>::const_iterator ich=pDD->chambers().begin(); ich!=pDD->chambers().end();ich++){
133 if ( it !=
_cache.end()) {
134 std::cout <<
"DTTrig::init: Trigger unit already exists" << std::endl;
156 else if(chid.
sector()==14) {
167 std::cout <<
"DTTrig::init: adding TU in SC << "
168 <<
" sector = " << scid.
sector()
169 <<
" wheel = " << scid.
wheel()
174 std::cout <<
"DTTrig::createTUs: Trigger Unit not in the map: ";
195 <<
"DTTrig::triggerReco DTDigiCollection with input tag " <<
_digitag
196 <<
"requested in configuration, but not found in the event." << std::endl;
204 for (detUnitIt=dtDigis->begin();
205 detUnitIt!=dtDigis->end();
207 const DTLayerId& layId = (*detUnitIt).first;
212 digiMap[chambId].put(range,layId);
260 if (dmit !=digiMap.end()){
276 bool mustreco =
false;
277 for (
int i=1;
i<5;
i++) {
283 for (
int i=1;
i<4;
i++) {
311 std::cout <<
"DTTrig::updateES updating DTTPG configuration" << std::endl;
328 std::cout <<
"DTTrig::updateES updating muon geometry" << std::endl;
333 (*it).second->setGeom(geomHandle->chamber((*it).second->statId()));
343 std::cout <<
"DTTrig::updateES updating synchronizer" << std::endl;
383 if ( it ==
_cache.end()) {
384 std::cout <<
"DTTrig::trigUnit: Trigger Unit not in the map: ";
399 std::cout <<
"DTTrig::SCUnit: Trigger Unit not in the map: ";
497 if(unit->
nSegmPh(step)<1)
return 0;
504 if(unit->
nSegmPh(step)<2)
return 0;
529 if(unit->
nSegmTh(step)<1)
return 0;
569 std::vector<DTBtiTrigData>
572 std::vector<DTBtiTrigData> trigs;
576 std::vector<DTBtiTrigData>::const_iterator
p;
577 std::vector<DTBtiTrigData>::const_iterator peb=tu->
BtiTrigs()->
end();
585 std::vector<DTTracoTrigData>
587 std::vector<DTTracoTrigData> trigs;
592 std::vector<DTTracoTrigData>::const_iterator
p;
593 std::vector<DTTracoTrigData>::const_iterator peb=tu->
TracoTrigs()->
end();
601 std::vector<DTChambPhSegm>
604 std::vector<DTChambPhSegm> trigs;
608 std::vector<DTChambPhSegm>::const_iterator
p;
609 std::vector<DTChambPhSegm>::const_iterator peb=tu->
TSPhTrigs()->
end();
617 std::vector<DTChambThSegm>
620 std::vector<DTChambThSegm> trigs;
624 std::vector<DTChambThSegm>::const_iterator
p;
625 std::vector<DTChambThSegm>::const_iterator peb=tu->
TSThTrigs()->
end();
633 std::vector<DTSectCollPhSegm>
636 std::vector<DTSectCollPhSegm> trigs;
651 std::vector<DTSectCollPhSegm>::const_iterator
p;
652 std::vector<DTSectCollPhSegm>::const_iterator peb=sc->
endPh();
653 for(p=sc->
beginPh();p!=peb;p++){
662 std::vector<DTSectCollThSegm>
665 std::vector<DTSectCollThSegm> trigs;
669 std::vector<DTSectCollThSegm>::const_iterator
p;
670 std::vector<DTSectCollThSegm>::const_iterator peb=sc->
endTh();
671 for(p=sc->
beginTh();p!=peb;p++){
virtual void reconstruct()
Load Trigger Units triggers and run Sector Collector algorithm.
int sizePh()
Return Phi cache size.
virtual void reconstruct(const DTDigiCollection dtDigis)
void clearCache()
Clear all traco stuff (cache & map)
T getParameter(std::string const &) const
unsigned long long cacheIdentifier() const
T getUntrackedParameter(std::string const &, T const &) const
const DTChambThSegm * thetaSegment(int step, int n)
Return output segments, theta view.
SCcontainer::iterator SC_iterator
void dumpLUTParam(DTChamberId &chambid) const
SV 091111 Dump luts string commands from configuration parameters.
unsigned long long _ttrigid
std::vector< DTSectCollPhSegm >::const_iterator endPh()
Return iterator to the end of Phi cache.
DTSectColl * SCUnit(DTSectCollId scid) const
Return a SC unit - Muon numbering - const version.
DTChamberId chamberId() const
Return the corresponding ChamberId.
DTTSTheta * TSThTrigs() const
Return the chamber Trigger Server (Theta)
void clearCache()
Clear all BTI stuff (map & cache)
DTChambPhSegm * chPhiSegm2(DTChamberId sid, int step)
Return the second phi track segment in req. chamber/step.
int sizeTh()
Return Theta cache size.
int nSegmTh(int step)
Return number of DTSectCollTheta segments (SC step)
DTTSPhi * TSPhTrigs() const
Return the chamber Trigger Server (Phi)
DTSuperLayerId superlayerId() const
Return the corresponding SuperLayerId.
TUcontainer::iterator TU_iterator
DTSectCollPhSegm * chSectCollPhSegm1(DTSectColl *unit, int step)
Return the first phi track segment in req. chamber/step [SC step].
DTChambPhSegm * chPhiSegm1(DTChamberId sid, int step)
Return the first phi track segment in req. chamber/step.
unsigned long long _geomid
virtual void setES(const edm::EventSetup &setup)=0
Pass the Event Setup to the synchronization module at each event.
std::vector< DTSectCollPhSegm > SCPhTrigs()
Return a copy of all the Sector Collector (Phi) triggers.
void dumpLUT(short int btic) const
Dump the Lut file.
DTBtiCard * BtiTrigs() const
Return container of BTI triggers.
int nSegmPh(int step)
Return number of DTSectCollPhi segments (SC step)
void updateES(const edm::EventSetup &iSetup)
update the eventsetup info
DTChamberId id() const
Return the DTChamberId of this chamber.
void triggerReco(const edm::Event &iEvent, const edm::EventSetup &iSetup)
Run the whole trigger reconstruction chain.
DTSCTrigUnit * constTrigUnit(DTChamberId sid) const
Return a trigger unit - Muon numbering - const version.
void dumpGeom()
Dump the geometry.
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
DTSectCollPhSegm * chSectCollPhSegm2(DTSectColl *unit, int step)
Return the second phi track segment in req. chamber/step [SC step].
DTDigiMap::iterator DTDigiMap_iterator
TUcontainer::const_iterator TU_const_iterator
std::vector< DTChambThSegm > TSThTrigs()
Return a copy of all the Trigger Server (Theta) triggers.
void addTU(DTSCTrigUnit *tru)
Add a Trigger Unit to the Sector Collector.
std::vector< DTSectCollThSegm >::const_iterator beginTh()
Return iterator to the begni of Theta cache.
void dumpLuts(short int lut_btic, const DTConfigManager *conf)
Dump the LUT files.
DTSCTrigUnit * trigUnit(DTChamberId sid)
Return a trigger unit - Muon numbering.
std::vector< DTTracoTrigData > TracoTrigs()
Return a copy of all the TRACO triggers.
DTTracoCard * TracoTrigs() const
Return container of TRACO triggers.
void reconstruct()
Load BTIs triggers and run TSTheta algoritm.
const DTSectCollThSegm * SectCollThSegment(int step)
Return requested Sector Collector Theta Segment.
T const * product() const
std::vector< DTSectCollThSegm >::const_iterator endTh()
Return iterator to the end of Theta cache.
const_iterator begin() const
Get first cache element.
DTChambThSegm * chThetaSegm(DTChamberId sid, int step)
Return the theta candidates in req. chamber/step.
void clearCache()
Local position in chamber of a trigger-data object.
std::map< DTChamberId, DTDigiCollection, std::less< DTChamberId > > DTDigiMap
DTTTrigBaseSync * _digi_sync
const DTConfigManager * _conf_manager
DTChamberId statId() const
Identifier of the associated chamber.
std::vector< DTSectCollPhSegm >::const_iterator beginPh()
Return iterator to the beghin of Phi cache.
const DTSectCollPhSegm * SectCollPhSegment(int step, unsigned n)
Return requested Sector Collector Phi Segment 1st/2nd.
virtual void reconstruct()
Load TRACO triggers and run TSPhi algorithm.
DTSectCollThSegm * chSectCollThSegm(DTSectColl *unit, int step)
Return the theta track segment in req. chamber/step [SC step].
virtual void reconstruct()
Load BTIs triggers and run TRACOs algorithm.
std::pair< const_iterator, const_iterator > Range
const DTChambPhSegm * phiSegment(int step, int n)
Return output segments, phi view.
int nPhiSegm(int step)
Number of Phi segments for a given step.
int station() const
Return the station number.
int wheel() const
Return the wheel number.
const_iterator end() const
Get last cache element.
void createTUs(const edm::EventSetup &iSetup)
Create the trigger units and store them in the cache.
void clearCache()
Clear cache vector.
DTTSPhi * getTSPhi(int istat) const
Return TSPhi.
T get(const Candidate &c)
unsigned long long _configid
SCcontainer::const_iterator SC_const_iterator
int size() const
Get cache vector's size.
std::vector< DTBtiTrigData > BtiTrigs()
Return a copy of all the BTI triggers.
DTTrig(const edm::ParameterSet ¶ms)
Constructors.
std::vector< DTSectCollThSegm > SCThTrigs()
Return a copy of all the Sector Collector (Theta) triggers.
DTTSTheta * getTSTheta(int istat) const
Return TSTheta.
std::vector< DTChambPhSegm > TSPhTrigs()
Return a copy of all the Trigger Server (Phi) triggers.
int nThetaSegm(int step)
Number of theta segments for a given step.
void clear()
Clear the trigger units cache.