CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
DTTracoCard Class Reference

#include <DTTracoCard.h>

Inheritance diagram for DTTracoCard:
DTCache< T, Coll > DTGeomSupplier

Public Member Functions

void clearCache ()
 Clear all traco stuff (cache & map) More...
 
const DTConfigLUTsconfig_luts () const
 Return LUTS config for this chamber (=minicrate) More...
 
bool debug ()
 Return TU debug flag. More...
 
 DTTracoCard (DTTrigGeom *, DTBtiCard *, DTTSTheta *)
 Constructor. More...
 
DTTracoChipgetTRACO (const DTTracoId &tracoid) const
 Returns the required DTTracoChip. Return 0 if it doesn't exist. More...
 
DTTracoChipgetTRACO (int n) const
 Returns the required DTTracoChip. Return 0 if it doesn't exist. More...
 
LocalVector localDirection (const DTTrigData *) const override
 NEWGEO Local direction in chamber of a trigger-data object. More...
 
LocalPoint localPosition (const DTTrigData *) const override
 NEWGEO Local position in chamber of a trigger-data object. More...
 
bool lutFromDBFlag ()
 Return lut computation option (DB/geometry) More...
 
void reconstruct () override
 Load BTIs triggers and run TRACOs algorithm. More...
 
void setConfig (const DTConfigManager *conf)
 Set configuration. More...
 
DTTracoTrigstoreTrigger (DTTracoTrigData)
 
std::vector< DTTracoChip * > tracoList ()
 Returns the active TRACO list. More...
 
DTTSThetaTSTh () const
 Return TSTheta. More...
 
bool useAcceptParamFlag ()
 Return acceptance flag. More...
 
 ~DTTracoCard () override
 Destructor. More...
 
- Public Member Functions inherited from DTCache< T, Coll >
const_iterator begin () const
 Get first cache element. More...
 
void clearCache ()
 Clear cache vector. More...
 
 DTCache ()
 Constructor. More...
 
const_iterator end () const
 Get last cache element. More...
 
int size () const
 Get cache vector's size. More...
 
virtual ~DTCache ()
 Destructor. More...
 
- Public Member Functions inherited from DTGeomSupplier
DTChamberId ChamberId () const
 Identifier of the associated chamber. More...
 
GlobalVector CMSDirection (const DTTrigData *trig) const
 CMS direction in chamber of a trigger -data object. More...
 
GlobalPoint CMSPosition (const DTTrigData *trig) const
 CMS position in chamber of a trigger-data object. More...
 
 DTGeomSupplier (DTTrigGeom *geom)
 Constructor. More...
 
DTTrigGeomgeom () const
 Associated geometry. More...
 
virtual void print (const DTTrigData *trig) const
 Print a trigger-data object with also local and global position/direction. More...
 
int sector () const
 Return sector number. More...
 
const DTChamberstat () const
 Associated chamber. More...
 
int station () const
 Return station number. More...
 
int wheel () const
 Return wheel number. More...
 
virtual ~DTGeomSupplier ()
 Destructor. More...
 

Private Member Functions

DTTracoChipactiveGetTRACO (const DTTracoId &tracoid)
 Returns the required DTTracoChip. Create it if it doesn't exist. More...
 
DTTracoChipactiveGetTRACO (int)
 Returns the required DTTracoChip. Create it if it doesn't exist. More...
 
DTConfigTracoconfig_traco (const DTTracoId &tracoid) const
 Return single TRACO config. More...
 
void loadTRACO ()
 store BTI triggers in TRACO's More...
 
void localClear ()
 clear the TRACO map More...
 
void runTRACO ()
 run TRACO algorithm More...
 

Private Attributes

DTBtiCard_bticard
 
const DTConfigLUTs_conf_luts
 
ConfTracoMap _conf_traco_map
 
bool _debug
 
bool _flag_acc
 
bool _lut_from_db
 
TRACOContainer _tracomap
 
DTTSTheta_tstheta
 

Additional Inherited Members

- Public Types inherited from DTCache< T, Coll >
typedef my_collection::const_iterator const_iterator
 
typedef my_collection::iterator iterator
 
typedef Coll my_collection
 
typedef T my_type
 
- Protected Attributes inherited from DTCache< T, Coll >
my_collection _cache
 
- Protected Attributes inherited from DTGeomSupplier
DTTrigGeom_geom
 

Detailed Description

Contains active DTTracoChips

Author
C. Grandi, S. Vanini

Modifications: III/07 : SV configuration with DTConfigManager

Definition at line 58 of file DTTracoCard.h.

Constructor & Destructor Documentation

◆ DTTracoCard()

DTTracoCard::DTTracoCard ( DTTrigGeom geo,
DTBtiCard bticard,
DTTSTheta tstheta 
)

Constructor.

Definition at line 48 of file DTTracoCard.cc.

49  : DTGeomSupplier(geo), _bticard(bticard), _tstheta(tstheta) {}

◆ ~DTTracoCard()

DTTracoCard::~DTTracoCard ( )
override

Destructor.

Definition at line 55 of file DTTracoCard.cc.

55 { localClear(); }

References localClear().

Member Function Documentation

◆ activeGetTRACO() [1/2]

DTTracoChip* DTTracoCard::activeGetTRACO ( const DTTracoId tracoid)
inlineprivate

Returns the required DTTracoChip. Create it if it doesn't exist.

Definition at line 127 of file DTTracoCard.h.

127 { return activeGetTRACO(tracoid.traco()); }

References activeGetTRACO(), and DTTracoId::traco().

Referenced by activeGetTRACO().

◆ activeGetTRACO() [2/2]

DTTracoChip * DTTracoCard::activeGetTRACO ( int  n)
private

Returns the required DTTracoChip. Create it if it doesn't exist.

Definition at line 270 of file DTTracoCard.cc.

270  {
271  // the traco identifier
272  DTChamberId sid = geom()->statId();
273  DTTracoId _id = DTTracoId(sid, n);
274 
275  DTTracoChip *traco = nullptr;
276  TRACO_iter ptraco = _tracomap.find(n);
277  if (ptraco != _tracomap.end()) {
278  traco = (*ptraco).second;
279  } else {
280  traco = new DTTracoChip(this, n, config_traco(_id));
281  _tracomap[n] = traco;
282  }
283  return traco;
284 }

References _tracomap, config_traco(), DTGeomSupplier::geom(), dqmiodumpmetadata::n, and DTTrigGeom::statId().

Referenced by loadTRACO(), and storeTrigger().

◆ clearCache()

void DTTracoCard::clearCache ( )

Clear all traco stuff (cache & map)

Definition at line 61 of file DTTracoCard.cc.

61  {
63  localClear();
64 }

References DTCache< T, Coll >::clearCache(), and localClear().

Referenced by reconstruct(), and DTTrig::triggerReco().

◆ config_luts()

const DTConfigLUTs* DTTracoCard::config_luts ( ) const
inline

Return LUTS config for this chamber (=minicrate)

Definition at line 108 of file DTTracoCard.h.

108 { return _conf_luts; }

References _conf_luts.

Referenced by DTTracoChip::DTTracoChip().

◆ config_traco()

DTConfigTraco * DTTracoCard::config_traco ( const DTTracoId tracoid) const
private

Return single TRACO config.

Definition at line 436 of file DTTracoCard.cc.

436  {
437  // loop on map to find traco
438  ConfTracoMap::const_iterator titer = _conf_traco_map.find(tracoid);
439  if (titer == _conf_traco_map.end()) {
440  std::cout << "DTTracoCard::config_traco : TRACO (" << tracoid.wheel() << "," << tracoid.sector() << ","
441  << tracoid.station() << "," << tracoid.traco() << ") not found, return 0" << std::endl;
442  return nullptr;
443  }
444 
445  return const_cast<DTConfigTraco *>(&(*titer).second);
446 }

References _conf_traco_map, gather_cfg::cout, DTTracoId::sector(), DTTracoId::station(), DTTracoId::traco(), and DTTracoId::wheel().

Referenced by activeGetTRACO(), localDirection(), and localPosition().

◆ debug()

bool DTTracoCard::debug ( )
inline

Return TU debug flag.

Definition at line 74 of file DTTracoCard.h.

74 { return _debug; }

References _debug.

Referenced by loadTRACO(), localDirection(), and runTRACO().

◆ getTRACO() [1/2]

DTTracoChip* DTTracoCard::getTRACO ( const DTTracoId tracoid) const
inline

Returns the required DTTracoChip. Return 0 if it doesn't exist.

Definition at line 83 of file DTTracoCard.h.

83 { return getTRACO(tracoid.traco()); }

References getTRACO(), and DTTracoId::traco().

Referenced by getTRACO().

◆ getTRACO() [2/2]

DTTracoChip * DTTracoCard::getTRACO ( int  n) const

Returns the required DTTracoChip. Return 0 if it doesn't exist.

Definition at line 286 of file DTTracoCard.cc.

286  {
287  TRACO_const_iter ptraco = _tracomap.find(n);
288  if (ptraco == _tracomap.end())
289  return nullptr;
290  return (*ptraco).second;
291 }

References _tracomap, and dqmiodumpmetadata::n.

Referenced by DTTracoChip::setFlag().

◆ loadTRACO()

void DTTracoCard::loadTRACO ( )
private

store BTI triggers in TRACO's

Definition at line 92 of file DTTracoCard.cc.

92  {
93  localClear();
94 
95  if (debug()) {
96  std::cout << "DTTracoCard::loadTRACO called for wheel=" << wheel();
97  std::cout << ", station=" << station();
98  std::cout << ", sector=" << sector() << std::endl;
99  }
100 
101  int maxtc = int(ceil(float(geom()->nCell(1)) / float(DTConfig::NBTITC)));
102 
103  // loop on all BTI triggers
104  std::vector<DTBtiTrigData>::const_iterator p;
105  std::vector<DTBtiTrigData>::const_iterator pend = _bticard->end();
106  for (p = _bticard->begin(); p != pend; p++) {
107  if (debug()) {
108  std::cout << "Found bti trigger: ";
109  (*p).print();
110  }
111 
112  // BTI data
113  int nbti = (*p).btiNumber();
114  int nsl = (*p).btiSL();
115  int step = (*p).step();
116  int K = (*p).K();
117  DTBtiId id_bti = (*p).parentId();
118 
119  DTConfigBti *conf_bti = _bticard->config_bti(id_bti);
120  int LL = conf_bti->LL();
121  int LH = conf_bti->LH();
122  int CL = conf_bti->CL();
123  int CH = conf_bti->CH();
124  int RL = conf_bti->RL();
125  int RH = conf_bti->RH();
126  /*
127  if(debug())
128  std::cout << "Bti trigger acceptances: \n"
129  << " LL " << LL << ", LH " << LH << "\n"
130  << " CL " << CL << ", CH " << CH << "\n"
131  << " RL " << RL << ", RH " << RH << std::endl;
132  */
133  // assign BTI to TRACO (central TRACO for sl=3); ntc=1,2...maxtc
134  int ntc = static_cast<int>((nbti - 1) / DTConfig::NBTITC) + 1;
135  if (ntc < 1 || ntc > maxtc)
136  continue;
137 
138  if (debug())
139  std::cout << "Bti trigger assigned to traco " << ntc << " (maxtc " << maxtc << ")" << std::endl;
140 
141  // TRACO information
142  DTTracoId tracoid = DTTracoId(wheel(), station(), sector(), ntc);
143 
144  // position inside TRACO:
145  int pos = nbti - (ntc - 1) * DTConfig::NBTITC;
146 
147  // store trigger in TRACO. Create TRACO if it doesn't exist
148  // SV tb2003 : check if traco is connected!
149 
150  // SV 091103 : add bti trigger filtering in acceptance windows
151  // if flag is useAcceptParam() = true
152 
153  // Load master TRACO plane
154  if (nsl == 1) {
155  if (!_flag_acc || (K >= CL && K <= CH))
156  activeGetTRACO(ntc)->add_btiT(step, pos, &(*p));
157  else if (debug())
158  std::cout << "ATTENTION: in TRACO n. " << ntc << " bti pos " << pos << " trigger K= " << K
159  << " outside acceptance " << CL << "<K<" << CH << std::endl;
160  }
161 
162  // Load slave TRACO plane
163  if (nsl == 3) {
164  // 3 TRACO's
165  // for(int tci=-1;tci<=1;tci++) {
166  // if( (ntc+tci)>0 && (ntc+tci)<=maxtc )
167  // activeGetTRACO(ntc+tci)->add_btiT( step, pos+8-4*tci, &(*p) );
168  // else{
169  // if(debug())
170  // std::cout << "ATTENTION: traco " << ntc+tci << " is disconnected!"
171  // << std::endl;
172  // }
173 
174  // Left Traco
175  if ((ntc - 1) > 0 && (ntc - 1) <= maxtc) {
176  if (!_flag_acc || (K >= LL && K <= LH)) {
177  activeGetTRACO(ntc - 1)->add_btiT(step, pos + 8 - 4 * (-1), &(*p));
178  } else {
179  if (debug()) {
180  std::cout << "ATTENTION: in TRACO n. " << ntc - 1 << " bti pos " << pos + 8 - 4 * (-1)
181  << " trigger K= " << K << " outside acceptance " << LL << "<K<" << LH << std::endl;
182  }
183  }
184  }
185 
186  // Central Traco
187  if ((ntc) > 0 && (ntc) <= maxtc) {
188  if (!_flag_acc || (K >= CL && K <= CH)) {
189  activeGetTRACO(ntc)->add_btiT(step, pos + 8 - 4 * (0), &(*p));
190  } else {
191  if (debug())
192  std::cout << "ATTENTION: in TRACO n. " << ntc << " bti pos " << pos + 8 - 4 * (0) << " trigger K= " << K
193  << " outside acceptance " << CL << "<K<" << CH << std::endl;
194  }
195  }
196 
197  // Right Traco
198  if ((ntc + 1) > 0 && (ntc + 1) <= maxtc) {
199  if (!_flag_acc || (K >= RL && K <= RH)) {
200  activeGetTRACO(ntc + 1)->add_btiT(step, pos + 8 - 4 * (+1), &(*p));
201  } else {
202  if (debug())
203  std::cout << "ATTENTION: in TRACO n. " << ntc + 1 << " bti pos " << pos + 8 - 4 * (+1)
204  << " trigger K= " << K << " outside acceptance " << RL << "<K<" << RH << std::endl;
205  }
206  }
207  }
208 
209  // Filter Theta BTIs -> this is done in DTBtiChip
210 
211  } // end loop on bti trigs
212 }

References _bticard, _flag_acc, activeGetTRACO(), DTTracoChip::add_btiT(), DTCache< T, Coll >::begin(), reco::ceil(), DTConfigBti::CH(), L1DTConfigFromDB_cfi::CH, DTConfigBti::CL(), L1DTConfigFromDB_cfi::CL, DTBtiCard::config_bti(), gather_cfg::cout, debug(), DTCache< T, Coll >::end(), DTGeomSupplier::geom(), createfilelist::int, DTConfigBti::LH(), L1DTConfigFromDB_cfi::LH, DTConfigBti::LL(), L1DTConfigFromDB_cfi::LL, localClear(), DTConfig::NBTITC, AlCaHLTBitMon_ParallelJobs::p, DTConfigBti::RH(), L1DTConfigFromDB_cfi::RH, DTConfigBti::RL(), L1DTConfigFromDB_cfi::RL, DTGeomSupplier::sector(), DTGeomSupplier::station(), and DTGeomSupplier::wheel().

Referenced by reconstruct().

◆ localClear()

void DTTracoCard::localClear ( )
private

clear the TRACO map

Definition at line 84 of file DTTracoCard.cc.

84  {
85  // Clear the map
86  for (TRACO_iter p = _tracomap.begin(); p != _tracomap.end(); p++) {
87  delete (*p).second;
88  }
89  _tracomap.clear();
90 }

References _tracomap, and AlCaHLTBitMon_ParallelJobs::p.

Referenced by clearCache(), loadTRACO(), and ~DTTracoCard().

◆ localDirection()

LocalVector DTTracoCard::localDirection ( const DTTrigData tr) const
overridevirtual

NEWGEO Local direction in chamber of a trigger-data object.

Implements DTGeomSupplier.

Definition at line 403 of file DTTracoCard.cc.

403  {
404  // NEWGEO
405  DTTracoTrigData *trig = dynamic_cast<DTTracoTrigData *>(const_cast<DTTrigData *>(tr));
406  if (!trig) {
407  std::cout << "DTtracoCard::localDirection called with wrong argument!" << std::endl;
408  return LocalVector(0, 0, 0);
409  }
410 
411  // FE position
412  // int FE = geom()->posFE(3);
413 
414  float psi =
415  atan((float)(trig->K()) * geom()->cellPitch() / (geom()->distSL() * config_traco(trig->parentId())->BTIC()));
416 
417  if (config_traco(trig->parentId())->debug() == 4)
418  std::cout << "K " << trig->K() << " == psi " << psi << " in FE frame " << std::endl;
419 
420  // (xd,yd,zd) in chamber frame
421  float xd = -sin(psi);
422  float yd = 0;
423  float zd = -cos(psi);
424 
425  // 10/07/06 Not needed anymore (chages in geometry)
426  // if(FE==1){//FE in negative y
427  // xd = - xd;
428  //}
429 
430  if (config_traco(trig->parentId())->debug() == 4)
431  std::cout << "Direction in chamber frame is (" << xd << "," << yd << "," << zd << ")" << std::endl;
432 
433  return LocalVector(xd, yd, zd);
434 }

References L1DTConfigFromDB_cfi::BTIC, DTTrigGeom::cellPitch(), config_traco(), funct::cos(), gather_cfg::cout, debug(), DTTrigGeom::distSL(), DTGeomSupplier::geom(), funct::sin(), and ClusterTask_cfi::trig.

Referenced by DTTracoChip::calculateAngles(), and DTTSPhi::localDirection().

◆ localPosition()

LocalPoint DTTracoCard::localPosition ( const DTTrigData tr) const
overridevirtual

NEWGEO Local position in chamber of a trigger-data object.

Implements DTGeomSupplier.

Definition at line 351 of file DTTracoCard.cc.

351  {
352  // NEWGEO
353  DTTracoTrigData *trig = dynamic_cast<DTTracoTrigData *>(const_cast<DTTrigData *>(tr));
354  if (!trig) {
355  std::cout << "DTTracoCard::localPosition called with wrong argument!" << std::endl;
356  return LocalPoint(0, 0, 0);
357  }
358  float x = geom()->localPosition(trig->parentId()).x();
359  float y = geom()->localPosition(trig->parentId()).y();
360  float z = geom()->localPosition(trig->parentId()).z();
361 
362  float trig_pos = geom()->cellPitch() * ((float)trig->X() / (float)(config_traco(trig->parentId())->BTIC()));
363 
364  // 10/7/06 May be not needed anymore in new geometry
365  // if(geom()->posFE(1)==1)
366  // trig_pos = -trig_pos;
367 
368  x += trig_pos;
369 
370  // If not correlated get the position of the SL instead of the chamber center
371  // z axis toward vertex
372  if (trig->posIn() == 0) {
373  z -= 0.5 * geom()->distSL(); // no inner ==> only outer
374  } else if (trig->posOut() == 0) {
375  z += 0.5 * geom()->distSL(); // no outer ==> only inner
376  }
377  return LocalPoint(x, y, z);
378 }

References L1DTConfigFromDB_cfi::BTIC, DTTrigGeom::cellPitch(), config_traco(), gather_cfg::cout, DTTrigGeom::distSL(), dqmMemoryStats::float, DTGeomSupplier::geom(), DTTrigGeom::localPosition(), ClusterTask_cfi::trig, x, y, and z.

Referenced by DTTSPhi::localPosition().

◆ lutFromDBFlag()

bool DTTracoCard::lutFromDBFlag ( )
inline

Return lut computation option (DB/geometry)

Definition at line 114 of file DTTracoCard.h.

114 { return _lut_from_db; }

References _lut_from_db.

Referenced by DTTracoChip::calculateAngles(), DTTracoChip::DTTracoChip(), and DTTracoChip::~DTTracoChip().

◆ reconstruct()

void DTTracoCard::reconstruct ( )
inlineoverridevirtual

Load BTIs triggers and run TRACOs algorithm.

Reimplemented from DTCache< T, Coll >.

Definition at line 101 of file DTTracoCard.h.

101  {
102  clearCache();
103  loadTRACO();
104  runTRACO();
105  }

References clearCache(), loadTRACO(), and runTRACO().

Referenced by DTTrig::triggerReco().

◆ runTRACO()

void DTTracoCard::runTRACO ( )
private

run TRACO algorithm

Definition at line 214 of file DTTracoCard.cc.

214  {
215  if (debug()) {
216  std::cout << "DTTracoCard:runTRACO called for wheel=" << wheel();
217  std::cout << ", station=" << station();
218  std::cout << ", sector=" << sector();
219  std::cout << ", " << _tracomap.size() << " TRACOs with signal" << std::endl;
220  }
221 
222  // run TRACO algorithm on all non-empty TRACO
223  if (!_tracomap.empty()) {
224  if (debug()) {
225  std::cout << "====================================================" << std::endl;
226  std::cout << " TRACO triggers " << std::endl;
227  }
228 
229  TRACO_iter ptraco;
230  for (ptraco = _tracomap.begin(); ptraco != _tracomap.end(); ptraco++) {
231  DTTracoChip *traco = (*ptraco).second;
232  traco->run();
233  for (int step = DTConfig::NSTEPF; step <= DTConfig::NSTEPL; step++) {
234  if (traco->nTrig(step) > 0) {
235  _cache.push_back(traco->triggerData(step, 1));
236  /*
237  std::cout<<"first bti sl3:
238  "<<geom()->localPosition(DTBtiId(wheel(),station(),sector(),3,1))<<std::endl;
239  std::cout<<"traco pos: " <<
240  geom()->localPosition((traco->triggerData(step,1).parentId()))<<std::endl;
241  traco->triggerData(step,1).print();
242  std::cout<<"pos: " << localPosition(&(traco->triggerData(step,1))) <<
243  std::endl; std::cout<<"dir: " <<
244  localDirection(&(traco->triggerData(step,1))) << std::endl; std::cout
245  << std::endl;
246  */
247  }
248  // Store second track only if no first track at previous BX
249  if (traco->nTrig(step) > 1 && traco->useSecondTrack(step)) {
250  _cache.push_back(traco->triggerData(step, 2));
251  /*
252  std::cout<<"first bti sl3:
253  "<<geom()->localPosition(DTBtiId(wheel(),station(),sector(),3,1))<<std::endl;
254  std::cout<<"traco pos: " <<
255  geom()->localPosition((traco->triggerData(step,2).parentId()))<<std::endl;
256  traco->triggerData(step,2).print();
257  std::cout<<"pos: " << localPosition(&(traco->triggerData(step,2))) <<
258  std::endl; std::cout<<"dir: " <<
259  localDirection(&(traco->triggerData(step,2))) << std::endl; std::cout
260  << std::endl;
261  */
262  }
263  }
264  }
265  if (debug())
266  std::cout << "====================================================" << std::endl;
267  }
268 }

References DTCache< T, Coll >::_cache, _tracomap, gather_cfg::cout, debug(), DTConfig::NSTEPF, DTConfig::NSTEPL, DTTracoChip::nTrig(), DTTracoChip::run(), DTGeomSupplier::sector(), DTGeomSupplier::station(), DTTracoChip::triggerData(), DTTracoChip::useSecondTrack(), and DTGeomSupplier::wheel().

Referenced by reconstruct().

◆ setConfig()

void DTTracoCard::setConfig ( const DTConfigManager conf)

Set configuration.

Definition at line 66 of file DTTracoCard.cc.

66  {
67  // get traco configuration map
68  DTChamberId sid = ChamberId();
70  _debug = conf->getDTTPGDebug();
71 
72  // get bti acceptance flag
73  _flag_acc = conf->useAcceptParam();
74 
75  // get lut computation flag
76  _lut_from_db = conf->lutFromDB();
77 
78  // get lut configuration for this chamber
79  // 100511 SV only if luts are read from OMDS
80  if (_lut_from_db)
81  _conf_luts = conf->getDTConfigLUTs(sid);
82 }

References _conf_luts, _conf_traco_map, _debug, _flag_acc, _lut_from_db, DTGeomSupplier::ChamberId(), DTConfigManager::getDTConfigLUTs(), DTConfigManager::getDTConfigTracoMap(), DTConfigManager::getDTTPGDebug(), DTConfigManager::lutFromDB(), and DTConfigManager::useAcceptParam().

Referenced by DTSCTrigUnit::setConfig().

◆ storeTrigger()

DTTracoTrig * DTTracoCard::storeTrigger ( DTTracoTrigData  td)

Returns a DTTracoTrig corresponding to a DTTracoTrigData. Creates the corresponding TRACO chip if needed and stores the trigger

Definition at line 305 of file DTTracoCard.cc.

305  {
306  DTTracoId tracoid = td.parentId();
307  if (!(tracoid.wheel() == wheel() && tracoid.sector() == sector() && tracoid.station() == station()))
308  return nullptr;
309  std::cout << "DTTracoChip::trigger: trigger not belonging to this card! ";
310  std::cout << "card=(" << wheel() << "," << station() << "," << sector() << ") ";
311  std::cout << "trig=(" << tracoid.wheel() << "," << tracoid.station() << "," << tracoid.sector() << ")";
312  // get the appropriate Traco
313  DTTracoChip *traco = activeGetTRACO(tracoid.traco());
314  // create a new trigger in the Traco
315  DTTracoTrig *trig = new DTTracoTrig(traco, td);
316  // add the trigger to the Traco
317  traco->addTrig(td.step(), trig);
318  // return the trigger
319  return trig;
320 }

References activeGetTRACO(), DTTracoChip::addTrig(), gather_cfg::cout, DTTracoTrigData::parentId(), DTTracoId::sector(), DTGeomSupplier::sector(), DTTracoId::station(), DTGeomSupplier::station(), DTTracoTrigData::step(), DTTracoId::traco(), ClusterTask_cfi::trig, DTTracoId::wheel(), and DTGeomSupplier::wheel().

◆ tracoList()

std::vector< DTTracoChip * > DTTracoCard::tracoList ( )

Returns the active TRACO list.

Definition at line 293 of file DTTracoCard.cc.

293  {
294  std::vector<DTTracoChip *> blist;
295 
296  if (size() < 1)
297  return blist;
298 
299  for (TRACO_const_iter p = _tracomap.begin(); p != _tracomap.end(); p++) {
300  blist.push_back((*p).second);
301  }
302  return blist;
303 }

References _tracomap, AlCaHLTBitMon_ParallelJobs::p, and DTCache< T, Coll >::size().

◆ TSTh()

DTTSTheta* DTTracoCard::TSTh ( ) const
inline

Return TSTheta.

Definition at line 77 of file DTTracoCard.h.

77 { return _tstheta; }

References _tstheta.

Referenced by DTTracoChip::storeUncorr().

◆ useAcceptParamFlag()

bool DTTracoCard::useAcceptParamFlag ( )
inline

Return acceptance flag.

Definition at line 111 of file DTTracoCard.h.

111 { return _flag_acc; }

References _flag_acc.

Referenced by DTTracoChip::add_btiT().

Member Data Documentation

◆ _bticard

DTBtiCard* DTTracoCard::_bticard
private

Definition at line 136 of file DTTracoCard.h.

Referenced by loadTRACO().

◆ _conf_luts

const DTConfigLUTs* DTTracoCard::_conf_luts
private

Definition at line 142 of file DTTracoCard.h.

Referenced by config_luts(), and setConfig().

◆ _conf_traco_map

ConfTracoMap DTTracoCard::_conf_traco_map
private

Definition at line 140 of file DTTracoCard.h.

Referenced by config_traco(), and setConfig().

◆ _debug

bool DTTracoCard::_debug
private

Definition at line 144 of file DTTracoCard.h.

Referenced by debug(), and setConfig().

◆ _flag_acc

bool DTTracoCard::_flag_acc
private

Definition at line 146 of file DTTracoCard.h.

Referenced by loadTRACO(), setConfig(), and useAcceptParamFlag().

◆ _lut_from_db

bool DTTracoCard::_lut_from_db
private

Definition at line 147 of file DTTracoCard.h.

Referenced by lutFromDBFlag(), and setConfig().

◆ _tracomap

TRACOContainer DTTracoCard::_tracomap
private

Definition at line 139 of file DTTracoCard.h.

Referenced by activeGetTRACO(), getTRACO(), localClear(), runTRACO(), and tracoList().

◆ _tstheta

DTTSTheta* DTTracoCard::_tstheta
private

Definition at line 137 of file DTTracoCard.h.

Referenced by TSTh().

DTTracoCard::activeGetTRACO
DTTracoChip * activeGetTRACO(int)
Returns the required DTTracoChip. Create it if it doesn't exist.
Definition: DTTracoCard.cc:270
L1DTConfigFromDB_cfi.CL
CL
Definition: L1DTConfigFromDB_cfi.py:283
DDAxes::y
DTTracoCard::runTRACO
void runTRACO()
run TRACO algorithm
Definition: DTTracoCard.cc:214
DTTracoId
Definition: DTTracoId.h:34
DTConfigManager::getDTConfigLUTs
const DTConfigLUTs * getDTConfigLUTs(DTChamberId) const
Get desired LUT configuration.
Definition: DTConfigManager.cc:149
DTConfigBti::LH
int LH() const
K right limit for left traco.
Definition: DTConfigBti.h:103
dqmMemoryStats.float
float
Definition: dqmMemoryStats.py:127
dqmiodumpmetadata.n
n
Definition: dqmiodumpmetadata.py:28
DTCache::size
int size() const
Get cache vector's size.
Definition: DTCache.h:44
DTConfigManager::getDTTPGDebug
bool getDTTPGDebug() const
Get global debug flag.
Definition: DTConfigManager.h:99
step
step
Definition: StallMonitor.cc:94
DTTracoCard::getTRACO
DTTracoChip * getTRACO(int n) const
Returns the required DTTracoChip. Return 0 if it doesn't exist.
Definition: DTTracoCard.cc:286
DTConfigManager::lutFromDB
bool lutFromDB() const
Lut from DB flag.
Definition: DTConfigManager.h:105
TRACO_const_iter
TRACOContainer::const_iterator TRACO_const_iter
Definition: DTTracoCard.h:51
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
DTConfigBti::RH
int RH() const
K right limit for right traco.
Definition: DTConfigBti.h:115
TRACO_iter
TRACOContainer::iterator TRACO_iter
Definition: DTTracoCard.h:52
gather_cfg.cout
cout
Definition: gather_cfg.py:144
pos
Definition: PixelAliasList.h:18
DTConfigBti
Definition: DTConfigBti.h:36
DTConfig::NSTEPL
static const int NSTEPL
Constants: first and last step to start trigger finding.
Definition: DTConfig.h:35
DTTracoChip::run
void run()
Run TRACO algorithm.
Definition: DTTracoChip.cc:239
DTConfig::NSTEPF
static const int NSTEPF
Definition: DTConfig.h:35
DTTracoChip::add_btiT
void add_btiT(int step, int pos, const DTBtiTrigData *btitrig)
Add a BTI trigger to the TRACO.
Definition: DTTracoChip.cc:962
DDAxes::x
DTConfigBti::CH
int CH() const
K right limit for center traco.
Definition: DTConfigBti.h:109
L1DTConfigFromDB_cfi.LL
LL
Definition: L1DTConfigFromDB_cfi.py:289
DTTracoId::station
int station() const
Returns station number.
Definition: DTTracoId.h:55
align::LocalPoint
Point3DBase< Scalar, LocalTag > LocalPoint
Definition: Definitions.h:30
DTCache::begin
const_iterator begin() const
Get first cache element.
Definition: DTCache.h:38
DTGeomSupplier::ChamberId
DTChamberId ChamberId() const
Identifier of the associated chamber.
Definition: DTGeomSupplier.h:57
DTTracoChip::nTrig
int nTrig(int step) const
Return the number of trigger candidates.
Definition: DTTracoChip.cc:1043
DTGeomSupplier::sector
int sector() const
Return sector number.
Definition: DTGeomSupplier.h:66
funct::sin
Sin< T >::type sin(const T &t)
Definition: Sin.h:22
DTTracoCard::localClear
void localClear()
clear the TRACO map
Definition: DTTracoCard.cc:84
funct::cos
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
DTCache::_cache
my_collection _cache
Definition: DTCache.h:53
DTTracoCard::_conf_traco_map
ConfTracoMap _conf_traco_map
Definition: DTTracoCard.h:140
reco::ceil
constexpr int32_t ceil(float num)
Definition: constexpr_cmath.h:7
DTTracoCard::_bticard
DTBtiCard * _bticard
Definition: DTTracoCard.h:136
DTTracoTrigData::parentId
DTTracoId parentId() const
Return parent TRACO identifier.
Definition: DTTracoTrigData.h:156
DDAxes::z
L1DTConfigFromDB_cfi.RH
RH
Definition: L1DTConfigFromDB_cfi.py:324
DTConfigManager::useAcceptParam
bool useAcceptParam() const
Use Bti acceptance parameters (LL,LH,CL,CH,RL,RH)
Definition: DTConfigManager.h:108
DTTracoCard::_debug
bool _debug
Definition: DTTracoCard.h:144
DTTracoChip::useSecondTrack
int useSecondTrack(int step) const
a flag for a usable second track
Definition: DTTracoChip.cc:1114
DTTracoCard::_flag_acc
bool _flag_acc
Definition: DTTracoCard.h:146
DTTracoTrig
Definition: DTTracoTrig.h:40
DTTracoChip
Definition: DTTracoChip.h:53
DTGeomSupplier::wheel
int wheel() const
Return wheel number.
Definition: DTGeomSupplier.h:60
DTConfigBti::CL
int CL() const
K left limit for center traco.
Definition: DTConfigBti.h:106
DTTracoChip::triggerData
DTTracoTrigData triggerData(int step, unsigned n) const
Return the data part of the requested trigger.
Definition: DTTracoChip.cc:1067
DTTrigGeom::localPosition
LocalPoint localPosition(const DTBtiId) const
Local position in chamber of a BTI.
Definition: DTTrigGeom.cc:508
L1DTConfigFromDB_cfi.CH
CH
Definition: L1DTConfigFromDB_cfi.py:282
DTCache::end
const_iterator end() const
Get last cache element.
Definition: DTCache.h:41
LocalVector
Local3DVector LocalVector
Definition: LocalVector.h:12
createfilelist.int
int
Definition: createfilelist.py:10
DTGeomSupplier::DTGeomSupplier
DTGeomSupplier(DTTrigGeom *geom)
Constructor.
Definition: DTGeomSupplier.h:45
DTCache::clearCache
void clearCache()
Clear cache vector.
Definition: DTCache.h:47
DTTrigGeom::cellPitch
float cellPitch() const
Width of a cell (cm) i.e. distance between ywo wires.
Definition: DTTrigGeom.h:76
DTConfigBti::RL
int RL() const
K left limit for right traco.
Definition: DTConfigBti.h:112
DTBtiId
Definition: DTBtiId.h:32
DTTracoCard::loadTRACO
void loadTRACO()
store BTI triggers in TRACO's
Definition: DTTracoCard.cc:92
DTTracoCard::debug
bool debug()
Return TU debug flag.
Definition: DTTracoCard.h:74
L1DTConfigFromDB_cfi.BTIC
BTIC
Definition: L1DTConfigFromDB_cfi.py:342
ClusterTask_cfi.trig
trig
Definition: ClusterTask_cfi.py:336
DTTracoCard::_lut_from_db
bool _lut_from_db
Definition: DTTracoCard.h:147
DTConfigManager::getDTConfigTracoMap
const std::map< DTTracoId, DTConfigTraco > & getDTConfigTracoMap(DTChamberId) const
Get desired TRACO configuration map for a given DTChamber.
Definition: DTConfigManager.cc:106
psi
std::map< std::string, int, std::less< std::string > > psi
Definition: CountProcessesAction.h:15
DTTracoId::traco
int traco() const
Returns the traco.
Definition: DTTracoId.h:59
DTTracoTrigData
Definition: DTTracoTrigData.h:37
DTGeomSupplier::station
int station() const
Return station number.
Definition: DTGeomSupplier.h:63
DTTracoTrigData::step
int step() const
Return step.
Definition: DTTracoTrigData.h:162
DTConfigBti::LL
int LL() const
K left limit for left traco.
Definition: DTConfigBti.h:100
DTTracoCard::_conf_luts
const DTConfigLUTs * _conf_luts
Definition: DTTracoCard.h:142
DTTracoId::wheel
int wheel() const
Returns wheel number.
Definition: DTTracoId.h:53
DTGeomSupplier::geom
DTTrigGeom * geom() const
Associated geometry.
Definition: DTGeomSupplier.h:51
DTChamberId
Definition: DTChamberId.h:14
DTTracoCard::_tstheta
DTTSTheta * _tstheta
Definition: DTTracoCard.h:137
DTTrigGeom::statId
DTChamberId statId() const
Identifier of the associated chamber.
Definition: DTTrigGeom.h:53
DTTracoCard::config_traco
DTConfigTraco * config_traco(const DTTracoId &tracoid) const
Return single TRACO config.
Definition: DTTracoCard.cc:436
DTBtiCard::config_bti
DTConfigBti * config_bti(DTBtiId &btiid) const
Return bti chip configuration.
Definition: DTBtiCard.cc:637
DTTracoCard::_tracomap
TRACOContainer _tracomap
Definition: DTTracoCard.h:139
DTTracoId::sector
int sector() const
Returns sector number.
Definition: DTTracoId.h:57
L1DTConfigFromDB_cfi.LH
LH
Definition: L1DTConfigFromDB_cfi.py:288
DTConfig::NBTITC
static const int NBTITC
Definition: DTConfig.h:37
DTTrigGeom::distSL
float distSL() const
Distance between the phi view superlayers (cms)
Definition: DTTrigGeom.h:79
DTTracoCard::clearCache
void clearCache()
Clear all traco stuff (cache & map)
Definition: DTTracoCard.cc:61
DTTracoChip::addTrig
void addTrig(int step, DTTracoTrig *)
Add a TRACO trigger.
Definition: DTTracoChip.cc:1026
L1DTConfigFromDB_cfi.RL
RL
Definition: L1DTConfigFromDB_cfi.py:325