CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Attributes | Protected Member Functions | Private Attributes | Friends
L1GctHfBitCountsLut Class Reference

LUT for compression of HF feature bit counts to output format. More...

#include <L1GctHfBitCountsLut.h>

Inheritance diagram for L1GctHfBitCountsLut:
L1GctLut< 5, 3 >

Public Member Functions

std::vector< unsigned > getThresholdsGct () const
 Get thresholds. More...
 
 L1GctHfBitCountsLut (const L1GctHfEtSumsLut::hfLutType &type)
 Constructor for use with emulator - which type of Lut? More...
 
 L1GctHfBitCountsLut ()
 Default constructor. More...
 
 L1GctHfBitCountsLut (const L1GctHfBitCountsLut &lut)
 Copy constructor. More...
 
L1GctHfEtSumsLut::hfLutType lutType () const
 Return the type of Lut. More...
 
L1GctHfBitCountsLut operator= (const L1GctHfBitCountsLut &lut)
 Overload = operator. More...
 
 ~L1GctHfBitCountsLut () override
 Destructor. More...
 
- Public Member Functions inherited from L1GctLut< 5, 3 >
uint16_t lutValue (const uint16_t lutAddress) const
 Access the look-up table contents for a given Address. More...
 
int operator!= (const L1GctLut< KAddressBits, KDataBits > &rhsLut) const
 Inequality check between look-up tables. More...
 
int operator== (const L1GctLut< KAddressBits, KDataBits > &rhsLut) const
 Equality check between look-up tables. More...
 
uint16_t operator[] (const uint16_t lutAddress) const
 Access the look-up table contents for a given Address. More...
 
void setTerse ()
 
bool setupOk ()
 
void setVerbose ()
 control output messages More...
 
virtual ~L1GctLut ()
 

Static Public Attributes

static const int NAddress = 5
 
static const int NData = 3
 
- Static Public Attributes inherited from L1GctLut< 5, 3 >
static const uint16_t MAX_ADDRESS_BITMASK
 
static const uint16_t MAX_DATA_BITMASK
 

Protected Member Functions

uint16_t value (const uint16_t lutAddress) const override
 
- Protected Member Functions inherited from L1GctLut< 5, 3 >
bool equalityCheck (const L1GctLut< KAddressBits, KDataBits > &c) const
 
 L1GctLut ()
 

Private Attributes

L1GctHfEtSumsLut::hfLutType m_lutType
 

Friends

std::ostream & operator<< (std::ostream &os, const L1GctHfBitCountsLut &lut)
 Overload << operator. More...
 

Additional Inherited Members

- Protected Attributes inherited from L1GctLut< 5, 3 >
bool m_setupOk
 
bool m_verbose
 

Detailed Description

LUT for compression of HF feature bit counts to output format.

Author
Greg Heath
Date
September 2008

Definition at line 19 of file L1GctHfBitCountsLut.h.

Constructor & Destructor Documentation

L1GctHfBitCountsLut::L1GctHfBitCountsLut ( const L1GctHfEtSumsLut::hfLutType type)

Constructor for use with emulator - which type of Lut?

Definition at line 7 of file L1GctHfBitCountsLut.cc.

References L1GctLut< 5, 3 >::m_setupOk.

9  // No setup required
10  m_setupOk = true;
11 }
Base class for LookUp Tables.
Definition: L1GctLut.h:19
L1GctHfEtSumsLut::hfLutType m_lutType
L1GctHfBitCountsLut::L1GctHfBitCountsLut ( )

Default constructor.

Definition at line 13 of file L1GctHfBitCountsLut.cc.

References L1GctLut< 5, 3 >::m_setupOk.

14  // No setup required
15  m_setupOk = true;
16 }
Base class for LookUp Tables.
Definition: L1GctLut.h:19
L1GctHfEtSumsLut::hfLutType m_lutType
L1GctHfBitCountsLut::L1GctHfBitCountsLut ( const L1GctHfBitCountsLut lut)

Copy constructor.

Definition at line 18 of file L1GctHfBitCountsLut.cc.

References L1GctLut< 5, 3 >::m_setupOk.

20  // No setup required
21  m_setupOk = true;
22 }
L1GctHfEtSumsLut::hfLutType lutType() const
Return the type of Lut.
Base class for LookUp Tables.
Definition: L1GctLut.h:19
L1GctHfEtSumsLut::hfLutType m_lutType
L1GctHfBitCountsLut::~L1GctHfBitCountsLut ( )
override

Destructor.

Definition at line 24 of file L1GctHfBitCountsLut.cc.

24 {}

Member Function Documentation

std::vector< unsigned > L1GctHfBitCountsLut::getThresholdsGct ( ) const

Get thresholds.

Definition at line 35 of file L1GctHfBitCountsLut.cc.

References PVValHelper::add(), NData, and mps_fire::result.

35  {
36  std::vector<unsigned> result;
37  // Return "address=data" up to the maximum number of output codes
38  for (unsigned add = 1; add < (1 << NData); add++) {
39  result.push_back(add);
40  }
41  return result;
42 }
static const int NData
tuple result
Definition: mps_fire.py:311
void add(std::map< std::string, TH1 * > &h, TH1 *hist)
L1GctHfEtSumsLut::hfLutType L1GctHfBitCountsLut::lutType ( ) const
inline

Return the type of Lut.

Definition at line 42 of file L1GctHfBitCountsLut.h.

References m_lutType.

42 { return m_lutType; }
L1GctHfEtSumsLut::hfLutType m_lutType
L1GctHfBitCountsLut L1GctHfBitCountsLut::operator= ( const L1GctHfBitCountsLut lut)

Overload = operator.

Definition at line 44 of file L1GctHfBitCountsLut.cc.

References groupFilesInBlocks::temp.

44  {
45  const L1GctHfBitCountsLut& temp(lut);
46  return temp;
47 }
LUT for compression of HF feature bit counts to output format.
uint16_t L1GctHfBitCountsLut::value ( const uint16_t  lutAddress) const
overrideprotectedvirtual

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const L1GctHfBitCountsLut lut 
)
friend

Overload << operator.

Definition at line 49 of file L1GctHfBitCountsLut.cc.

49  {
50  os << "===L1GctHfBitCountsLut===" << std::endl;
51  os << "\n===Lookup table contents===\n" << std::endl;
53  os << *temp;
54  return os;
55 }
Base class for LookUp Tables.
Definition: L1GctLut.h:19

Member Data Documentation

L1GctHfEtSumsLut::hfLutType L1GctHfBitCountsLut::m_lutType
private

Definition at line 51 of file L1GctHfBitCountsLut.h.

Referenced by lutType().

const int L1GctHfBitCountsLut::NAddress = 5
static

Definition at line 24 of file L1GctHfBitCountsLut.h.

const int L1GctHfBitCountsLut::NData = 3
static

Definition at line 24 of file L1GctHfBitCountsLut.h.

Referenced by getThresholdsGct(), and value().