![]() |
![]() |
#include <L1Trigger/HardwareValidation/interface/DEutils.h>
Public Types | |
typedef de_trait::cand_type | cand_type |
typedef T::const_iterator | col_cit |
typedef T::iterator | col_it |
typedef T::size_type | col_sz |
typedef de_trait::coll_type | coll_type |
typedef DEtrait< T > | de_trait |
Public Member Functions | |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal (const cand_type &lhs, const cand_type &rhs) |
bool | de_equal (const cand_type &, const cand_type &) |
--- candidate match definition --- | |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
template<> | |
bool | de_equal_loc (const cand_type &lhs, const cand_type &rhs) |
bool | de_equal_loc (const cand_type &, const cand_type &) |
--- candidate location-match definition --- | |
col_it | de_find (col_it, col_it, const cand_type &) |
--- find candidate --- | |
bool | de_nequal (const cand_type &, const cand_type &) |
bool | de_nequal_loc (const cand_type &, const cand_type &) |
int | de_type () const |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
template<> | |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int aflag) |
L1DataEmulDigi | DEDigi (col_cit itd, col_cit itm, int ctype) |
--- form de-digi --- | |
DEutils () | |
std::string | GetName (int) const |
--- name candidate --- | |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
template<> | |
bool | is_empty (col_cit it) const |
bool | is_empty (col_cit) const |
--- candidate emptiness definition --- | |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
template<> | |
std::string | print (col_cit it) const |
std::string | print (col_cit) const |
--- print candidate --- | |
~DEutils () |
Definition at line 14 of file DEutils.h.
typedef T::size_type DEutils< T >::col_sz |
Definition at line 25 of file DEutils.h.
References DEutils< T >::de_type(), and lat::endl().
00025 { 00026 if(de_type()>30) 00027 edm::LogError("L1ComparatorDeutilsCollType") //throw cms::Exception("ERROR") 00028 << "DEutils::DEutils() :: " 00029 << "specialization is still missing for collection of type:" 00030 << de_type() << std::endl; 00031 }
bool DEutils< L1CSCSPStatusDigiCollection_ >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 678 of file DEutils.h.
00678 { 00679 bool val = true; 00680 val &= (lhs.slot() == rhs.slot()); 00681 val &= (lhs.BXN () == rhs.BXN ()); 00682 val &= (lhs.FMM () == rhs.FMM ()); 00683 val &= (lhs.SEs () == rhs.SEs ()); 00684 val &= (lhs.SMs () == rhs.SMs ()); 00685 val &= (lhs.BXs () == rhs.BXs ()); 00686 val &= (lhs.AFs () == rhs.AFs ()); 00687 val &= (lhs.VPs () == rhs.VPs ()); 00688 return val; 00689 }
bool DEutils< CSCCLCTDigiCollection_ >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< CSCALCTDigiCollection_ >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< CSCCorrelatedLCTDigiCollection_ >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 652 of file DEutils.h.
00652 { 00653 // Exclude track number from comparison since it is only meaningful for 00654 // LCTs upstream of the MPC but not downstream (the latter ones are 00655 // unpacked by the CSC TF unpacker). 00656 bool val = true; 00657 val &= (lhs.isValid() == rhs.isValid() ); 00658 val &= (lhs.getQuality() == rhs.getQuality()); 00659 val &= (lhs.getKeyWG() == rhs.getKeyWG() ); 00660 val &= (lhs.getStrip() == rhs.getStrip() ); 00661 val &= (lhs.getPattern() == rhs.getPattern()); 00662 val &= (lhs.getBend() == rhs.getBend() ); 00663 val &= (lhs.getBX() == rhs.getBX() ); 00664 val &= (lhs.getMPCLink() == rhs.getMPCLink()); 00665 val &= (lhs.getCSCID() == rhs.getCSCID() ); 00666 return val; 00667 //return lhs==rhs; 00668 }
bool DEutils< L1MuGMTCandCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 637 of file DEutils.h.
References dw.
00637 { 00638 //return (lhs.getDataWord() == rhs.getDataWord() ); 00639 //return lhs==rhs; //(dataword,bx..) 00640 bool val = true; 00641 unsigned int dw = rhs.getDataWord(); 00642 unsigned int ew = lhs.getDataWord(); 00643 unsigned int mask = 0x3ffffff; //26-bit 00644 //mask bits 22 (isolation), 23 (mip) [not permanent!] 00645 mask &= (~(0x0c00000)); 00646 dw &= mask; ew &= mask; 00647 val &= (dw==ew); 00648 return val; 00649 }
bool DEutils< L1MuRegionalCandCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 617 of file DEutils.h.
References dw, and dedefs::RPC.
00617 { 00618 bool val = true; 00619 val &= (lhs.type_idx() == rhs.type_idx()); 00620 val &= (lhs.bx() == rhs.bx()); 00621 if(!val) return val; 00622 unsigned int dw = lhs.getDataWord(); 00623 unsigned int ew = rhs.getDataWord(); 00624 unsigned int mask = 0xffffffff; //32-bit 00625 //RPC: mask bits 25,26,27 (3 lowest bits of bx counter); 00626 // emulator doesn't set these bits (permanent masking) 00627 if(rhs.type_idx()==dedefs::RPC) 00628 mask &= 0xf1ffffff; 00629 dw &= mask; ew &= mask; 00630 val &= (dw==ew); 00631 //val &= (lhs.getDataWord() == rhs.getDataWord() ); 00632 //check whether collections being compared refer to same system and bx! 00633 return val; 00634 }
bool DEutils< L1MuDTChambThDigiCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 602 of file DEutils.h.
00602 { 00603 bool val = true; 00604 val &= (lhs.whNum() ==rhs.whNum() ); 00605 val &= (lhs.scNum() ==rhs.scNum() ); 00606 val &= (lhs.stNum() ==rhs.stNum() ); 00607 //for(int i=0; i<7; i++) { 00608 // val &= (lhs.code(i) ==rhs.code(i) ); 00609 // val &= (lhs.position(i)==rhs.position(i)); 00610 // val &= (lhs.quality(i) ==rhs.quality(i) ); 00611 //} 00612 //val &= (lhs.bxNum() ==rhs.bxNum() ); 00613 return val; 00614 }
bool DEutils< L1MuDTChambPhDigiCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 587 of file DEutils.h.
00587 { 00588 bool val = true; 00589 val &= (lhs.whNum() ==rhs.whNum() ); 00590 val &= (lhs.scNum() ==rhs.scNum() ); 00591 val &= (lhs.stNum() ==rhs.stNum() ); 00592 val &= (lhs.phi() ==rhs.phi() ); 00593 val &= (lhs.phiB() ==rhs.phiB() ); 00594 val &= (lhs.code() ==rhs.code() ); 00595 val &= (lhs.Ts2Tag()==rhs.Ts2Tag()); 00596 //val &= (lhs.BxCnt() ==rhs.BxCnt() ); 00597 //val &= (lhs.bxNum() ==rhs.bxNum() ); 00598 return val; 00599 }
bool DEutils< L1GctJetCandCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1GctEmCandCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1CaloRegionCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 557 of file DEutils.h.
00557 { 00558 bool val = true; 00559 val &= (lhs.et() == rhs.et() ); 00560 val &= (lhs.rctCrate() == rhs.rctCrate() ); 00561 val &= (lhs.rctRegionIndex() == rhs.rctRegionIndex()); 00562 val &= (lhs.id().isHf() == rhs.id().isHf()); 00563 if (!lhs.id().isHf()){ 00564 val &= (lhs.overFlow() == rhs.overFlow() ); 00565 val &= (lhs.tauVeto() == rhs.tauVeto() ); 00566 //mask temporarily (!) mip and quiet bits 00567 //val &= (lhs.mip() == rhs.mip() ); 00568 //val &= (lhs.quiet() == rhs.quiet() ); 00569 val &= (lhs.rctCard() == rhs.rctCard() ); 00570 } else { 00571 val &= (lhs.fineGrain() == rhs.fineGrain()); 00572 } 00573 return val; 00574 }
bool DEutils< L1CaloEmCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 546 of file DEutils.h.
00546 { 00547 bool val = true; 00548 val &= (lhs.raw() == rhs.raw() ); 00549 val &= (lhs.rctCrate() == rhs.rctCrate()); 00550 val &= (lhs.isolated() == rhs.isolated()); 00551 val &= (lhs.index() == rhs.index() ); 00552 //val &= (lhs.bx() == rhs.bx() ); 00553 return val; 00554 }
bool DEutils< HcalTrigPrimDigiCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< EcalTrigPrimDigiCollection >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 527 of file DEutils.h.
00527 { 00528 bool val = true; 00529 unsigned int mask = 0x0fff; //keep only ttf[11:9], fg [8], Et [7:0] 00530 mask &= 0x0eff; //fg bit temporary(!) mask 00531 val &= ((lhs[lhs.sampleOfInterest()].raw()&mask) == (rhs[rhs.sampleOfInterest()].raw()&mask)); 00532 val &= (lhs.id().rawId() == rhs.id().rawId()); 00533 return val; 00534 }
bool DEutils< T >::de_equal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
--- candidate match definition ---
Definition at line 517 of file DEutils.h.
Referenced by DEutils< T >::de_find(), and DEutils< T >::de_nequal().
bool DEutils< L1CSCSPStatusDigiCollection_ >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< CSCCLCTDigiCollection_ >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< CSCALCTDigiCollection_ >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< CSCCorrelatedLCTDigiCollection_ >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1MuDTChambThDigiCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1MuDTChambPhDigiCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 776 of file DEutils.h.
00776 { 00777 bool val = true; 00778 val &= (lhs.whNum() ==rhs.whNum() ); 00779 val &= (lhs.scNum() ==rhs.scNum() ); 00780 val &= (lhs.stNum() ==rhs.stNum() ); 00781 //val &= (lhs.phi() ==rhs.phi() ); 00782 //val &= (lhs.phiB() ==rhs.phiB() ); 00783 //val &= (lhs.bxNum() ==rhs.bxNum() ); 00784 return val; 00785 }
bool DEutils< L1MuGMTCandCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1MuRegionalCandCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1GctJetCandCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1GctEmCandCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< L1CaloRegionCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 732 of file DEutils.h.
00732 { 00733 bool val = true; 00734 val &= (lhs.rctCrate() == rhs.rctCrate() ); 00735 val &= (lhs.id().isHf() == rhs.id().isHf()); 00736 if (!lhs.id().isHf()) 00737 val &= (lhs.rctCard() == rhs.rctCard() ); 00738 val &= (lhs.rctRegionIndex() == rhs.rctRegionIndex()); 00739 return val; 00740 }
bool DEutils< L1CaloEmCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< HcalTrigPrimDigiCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< EcalTrigPrimDigiCollection >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
bool DEutils< T >::de_equal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
--- candidate location-match definition ---
Definition at line 694 of file DEutils.h.
Referenced by DEutils< T >::de_nequal_loc().
bool DEutils< T >::de_nequal | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 522 of file DEutils.h.
References DEutils< T >::de_equal().
00522 { 00523 return !de_equal(lhs,rhs); 00524 }
bool DEutils< T >::de_nequal_loc | ( | const cand_type & | lhs, | |
const cand_type & | rhs | |||
) | [inline] |
Definition at line 699 of file DEutils.h.
References DEutils< T >::de_equal_loc().
00699 { 00700 return !de_equal_loc(lhs,rhs); 00701 }
Definition at line 34 of file DEutils.h.
Referenced by DEutils< T >::DEDigi(), DEutils< T >::DEutils(), and DEutils< T >::GetName().
L1DataEmulDigi DEutils< L1CSCSPStatusDigiCollection_ >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 482 of file DEutils.h.
References dedefs::CTF, and DEutils< T >::de_type().
00482 { 00483 int cid = de_type(); 00484 int errt = aflag; 00485 double x1; //sector/slot 00486 x1 = (aflag!=4) ? itd->slot() : itm->slot(); 00487 //sector-slot map to be in principle to be provided from event setup 00488 //int de_cscstatus_slot2sector[22] = 00489 // {0,0,0,0,0, 0,1,2,3,4, 5,6,0,0,0, 0,7,8,9,10, 11,12}; 00490 //x1 = (aflag!=4) ? slot2sector[itd->slot()] : slot2sector[itm->slot()]; 00491 L1DataEmulDigi digi(dedefs::CTF,cid, x1,0,0, errt); 00492 //note: no data word and rank defined for candidate 00493 return digi; 00494 }
L1DataEmulDigi DEutils< CSCCLCTDigiCollection_ >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 431 of file DEutils.h.
References dedefs::CTP, DEutils< T >::de_type(), dw, edm::eq(), L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00431 { 00432 int cid = de_type(); 00433 int errt = aflag; 00434 double x1 = (aflag!=4) ? itd->getKeyStrip() : itm->getKeyStrip(); 00435 double x3 = (aflag!=4) ? itd->getTrknmb() : itm->getTrknmb(); 00436 L1DataEmulDigi digi(dedefs::CTP,cid, x1,0,x3, errt); 00437 int dq = (aflag==4)?0:itd->getQuality(); 00438 int eq = (aflag==3)?0:itm->getQuality(); 00439 digi.setRank((float)dq,(float)eq); 00440 // Pack cathode digi members into 19-bit data words. 00441 static const int kValidBitWidth = 1; 00442 static const int kQualityBitWidth = 3; 00443 static const int kPatternBitWidth = 4; 00444 static const int kBendBitWidth = 1; 00445 static const int kHalfstripBitWidth = 5; 00446 static const int kCFEBBitWidth = 3; 00447 static const int kBxBitWidth = 2; 00448 // While packing, check that the right number of bits is retained. 00449 unsigned shift = 0, dw = 0, ew = 0; 00450 dw = itd->isValid() & ((1<<kValidBitWidth)-1); 00451 dw += (itd->getQuality() & ((1<<kQualityBitWidth)-1)) << 00452 (shift += kValidBitWidth); 00453 dw += (itd->getPattern() & ((1<<kPatternBitWidth)-1)) << 00454 (shift += kQualityBitWidth); 00455 dw += (itd->getBend() & ((1<<kBendBitWidth)-1)) << 00456 (shift += kPatternBitWidth); 00457 dw += (itd->getStrip() & ((1<<kHalfstripBitWidth)-1)) << 00458 (shift += kBendBitWidth); 00459 dw += (itd->getCFEB() & ((1<<kCFEBBitWidth)-1)) << 00460 (shift += kHalfstripBitWidth); 00461 dw += (itd->getBX() & ((1<<kBxBitWidth)-1)) << 00462 (shift += kCFEBBitWidth); 00463 shift = 0; 00464 ew = itm->isValid() & ((1<<kValidBitWidth)-1); 00465 ew += (itm->getQuality() & ((1<<kQualityBitWidth)-1)) << 00466 (shift += kValidBitWidth); 00467 ew += (itm->getPattern() & ((1<<kPatternBitWidth)-1)) << 00468 (shift += kQualityBitWidth); 00469 ew += (itm->getBend() & ((1<<kBendBitWidth)-1)) << 00470 (shift += kPatternBitWidth); 00471 ew += (itm->getStrip() & ((1<<kHalfstripBitWidth)-1)) << 00472 (shift += kBendBitWidth); 00473 ew += (itm->getCFEB() & ((1<<kCFEBBitWidth)-1)) << 00474 (shift += kHalfstripBitWidth); 00475 ew += (itm->getBX() & ((1<<kBxBitWidth)-1)) << 00476 (shift += kCFEBBitWidth); 00477 digi.setData(dw, ew); 00478 return digi; 00479 }
L1DataEmulDigi DEutils< CSCALCTDigiCollection_ >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 386 of file DEutils.h.
References dedefs::CTP, DEutils< T >::de_type(), dw, edm::eq(), L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00386 { 00387 int cid = de_type(); 00388 int errt = aflag; 00389 double x2 = (aflag!=4) ? itd->getKeyWG () : itm->getKeyWG (); 00390 double x3 = (aflag!=4) ? itd->getTrknmb() : itm->getTrknmb(); 00391 L1DataEmulDigi digi(dedefs::CTP,cid, 0,x2,x3, errt); 00392 int dq = (aflag==4)?0:itd->getQuality(); 00393 int eq = (aflag==3)?0:itm->getQuality(); 00394 digi.setRank((float)dq,(float)eq); 00395 // Pack anode digi members into 17-bit data words. 00396 static const int kValidBitWidth = 1; 00397 static const int kQualityBitWidth = 2; 00398 static const int kAccelBitWidth = 1; 00399 static const int kPatternBBitWidth = 1; 00400 static const int kWireGroupBitWidth = 7; 00401 static const int kBxBitWidth = 5; 00402 // While packing, check that the right number of bits is retained. 00403 unsigned shift = 0, dw = 0, ew = 0; 00404 dw = itd->isValid() & ((1<<kValidBitWidth)-1); 00405 dw += (itd->getQuality() & ((1<<kQualityBitWidth)-1)) << 00406 (shift += kValidBitWidth); 00407 dw += (itd->getAccelerator() & ((1<<kAccelBitWidth)-1)) << 00408 (shift += kQualityBitWidth); 00409 dw += (itd->getCollisionB() & ((1<<kPatternBBitWidth)-1)) << 00410 (shift += kAccelBitWidth); 00411 dw += (itd->getKeyWG() & ((1<<kWireGroupBitWidth)-1)) << 00412 (shift += kPatternBBitWidth); 00413 dw += (itd->getBX() & ((1<<kBxBitWidth)-1)) << 00414 (shift += kWireGroupBitWidth); 00415 shift = 0; 00416 ew = itm->isValid() & ((1<<kValidBitWidth)-1); 00417 ew += (itm->getQuality() & ((1<<kQualityBitWidth)-1)) << 00418 (shift += kValidBitWidth); 00419 ew += (itm->getAccelerator() & ((1<<kAccelBitWidth)-1)) << 00420 (shift += kQualityBitWidth); 00421 ew += (itm->getCollisionB() & ((1<<kPatternBBitWidth)-1)) << 00422 (shift += kAccelBitWidth); 00423 ew += (itm->getKeyWG() & ((1<<kWireGroupBitWidth)-1)) << 00424 (shift += kPatternBBitWidth); 00425 ew += (itm->getBX() & ((1<<kBxBitWidth)-1)) << 00426 (shift += kWireGroupBitWidth); 00427 digi.setData(dw, ew); 00428 return digi; 00429 }
L1DataEmulDigi DEutils< CSCCorrelatedLCTDigiCollection_ >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 322 of file DEutils.h.
References DEutils< T >::de_type(), dw, edm::eq(), L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00322 { 00323 int cid = de_type(); 00324 int errt = aflag; 00325 double x1 = (aflag!=4) ? itd->getStrip() : itm->getStrip(); 00326 double x2 = (aflag!=4) ? itd->getKeyWG() : itm->getKeyWG(); 00327 double x3 = (aflag!=4) ? itd->getTrknmb(): itm->getTrknmb(); 00328 //multiple subsystem ctp,ctf 00329 L1DataEmulDigi digi(-1,cid, x1,x2,x3, errt); 00330 int dq = (aflag==4)?0:itd->getQuality(); 00331 int eq = (aflag==3)?0:itm->getQuality(); 00332 digi.setRank((float)dq,(float)eq); 00333 // Pack LCT digi members into 32-bit data words. 00334 static const int kValidBitWidth = 1; // Reverse the order of the 1st 00335 static const int kQualityBitWidth = 4; // frame to keep the valid bit 00336 static const int kPatternBitWidth = 4; // first and quality second, as 00337 static const int kWireGroupBitWidth = 7; // is done in ALCT and CLCT. 00338 static const int kHalfstripBitWidth = 8; 00339 static const int kBendBitWidth = 1; 00340 static const int kBxBitWidth = 1; 00341 // Use sync_err and bx0_local bits to store MPC link. 00342 static const int kMPCLinkBitWidth = 2; 00343 static const int kCSCIdBitWidth = 4; 00344 // While packing, check that the right number of bits is retained. 00345 unsigned shift = 0, dw = 0, ew = 0; 00346 dw = itd->isValid() & ((1<<kValidBitWidth)-1); 00347 dw += (itd->getQuality() & ((1<<kQualityBitWidth)-1)) << 00348 (shift += kValidBitWidth); 00349 dw += (itd->getPattern() & ((1<<kPatternBitWidth)-1)) << 00350 (shift += kQualityBitWidth); 00351 dw += (itd->getKeyWG() & ((1<<kWireGroupBitWidth)-1)) << 00352 (shift += kPatternBitWidth); 00353 dw += (itd->getStrip() & ((1<<kHalfstripBitWidth)-1)) << 00354 (shift += kWireGroupBitWidth); 00355 dw += (itd->getBend() & ((1<<kBendBitWidth)-1)) << 00356 (shift += kHalfstripBitWidth); 00357 dw += (itd->getBX() & ((1<<kBxBitWidth)-1)) << 00358 (shift += kBendBitWidth); 00359 dw += (itd->getMPCLink() & ((1<<kMPCLinkBitWidth)-1)) << 00360 (shift += kBxBitWidth); 00361 dw += (itd->getCSCID() & ((1<<kCSCIdBitWidth)-1)) << 00362 (shift += kMPCLinkBitWidth); 00363 shift = 0; 00364 ew = itm->isValid() & ((1<<kValidBitWidth)-1); 00365 ew += (itm->getQuality() & ((1<<kQualityBitWidth)-1)) << 00366 (shift += kValidBitWidth); 00367 ew += (itm->getPattern() & ((1<<kPatternBitWidth)-1)) << 00368 (shift += kQualityBitWidth); 00369 ew += (itm->getKeyWG() & ((1<<kWireGroupBitWidth)-1)) << 00370 (shift += kPatternBitWidth); 00371 ew += (itm->getStrip() & ((1<<kHalfstripBitWidth)-1)) << 00372 (shift += kWireGroupBitWidth); 00373 ew += (itm->getBend() & ((1<<kBendBitWidth)-1)) << 00374 (shift += kHalfstripBitWidth); 00375 ew += (itm->getBX() & ((1<<kBxBitWidth)-1)) << 00376 (shift += kBendBitWidth); 00377 ew += (itm->getMPCLink() & ((1<<kMPCLinkBitWidth)-1)) << 00378 (shift += kBxBitWidth); 00379 ew += (itm->getCSCID() & ((1<<kCSCIdBitWidth)-1)) << 00380 (shift += kMPCLinkBitWidth); 00381 digi.setData(dw, ew); 00382 return digi; 00383 }
L1DataEmulDigi DEutils< L1MuDTChambThDigiCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 300 of file DEutils.h.
References DEutils< T >::de_type(), dedefs::DTP, i, and L1DataEmulDigi::setRank().
00300 { 00301 int cid = de_type(); 00302 int errt = aflag; 00303 double x1 = (aflag!=4) ? itd->scNum() : itm->scNum(); 00304 double x2 = (aflag!=4) ? itd->whNum() : itm->whNum(); 00305 double x3 = (aflag!=4) ? itd->stNum() : itm->stNum(); 00306 L1DataEmulDigi digi(dedefs::DTP,cid, x1,x2,x3, errt); 00307 //note: no data word defined for candidate 00308 int dr(0), er(0); 00309 for(int i=0; i<7;i++){ 00310 if(itd->code(i)>=dr) dr=itd->quality(i); 00311 if(itm->code(i)>=er) er=itm->quality(i); 00312 } 00313 //alternatives: code() = quality() + positions() 00314 dr = (aflag==4)?0:dr; 00315 er = (aflag==3)?0:er; 00316 digi.setRank((float)dr,(float)er); 00317 return digi; 00318 }
L1DataEmulDigi DEutils< L1MuDTChambPhDigiCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 284 of file DEutils.h.
References DEutils< T >::de_type(), dedefs::DTP, and L1DataEmulDigi::setRank().
00284 { 00285 int cid = de_type(); 00286 int errt = aflag; 00287 double x1 = (aflag!=4) ? itd->scNum() : itm->scNum(); 00288 double x2 = (aflag!=4) ? itd->whNum() : itm->whNum(); 00289 double x3 = (aflag!=4) ? itd->stNum() : itm->stNum(); 00290 L1DataEmulDigi digi(dedefs::DTP,cid, x1,x2,x3, errt); 00291 //other coordinate methods phi(), phiB() 00292 //note: no data word defined for candidate 00293 int dr = (aflag==4)?0:itd->code(); 00294 int er = (aflag==3)?0:itm->code(); 00295 digi.setRank((float)dr,(float)er); 00296 return digi; 00297 }
L1DataEmulDigi DEutils< L1MuGMTCandCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 256 of file DEutils.h.
References GenMuonPlsPt100GeV_cfg::cout, DEutils< T >::de_type(), dw, lat::endl(), dedefs::GMT, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00256 { 00257 int cid = de_type(); 00258 int errt = aflag; 00259 //double x1 = (aflag!=4) ? itd->phiValue() : itm->phiValue(); 00260 //double x2 = (aflag!=4) ? itd->etaValue() : itm->etaValue(); 00261 double x1 = (aflag!=4) ? itd->phiIndex() : itm->phiIndex(); 00262 double x2 = (aflag!=4) ? itd->etaIndex() : itm->etaIndex(); 00263 L1DataEmulDigi digi(dedefs::GMT,cid, x1,x2,0, errt); 00264 unsigned int dw = (aflag==4)?0 : itd->getDataWord(); 00265 unsigned int ew = (aflag==3)?0 : itm->getDataWord(); 00266 unsigned int mask = 0x3ffffff; //26-bit 00267 //mask bits 22 (isolation), 23 (mip) [not permanent!] 00268 mask &= (~(0x0c00000)); 00269 dw &= mask; ew &= mask; 00270 digi.setData(dw,ew); 00271 int de = (aflag==4)?0:itd->ptIndex();//ptValue(); 00272 int ee = (aflag==3)?0:itm->ptIndex();//ptValue(); 00273 digi.setRank((float)de,(float)ee); 00274 if(0) //check print 00275 std::cout << "l1dataemuldigi l1mugmtcandcoll type:" << cid 00276 //<< " eta:" << itd->etaValue() << ", " << itm->etaValue() 00277 //<< " phi:" << itd->phiValue() << ", " << itm->phiValue() 00278 << std::hex << " word d:" << dw << "e:" << ew << std::dec 00279 << std::endl; 00280 return digi; 00281 }
L1DataEmulDigi DEutils< L1MuRegionalCandCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 215 of file DEutils.h.
References GenMuonPlsPt100GeV_cfg::cout, dedefs::CTF, DEutils< T >::de_type(), dedefs::DTF, dw, lat::endl(), dedefs::RPC, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00215 { 00216 int sid; 00217 switch(itd->type_idx()) { // 0 DT, 1 bRPC, 2 CSC, 3 fRPC 00218 case 0: sid=dedefs::DTF; break; 00219 case 1: sid=dedefs::RPC; break; 00220 case 2: sid=dedefs::CTF; break; 00221 case 3: sid=dedefs::RPC; break; 00222 default: sid=-1; 00223 } 00224 int cid = de_type(); 00225 int errt = aflag; 00226 //double x1 = (aflag!=4) ? itd->phiValue() : itm->phiValue(); 00227 //double x2 = (aflag!=4) ? itd->etaValue() : itm->etaValue(); 00228 double x1 = (aflag!=4) ? itd->phi_packed() : itm->phi_packed(); 00229 double x2 = (aflag!=4) ? itd->eta_packed() : itm->eta_packed(); 00230 L1DataEmulDigi digi(sid,cid, x1,x2,0, errt); 00231 unsigned int dw = (aflag==4)?0 : itd->getDataWord(); 00232 unsigned int ew = (aflag==3)?0 : itm->getDataWord(); 00233 unsigned int mask = 0xffffffff; //32-bit 00234 //RPC: mask bits 25,26,27 (3 lowest bits of bx counter); 00235 // emulator doesn't set these bits (permanent masking) 00236 if(sid==dedefs::RPC) 00237 mask &= 0xf1ffffff; 00238 dw &= mask; ew &= mask; 00239 digi.setData(dw,ew); 00240 int de = (aflag==4)?0:itd->pt_packed();//ptValue(); 00241 int ee = (aflag==3)?0:itm->pt_packed();//ptValue(); 00242 digi.setRank((float)de,(float)ee); 00243 //note: phi,eta,pt 'values' not always set for all muon tf systems 00244 //(under discussion) need universal mechanism for setting up physical units 00245 if(0) //check print 00246 std::cout << "L1DataEmulDigi DEutils<L1MuRegionalCandCollection>] dedigi info" 00247 //<< " phivalue:" << itd->phiValue() << "," << itm->phiValue() 00248 //<< " etavalue:" << itd->etaValue() << "," << itm->etaValue() 00249 << " phipackd:" << itd->phi_packed() << "," << itm->phi_packed() 00250 << " etapackd:" << itd->eta_packed() << "," << itm->eta_packed() 00251 << std::endl; 00252 return digi; 00253 }
L1DataEmulDigi DEutils< L1GctJetCandCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 191 of file DEutils.h.
References DEutils< T >::de_type(), dw, dedefs::GCT, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00191 { 00192 int cid = de_type(); 00193 int errt = aflag; 00194 //phi: 0..17; eta: -6..-0,+0..+6; eta sign:1(z-),0(z+) 00195 // bring it to global coordinates 0..21 below 00196 double x1 = (aflag!=4) ? itd->phiIndex() : itm->phiIndex(); 00197 unsigned deta(0), eeta(0); 00198 if (!itd->isForward()) deta=(itd->etaSign()==1?10-(itd->etaIndex()&0x7):(itd->etaIndex()&0x7)+11); 00199 else deta=(itd->etaSign()==1? 3-(itd->etaIndex()&0x7):(itd->etaIndex()&0x7)+18 ); 00200 if (!itm->isForward()) eeta=(itm->etaSign()==1?10-(itm->etaIndex()&0x7):(itm->etaIndex()&0x7)+11); 00201 else eeta=(itm->etaSign()==1? 3-(itm->etaIndex()&0x7):(itm->etaIndex()&0x7)+18 ); 00202 double x2 = (aflag!=4) ? deta : eeta; 00203 L1DataEmulDigi digi(dedefs::GCT,cid, x1,x2,0., errt); 00204 unsigned int dw = (aflag==4)?0:itd->raw(); 00205 unsigned int ew = (aflag==3)?0:itm->raw(); 00206 dw &= 0x7fff; ew &= 0x7fff; //15-bit 00207 digi.setData(dw,ew); 00208 int de = (aflag==4)?0:itd->rank(); 00209 int ee = (aflag==3)?0:itm->rank(); 00210 digi.setRank((float)de,(float)ee); 00211 return digi; 00212 }
L1DataEmulDigi DEutils< L1GctEmCandCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 172 of file DEutils.h.
References DEutils< T >::de_type(), dw, dedefs::GCT, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00172 { 00173 int cid = de_type(); 00174 int errt = aflag; 00175 //phi: 0..17; eta: 0..21 00176 // bring it to global coordinates 00177 double x1 = (aflag!=4) ? itd->regionId().iphi() : itm->regionId().iphi(); 00178 double x2 = (aflag!=4) ? itd->regionId().ieta() : itm->regionId().ieta(); 00179 L1DataEmulDigi digi(dedefs::GCT,cid, x1,x2,0., errt); 00180 unsigned int dw = (aflag==4)?0:itd->raw(); 00181 unsigned int ew = (aflag==3)?0:itm->raw(); 00182 dw &= 0x7fff; ew &= 0x7fff; //15-bit 00183 digi.setData(dw,ew); 00184 int de = (aflag==4)?0:itd->rank(); 00185 int ee = (aflag==3)?0:itm->rank(); 00186 digi.setRank((float)de,(float)ee); 00187 return digi; 00188 }
L1DataEmulDigi DEutils< L1CaloRegionCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
bits: iphi(23:19), ieta(18:14) + quiet(13), mip(12), fg(11), ovf(10), et (9:0)
Definition at line 142 of file DEutils.h.
References DEutils< T >::de_type(), dw, dedefs::RCT, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00142 { 00143 int cid = de_type(); 00144 int errt = aflag; 00145 double x1, x2, x3(0.); 00146 x1 = (aflag!=4) ? itd->id().iphi() : itm->id().iphi(); 00147 x2 = (aflag!=4) ? itd->id().ieta() : itm->id().ieta(); 00148 x3 = (aflag!=4) ? itd->id().rctCard() : itm->id().rctCard(); 00149 L1DataEmulDigi digi(dedefs::RCT,cid, x1,x2,x3, errt); 00150 unsigned int dw = itd->raw(); 00151 unsigned int ew = itm->raw(); 00152 unsigned int mask = 0x3fff; 00153 //mask (temporary) mip(12), quiet (13) 00154 mask = 0x0fff; 00155 dw &= mask; 00156 dw += (((itd->id().ieta())&0x1f)<<14); 00157 dw += (((itd->id().iphi())&0x1f)<<19); 00158 ew &= mask; 00159 ew += (((itm->id().ieta())&0x1f)<<14); 00160 ew += (((itm->id().iphi())&0x1f)<<19); 00161 dw = (aflag==4)?0:dw; 00162 ew = (aflag==3)?0:ew; 00164 digi.setData(dw,ew); 00165 int de = (aflag==4)?0:itd->et(); 00166 int ee = (aflag==3)?0:itm->et(); 00167 digi.setRank((float)de,(float)ee); 00168 return digi; 00169 }
L1DataEmulDigi DEutils< L1CaloEmCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
bits: index(17:16) iso(15) crate(14:10) + card(9:7) region(6) rank (5:0) (rank & 0x3f) + ((region & 0x1)<<6) + ((card & 0x7)<<7) + ((card & 0x1f)<<10) + ((0x1)<<15) + ((0x3)<<16)
Definition at line 109 of file DEutils.h.
References DEutils< T >::de_type(), dw, dedefs::RCT, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00109 { 00110 int cid = de_type(); 00111 int errt = aflag; 00112 double x1, x2, x3(0.); 00113 // global index ieta (0-21), iphi (0-17), card (0-6) 00114 x1 = (aflag!=4) ? itd->regionId().iphi() : itm->regionId().iphi(); 00115 x2 = (aflag!=4) ? itd->regionId().ieta() : itm->regionId().ieta(); 00116 x3 = (aflag!=4) ? itd->regionId().rctCard() : itm->regionId().rctCard(); 00117 //alternative coordinates: rctCrate(), rctCard(), index() 00118 L1DataEmulDigi digi(dedefs::RCT,cid, x1,x2,x3, errt); 00119 unsigned int dw = itd->raw(); 00120 unsigned int ew = itm->raw(); 00121 dw &= 0x3ff; 00122 dw += (((itd->rctCrate())&0x1f)<<10); 00123 dw += (((itd->isolated()?1:0)&0x1)<<15); 00124 dw += (((itd->index())&0x3)<<16); 00125 ew &= 0x3ff; 00126 ew += (((itm->rctCrate())&0x1f)<<10); 00127 ew += (((itm->isolated()?1:0)&0x1)<<15); 00128 ew += (((itm->index())&0x3)<<16); 00129 dw = (aflag==4)?0:dw; 00130 ew = (aflag==3)?0:ew; 00134 digi.setData(dw,ew); 00135 int de = (aflag==4)?0:itd->rank(); 00136 int ee = (aflag==3)?0:itm->rank(); 00137 digi.setRank((float)de,(float)ee); 00138 return digi; 00139 }
L1DataEmulDigi DEutils< HcalTrigPrimDigiCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 89 of file DEutils.h.
References DEutils< T >::de_type(), dw, dedefs::HTP, L1DataEmulDigi::setData(), and L1DataEmulDigi::setRank().
00089 { 00090 int cid = de_type(); 00091 int errt = aflag; 00092 double x1 = (aflag!=4) ? itd->id().iphi() : itm->id().iphi(); 00093 double x2 = (aflag!=4) ? itd->id().ieta() : itm->id().ieta(); 00094 L1DataEmulDigi digi(dedefs::HTP,cid, x1,x2,0, errt); 00095 unsigned int dw = (aflag==4)?0:itd->t0().raw(); 00096 unsigned int ew = (aflag==3)?0:itm->t0().raw(); 00097 //16-bit; bits 10:9 not set(?); 00098 // bits 15:11 not accessible in emulator (slb/channel ids) 00099 unsigned int mask = 0x01ff; 00100 dw &= mask; ew &= mask; 00101 digi.setData(dw,ew); 00102 int de = (aflag==4)?0:itd->SOI_compressedEt(); 00103 int ee = (aflag==3)?0:itm->SOI_compressedEt(); 00104 digi.setRank((float)de,(float)ee); 00105 return digi; 00106 }
L1DataEmulDigi DEutils< EcalTrigPrimDigiCollection >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | aflag | |||
) | [inline] |
Definition at line 60 of file DEutils.h.
References DEutils< T >::de_type(), dw, dedefs::ETP, L1DataEmulDigi::setData(), L1DataEmulDigi::setDEpair(), and L1DataEmulDigi::setRank().
00060 { 00061 int cid = de_type(); 00062 int errt = aflag; 00063 //fill data if flagged, otherwise emulator 00064 double x1 = (aflag!=4) ? itd->id().iphi() : itm->id().iphi(); 00065 double x2 = (aflag!=4) ? itd->id().ieta() : itm->id().ieta(); 00066 L1DataEmulDigi digi(dedefs::ETP,cid, x1,x2,0, errt); 00067 unsigned int dwS = (aflag==4)?0:itd->sample(itd->sampleOfInterest()).raw(); 00068 unsigned int ewS = (aflag==3)?0:itm->sample(itm->sampleOfInterest()).raw(); 00069 //dw1 &= 0x01ff; ew1 &= 0x01ff; //9-bit: fg(8),energy(7:0) 00070 unsigned int dwI = (aflag==4)?0:itd->id().rawId(); 00071 unsigned int ewI = (aflag==3)?0:itm->id().rawId(); 00072 //dw2 &= 0xfe00ffff; ew2 &= 0xfe00ffff; //32-bit, reset unused (24:16) 00073 //merge id and sample words 00074 unsigned int dw = (dwI & 0xfe00ffff ) | ( (dwS & 0x000001ff)<<16 ); 00075 unsigned int ew = (ewI & 0xfe00ffff ) | ( (ewS & 0x000001ff)<<16 ); 00076 digi.setData(dw,ew); 00077 int de = (aflag==4)?0:itd->compressedEt() ; 00078 int ee = (aflag==3)?0:itm->compressedEt() ; 00079 digi.setRank((float)de,(float)ee); 00080 L1MonitorDigi dedata(dedefs::ETP,cid, itd->id().iphi(),itd->id().ieta(),0, 00081 itd->compressedEt(),itd->id().rawId()); 00082 L1MonitorDigi deemul(dedefs::ETP,cid, itm->id().iphi(),itm->id().ieta(),0, 00083 itm->compressedEt(),itm->id().rawId()); 00084 digi.setDEpair(dedata,deemul); 00085 return digi; 00086 }
L1DataEmulDigi DEutils< T >::DEDigi | ( | col_cit | itd, | |
col_cit | itm, | |||
int | ctype | |||
) | [inline] |
--- form de-digi ---
return empty digi by default
Definition at line 54 of file DEutils.h.
00054 { 00056 return L1DataEmulDigi(); 00057 }
--- name candidate ---
Definition at line 1179 of file DEutils.h.
References dedefs::CSCsta, dedefs::CSCtpa, dedefs::CSCtpc, dedefs::CSCtpl, DEutils< T >::de_type(), dedefs::DTtpPh, dedefs::DTtpTh, dedefs::ECALtp, dedefs::GCTcenjets, dedefs::GCTforjets, dedefs::GCTisolaem, dedefs::GCTnoisoem, dedefs::GCTtaujets, dedefs::GMTcnd, dedefs::GMTrdt, dedefs::GTdword, dedefs::HCALtp, i, dedefs::LTCi, dedefs::MUrtf, dedefs::RCTem, and dedefs::RCTrgn.
01179 { 01180 01181 const int nlabel = 16; 01182 if(!(i<nlabel)) 01183 return "un-defined" ; 01184 std::string str[nlabel]= {"un-registered"}; 01185 01186 switch(de_type()) { 01187 case dedefs::ECALtp: 01188 str[0] = "ECAL tp"; 01189 str[1] = "EcalTrigPrimDigiCollection"; 01190 str[2] = "EcalTriggerPrimitiveDigi"; 01191 break; 01192 case dedefs::HCALtp: 01193 str[0] = "HCAL tp"; 01194 str[1] = "HcalTrigPrimDigiCollection"; 01195 str[2] = "HcalTriggerPrimitiveDigi"; 01196 break; 01197 case dedefs::RCTem: 01198 str[0] = "RCT em"; 01199 str[1] = "L1CaloEmCollection"; 01200 str[2] = "L1CaloEmCand"; 01201 break; 01202 case dedefs::RCTrgn: 01203 str[0] = "RCT region"; 01204 str[1] = "L1CaloRegionCollection"; 01205 str[2] = "L1CaloRegion"; 01206 break; 01207 case dedefs::GCTisolaem: 01208 str[0] = "GCT em isolated"; 01209 str[1] = "L1GctEmCandCollection"; 01210 str[2] = "L1GctEmCand"; 01211 break; 01212 case dedefs::GCTnoisoem: 01213 str[0] = "GCT em non-isolated"; 01214 str[1] = "L1GctEmCandCollection"; 01215 str[2] = "L1GctEmCand"; 01216 break; 01217 case dedefs::GCTcenjets: 01218 str[0] = "GCT central jet"; 01219 str[1] = "L1GctJetCandCollection"; 01220 str[2] = "L1GctJetCand"; 01221 break; 01222 case dedefs::GCTforjets: 01223 str[0] = "GCT forward jet"; 01224 str[1] = "L1GctJetCandCollection"; 01225 str[2] = "L1GctJetCand"; 01226 break; 01227 case dedefs::GCTtaujets: 01228 str[0] = "GCT tau jet"; 01229 str[1] = "L1GctJetCandCollection"; 01230 str[2] = "L1GctJetCand"; 01231 break; 01232 case dedefs::DTtpPh: 01233 str[0] = "DT tp phi"; 01234 str[1] = "L1MuDTChambPhDigiCollection"; 01235 str[2] = "L1MuDTChambPhDigi"; 01236 break; 01237 case dedefs::DTtpTh: 01238 str[0] = "DT tp theta"; 01239 str[1] = "L1MuDTChambThDigiCollection"; 01240 str[2] = "L1MuDTChambThDigi"; 01241 break; 01242 case dedefs::CSCtpa: 01243 str[0] = "CSC tpa"; 01244 str[1] = "CSCALCTDigiCollection"; 01245 str[2] = "CSCALCTDigi"; 01246 break; 01247 case dedefs::CSCtpc: 01248 str[0] = "CSC tpc"; 01249 str[1] = "CSCCLCTDigiCollection"; 01250 str[2] = "CSCCLCTDigi"; 01251 break; 01252 case dedefs::CSCtpl: 01253 str[0] = "CSC tp"; 01254 str[1] = "CSCCorrelatedLCTDigiCollection"; 01255 str[2] = "CSCCorrelatedLCTDigi"; 01256 break; 01257 case dedefs::CSCsta: 01258 str[0] = "CSC tf status"; 01259 str[1] = "L1CSCSPStatusDigiCollection_"; 01260 str[2] = "L1CSCSPStatusDigi"; 01261 break; 01262 case dedefs::MUrtf: 01263 str[0] = "Mu reg tf"; 01264 str[1] = "L1MuRegionalCandCollection"; 01265 str[2] = "L1MuRegionalCand"; 01266 break; 01267 case dedefs::LTCi: 01268 str[0] = "LTC"; 01269 str[1] = "LTCDigiCollection"; 01270 str[2] = "LTCDigi"; 01271 break; 01272 case dedefs::GMTcnd: 01273 str[0] = "GMT cand"; 01274 str[1] = "L1MuGMTCandCollection"; 01275 str[2] = "L1MuGMTCand"; 01276 break; 01277 case dedefs::GMTrdt: 01278 str[0] = "GMT record"; 01279 str[1] = "L1MuGMTReadoutRecordCollection"; 01280 str[2] = "L1MuGMTReadoutRecord"; 01281 break; 01282 case dedefs::GTdword: 01283 str[0] = ""; 01284 str[1] = ""; 01285 str[2] = ""; 01286 break; 01287 //default: 01288 } 01289 return str[i]; 01290 }
bool DEutils< L1CSCSPStatusDigiCollection_ >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< CSCCLCTDigiCollection_ >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< CSCALCTDigiCollection_ >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< CSCCorrelatedLCTDigiCollection_ >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1MuGMTCandCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1MuRegionalCandCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
Definition at line 887 of file DEutils.h.
00887 { 00888 //note: following call used to give trouble sometimes 00889 return (it->empty()); 00890 //virtual bool empty() const { return readDataField( PT_START, PT_LENGTH) == 0; } 00891 //return (it->getDataWord()==0); 00892 //return (it->pt_packed()==0); 00893 }
bool DEutils< L1MuDTChambThDigiCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1MuDTChambPhDigiCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1GctJetCandCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1GctEmCandCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1CaloRegionCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< L1CaloEmCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< HcalTrigPrimDigiCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
bool DEutils< EcalTrigPrimDigiCollection >::is_empty | ( | col_cit | it | ) | const [inline] |
Definition at line 836 of file DEutils.h.
00836 { 00837 bool val = false; 00838 val |= ((it->sample(it->sampleOfInterest()).raw()&0x0fff)==0); 00839 if(val) return val; 00840 unsigned int ttf = it->ttFlag(); 00841 val |= ((ttf!=0x1) && (ttf!=0x3)); //compare only if ttf is 1 or 3 00842 return val; 00843 // return ( it->size()==0 || it->sample(it->sampleOfInterest()).raw()==0); 00844 }
std::string DEutils< L1CSCSPStatusDigiCollection_ >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 1161 of file DEutils.h.
References lat::endl(), and ss.
01161 { 01162 std::stringstream ss; 01163 ss 01164 << " slot:"<< it->slot() 01165 << " bxn:" << it->BXN () 01166 << " fmm:" << it->FMM () 01167 << " ses:" << it->SEs () 01168 << " sms:" << it->SMs () 01169 << " bxs:" << it->BXs () 01170 << " afs:" << it->AFs () 01171 << " vps:" << it->VPs () 01172 << std::endl; 01173 return ss.str(); 01174 }
std::string DEutils< CSCCLCTDigiCollection_ >::print | ( | col_cit | it | ) | const [inline] |
std::string DEutils< CSCALCTDigiCollection_ >::print | ( | col_cit | it | ) | const [inline] |
std::string DEutils< CSCCorrelatedLCTDigiCollection_ >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 1124 of file DEutils.h.
References ss.
01124 { 01125 std::stringstream ss; 01126 ss 01127 //<< " lct#:" << it->getTrknmb() 01128 //<< " val:" << it->isValid() 01129 //<< " qua:" << it->getQuality() 01130 //<< " strip:" << it->getStrip() 01131 //<< " bend:" << ((it->getBend() == 0) ? 'L' : 'R') 01132 //<< " patt:" << it->getPattern() 01133 //<<" key wire:" << it->getKeyWG() 01134 //<< " bx:" << it->getBX() 01135 //<< " mpc-link:" << it->getMPCLink() 01136 //<< " csc id:" << it->getCSCID() 01137 //<< std::endl; 01138 << *it; 01139 return ss.str(); 01140 }
std::string DEutils< L1MuGMTCandCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 1096 of file DEutils.h.
References lat::endl(), and ss.
01096 { 01097 std::stringstream ss; 01098 ss << std::setiosflags(std::ios::showpoint | std::ios::fixed | std::ios::right | std::ios::adjustfield); 01099 //const float noval = -10; //L1MuGMTCand::m_invalidValue; 01100 ss << std::hex << std::setfill('0') 01101 << " 0x" << std::setw(7) << it->getDataWord(); 01102 //if(it->phiValue()==noval || it->etaValue()==noval || it->ptValue()==noval) 01103 ss << std::hex << std::setfill('0') 01104 << " pt:0x" << std::setw(2) << it->ptIndex() 01105 << " eta:0x"<< std::setw(2) << it->etaIndex() 01106 << " phi:0x"<< std::setw(3) << it->phiIndex(); 01107 //else 01108 // ss << std::dec << std::setfill(' ') 01109 // << " pt:" << std::setw(5) << std::setprecision(1) << it->ptValue() <<"[GeV]" 01110 // << " phi:" << std::setw(5) << std::setprecision(3) << it->phiValue()<<"[rad]" 01111 // << " eta:" << std::setw(6) << std::setprecision(2) << it->etaValue(); 01112 ss << std::dec << std::setfill(' ') 01113 << " cha:" << std::setw(2) << it->charge() 01114 << " qua:" << std::setw(3) << it->quality() 01115 << " iso:" << std::setw(1) << it->isol() 01116 << " mip:" << std::setw(1) << it->mip() 01117 << " bx:" << it->bx() 01118 << std::endl; 01119 //ss << it->print() 01120 return ss.str(); 01121 }
std::string DEutils< L1MuRegionalCandCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 1067 of file DEutils.h.
References lat::endl(), and ss.
01067 { 01068 std::stringstream ss; 01069 //const float noval = -10; //L1MuRegionalCand::m_invalidValue; 01070 ss << std::setiosflags(std::ios::showpoint | std::ios::fixed | std::ios::right | std::ios::adjustfield); 01071 ss << std::hex << std::setfill('0') 01072 << " 0x" << std::setw(8) << it->getDataWord(); 01073 //if(it->phiValue()==noval || it->etaValue()==noval || it->ptValue()==noval ) 01074 ss << std::hex << std::setfill('0') 01075 << " pt:0x" << std::setw(2) << it->pt_packed() 01076 << " phi:0x"<< std::setw(2) << it->phi_packed() 01077 << " eta:0x"<< std::setw(2) << it->eta_packed(); 01078 //else 01079 // ss << std::dec << std::setfill(' ') 01080 // << " pt:" << std::setw(5) << std::setprecision(1) << it->ptValue() <<"[GeV]" 01081 // << " phi:" << std::setw(5) << std::setprecision(3) << it->phiValue()<<"[rad]" 01082 // << " eta:" << std::setw(6) << std::setprecision(3) << it->etaValue(); 01083 ss << std::dec << std::setfill(' ') 01084 << " qua:" << std::setw(1) << it->quality() 01085 << " cha:" << std::setw(2) << it->chargeValue() 01086 << " chav:" << std::setw(1) << it->chargeValid() 01087 << " fh:" << std::setw(1) << it->isFineHalo() 01088 << " bx:" << std::setw(4) << it->bx() 01089 << " [id:" << std::setw(1) << it->type_idx() << "]" // 0 DT, 1 bRPC, 2 CSC, 3 fRPC 01090 << std::endl; 01091 //ss << it->print() 01092 return ss.str(); 01093 }
std::string DEutils< L1MuDTChambThDigiCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 1054 of file DEutils.h.
References lat::endl(), and ss.
01054 { 01055 std::stringstream ss; 01056 ss << "" 01057 << " bxNum:" << it->bxNum() 01058 << " whNum:" << it->whNum() 01059 << " scNum:" << it->scNum() 01060 << " stNum:" << it->stNum() 01061 << std::endl; 01062 //nb: operator << not implemented in base class L1MuDTChambThDigi 01063 return ss.str(); 01064 }
std::string DEutils< L1MuDTChambPhDigiCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 1036 of file DEutils.h.
References lat::endl(), and ss.
01036 { 01037 std::stringstream ss; 01038 ss << "" 01039 << " bxNum:" << it->bxNum() 01040 << " whNum:" << it->whNum() 01041 << " scNum:" << it->scNum() 01042 << " stNum:" << it->stNum() 01043 << " phi:" << it->phi() 01044 << " phiB:" << it->phiB() 01045 << " code:" << it->code() 01046 << " Ts2Tag:" << it->Ts2Tag() 01047 << " BxCnt:" << it->BxCnt() 01048 << std::endl; 01049 //nb: operator << not implemented in base class L1MuDTChambPhDigi 01050 return ss.str(); 01051 }
std::string DEutils< L1GctJetCandCollection >::print | ( | col_cit | it | ) | const [inline] |
std::string DEutils< L1GctEmCandCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 999 of file DEutils.h.
References lat::endl(), and ss.
00999 { 01000 std::stringstream ss; 01001 //get rct index 01002 //int ieta = (it->etaIndex()&0x7); ieta = it->etaSign() ? 10-ieta:11+ieta; 01003 ss << "0x" << std::setw(4) << std::setfill('0') << std::hex << it->raw() 01004 << ", rank=0x"<< std::setw(2) << std::hex << it->rank() 01005 << std::setfill(' ') << std::dec 01006 << ", etaSign:" << it->etaSign() 01007 << ", eta:" << (it->etaIndex()&0x7) //0..6 01008 << ", phi:" << std::setw(2) << it->phiIndex() //0..17 01009 << " (ieta:" << std::setw(2) << it->regionId().ieta() //0..21 01010 << ",iphi:" << std::setw(2) << it->regionId().iphi() << ")" //0..17 01011 << ", iso:" << it->isolated() 01012 << ", cap block:" << std::setw(3) << it->capBlock() 01013 << ", index:" << it->capIndex() 01014 << ", bx:" << it->bx() 01015 << std::endl; 01016 //<< " " << *it << std::dec << std::endl; 01017 return ss.str(); 01018 }
std::string DEutils< L1CaloRegionCollection >::print | ( | col_cit | it | ) | const [inline] |
std::string DEutils< L1CaloEmCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 970 of file DEutils.h.
References lat::endl(), and ss.
00970 { 00971 std::stringstream ss; 00972 ss << "0x" << std::setw(4) << std::setfill('0') << std::hex << it->raw() 00973 << ", rank=0x"<< std::setw(2) << std::hex << it->rank() 00974 << std::setfill(' ') << std::dec 00975 << ", region:"<< std::setw(1) << it->rctRegion() 00976 << ", card:" << std::setw(1) << it->rctCard() 00977 << ", crate:" << std::setw(2) << it->rctCrate() 00978 << ", ieta:" << std::setw(2) << it->regionId().ieta() //0..21 00979 << ", iphi:" << std::setw(2) << it->regionId().iphi() //0..17 00980 //<< ", eta:" << std::setw(2) << it->regionId().rctEta() //0..10 00981 //<< ", phi:" << std::setw(2) << it->regionId().rctPhi() //0..1 00982 << ", iso:" << std::setw(1) << it->isolated() 00983 << ", index:" << std::setw(1) << it->index() 00984 << ", bx:" << it->bx() 00985 << std::endl; 00986 //ss << *it; 00987 return ss.str(); 00988 }
std::string DEutils< HcalTrigPrimDigiCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 953 of file DEutils.h.
References lat::endl(), and ss.
00953 { 00954 std::stringstream ss; 00955 ss << "0x" << std::setw(4) << std::setfill('0') << std::hex 00956 << it->t0().raw() 00957 << std::setfill(' ') << std::dec 00958 << ", et:" << std::setw(3) << it->SOI_compressedEt() 00959 << ", fg:" << std::setw(1) << it->SOI_fineGrain() 00960 << ", sdet:" << it->id().subdet() 00961 << ", iz:" << ((it->id().zside()>0)?("+"):("-")) 00962 << ", ieta:" << std::setw(2) << it->id().ietaAbs() 00963 << ", iphi:" << std::setw(2) << it->id().iphi() 00964 << std::endl; 00965 //ss << *it << std::endl; 00966 return ss.str(); 00967 }
std::string DEutils< EcalTrigPrimDigiCollection >::print | ( | col_cit | it | ) | const [inline] |
Definition at line 935 of file DEutils.h.
References EcalBarrel, lat::endl(), and ss.
00935 { 00936 std::stringstream ss; 00937 ss << "0x" << std::setw(4) << std::setfill('0') << std::hex 00938 << it->sample(it->sampleOfInterest()).raw() 00939 << std::setfill(' ') << std::dec 00940 << ", et:" << std::setw(3) << it->compressedEt() 00941 << ", fg:" << std::setw(1) << it->fineGrain() 00942 << ", ttf:" << std::setw(2) << it->ttFlag() 00943 << ", sdet:" << ((it->id().subDet()==EcalBarrel)?("Barrel"):("Endcap")) 00944 << ", iz:" << ((it->id().zside()>0)?("+"):("-")) 00945 << ", ieta:" << std::setw(2) << it->id().ietaAbs() 00946 << ", iphi:" << std::setw(2) << it->id().iphi() 00947 //<< "\n\t: " << *it 00948 << std::endl; 00949 return ss.str(); 00950 }