CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
l1t::MicroGMTRelativeIsolationCheckLUT Class Reference

#include <MicroGMTRelativeIsolationCheckLUT.h>

Inheritance diagram for l1t::MicroGMTRelativeIsolationCheckLUT:
l1t::MicroGMTLUT l1t::LUT

Public Member Functions

int hashInput (int energySum, int pt) const
 
int lookup (int energySum, int pt) const
 
 MicroGMTRelativeIsolationCheckLUT ()
 
 MicroGMTRelativeIsolationCheckLUT (const std::string &fname)
 
void unHashInput (int input, int &energySum, int &pt) const
 
virtual ~MicroGMTRelativeIsolationCheckLUT ()
 
- Public Member Functions inherited from l1t::MicroGMTLUT
int checkedInput (unsigned in, unsigned maxWidth) const
 
void initialize ()
 
int load (const std::string &inFileName)
 
virtual int lookupPacked (int input) const
 
 MicroGMTLUT ()
 
void save (std::ofstream &output)
 
virtual ~MicroGMTLUT ()
 
- Public Member Functions inherited from l1t::LUT
int data (unsigned int address) const
 
bool empty () const
 
 LUT ()
 
 LUT (std::istream &stream)
 
unsigned int maxSize () const
 
unsigned int nrBitsAddress () const
 
unsigned int nrBitsData () const
 
int read (std::istream &stream)
 
void write (std::ostream &stream) const
 
 ~LUT ()
 

Private Attributes

int m_energySumInWidth
 
int m_energySumMask
 
int m_ptInWidth
 
int m_ptMask
 

Additional Inherited Members

- Public Types inherited from l1t::LUT
enum  ReadCodes {
  SUCCESS =0, NO_ENTRIES =1, DUP_ENTRIES =2, MISS_ENTRIES =3,
  MAX_ADDRESS_OUTOFRANGE =4, NO_HEADER =5
}
 
- Protected Attributes inherited from l1t::MicroGMTLUT
bool m_initialized
 
std::vector
< MicroGMTConfiguration::input_t
m_inputs
 
unsigned m_outWidth
 
unsigned m_totalInWidth
 

Detailed Description

Definition at line 8 of file MicroGMTRelativeIsolationCheckLUT.h.

Constructor & Destructor Documentation

l1t::MicroGMTRelativeIsolationCheckLUT::MicroGMTRelativeIsolationCheckLUT ( )
inline

Definition at line 10 of file MicroGMTRelativeIsolationCheckLUT.h.

10 {};
l1t::MicroGMTRelativeIsolationCheckLUT::MicroGMTRelativeIsolationCheckLUT ( const std::string &  fname)
explicit

Definition at line 3 of file MicroGMTRelativeIsolationCheckLUT.cc.

References l1t::MicroGMTConfiguration::ENERGYSUM, l1t::MicroGMTLUT::load(), m_energySumInWidth, m_energySumMask, l1t::MicroGMTLUT::m_inputs, l1t::MicroGMTLUT::m_outWidth, m_ptInWidth, m_ptMask, l1t::MicroGMTLUT::m_totalInWidth, l1t::MicroGMTConfiguration::PT, and AlCaHLTBitMon_QueryRunRegistry::string.

4 {
6  m_outWidth = 1;
7 
9  m_ptMask = ((1 << m_ptInWidth) - 1) << m_energySumInWidth;
10  if (fname != std::string("")) {
11  load(fname);
12  }
15 }
unsigned m_totalInWidth
Definition: MicroGMTLUT.h:33
int load(const std::string &inFileName)
Definition: MicroGMTLUT.cc:14
std::vector< MicroGMTConfiguration::input_t > m_inputs
Definition: MicroGMTLUT.h:35
string fname
main script
unsigned m_outWidth
Definition: MicroGMTLUT.h:34
virtual l1t::MicroGMTRelativeIsolationCheckLUT::~MicroGMTRelativeIsolationCheckLUT ( )
inlinevirtual

Definition at line 12 of file MicroGMTRelativeIsolationCheckLUT.h.

12 {};

Member Function Documentation

int l1t::MicroGMTRelativeIsolationCheckLUT::hashInput ( int  energySum,
int  pt 
) const

Definition at line 25 of file MicroGMTRelativeIsolationCheckLUT.cc.

References mps_fire::result.

26 {
27  int result = 0;
28  result += energySum << m_ptInWidth;
29  result += pT;
30  return result;
31 }
tuple result
Definition: mps_fire.py:95
double energySum(const DataFrame &df, int fs, int ls)
int l1t::MicroGMTRelativeIsolationCheckLUT::lookup ( int  energySum,
int  pt 
) const

Definition at line 18 of file MicroGMTRelativeIsolationCheckLUT.cc.

19 {
20  // normalize these two to the same scale and then calculate?
22 }
virtual int lookupPacked(int input) const
Definition: MicroGMTLUT.cc:30
int checkedInput(unsigned in, unsigned maxWidth) const
Definition: MicroGMTLUT.cc:55
double energySum(const DataFrame &df, int fs, int ls)
void l1t::MicroGMTRelativeIsolationCheckLUT::unHashInput ( int  input,
int &  energySum,
int &  pt 
) const

Member Data Documentation

int l1t::MicroGMTRelativeIsolationCheckLUT::m_energySumInWidth
private
int l1t::MicroGMTRelativeIsolationCheckLUT::m_energySumMask
private
int l1t::MicroGMTRelativeIsolationCheckLUT::m_ptInWidth
private
int l1t::MicroGMTRelativeIsolationCheckLUT::m_ptMask
private