CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Member Functions | Private Attributes
l1t::VertexWord Class Reference

#include <VertexWord.h>

Public Types

enum  VertexBitLocations {
  kValidLSB = 0, kValidMSB = kValidLSB + VertexBitWidths::kValidSize - 1, kZ0LSB = kValidMSB + 1, kZ0MSB = kZ0LSB + VertexBitWidths::kZ0Size - 1,
  kNTrackInPVLSB = kZ0MSB + 1, kNTrackInPVMSB = kNTrackInPVLSB + VertexBitWidths::kNTrackInPVSize - 1, kSumPtLSB = kNTrackInPVMSB + 1, kSumPtMSB = kSumPtLSB + VertexBitWidths::kSumPtSize - 1,
  kQualityLSB = kSumPtMSB + 1, kQualityMSB = kQualityLSB + VertexBitWidths::kQualitySize - 1, kNTrackOutPVLSB = kQualityMSB + 1, kNTrackOutPVMSB = kNTrackOutPVLSB + VertexBitWidths::kNTrackOutPVSize - 1,
  kUnassignedLSB = kNTrackOutPVMSB + 1, kUnassignedMSB = kUnassignedLSB + VertexBitWidths::kUnassignedSize - 1
}
 
enum  VertexBitWidths {
  kValidSize = 1, kZ0Size = 15, kZ0MagSize = 6, kNTrackInPVSize = 8,
  kSumPtSize = 12, kSumPtMagSize = 10, kQualitySize = 3, kNTrackOutPVSize = 10,
  kUnassignedSize = 15, kVertexWordSize
}
 
typedef edm::Ref< l1t::VertexCollectionVertexRef
 
typedef ap_ufixed< VertexBitWidths::kNTrackOutPVSize, VertexBitWidths::kNTrackOutPVSize, AP_RND_CONV, AP_SAT > vtxinversemult_t
 
typedef ap_ufixed< VertexBitWidths::kNTrackInPVSize, VertexBitWidths::kNTrackInPVSize, AP_RND_CONV, AP_SAT > vtxmultiplicity_t
 
typedef ap_uint< VertexBitWidths::kQualitySize > vtxquality_t
 
typedef ap_ufixed< VertexBitWidths::kSumPtSize, VertexBitWidths::kSumPtMagSize, AP_RND_CONV, AP_SAT > vtxsumpt_t
 
typedef ap_uint< VertexBitWidths::kUnassignedSize > vtxunassigned_t
 
typedef ap_uint< VertexBitWidths::kValidSize > vtxvalid_t
 
typedef std::bitset< VertexBitWidths::kVertexWordSize > vtxword_bs_t
 
typedef ap_uint< VertexBitWidths::kVertexWordSize > vtxword_t
 
typedef ap_fixed< VertexBitWidths::kZ0Size, VertexBitWidths::kZ0MagSize, AP_RND_CONV, AP_SAT > vtxz0_t
 

Public Member Functions

unsigned int inverseMultiplicity () const
 
unsigned int inverseMultiplicityBits () const
 
vtxinversemult_t inverseMultiplicityWord () const
 
unsigned int multiplicity () const
 
unsigned int multiplicityBits () const
 
vtxmultiplicity_t multiplicityWord () const
 
VertexWordoperator= (const VertexWord &word)
 
double pt () const
 
unsigned int ptBits () const
 
vtxsumpt_t ptWord () const
 
unsigned int quality () const
 
unsigned int qualityBits () const
 
vtxquality_t qualityWord () const
 
void setVertexRef (const VertexRef &ref)
 
void setVertexWord (vtxvalid_t valid, vtxz0_t z0, vtxmultiplicity_t multiplicity, vtxsumpt_t pt, vtxquality_t quality, vtxinversemult_t inverseMultiplicity, vtxunassigned_t unassigned)
 
unsigned int unassigned () const
 
unsigned int unassignedBits () const
 
vtxunassigned_t unassignedWord () const
 
bool valid () const
 
unsigned int validBits () const
 
vtxvalid_t validWord () const
 
VertexRef vertexRef () const
 
 VertexWord ()
 
 VertexWord (unsigned int valid, double z0, unsigned int multiplicity, double pt, unsigned int quality, unsigned int inverseMultiplicity, unsigned int unassigned)
 
 VertexWord (unsigned int valid, unsigned int z0, unsigned int multiplicity, unsigned int pt, unsigned int quality, unsigned int inverseMultiplicity, unsigned int unassigned)
 
 VertexWord (vtxvalid_t valid, vtxz0_t z0, vtxmultiplicity_t multiplicity, vtxsumpt_t pt, vtxquality_t quality, vtxinversemult_t inverseMultiplicity, vtxunassigned_t unassigned)
 
 VertexWord (const VertexWord &word)
 
vtxword_t vertexWord () const
 
double z0 () const
 
unsigned int z0Bits () const
 
vtxz0_t z0Word () const
 
 ~VertexWord ()
 

Private Member Functions

double unpackSignedValue (unsigned int bits, unsigned int nBits, double lsb) const
 

Private Attributes

VertexRef vertexRef_
 
vtxword_bs_t vertexWord_
 

Detailed Description

Definition at line 26 of file VertexWord.h.

Member Typedef Documentation

◆ VertexRef

Definition at line 80 of file VertexWord.h.

◆ vtxinversemult_t

typedef ap_ufixed<VertexBitWidths::kNTrackOutPVSize, VertexBitWidths::kNTrackOutPVSize, AP_RND_CONV, AP_SAT> l1t::VertexWord::vtxinversemult_t

Definition at line 72 of file VertexWord.h.

◆ vtxmultiplicity_t

typedef ap_ufixed<VertexBitWidths::kNTrackInPVSize, VertexBitWidths::kNTrackInPVSize, AP_RND_CONV, AP_SAT> l1t::VertexWord::vtxmultiplicity_t

Definition at line 67 of file VertexWord.h.

◆ vtxquality_t

typedef ap_uint<VertexBitWidths::kQualitySize> l1t::VertexWord::vtxquality_t

Definition at line 70 of file VertexWord.h.

◆ vtxsumpt_t

typedef ap_ufixed<VertexBitWidths::kSumPtSize, VertexBitWidths::kSumPtMagSize, AP_RND_CONV, AP_SAT> l1t::VertexWord::vtxsumpt_t

Definition at line 69 of file VertexWord.h.

◆ vtxunassigned_t

typedef ap_uint<VertexBitWidths::kUnassignedSize> l1t::VertexWord::vtxunassigned_t

Definition at line 73 of file VertexWord.h.

◆ vtxvalid_t

typedef ap_uint<VertexBitWidths::kValidSize> l1t::VertexWord::vtxvalid_t

Definition at line 64 of file VertexWord.h.

◆ vtxword_bs_t

typedef std::bitset<VertexBitWidths::kVertexWordSize> l1t::VertexWord::vtxword_bs_t

Definition at line 76 of file VertexWord.h.

◆ vtxword_t

typedef ap_uint<VertexBitWidths::kVertexWordSize> l1t::VertexWord::vtxword_t

Definition at line 77 of file VertexWord.h.

◆ vtxz0_t

typedef ap_fixed<VertexBitWidths::kZ0Size, VertexBitWidths::kZ0MagSize, AP_RND_CONV, AP_SAT> l1t::VertexWord::vtxz0_t

Definition at line 65 of file VertexWord.h.

Member Enumeration Documentation

◆ VertexBitLocations

Enumerator
kValidLSB 
kValidMSB 
kZ0LSB 
kZ0MSB 
kNTrackInPVLSB 
kNTrackInPVMSB 
kSumPtLSB 
kSumPtMSB 
kQualityLSB 
kQualityMSB 
kNTrackOutPVLSB 
kNTrackOutPVMSB 
kUnassignedLSB 
kUnassignedMSB 

Definition at line 45 of file VertexWord.h.

45  {
46  // The location of the least significant bit (LSB) and most significant bit (MSB) in the vertex word for different fields
47  kValidLSB = 0,
49  kZ0LSB = kValidMSB + 1,
50  kZ0MSB = kZ0LSB + VertexBitWidths::kZ0Size - 1,
51  kNTrackInPVLSB = kZ0MSB + 1,
52  kNTrackInPVMSB = kNTrackInPVLSB + VertexBitWidths::kNTrackInPVSize - 1,
54  kSumPtMSB = kSumPtLSB + VertexBitWidths::kSumPtSize - 1,
55  kQualityLSB = kSumPtMSB + 1,
56  kQualityMSB = kQualityLSB + VertexBitWidths::kQualitySize - 1,
58  kNTrackOutPVMSB = kNTrackOutPVLSB + VertexBitWidths::kNTrackOutPVSize - 1,
61  };
const unsigned int kValidSize
const unsigned int kUnassignedSize

◆ VertexBitWidths

Enumerator
kValidSize 
kZ0Size 
kZ0MagSize 
kNTrackInPVSize 
kSumPtSize 
kSumPtMagSize 
kQualitySize 
kNTrackOutPVSize 
kUnassignedSize 
kVertexWordSize 

Definition at line 29 of file VertexWord.h.

29  {
30  // The sizes of the vertex word components and total word size
31  kValidSize = 1, // Width of the valid bit
32  kZ0Size = 15, // Width of z-position
33  kZ0MagSize = 6, // Width of z-position magnitude (signed)
34  kNTrackInPVSize = 8, // Width of the multiplicity in the PV (unsigned)
35  kSumPtSize = 12, // Width of pT
36  kSumPtMagSize = 10, // Width of pT magnitude (unsigned)
37  kQualitySize = 3, // Width of the quality field
38  kNTrackOutPVSize = 10, // Width of the multiplicity outside the PV (unsigned)
39  kUnassignedSize = 15, // Width of the unassigned bits
40 
42  kUnassignedSize, // Width of the vertex word in bits
43  };

Constructor & Destructor Documentation

◆ VertexWord() [1/5]

l1t::VertexWord::VertexWord ( )
inline

Definition at line 84 of file VertexWord.h.

84 {}

◆ VertexWord() [2/5]

l1t::VertexWord::VertexWord ( unsigned int  valid,
double  z0,
unsigned int  multiplicity,
double  pt,
unsigned int  quality,
unsigned int  inverseMultiplicity,
unsigned int  unassigned 
)

Definition at line 15 of file VertexWord.cc.

References inverseMultiplicity(), multiplicity(), pt(), quality(), setVertexWord(), unassigned(), valid(), and z0().

21  {
22  // convert directly to AP types
23  vtxvalid_t valid_ap = valid;
24  vtxz0_t z0_ap = z0;
26  vtxsumpt_t pt_ap = pt;
27  vtxquality_t quality_ap = quality;
29  vtxunassigned_t unassigned_ap = unassigned;
30 
31  setVertexWord(valid_ap, z0_ap, mult_ap, pt_ap, quality_ap, invmult_ap, unassigned_ap);
32  }
ap_uint< VertexBitWidths::kUnassignedSize > vtxunassigned_t
Definition: VertexWord.h:73
unsigned int unassigned() const
Definition: VertexWord.h:163
ap_ufixed< VertexBitWidths::kNTrackInPVSize, VertexBitWidths::kNTrackInPVSize, AP_RND_CONV, AP_SAT > vtxmultiplicity_t
Definition: VertexWord.h:67
unsigned int quality() const
Definition: VertexWord.h:161
void setVertexWord(vtxvalid_t valid, vtxz0_t z0, vtxmultiplicity_t multiplicity, vtxsumpt_t pt, vtxquality_t quality, vtxinversemult_t inverseMultiplicity, vtxunassigned_t unassigned)
Definition: VertexWord.cc:65
ap_ufixed< VertexBitWidths::kNTrackOutPVSize, VertexBitWidths::kNTrackOutPVSize, AP_RND_CONV, AP_SAT > vtxinversemult_t
Definition: VertexWord.h:72
ap_fixed< VertexBitWidths::kZ0Size, VertexBitWidths::kZ0MagSize, AP_RND_CONV, AP_SAT > vtxz0_t
Definition: VertexWord.h:65
ap_ufixed< VertexBitWidths::kSumPtSize, VertexBitWidths::kSumPtMagSize, AP_RND_CONV, AP_SAT > vtxsumpt_t
Definition: VertexWord.h:69
ap_uint< VertexBitWidths::kQualitySize > vtxquality_t
Definition: VertexWord.h:70
double pt() const
Definition: VertexWord.h:160
bool valid() const
Definition: VertexWord.h:157
double z0() const
Definition: VertexWord.h:158
unsigned int multiplicity() const
Definition: VertexWord.h:159
unsigned int inverseMultiplicity() const
Definition: VertexWord.h:162
ap_uint< VertexBitWidths::kValidSize > vtxvalid_t
Definition: VertexWord.h:64

◆ VertexWord() [3/5]

l1t::VertexWord::VertexWord ( unsigned int  valid,
unsigned int  z0,
unsigned int  multiplicity,
unsigned int  pt,
unsigned int  quality,
unsigned int  inverseMultiplicity,
unsigned int  unassigned 
)

Definition at line 34 of file VertexWord.cc.

References inverseMultiplicity(), multiplicity(), quality(), setVertexWord(), unassigned(), unpackSignedValue(), valid(), and z0().

40  {
41  // convert to AP types
42  vtxvalid_t valid_ap = valid;
43  vtxz0_t z0_ap = unpackSignedValue(
44  z0, VertexBitWidths::kZ0Size, 1.0 / (1 << (VertexBitWidths::kZ0Size - VertexBitWidths::kZ0MagSize)));
47  z0, VertexBitWidths::kSumPtSize, 1.0 / (1 << (VertexBitWidths::kSumPtSize - VertexBitWidths::kSumPtMagSize)));
48  vtxquality_t quality_ap = quality;
50  vtxunassigned_t unassigned_ap = unassigned;
51 
52  setVertexWord(valid_ap, z0_ap, mult_ap, pt_ap, quality_ap, invmult_ap, unassigned_ap);
53  }
ap_uint< VertexBitWidths::kUnassignedSize > vtxunassigned_t
Definition: VertexWord.h:73
unsigned int unassigned() const
Definition: VertexWord.h:163
ap_ufixed< VertexBitWidths::kNTrackInPVSize, VertexBitWidths::kNTrackInPVSize, AP_RND_CONV, AP_SAT > vtxmultiplicity_t
Definition: VertexWord.h:67
unsigned int quality() const
Definition: VertexWord.h:161
void setVertexWord(vtxvalid_t valid, vtxz0_t z0, vtxmultiplicity_t multiplicity, vtxsumpt_t pt, vtxquality_t quality, vtxinversemult_t inverseMultiplicity, vtxunassigned_t unassigned)
Definition: VertexWord.cc:65
ap_ufixed< VertexBitWidths::kNTrackOutPVSize, VertexBitWidths::kNTrackOutPVSize, AP_RND_CONV, AP_SAT > vtxinversemult_t
Definition: VertexWord.h:72
ap_fixed< VertexBitWidths::kZ0Size, VertexBitWidths::kZ0MagSize, AP_RND_CONV, AP_SAT > vtxz0_t
Definition: VertexWord.h:65
ap_ufixed< VertexBitWidths::kSumPtSize, VertexBitWidths::kSumPtMagSize, AP_RND_CONV, AP_SAT > vtxsumpt_t
Definition: VertexWord.h:69
ap_uint< VertexBitWidths::kQualitySize > vtxquality_t
Definition: VertexWord.h:70
bool valid() const
Definition: VertexWord.h:157
double z0() const
Definition: VertexWord.h:158
unsigned int multiplicity() const
Definition: VertexWord.h:159
double unpackSignedValue(unsigned int bits, unsigned int nBits, double lsb) const
Definition: VertexWord.h:182
unsigned int inverseMultiplicity() const
Definition: VertexWord.h:162
ap_uint< VertexBitWidths::kValidSize > vtxvalid_t
Definition: VertexWord.h:64

◆ VertexWord() [4/5]

l1t::VertexWord::VertexWord ( vtxvalid_t  valid,
vtxz0_t  z0,
vtxmultiplicity_t  multiplicity,
vtxsumpt_t  pt,
vtxquality_t  quality,
vtxinversemult_t  inverseMultiplicity,
vtxunassigned_t  unassigned 
)

Definition at line 55 of file VertexWord.cc.

References inverseMultiplicity(), multiplicity(), pt(), quality(), setVertexWord(), unassigned(), valid(), and z0().

61  {
63  }
unsigned int unassigned() const
Definition: VertexWord.h:163
unsigned int quality() const
Definition: VertexWord.h:161
void setVertexWord(vtxvalid_t valid, vtxz0_t z0, vtxmultiplicity_t multiplicity, vtxsumpt_t pt, vtxquality_t quality, vtxinversemult_t inverseMultiplicity, vtxunassigned_t unassigned)
Definition: VertexWord.cc:65
double pt() const
Definition: VertexWord.h:160
bool valid() const
Definition: VertexWord.h:157
double z0() const
Definition: VertexWord.h:158
unsigned int multiplicity() const
Definition: VertexWord.h:159
unsigned int inverseMultiplicity() const
Definition: VertexWord.h:162

◆ ~VertexWord()

l1t::VertexWord::~VertexWord ( )
inline

Definition at line 107 of file VertexWord.h.

107 {}

◆ VertexWord() [5/5]

l1t::VertexWord::VertexWord ( const VertexWord word)
inline

Definition at line 110 of file VertexWord.h.

References vertexWord_.

110 { vertexWord_ = word.vertexWord_; }
vtxword_bs_t vertexWord_
Definition: VertexWord.h:193
uint64_t word

Member Function Documentation

◆ inverseMultiplicity()

unsigned int l1t::VertexWord::inverseMultiplicity ( ) const
inline

Definition at line 162 of file VertexWord.h.

References inverseMultiplicityWord().

Referenced by setVertexWord(), and VertexWord().

162 { return inverseMultiplicityWord().to_uint(); }
vtxinversemult_t inverseMultiplicityWord() const
Definition: VertexWord.h:137

◆ inverseMultiplicityBits()

unsigned int l1t::VertexWord::inverseMultiplicityBits ( ) const
inline

Definition at line 152 of file VertexWord.h.

References inverseMultiplicityWord().

152 { return inverseMultiplicityWord().to_uint(); }
vtxinversemult_t inverseMultiplicityWord() const
Definition: VertexWord.h:137

◆ inverseMultiplicityWord()

vtxinversemult_t l1t::VertexWord::inverseMultiplicityWord ( ) const
inline

Definition at line 137 of file VertexWord.h.

References vertexWord().

Referenced by inverseMultiplicity(), and inverseMultiplicityBits().

137  {
138  return vertexWord()(VertexBitLocations::kNTrackOutPVMSB, VertexBitLocations::kNTrackOutPVLSB);
139  }
vtxword_t vertexWord() const
Definition: VertexWord.h:143

◆ multiplicity()

unsigned int l1t::VertexWord::multiplicity ( ) const
inline

Definition at line 159 of file VertexWord.h.

References multiplicityWord().

Referenced by setVertexWord(), and VertexWord().

159 { return multiplicityWord().to_uint(); }
vtxmultiplicity_t multiplicityWord() const
Definition: VertexWord.h:126

◆ multiplicityBits()

unsigned int l1t::VertexWord::multiplicityBits ( ) const
inline

Definition at line 149 of file VertexWord.h.

References multiplicityWord().

149 { return multiplicityWord().to_uint(); }
vtxmultiplicity_t multiplicityWord() const
Definition: VertexWord.h:126

◆ multiplicityWord()

vtxmultiplicity_t l1t::VertexWord::multiplicityWord ( ) const
inline

Definition at line 126 of file VertexWord.h.

References vertexWord().

Referenced by multiplicity(), and multiplicityBits().

126  {
127  return vertexWord()(VertexBitLocations::kNTrackInPVMSB, VertexBitLocations::kNTrackInPVLSB);
128  }
vtxword_t vertexWord() const
Definition: VertexWord.h:143

◆ operator=()

VertexWord& l1t::VertexWord::operator= ( const VertexWord word)
inline

Definition at line 113 of file VertexWord.h.

References vertexWord_.

113  {
114  vertexWord_ = word.vertexWord_;
115  return *this;
116  }
vtxword_bs_t vertexWord_
Definition: VertexWord.h:193
uint64_t word

◆ pt()

double l1t::VertexWord::pt ( ) const
inline

◆ ptBits()

unsigned int l1t::VertexWord::ptBits ( ) const
inline

Definition at line 150 of file VertexWord.h.

References ptWord().

150 { return ptWord().to_uint(); }
vtxsumpt_t ptWord() const
Definition: VertexWord.h:129

◆ ptWord()

vtxsumpt_t l1t::VertexWord::ptWord ( ) const
inline

Definition at line 129 of file VertexWord.h.

References runTheMatrix::ret, and vertexWord().

Referenced by pt(), and ptBits().

129  {
130  vtxsumpt_t ret;
131  ret.V = vertexWord()(VertexBitLocations::kSumPtMSB, VertexBitLocations::kSumPtLSB);
132  return ret;
133  }
ret
prodAgent to be discontinued
ap_ufixed< VertexBitWidths::kSumPtSize, VertexBitWidths::kSumPtMagSize, AP_RND_CONV, AP_SAT > vtxsumpt_t
Definition: VertexWord.h:69
vtxword_t vertexWord() const
Definition: VertexWord.h:143

◆ quality()

unsigned int l1t::VertexWord::quality ( ) const
inline

Definition at line 161 of file VertexWord.h.

References qualityWord().

Referenced by setVertexWord(), and VertexWord().

161 { return qualityWord().to_uint(); }
vtxquality_t qualityWord() const
Definition: VertexWord.h:134

◆ qualityBits()

unsigned int l1t::VertexWord::qualityBits ( ) const
inline

Definition at line 151 of file VertexWord.h.

References qualityWord().

151 { return qualityWord().to_uint(); }
vtxquality_t qualityWord() const
Definition: VertexWord.h:134

◆ qualityWord()

vtxquality_t l1t::VertexWord::qualityWord ( ) const
inline

Definition at line 134 of file VertexWord.h.

References vertexWord().

Referenced by quality(), and qualityBits().

134  {
135  return vertexWord()(VertexBitLocations::kQualityMSB, VertexBitLocations::kQualityLSB);
136  }
vtxword_t vertexWord() const
Definition: VertexWord.h:143

◆ setVertexRef()

void l1t::VertexWord::setVertexRef ( const VertexRef ref)
inline

Definition at line 178 of file VertexWord.h.

References vertexRef_.

178 { vertexRef_ = ref; }
VertexRef vertexRef_
Definition: VertexWord.h:194

◆ setVertexWord()

void l1t::VertexWord::setVertexWord ( vtxvalid_t  valid,
vtxz0_t  z0,
vtxmultiplicity_t  multiplicity,
vtxsumpt_t  pt,
vtxquality_t  quality,
vtxinversemult_t  inverseMultiplicity,
vtxunassigned_t  unassigned 
)

Definition at line 65 of file VertexWord.cc.

References b, inverseMultiplicity(), l1tmhtemu::kUnassignedSize, l1tmhtemu::kValidSize, multiplicity(), hltrates_dqm_sourceclient-live_cfg::offset, pt(), quality(), unassigned(), valid(), vertexWord_, and z0().

Referenced by VertexWord().

71  {
72  // pack the vertex word
73  unsigned int offset = 0;
74  for (unsigned int b = offset; b < (offset + VertexBitWidths::kValidSize); b++) {
75  vertexWord_.set(b, valid[b - offset]);
76  }
78  for (unsigned int b = offset; b < (offset + VertexBitWidths::kZ0Size); b++) {
79  vertexWord_.set(b, z0[b - offset]);
80  }
81  offset += VertexBitWidths::kZ0Size;
82 
83  for (unsigned int b = offset; b < (offset + VertexBitWidths::kNTrackInPVSize); b++) {
85  }
86  offset += VertexBitWidths::kNTrackInPVSize;
87  for (unsigned int b = offset; b < (offset + VertexBitWidths::kSumPtSize); b++) {
88  vertexWord_.set(b, pt[b - offset]);
89  }
90  offset += VertexBitWidths::kSumPtSize;
91  for (unsigned int b = offset; b < (offset + VertexBitWidths::kQualitySize); b++) {
92  vertexWord_.set(b, quality[b - offset]);
93  }
94  offset += VertexBitWidths::kQualitySize;
95  for (unsigned int b = offset; b < (offset + VertexBitWidths::kNTrackOutPVSize); b++) {
97  }
98  offset += VertexBitWidths::kNTrackOutPVSize;
99  for (unsigned int b = offset; b < (offset + VertexBitWidths::kUnassignedSize); b++) {
100  vertexWord_.set(b, unassigned[b - offset]);
101  }
102  }
vtxword_bs_t vertexWord_
Definition: VertexWord.h:193
unsigned int unassigned() const
Definition: VertexWord.h:163
unsigned int quality() const
Definition: VertexWord.h:161
const unsigned int kValidSize
double pt() const
Definition: VertexWord.h:160
bool valid() const
Definition: VertexWord.h:157
double b
Definition: hdecay.h:120
double z0() const
Definition: VertexWord.h:158
const unsigned int kUnassignedSize
unsigned int multiplicity() const
Definition: VertexWord.h:159
unsigned int inverseMultiplicity() const
Definition: VertexWord.h:162

◆ unassigned()

unsigned int l1t::VertexWord::unassigned ( ) const
inline

Definition at line 163 of file VertexWord.h.

References unassignedWord().

Referenced by setVertexWord(), and VertexWord().

163 { return unassignedWord().to_uint(); }
vtxunassigned_t unassignedWord() const
Definition: VertexWord.h:140

◆ unassignedBits()

unsigned int l1t::VertexWord::unassignedBits ( ) const
inline

Definition at line 153 of file VertexWord.h.

References unassignedWord().

153 { return unassignedWord().to_uint(); }
vtxunassigned_t unassignedWord() const
Definition: VertexWord.h:140

◆ unassignedWord()

vtxunassigned_t l1t::VertexWord::unassignedWord ( ) const
inline

◆ unpackSignedValue()

double l1t::VertexWord::unpackSignedValue ( unsigned int  bits,
unsigned int  nBits,
double  lsb 
) const
inlineprivate

Definition at line 182 of file VertexWord.h.

References ALPAKA_ACCELERATOR_NAMESPACE::pixelClustering::pixelStatus::bits, and l1tHGCalVFEProducer_cfi::lsb.

Referenced by VertexWord().

182  {
183  int isign = 1;
184  unsigned int digitized_maximum = (1 << nBits) - 1;
185  if (bits & (1 << (nBits - 1))) { // check the sign
186  isign = -1;
187  bits = (1 << (nBits + 1)) - bits; // if negative, flip everything for two's complement encoding
188  }
189  return (double(bits & digitized_maximum) + 0.5) * lsb * isign;
190  }

◆ valid()

bool l1t::VertexWord::valid ( ) const
inline

Definition at line 157 of file VertexWord.h.

References validWord().

Referenced by setVertexWord(), and VertexWord().

157 { return validWord().to_bool(); }
vtxvalid_t validWord() const
Definition: VertexWord.h:120

◆ validBits()

unsigned int l1t::VertexWord::validBits ( ) const
inline

Definition at line 147 of file VertexWord.h.

References validWord().

147 { return validWord().to_uint(); }
vtxvalid_t validWord() const
Definition: VertexWord.h:120

◆ validWord()

vtxvalid_t l1t::VertexWord::validWord ( ) const
inline

◆ vertexRef()

VertexRef l1t::VertexWord::vertexRef ( ) const
inline

Definition at line 166 of file VertexWord.h.

References vertexRef_.

166 { return vertexRef_; }
VertexRef vertexRef_
Definition: VertexWord.h:194

◆ vertexWord()

vtxword_t l1t::VertexWord::vertexWord ( ) const
inline

Definition at line 143 of file VertexWord.h.

References vertexWord_.

Referenced by inverseMultiplicityWord(), multiplicityWord(), L1TCorrelatorLayer1Producer::produce(), ptWord(), qualityWord(), unassignedWord(), validWord(), and z0Word().

143 { return vtxword_t(vertexWord_.to_string().c_str(), 2); }
vtxword_bs_t vertexWord_
Definition: VertexWord.h:193
ap_uint< VertexBitWidths::kVertexWordSize > vtxword_t
Definition: VertexWord.h:77

◆ z0()

double l1t::VertexWord::z0 ( ) const
inline

◆ z0Bits()

unsigned int l1t::VertexWord::z0Bits ( ) const
inline

Definition at line 148 of file VertexWord.h.

References z0Word().

148 { return z0Word().to_uint(); }
vtxz0_t z0Word() const
Definition: VertexWord.h:121

◆ z0Word()

vtxz0_t l1t::VertexWord::z0Word ( ) const
inline

Definition at line 121 of file VertexWord.h.

References runTheMatrix::ret, and vertexWord().

Referenced by z0(), and z0Bits().

121  {
122  vtxz0_t ret;
123  ret.V = vertexWord()(VertexBitLocations::kZ0MSB, VertexBitLocations::kZ0LSB);
124  return ret;
125  }
ret
prodAgent to be discontinued
ap_fixed< VertexBitWidths::kZ0Size, VertexBitWidths::kZ0MagSize, AP_RND_CONV, AP_SAT > vtxz0_t
Definition: VertexWord.h:65
vtxword_t vertexWord() const
Definition: VertexWord.h:143

Member Data Documentation

◆ vertexRef_

VertexRef l1t::VertexWord::vertexRef_
private

Definition at line 194 of file VertexWord.h.

Referenced by setVertexRef(), and vertexRef().

◆ vertexWord_

vtxword_bs_t l1t::VertexWord::vertexWord_
private

Definition at line 193 of file VertexWord.h.

Referenced by operator=(), setVertexWord(), VertexWord(), and vertexWord().