CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes
TTTrack_TrackWord Class Reference

#include <TTTrack_TrackWord.h>

Inheritance diagram for TTTrack_TrackWord:
TTTrack< T >

Public Types

typedef ap_uint< TrackBitWidths::kBendChi2Size > bendChi2_t
 
typedef ap_uint< TrackBitWidths::kChi2RPhiSize > chi2rphi_t
 
typedef ap_uint< TrackBitWidths::kChi2RZSize > chi2rz_t
 
typedef ap_uint< TrackBitWidths::kD0Size > d0_t
 
typedef ap_uint< TrackBitWidths::kHitPatternSize > hit_t
 
typedef ap_uint< TrackBitWidths::kMVAOtherSize > otherMVA_t
 
typedef ap_uint< TrackBitWidths::kPhiSize > phi_t
 
typedef ap_uint< TrackBitWidths::kMVAQualitySize > qualityMVA_t
 
typedef ap_uint< TrackBitWidths::kRinvSize > rinv_t
 
typedef ap_uint< TrackBitWidths::kTanlSize > tanl_t
 
typedef std::bitset< TrackBitWidths::kTrackWordSize > tkword_bs_t
 
typedef ap_uint< TrackBitWidths::kTrackWordSize > tkword_t
 
enum  TrackBitLocations {
  kMVAOtherLSB = 0, kMVAOtherMSB = kMVAOtherLSB + TrackBitWidths::kMVAOtherSize - 1, kMVAQualityLSB = kMVAOtherMSB + 1, kMVAQualityMSB = kMVAQualityLSB + TrackBitWidths::kMVAQualitySize - 1,
  kHitPatternLSB = kMVAQualityMSB + 1, kHitPatternMSB = kHitPatternLSB + TrackBitWidths::kHitPatternSize - 1, kBendChi2LSB = kHitPatternMSB + 1, kBendChi2MSB = kBendChi2LSB + TrackBitWidths::kBendChi2Size - 1,
  kD0LSB = kBendChi2MSB + 1, kD0MSB = kD0LSB + TrackBitWidths::kD0Size - 1, kChi2RZLSB = kD0MSB + 1, kChi2RZMSB = kChi2RZLSB + TrackBitWidths::kChi2RZSize - 1,
  kZ0LSB = kChi2RZMSB + 1, kZ0MSB = kZ0LSB + TrackBitWidths::kZ0Size - 1, kTanlLSB = kZ0MSB + 1, kTanlMSB = kTanlLSB + TrackBitWidths::kTanlSize - 1,
  kChi2RPhiLSB = kTanlMSB + 1, kChi2RPhiMSB = kChi2RPhiLSB + TrackBitWidths::kChi2RPhiSize - 1, kPhiLSB = kChi2RPhiMSB + 1, kPhiMSB = kPhiLSB + TrackBitWidths::kPhiSize - 1,
  kRinvLSB = kPhiMSB + 1, kRinvMSB = kRinvLSB + TrackBitWidths::kRinvSize - 1, kValidLSB = kRinvMSB + 1, kValidMSB = kValidLSB + TrackBitWidths::kValidSize - 1
}
 
enum  TrackBitWidths {
  kMVAOtherSize = 6, kMVAQualitySize = 3, kHitPatternSize = 7, kBendChi2Size = 3,
  kD0Size = 13, kChi2RZSize = 4, kZ0Size = 12, kTanlSize = 16,
  kChi2RPhiSize = 4, kPhiSize = 12, kRinvSize = 15, kValidSize = 1,
  kTrackWordSize
}
 
typedef ap_uint< TrackBitWidths::kValidSize > valid_t
 
typedef ap_uint< TrackBitWidths::kZ0Size > z0_t
 

Public Member Functions

double getBendChi2 () const
 
unsigned int getBendChi2Bits () const
 
bendChi2_t getBendChi2Word () const
 
double getChi2RPhi () const
 
unsigned int getChi2RPhiBits () const
 
chi2rphi_t getChi2RPhiWord () const
 
double getChi2RZ () const
 
unsigned int getChi2RZBits () const
 
chi2rz_t getChi2RZWord () const
 
double getD0 () const
 
unsigned int getD0Bits () const
 
d0_t getD0Word () const
 
unsigned int getHitPattern () const
 
unsigned int getHitPatternBits () const
 
hit_t getHitPatternWord () const
 
unsigned int getMVAOther () const
 
unsigned int getMVAOtherBits () const
 
otherMVA_t getMVAOtherWord () const
 
unsigned int getMVAQuality () const
 
unsigned int getMVAQualityBits () const
 
qualityMVA_t getMVAQualityWord () const
 
double getPhi () const
 
unsigned int getPhiBits () const
 
phi_t getPhiWord () const
 
double getRinv () const
 
unsigned int getRinvBits () const
 
rinv_t getRinvWord () const
 
double getTanl () const
 
unsigned int getTanlBits () const
 
tanl_t getTanlWord () const
 
tkword_t getTrackWord () const
 
bool getValid () const
 
unsigned int getValidBits () const
 
valid_t getValidWord () const
 
double getZ0 () const
 
unsigned int getZ0Bits () const
 
z0_t getZ0Word () const
 
TTTrack_TrackWordoperator= (const TTTrack_TrackWord &word)
 
void setTrackWord (ap_uint< TrackBitWidths::kValidSize > valid, ap_uint< TrackBitWidths::kRinvSize > rInv, ap_uint< TrackBitWidths::kPhiSize > phi0, ap_uint< TrackBitWidths::kTanlSize > tanl, ap_uint< TrackBitWidths::kZ0Size > z0, ap_uint< TrackBitWidths::kD0Size > d0, ap_uint< TrackBitWidths::kChi2RPhiSize > chi2RPhi, ap_uint< TrackBitWidths::kChi2RZSize > chi2RZ, ap_uint< TrackBitWidths::kBendChi2Size > bendChi2, ap_uint< TrackBitWidths::kHitPatternSize > hitPattern, ap_uint< TrackBitWidths::kMVAQualitySize > mvaQuality, ap_uint< TrackBitWidths::kMVAOtherSize > mvaOther)
 
void setTrackWord (unsigned int valid, const GlobalVector &momentum, const GlobalPoint &POCA, double rInv, double chi2RPhi, double chi2RZ, double bendChi2, unsigned int hitPattern, unsigned int mvaQuality, unsigned int mvaOther, unsigned int sector)
 
void setTrackWord (unsigned int valid, unsigned int rInv, unsigned int phi0, unsigned int tanl, unsigned int z0, unsigned int d0, unsigned int chi2RPhi, unsigned int chi2RZ, unsigned int bendChi2, unsigned int hitPattern, unsigned int mvaQuality, unsigned int mvaOther)
 
bool singleDigitizationSchemeTest (const double floatingPointValue, const unsigned int nBits, const double lsb) const
 
void testDigitizationScheme () const
 
 TTTrack_TrackWord ()
 
 TTTrack_TrackWord (const TTTrack_TrackWord &word)
 
 TTTrack_TrackWord (unsigned int valid, const GlobalVector &momentum, const GlobalPoint &POCA, double rInv, double chi2RPhi, double chi2RZ, double bendChi2, unsigned int hitPattern, unsigned int mvaQuality, unsigned int mvaOther, unsigned int sector)
 
 TTTrack_TrackWord (unsigned int valid, unsigned int rInv, unsigned int phi0, unsigned int tanl, unsigned int z0, unsigned int d0, unsigned int chi2RPhi, unsigned int chi2RZ, unsigned int bendChi2, unsigned int hitPattern, unsigned int mvaQuality, unsigned int mvaOther)
 

Static Public Attributes

static constexpr std::array< double, 1<< TrackBitWidths::kBendChi2Size > bendChi2Bins
 
static constexpr std::array< double, 1<< TrackBitWidths::kChi2RPhiSize > chi2RPhiBins
 
static constexpr std::array< double, 1<< TrackBitWidths::kChi2RZSize > chi2RZBins
 
static constexpr double minD0 = -16.
 
static constexpr double minPhi0 = -0.7853981696
 
static constexpr double minRinv = -0.006
 
static constexpr double minTanl = -8.
 
static constexpr double minZ0 = -20.46912512
 
static constexpr unsigned int nSectors = 9
 
static constexpr double sectorWidth = (2. * M_PI) / nSectors
 
static constexpr double stepD0 = (1. / (1 << 8))
 
static constexpr double stepPhi0 = (2. * std::abs(minPhi0)) / (1 << TrackBitWidths::kPhiSize)
 
static constexpr double stepRinv = (2. * std::abs(minRinv)) / (1 << TrackBitWidths::kRinvSize)
 
static constexpr double stepTanL = (1. / (1 << 12))
 
static constexpr double stepZ0 = (2. * std::abs(minZ0)) / (1 << TrackBitWidths::kZ0Size)
 

Protected Member Functions

float localPhi (float globalPhi, unsigned int sector) const
 

Private Member Functions

unsigned int digitizeSignedValue (double value, unsigned int nBits, double lsb) const
 
template<typename T >
constexpr unsigned int getBin (double value, const T &bins) const
 
double undigitizeSignedValue (unsigned int twosValue, unsigned int nBits, double lsb) const
 

Private Attributes

tkword_bs_t trackWord_
 

Detailed Description

Definition at line 35 of file TTTrack_TrackWord.h.

Member Typedef Documentation

◆ bendChi2_t

typedef ap_uint<TrackBitWidths::kBendChi2Size> TTTrack_TrackWord::bendChi2_t

Definition at line 124 of file TTTrack_TrackWord.h.

◆ chi2rphi_t

typedef ap_uint<TrackBitWidths::kChi2RPhiSize> TTTrack_TrackWord::chi2rphi_t

Definition at line 122 of file TTTrack_TrackWord.h.

◆ chi2rz_t

typedef ap_uint<TrackBitWidths::kChi2RZSize> TTTrack_TrackWord::chi2rz_t

Definition at line 123 of file TTTrack_TrackWord.h.

◆ d0_t

typedef ap_uint<TrackBitWidths::kD0Size> TTTrack_TrackWord::d0_t

Definition at line 119 of file TTTrack_TrackWord.h.

◆ hit_t

typedef ap_uint<TrackBitWidths::kHitPatternSize> TTTrack_TrackWord::hit_t

Definition at line 125 of file TTTrack_TrackWord.h.

◆ otherMVA_t

typedef ap_uint<TrackBitWidths::kMVAOtherSize> TTTrack_TrackWord::otherMVA_t

Definition at line 127 of file TTTrack_TrackWord.h.

◆ phi_t

typedef ap_uint<TrackBitWidths::kPhiSize> TTTrack_TrackWord::phi_t

Definition at line 116 of file TTTrack_TrackWord.h.

◆ qualityMVA_t

typedef ap_uint<TrackBitWidths::kMVAQualitySize> TTTrack_TrackWord::qualityMVA_t

Definition at line 126 of file TTTrack_TrackWord.h.

◆ rinv_t

typedef ap_uint<TrackBitWidths::kRinvSize> TTTrack_TrackWord::rinv_t

Definition at line 115 of file TTTrack_TrackWord.h.

◆ tanl_t

typedef ap_uint<TrackBitWidths::kTanlSize> TTTrack_TrackWord::tanl_t

Definition at line 117 of file TTTrack_TrackWord.h.

◆ tkword_bs_t

typedef std::bitset<TrackBitWidths::kTrackWordSize> TTTrack_TrackWord::tkword_bs_t

Definition at line 130 of file TTTrack_TrackWord.h.

◆ tkword_t

typedef ap_uint<TrackBitWidths::kTrackWordSize> TTTrack_TrackWord::tkword_t

Definition at line 131 of file TTTrack_TrackWord.h.

◆ valid_t

typedef ap_uint<TrackBitWidths::kValidSize> TTTrack_TrackWord::valid_t

Definition at line 112 of file TTTrack_TrackWord.h.

◆ z0_t

typedef ap_uint<TrackBitWidths::kZ0Size> TTTrack_TrackWord::z0_t

Definition at line 118 of file TTTrack_TrackWord.h.

Member Enumeration Documentation

◆ TrackBitLocations

Enumerator
kMVAOtherLSB 
kMVAOtherMSB 
kMVAQualityLSB 
kMVAQualityMSB 
kHitPatternLSB 
kHitPatternMSB 
kBendChi2LSB 
kBendChi2MSB 
kD0LSB 
kD0MSB 
kChi2RZLSB 
kChi2RZMSB 
kZ0LSB 
kZ0MSB 
kTanlLSB 
kTanlMSB 
kChi2RPhiLSB 
kChi2RPhiMSB 
kPhiLSB 
kPhiMSB 
kRinvLSB 
kRinvMSB 
kValidLSB 
kValidMSB 

Definition at line 58 of file TTTrack_TrackWord.h.

58  {
59  // The location of the least significant bit (LSB) and most significant bit (MSB) in the track word for different fields
60  kMVAOtherLSB = 0,
61  kMVAOtherMSB = kMVAOtherLSB + TrackBitWidths::kMVAOtherSize - 1,
63  kMVAQualityMSB = kMVAQualityLSB + TrackBitWidths::kMVAQualitySize - 1,
65  kHitPatternMSB = kHitPatternLSB + TrackBitWidths::kHitPatternSize - 1,
67  kBendChi2MSB = kBendChi2LSB + TrackBitWidths::kBendChi2Size - 1,
68  kD0LSB = kBendChi2MSB + 1,
69  kD0MSB = kD0LSB + TrackBitWidths::kD0Size - 1,
70  kChi2RZLSB = kD0MSB + 1,
71  kChi2RZMSB = kChi2RZLSB + TrackBitWidths::kChi2RZSize - 1,
72  kZ0LSB = kChi2RZMSB + 1,
73  kZ0MSB = kZ0LSB + TrackBitWidths::kZ0Size - 1,
74  kTanlLSB = kZ0MSB + 1,
75  kTanlMSB = kTanlLSB + TrackBitWidths::kTanlSize - 1,
76  kChi2RPhiLSB = kTanlMSB + 1,
77  kChi2RPhiMSB = kChi2RPhiLSB + TrackBitWidths::kChi2RPhiSize - 1,
78  kPhiLSB = kChi2RPhiMSB + 1,
79  kPhiMSB = kPhiLSB + TrackBitWidths::kPhiSize - 1,
80  kRinvLSB = kPhiMSB + 1,
81  kRinvMSB = kRinvLSB + TrackBitWidths::kRinvSize - 1,
82  kValidLSB = kRinvMSB + 1,
83  kValidMSB = kValidLSB + TrackBitWidths::kValidSize - 1,
84  };

◆ TrackBitWidths

Enumerator
kMVAOtherSize 
kMVAQualitySize 
kHitPatternSize 
kBendChi2Size 
kD0Size 
kChi2RZSize 
kZ0Size 
kTanlSize 
kChi2RPhiSize 
kPhiSize 
kRinvSize 
kValidSize 
kTrackWordSize 

Definition at line 38 of file TTTrack_TrackWord.h.

38  {
39  // The sizes of the track word components
40  kMVAOtherSize = 6, // Space for two specialized MVA selections
41  kMVAQualitySize = 3, // Width of track quality MVA
42  kHitPatternSize = 7, // Width of the hit pattern for stubs
43  kBendChi2Size = 3, // Width of the bend-chi2/dof
44  kD0Size = 13, // Width of D0
45  kChi2RZSize = 4, // Width of chi2/dof for r-z
46  kZ0Size = 12, // Width of z-position (40cm / 0.1)
47  kTanlSize = 16, // Width of tan(lambda)
48  kChi2RPhiSize = 4, // Width of chi2/dof for r-phi
49  kPhiSize = 12, // Width of phi
50  kRinvSize = 15, // Width of Rinv
51  kValidSize = 1, // Valid bit
52 
55  kMVAOtherSize, // Width of the track word in bits
56  };

Constructor & Destructor Documentation

◆ TTTrack_TrackWord() [1/4]

TTTrack_TrackWord::TTTrack_TrackWord ( )
inline

Definition at line 135 of file TTTrack_TrackWord.h.

135 {}

◆ TTTrack_TrackWord() [2/4]

TTTrack_TrackWord::TTTrack_TrackWord ( unsigned int  valid,
const GlobalVector momentum,
const GlobalPoint POCA,
double  rInv,
double  chi2RPhi,
double  chi2RZ,
double  bendChi2,
unsigned int  hitPattern,
unsigned int  mvaQuality,
unsigned int  mvaOther,
unsigned int  sector 
)

Definition at line 30 of file TTTrack_TrackWord.cc.

40  {
41  setTrackWord(valid, momentum, POCA, rInv, chi2RPhi, chi2RZ, bendChi2, hitPattern, mvaQuality, mvaOther, sector);
42 }

References setTrackWord(), and RunInfoPI::valid.

◆ TTTrack_TrackWord() [3/4]

TTTrack_TrackWord::TTTrack_TrackWord ( unsigned int  valid,
unsigned int  rInv,
unsigned int  phi0,
unsigned int  tanl,
unsigned int  z0,
unsigned int  d0,
unsigned int  chi2RPhi,
unsigned int  chi2RZ,
unsigned int  bendChi2,
unsigned int  hitPattern,
unsigned int  mvaQuality,
unsigned int  mvaOther 
)

Definition at line 44 of file TTTrack_TrackWord.cc.

55  {
56  setTrackWord(valid, rInv, phi0, tanl, z0, d0, chi2RPhi, chi2RZ, bendChi2, hitPattern, mvaQuality, mvaOther);
57 }

References d0, setTrackWord(), RunInfoPI::valid, and HLTMuonOfflineAnalyzer_cfi::z0.

◆ TTTrack_TrackWord() [4/4]

TTTrack_TrackWord::TTTrack_TrackWord ( const TTTrack_TrackWord word)
inline

Definition at line 161 of file TTTrack_TrackWord.h.

161 { trackWord_ = word.trackWord_; }

References trackWord_.

Member Function Documentation

◆ digitizeSignedValue()

unsigned int TTTrack_TrackWord::digitizeSignedValue ( double  value,
unsigned int  nBits,
double  lsb 
) const
inlineprivate

Definition at line 280 of file TTTrack_TrackWord.h.

280  {
281  // Digitize the incoming value
282  int digitizedValue = std::floor(value / lsb);
283 
284  // Calculate the maxmum possible positive value given an output of nBits in size
285  int digitizedMaximum = (1 << (nBits - 1)) - 1; // The remove 1 bit from nBits to account for the sign
286  int digitizedMinimum = -1. * (digitizedMaximum + 1);
287 
288  // Saturate the digitized value
289  digitizedValue = std::clamp(digitizedValue, digitizedMinimum, digitizedMaximum);
290 
291  // Do the two's compliment encoding
292  unsigned int twosValue = digitizedValue;
293  if (digitizedValue < 0) {
294  twosValue += (1 << nBits);
295  }
296 
297  return twosValue;
298  }

References hgcalVFEProducer_cfi::lsb.

Referenced by setTrackWord(), and singleDigitizationSchemeTest().

◆ getBendChi2()

double TTTrack_TrackWord::getBendChi2 ( ) const
inline

Definition at line 224 of file TTTrack_TrackWord.h.

224 { return bendChi2Bins[getBendChi2Bits()]; }

References bendChi2Bins, and getBendChi2Bits().

◆ getBendChi2Bits()

unsigned int TTTrack_TrackWord::getBendChi2Bits ( ) const
inline

Definition at line 209 of file TTTrack_TrackWord.h.

209 { return getBendChi2Word().to_uint(); }

References getBendChi2Word().

Referenced by getBendChi2().

◆ getBendChi2Word()

bendChi2_t TTTrack_TrackWord::getBendChi2Word ( ) const
inline

Definition at line 184 of file TTTrack_TrackWord.h.

184  {
185  return getTrackWord()(TrackBitLocations::kBendChi2MSB, TrackBitLocations::kBendChi2LSB);
186  }

References getTrackWord().

Referenced by getBendChi2Bits().

◆ getBin()

template<typename T >
constexpr unsigned int TTTrack_TrackWord::getBin ( double  value,
const T bins 
) const
inlineconstexprprivate

Definition at line 301 of file TTTrack_TrackWord.h.

301  {
302  auto up = std::upper_bound(bins.begin(), bins.end(), value);
303  return (up - bins.begin() - 1);
304  }

References trigObjTnPSource_cfi::bins, up, pfDeepBoostedJetPreprocessParams_cfi::upper_bound, and relativeConstraints::value.

Referenced by BTagWeightCalculator.BTagWeightCalculator::calcJetWeightImpl(), and setTrackWord().

◆ getChi2RPhi()

double TTTrack_TrackWord::getChi2RPhi ( ) const
inline

Definition at line 222 of file TTTrack_TrackWord.h.

222 { return chi2RPhiBins[getChi2RPhiBits()]; }

References chi2RPhiBins, and getChi2RPhiBits().

◆ getChi2RPhiBits()

unsigned int TTTrack_TrackWord::getChi2RPhiBits ( ) const
inline

Definition at line 207 of file TTTrack_TrackWord.h.

207 { return getChi2RPhiWord().to_uint(); }

References getChi2RPhiWord().

Referenced by getChi2RPhi().

◆ getChi2RPhiWord()

chi2rphi_t TTTrack_TrackWord::getChi2RPhiWord ( ) const
inline

Definition at line 178 of file TTTrack_TrackWord.h.

178  {
179  return getTrackWord()(TrackBitLocations::kChi2RPhiMSB, TrackBitLocations::kChi2RPhiLSB);
180  }

References getTrackWord().

Referenced by getChi2RPhiBits().

◆ getChi2RZ()

double TTTrack_TrackWord::getChi2RZ ( ) const
inline

Definition at line 223 of file TTTrack_TrackWord.h.

223 { return chi2RZBins[getChi2RZBits()]; }

References chi2RZBins, and getChi2RZBits().

◆ getChi2RZBits()

unsigned int TTTrack_TrackWord::getChi2RZBits ( ) const
inline

Definition at line 208 of file TTTrack_TrackWord.h.

208 { return getChi2RZWord().to_uint(); }

References getChi2RZWord().

Referenced by getChi2RZ().

◆ getChi2RZWord()

chi2rz_t TTTrack_TrackWord::getChi2RZWord ( ) const
inline

Definition at line 181 of file TTTrack_TrackWord.h.

181  {
182  return getTrackWord()(TrackBitLocations::kChi2RZMSB, TrackBitLocations::kChi2RZLSB);
183  }

References getTrackWord().

Referenced by getChi2RZBits().

◆ getD0()

double TTTrack_TrackWord::getD0 ( ) const
inline

Definition at line 221 of file TTTrack_TrackWord.h.

221 { return undigitizeSignedValue(getD0Bits(), TrackBitWidths::kD0Size, stepD0); }

References getD0Bits(), stepD0, and undigitizeSignedValue().

◆ getD0Bits()

unsigned int TTTrack_TrackWord::getD0Bits ( ) const
inline

Definition at line 206 of file TTTrack_TrackWord.h.

206 { return getD0Word().to_uint(); }

References getD0Word().

Referenced by getD0().

◆ getD0Word()

d0_t TTTrack_TrackWord::getD0Word ( ) const
inline

Definition at line 177 of file TTTrack_TrackWord.h.

177 { return getTrackWord()(TrackBitLocations::kD0MSB, TrackBitLocations::kD0LSB); }

References getTrackWord().

Referenced by getD0Bits().

◆ getHitPattern()

unsigned int TTTrack_TrackWord::getHitPattern ( ) const
inline

Definition at line 225 of file TTTrack_TrackWord.h.

225 { return getHitPatternBits(); }

References getHitPatternBits().

◆ getHitPatternBits()

unsigned int TTTrack_TrackWord::getHitPatternBits ( ) const
inline

Definition at line 210 of file TTTrack_TrackWord.h.

210 { return getHitPatternWord().to_uint(); }

References getHitPatternWord().

Referenced by getHitPattern().

◆ getHitPatternWord()

hit_t TTTrack_TrackWord::getHitPatternWord ( ) const
inline

Definition at line 187 of file TTTrack_TrackWord.h.

187  {
188  return getTrackWord()(TrackBitLocations::kHitPatternMSB, TrackBitLocations::kHitPatternLSB);
189  }

References getTrackWord().

Referenced by getHitPatternBits().

◆ getMVAOther()

unsigned int TTTrack_TrackWord::getMVAOther ( ) const
inline

Definition at line 227 of file TTTrack_TrackWord.h.

227 { return getMVAOtherBits(); }

References getMVAOtherBits().

◆ getMVAOtherBits()

unsigned int TTTrack_TrackWord::getMVAOtherBits ( ) const
inline

Definition at line 212 of file TTTrack_TrackWord.h.

212 { return getMVAOtherWord().to_uint(); }

References getMVAOtherWord().

Referenced by getMVAOther().

◆ getMVAOtherWord()

otherMVA_t TTTrack_TrackWord::getMVAOtherWord ( ) const
inline

Definition at line 193 of file TTTrack_TrackWord.h.

193  {
194  return getTrackWord()(TrackBitLocations::kMVAOtherMSB, TrackBitLocations::kMVAOtherLSB);
195  }

References getTrackWord().

Referenced by getMVAOtherBits().

◆ getMVAQuality()

unsigned int TTTrack_TrackWord::getMVAQuality ( ) const
inline

Definition at line 226 of file TTTrack_TrackWord.h.

226 { return getMVAQualityBits(); }

References getMVAQualityBits().

◆ getMVAQualityBits()

unsigned int TTTrack_TrackWord::getMVAQualityBits ( ) const
inline

Definition at line 211 of file TTTrack_TrackWord.h.

211 { return getMVAQualityWord().to_uint(); }

References getMVAQualityWord().

Referenced by getMVAQuality().

◆ getMVAQualityWord()

qualityMVA_t TTTrack_TrackWord::getMVAQualityWord ( ) const
inline

Definition at line 190 of file TTTrack_TrackWord.h.

190  {
191  return getTrackWord()(TrackBitLocations::kMVAQualityMSB, TrackBitLocations::kMVAQualityLSB);
192  }

References getTrackWord().

Referenced by getMVAQualityBits().

◆ getPhi()

double TTTrack_TrackWord::getPhi ( ) const
inline

Definition at line 218 of file TTTrack_TrackWord.h.

218 { return undigitizeSignedValue(getPhiBits(), TrackBitWidths::kPhiSize, stepPhi0); }

References getPhiBits(), stepPhi0, and undigitizeSignedValue().

◆ getPhiBits()

unsigned int TTTrack_TrackWord::getPhiBits ( ) const
inline

Definition at line 203 of file TTTrack_TrackWord.h.

203 { return getPhiWord().to_uint(); }

References getPhiWord().

Referenced by getPhi().

◆ getPhiWord()

phi_t TTTrack_TrackWord::getPhiWord ( ) const
inline

Definition at line 174 of file TTTrack_TrackWord.h.

174 { return getTrackWord()(TrackBitLocations::kPhiMSB, TrackBitLocations::kPhiLSB); }

References getTrackWord().

Referenced by getPhiBits().

◆ getRinv()

double TTTrack_TrackWord::getRinv ( ) const
inline

Definition at line 217 of file TTTrack_TrackWord.h.

217 { return undigitizeSignedValue(getRinvBits(), TrackBitWidths::kRinvSize, stepRinv); }

References getRinvBits(), stepRinv, and undigitizeSignedValue().

◆ getRinvBits()

unsigned int TTTrack_TrackWord::getRinvBits ( ) const
inline

Definition at line 202 of file TTTrack_TrackWord.h.

202 { return getRinvWord().to_uint(); }

References getRinvWord().

Referenced by getRinv().

◆ getRinvWord()

rinv_t TTTrack_TrackWord::getRinvWord ( ) const
inline

Definition at line 173 of file TTTrack_TrackWord.h.

173 { return getTrackWord()(TrackBitLocations::kRinvMSB, TrackBitLocations::kRinvLSB); }

References getTrackWord().

Referenced by getRinvBits().

◆ getTanl()

double TTTrack_TrackWord::getTanl ( ) const
inline

Definition at line 219 of file TTTrack_TrackWord.h.

219 { return undigitizeSignedValue(getTanlBits(), TrackBitWidths::kTanlSize, stepTanL); }

References getTanlBits(), stepTanL, and undigitizeSignedValue().

◆ getTanlBits()

unsigned int TTTrack_TrackWord::getTanlBits ( ) const
inline

Definition at line 204 of file TTTrack_TrackWord.h.

204 { return getTanlWord().to_uint(); }

References getTanlWord().

Referenced by getTanl().

◆ getTanlWord()

tanl_t TTTrack_TrackWord::getTanlWord ( ) const
inline

Definition at line 175 of file TTTrack_TrackWord.h.

175 { return getTrackWord()(TrackBitLocations::kTanlMSB, TrackBitLocations::kTanlLSB); }

References getTrackWord().

Referenced by getTanlBits().

◆ getTrackWord()

tkword_t TTTrack_TrackWord::getTrackWord ( ) const
inline

◆ getValid()

bool TTTrack_TrackWord::getValid ( ) const
inline

Definition at line 216 of file TTTrack_TrackWord.h.

216 { return getValidWord().to_bool(); }

References getValidWord().

◆ getValidBits()

unsigned int TTTrack_TrackWord::getValidBits ( ) const
inline

Definition at line 201 of file TTTrack_TrackWord.h.

201 { return getValidWord().to_uint(); }

References getValidWord().

◆ getValidWord()

valid_t TTTrack_TrackWord::getValidWord ( ) const
inline

Definition at line 172 of file TTTrack_TrackWord.h.

172 { return getTrackWord()(TrackBitLocations::kValidMSB, TrackBitLocations::kValidLSB); }

References getTrackWord().

Referenced by getValid(), and getValidBits().

◆ getZ0()

double TTTrack_TrackWord::getZ0 ( ) const
inline

Definition at line 220 of file TTTrack_TrackWord.h.

220 { return undigitizeSignedValue(getZ0Bits(), TrackBitWidths::kZ0Size, stepZ0); }

References getZ0Bits(), stepZ0, and undigitizeSignedValue().

◆ getZ0Bits()

unsigned int TTTrack_TrackWord::getZ0Bits ( ) const
inline

Definition at line 205 of file TTTrack_TrackWord.h.

205 { return getZ0Word().to_uint(); }

References getZ0Word().

Referenced by getZ0().

◆ getZ0Word()

z0_t TTTrack_TrackWord::getZ0Word ( ) const
inline

Definition at line 176 of file TTTrack_TrackWord.h.

176 { return getTrackWord()(TrackBitLocations::kZ0MSB, TrackBitLocations::kZ0LSB); }

References getTrackWord().

Referenced by getZ0Bits().

◆ localPhi()

float TTTrack_TrackWord::localPhi ( float  globalPhi,
unsigned int  sector 
) const
inlineprotected

Definition at line 274 of file TTTrack_TrackWord.h.

274  {
275  return reco::deltaPhi(globalPhi, (sector * sectorWidth));
276  }

References reco::deltaPhi(), and sectorWidth.

Referenced by TTTrack< T >::localPhi(), and setTrackWord().

◆ operator=()

TTTrack_TrackWord& TTTrack_TrackWord::operator= ( const TTTrack_TrackWord word)
inline

Definition at line 164 of file TTTrack_TrackWord.h.

164  {
165  trackWord_ = word.trackWord_;
166  return *this;
167  }

References trackWord_.

◆ setTrackWord() [1/3]

void TTTrack_TrackWord::setTrackWord ( ap_uint< TrackBitWidths::kValidSize >  valid,
ap_uint< TrackBitWidths::kRinvSize >  rInv,
ap_uint< TrackBitWidths::kPhiSize >  phi0,
ap_uint< TrackBitWidths::kTanlSize >  tanl,
ap_uint< TrackBitWidths::kZ0Size >  z0,
ap_uint< TrackBitWidths::kD0Size >  d0,
ap_uint< TrackBitWidths::kChi2RPhiSize >  chi2RPhi,
ap_uint< TrackBitWidths::kChi2RZSize >  chi2RZ,
ap_uint< TrackBitWidths::kBendChi2Size >  bendChi2,
ap_uint< TrackBitWidths::kHitPatternSize >  hitPattern,
ap_uint< TrackBitWidths::kMVAQualitySize >  mvaQuality,
ap_uint< TrackBitWidths::kMVAOtherSize >  mvaOther 
)

Definition at line 132 of file TTTrack_TrackWord.cc.

144  {
145  // pack the track word
146  unsigned int offset = 0;
147  for (unsigned int b = offset; b < (offset + TrackBitWidths::kMVAOtherSize); b++) {
148  trackWord_.set(b, mvaOther[b - offset]);
149  }
150  offset += TrackBitWidths::kMVAOtherSize;
151  for (unsigned int b = offset; b < (offset + TrackBitWidths::kMVAQualitySize); b++) {
152  trackWord_.set(b, mvaQuality[b - offset]);
153  }
154  offset += TrackBitWidths::kMVAQualitySize;
155  for (unsigned int b = offset; b < (offset + TrackBitWidths::kHitPatternSize); b++) {
156  trackWord_.set(b, hitPattern[b - offset]);
157  }
158  offset += TrackBitWidths::kHitPatternSize;
159  for (unsigned int b = offset; b < (offset + TrackBitWidths::kBendChi2Size); b++) {
160  trackWord_.set(b, bendChi2[b - offset]);
161  }
162  offset += TrackBitWidths::kBendChi2Size;
163  for (unsigned int b = offset; b < (offset + TrackBitWidths::kD0Size); b++) {
164  trackWord_.set(b, d0[b - offset]);
165  }
166  offset += TrackBitWidths::kD0Size;
167  for (unsigned int b = offset; b < (offset + TrackBitWidths::kChi2RZSize); b++) {
168  trackWord_.set(b, chi2RZ[b - offset]);
169  }
170  offset += TrackBitWidths::kChi2RZSize;
171  for (unsigned int b = offset; b < (offset + TrackBitWidths::kZ0Size); b++) {
172  trackWord_.set(b, z0[b - offset]);
173  }
174  offset += TrackBitWidths::kZ0Size;
175  for (unsigned int b = offset; b < (offset + TrackBitWidths::kTanlSize); b++) {
176  trackWord_.set(b, tanl[b - offset]);
177  }
178  offset += TrackBitWidths::kTanlSize;
179  for (unsigned int b = offset; b < (offset + TrackBitWidths::kChi2RPhiSize); b++) {
180  trackWord_.set(b, chi2RPhi[b - offset]);
181  }
182  offset += TrackBitWidths::kChi2RPhiSize;
183  for (unsigned int b = offset; b < (offset + TrackBitWidths::kPhiSize); b++) {
184  trackWord_.set(b, phi0[b - offset]);
185  }
186  offset += TrackBitWidths::kPhiSize;
187  for (unsigned int b = offset; b < (offset + TrackBitWidths::kRinvSize); b++) {
188  trackWord_.set(b, rInv[b - offset]);
189  }
190  offset += TrackBitWidths::kRinvSize;
191  for (unsigned int b = offset; b < offset + TrackBitWidths::kValidSize; b++) {
192  trackWord_.set(b, valid[b - offset]);
193  }
194 }

References b, d0, hltrates_dqm_sourceclient-live_cfg::offset, trackWord_, RunInfoPI::valid, and HLTMuonOfflineAnalyzer_cfi::z0.

◆ setTrackWord() [2/3]

void TTTrack_TrackWord::setTrackWord ( unsigned int  valid,
const GlobalVector momentum,
const GlobalPoint POCA,
double  rInv,
double  chi2RPhi,
double  chi2RZ,
double  bendChi2,
unsigned int  hitPattern,
unsigned int  mvaQuality,
unsigned int  mvaOther,
unsigned int  sector 
)

Definition at line 60 of file TTTrack_TrackWord.cc.

70  {
71  // first, derive quantities to be packed
72  float rPhi = localPhi(momentum.phi(), sector); // this needs to be phi relative to the center of the sector
73  float rTanl = momentum.z() / momentum.perp();
74  float rZ0 = POCA.z();
75  float rD0 = POCA.perp();
76 
77  // bin and convert to integers
79  rinv_t rInv_ = digitizeSignedValue(rInv, TrackBitWidths::kRinvSize, stepRinv);
80  phi_t phi0_ = digitizeSignedValue(rPhi, TrackBitWidths::kPhiSize, stepPhi0);
81  tanl_t tanl_ = digitizeSignedValue(rTanl, TrackBitWidths::kTanlSize, stepTanL);
82  z0_t z0_ = digitizeSignedValue(rZ0, TrackBitWidths::kZ0Size, stepZ0);
83  d0_t d0_ = digitizeSignedValue(rD0, TrackBitWidths::kD0Size, stepD0);
84  chi2rphi_t chi2RPhi_ = getBin(chi2RPhi, chi2RPhiBins);
85  chi2rz_t chi2RZ_ = getBin(chi2RZ, chi2RZBins);
86  bendChi2_t bendChi2_ = getBin(bendChi2, bendChi2Bins);
87  hit_t hitPattern_ = hitPattern;
88  qualityMVA_t mvaQuality_ = mvaQuality;
89  otherMVA_t mvaOther_ = mvaOther;
90 
91  // pack the track word
92  //trackWord = ( mvaOther_, mvaQuality_, hitPattern_, bendChi2_, chi2RZ_, chi2RPhi_, d0_, z0_, tanl_, phi0_, rInv_, valid_ );
94  valid_, rInv_, phi0_, tanl_, z0_, d0_, chi2RPhi_, chi2RZ_, bendChi2_, hitPattern_, mvaQuality_, mvaOther_);
95 }

References bendChi2Bins, chi2RPhiBins, chi2RZBins, digitizeSignedValue(), getBin(), localPhi(), PV3DBase< T, PVType, FrameType >::perp(), PV3DBase< T, PVType, FrameType >::phi(), stepD0, stepPhi0, stepRinv, stepTanL, stepZ0, RunInfoPI::valid, sistrip::valid_, and PV3DBase< T, PVType, FrameType >::z().

Referenced by setTrackWord(), and TTTrack_TrackWord().

◆ setTrackWord() [3/3]

void TTTrack_TrackWord::setTrackWord ( unsigned int  valid,
unsigned int  rInv,
unsigned int  phi0,
unsigned int  tanl,
unsigned int  z0,
unsigned int  d0,
unsigned int  chi2RPhi,
unsigned int  chi2RZ,
unsigned int  bendChi2,
unsigned int  hitPattern,
unsigned int  mvaQuality,
unsigned int  mvaOther 
)

Definition at line 98 of file TTTrack_TrackWord.cc.

109  {
110  // bin and convert to integers
111  valid_t valid_ = valid;
112  rinv_t rInv_ = rInv;
113  phi_t phi0_ = phi0;
114  tanl_t tanl_ = tanl;
115  z0_t z0_ = z0;
116  d0_t d0_ = d0;
117  chi2rphi_t chi2RPhi_ = chi2RPhi;
118  chi2rz_t chi2RZ_ = chi2RZ;
119  bendChi2_t bendChi2_ = bendChi2;
120  hit_t hitPattern_ = hitPattern;
121  qualityMVA_t mvaQuality_ = mvaQuality;
122  otherMVA_t mvaOther_ = mvaOther;
123 
124  // pack the track word
125  //trackWord = ( otherMVA_t(mvaOther), qualityMVA_t(mvaQuality), hit_t(hitPattern),
126  // bendChi2_t(bendChi2), chi2rz_t(chi2RZ), chi2rphi_t(chi2RPhi),
127  // d0_t(d0), z0_t(z0), tanl_t(tanl), phi_t(phi0), rinv_t(rInv), valid_t(valid) );
128  setTrackWord(
129  valid_, rInv_, phi0_, tanl_, z0_, d0_, chi2RPhi_, chi2RZ_, bendChi2_, hitPattern_, mvaQuality_, mvaOther_);
130 }

References d0, setTrackWord(), RunInfoPI::valid, sistrip::valid_, and HLTMuonOfflineAnalyzer_cfi::z0.

◆ singleDigitizationSchemeTest()

bool TTTrack_TrackWord::singleDigitizationSchemeTest ( const double  floatingPointValue,
const unsigned int  nBits,
const double  lsb 
) const

Definition at line 196 of file TTTrack_TrackWord.cc.

198  {
199  unsigned int digitizedSignedValue = digitizeSignedValue(floatingPointValue, nBits, lsb);
200  double undigitizedSignedValue = undigitizeSignedValue(digitizedSignedValue, nBits, lsb);
201  unsigned int redigitizedSignedValue = digitizeSignedValue(undigitizedSignedValue, nBits, lsb);
203  nBits, lsb, floatingPointValue, digitizedSignedValue, undigitizedSignedValue, redigitizedSignedValue);
204  return (std::abs(floatingPointValue - undigitizedSignedValue) <= (lsb / 2.0)) &&
205  (digitizedSignedValue == redigitizedSignedValue);
206 }

References funct::abs(), digitizeSignedValue(), tttrack_trackword::infoTestDigitizationScheme(), hgcalVFEProducer_cfi::lsb, and undigitizeSignedValue().

Referenced by testDigitizationScheme().

◆ testDigitizationScheme()

void TTTrack_TrackWord::testDigitizationScheme ( ) const

Definition at line 208 of file TTTrack_TrackWord.cc.

208  {
209  /*
210  Expected output:
211  testDigitizationScheme: Floating point value = -4 Digitized value = 4 Un-digitized value = -3.5
212  testDigitizationScheme: Floating point value = 3 Digitized value = 3 Un-digitized value = 3.5
213  testDigitizationScheme: Floating point value = -3.5 Digitized value = 9 Un-digitized value = -3.25
214  testDigitizationScheme: Floating point value = 3.5 Digitized value = 7 Un-digitized value = 3.75
215  */
216  assert(singleDigitizationSchemeTest(-4.0, 3, 1.0));
217  assert(singleDigitizationSchemeTest(3.0, 3, 1.0));
218  assert(singleDigitizationSchemeTest(-3.5, 4, 0.5));
219  assert(singleDigitizationSchemeTest(3.5, 4, 0.5));
220 }

References cms::cuda::assert(), and singleDigitizationSchemeTest().

◆ undigitizeSignedValue()

double TTTrack_TrackWord::undigitizeSignedValue ( unsigned int  twosValue,
unsigned int  nBits,
double  lsb 
) const
inlineprivate

Definition at line 306 of file TTTrack_TrackWord.h.

306  {
307  // Check that none of the bits above the nBits-1 bit, in a range of [0, nBits-1], are set.
308  // This makes sure that it isn't possible for the value represented by `twosValue` to be
309  // any bigger than ((1 << nBits) - 1).
310  assert((twosValue >> nBits) == 0);
311 
312  // Convert from twos compliment to C++ signed integer (normal digitized value)
313  int digitizedValue = twosValue;
314  if (twosValue & (1 << (nBits - 1))) { // check if the twosValue is negative
315  digitizedValue -= (1 << nBits);
316  }
317 
318  // Convert to floating point value
319  return (double(digitizedValue) + 0.5) * lsb;
320  }

References cms::cuda::assert(), and hgcalVFEProducer_cfi::lsb.

Referenced by getD0(), getPhi(), getRinv(), getTanl(), getZ0(), and singleDigitizationSchemeTest().

Member Data Documentation

◆ bendChi2Bins

constexpr std::array<double, 1 << TrackBitWidths::kBendChi2Size> TTTrack_TrackWord::bendChi2Bins
staticconstexpr
Initial value:
= {
{0.0, 0.75, 1.0, 1.5, 2.25, 3.5, 5.0, 20.0}}

Definition at line 104 of file TTTrack_TrackWord.h.

Referenced by getBendChi2(), and setTrackWord().

◆ chi2RPhiBins

constexpr std::array<double, 1 << TrackBitWidths::kChi2RPhiSize> TTTrack_TrackWord::chi2RPhiBins
staticconstexpr
Initial value:
= {
{0.0, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 5.0, 6.0, 10.0, 15.0, 20.0, 35.0, 60.0, 200.0}}

Definition at line 100 of file TTTrack_TrackWord.h.

Referenced by getChi2RPhi(), and setTrackWord().

◆ chi2RZBins

constexpr std::array<double, 1 << TrackBitWidths::kChi2RZSize> TTTrack_TrackWord::chi2RZBins
staticconstexpr
Initial value:
= {
{0.0, 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, 6.0, 8.0, 10.0, 20.0, 50.0}}

Definition at line 102 of file TTTrack_TrackWord.h.

Referenced by getChi2RZ(), and setTrackWord().

◆ minD0

constexpr double TTTrack_TrackWord::minD0 = -16.
staticconstexpr

Definition at line 91 of file TTTrack_TrackWord.h.

◆ minPhi0

constexpr double TTTrack_TrackWord::minPhi0 = -0.7853981696
staticconstexpr

Definition at line 88 of file TTTrack_TrackWord.h.

◆ minRinv

constexpr double TTTrack_TrackWord::minRinv = -0.006
staticconstexpr

Definition at line 87 of file TTTrack_TrackWord.h.

◆ minTanl

constexpr double TTTrack_TrackWord::minTanl = -8.
staticconstexpr

Definition at line 89 of file TTTrack_TrackWord.h.

◆ minZ0

constexpr double TTTrack_TrackWord::minZ0 = -20.46912512
staticconstexpr

Definition at line 90 of file TTTrack_TrackWord.h.

◆ nSectors

constexpr unsigned int TTTrack_TrackWord::nSectors = 9
staticconstexpr

Definition at line 108 of file TTTrack_TrackWord.h.

◆ sectorWidth

constexpr double TTTrack_TrackWord::sectorWidth = (2. * M_PI) / nSectors
staticconstexpr

Definition at line 109 of file TTTrack_TrackWord.h.

Referenced by localPhi().

◆ stepD0

constexpr double TTTrack_TrackWord::stepD0 = (1. / (1 << 8))
staticconstexpr

Definition at line 97 of file TTTrack_TrackWord.h.

Referenced by getD0(), and setTrackWord().

◆ stepPhi0

constexpr double TTTrack_TrackWord::stepPhi0 = (2. * std::abs(minPhi0)) / (1 << TrackBitWidths::kPhiSize)
staticconstexpr

Definition at line 94 of file TTTrack_TrackWord.h.

Referenced by getPhi(), and setTrackWord().

◆ stepRinv

constexpr double TTTrack_TrackWord::stepRinv = (2. * std::abs(minRinv)) / (1 << TrackBitWidths::kRinvSize)
staticconstexpr

Definition at line 93 of file TTTrack_TrackWord.h.

Referenced by getRinv(), and setTrackWord().

◆ stepTanL

constexpr double TTTrack_TrackWord::stepTanL = (1. / (1 << 12))
staticconstexpr

Definition at line 95 of file TTTrack_TrackWord.h.

Referenced by getTanl(), and setTrackWord().

◆ stepZ0

constexpr double TTTrack_TrackWord::stepZ0 = (2. * std::abs(minZ0)) / (1 << TrackBitWidths::kZ0Size)
staticconstexpr

Definition at line 96 of file TTTrack_TrackWord.h.

Referenced by getZ0(), and setTrackWord().

◆ trackWord_

tkword_bs_t TTTrack_TrackWord::trackWord_
private

Definition at line 323 of file TTTrack_TrackWord.h.

Referenced by getTrackWord(), operator=(), setTrackWord(), and TTTrack_TrackWord().

TTTrack_TrackWord::getD0Bits
unsigned int getD0Bits() const
Definition: TTTrack_TrackWord.h:206
TTTrack_TrackWord::getChi2RZWord
chi2rz_t getChi2RZWord() const
Definition: TTTrack_TrackWord.h:181
pfDeepBoostedJetPreprocessParams_cfi.upper_bound
upper_bound
Definition: pfDeepBoostedJetPreprocessParams_cfi.py:16
TTTrack_TrackWord::chi2rz_t
ap_uint< TrackBitWidths::kChi2RZSize > chi2rz_t
Definition: TTTrack_TrackWord.h:123
TTTrack_TrackWord::kChi2RPhiLSB
Definition: TTTrack_TrackWord.h:76
TTTrack_TrackWord::chi2rphi_t
ap_uint< TrackBitWidths::kChi2RPhiSize > chi2rphi_t
Definition: TTTrack_TrackWord.h:122
TTTrack_TrackWord::kBendChi2Size
Definition: TTTrack_TrackWord.h:43
TTTrack_TrackWord::getChi2RZBits
unsigned int getChi2RZBits() const
Definition: TTTrack_TrackWord.h:208
TTTrack_TrackWord::kRinvSize
Definition: TTTrack_TrackWord.h:50
TTTrack_TrackWord::getZ0Bits
unsigned int getZ0Bits() const
Definition: TTTrack_TrackWord.h:205
reco::deltaPhi
constexpr double deltaPhi(double phi1, double phi2)
Definition: deltaPhi.h:26
tttrack_trackword::infoTestDigitizationScheme
void infoTestDigitizationScheme(const unsigned int, const double, const double, const unsigned int, const double, const unsigned int)
Definition: TTTrack_TrackWord.cc:16
TTTrack_TrackWord::getRinvWord
rinv_t getRinvWord() const
Definition: TTTrack_TrackWord.h:173
TTTrack_TrackWord::kTrackWordSize
Definition: TTTrack_TrackWord.h:53
TTTrack_TrackWord::getRinvBits
unsigned int getRinvBits() const
Definition: TTTrack_TrackWord.h:202
TTTrack_TrackWord::getBin
constexpr unsigned int getBin(double value, const T &bins) const
Definition: TTTrack_TrackWord.h:301
TTTrack_TrackWord::hit_t
ap_uint< TrackBitWidths::kHitPatternSize > hit_t
Definition: TTTrack_TrackWord.h:125
TTTrack_TrackWord::getPhiWord
phi_t getPhiWord() const
Definition: TTTrack_TrackWord.h:174
cms::cuda::assert
assert(be >=bs)
TTTrack_TrackWord::getPhiBits
unsigned int getPhiBits() const
Definition: TTTrack_TrackWord.h:203
TTTrack_TrackWord::kChi2RZSize
Definition: TTTrack_TrackWord.h:45
TTTrack_TrackWord::getValidWord
valid_t getValidWord() const
Definition: TTTrack_TrackWord.h:172
TTTrack_TrackWord::chi2RZBins
static constexpr std::array< double, 1<< TrackBitWidths::kChi2RZSize > chi2RZBins
Definition: TTTrack_TrackWord.h:102
TTTrack_TrackWord::kChi2RPhiMSB
Definition: TTTrack_TrackWord.h:77
TTTrack_TrackWord::getD0Word
d0_t getD0Word() const
Definition: TTTrack_TrackWord.h:177
TTTrack_TrackWord::kTanlMSB
Definition: TTTrack_TrackWord.h:75
TTTrack_TrackWord::bendChi2_t
ap_uint< TrackBitWidths::kBendChi2Size > bendChi2_t
Definition: TTTrack_TrackWord.h:124
hgcalVFEProducer_cfi.lsb
lsb
Definition: hgcalVFEProducer_cfi.py:80
TTTrack_TrackWord::d0_t
ap_uint< TrackBitWidths::kD0Size > d0_t
Definition: TTTrack_TrackWord.h:119
TTTrack_TrackWord::kChi2RZMSB
Definition: TTTrack_TrackWord.h:71
TTTrack_TrackWord::chi2RPhiBins
static constexpr std::array< double, 1<< TrackBitWidths::kChi2RPhiSize > chi2RPhiBins
Definition: TTTrack_TrackWord.h:100
TTTrack_TrackWord::kPhiMSB
Definition: TTTrack_TrackWord.h:79
TTTrack_TrackWord::trackWord_
tkword_bs_t trackWord_
Definition: TTTrack_TrackWord.h:323
TTTrack_TrackWord::kBendChi2MSB
Definition: TTTrack_TrackWord.h:67
sistrip::valid_
static const uint16_t valid_
Definition: Constants.h:17
TTTrack_TrackWord::stepTanL
static constexpr double stepTanL
Definition: TTTrack_TrackWord.h:95
PV3DBase::z
T z() const
Definition: PV3DBase.h:61
TTTrack_TrackWord::kValidMSB
Definition: TTTrack_TrackWord.h:83
word
uint64_t word
Definition: CTPPSTotemDataFormatter.cc:29
TTTrack_TrackWord::singleDigitizationSchemeTest
bool singleDigitizationSchemeTest(const double floatingPointValue, const unsigned int nBits, const double lsb) const
Definition: TTTrack_TrackWord.cc:196
TTTrack_TrackWord::kD0LSB
Definition: TTTrack_TrackWord.h:68
TTTrack_TrackWord::kZ0LSB
Definition: TTTrack_TrackWord.h:72
TTTrack_TrackWord::kMVAOtherSize
Definition: TTTrack_TrackWord.h:40
TTTrack_TrackWord::localPhi
float localPhi(float globalPhi, unsigned int sector) const
Definition: TTTrack_TrackWord.h:274
TTTrack_TrackWord::getChi2RPhiWord
chi2rphi_t getChi2RPhiWord() const
Definition: TTTrack_TrackWord.h:178
TTTrack_TrackWord::getBendChi2Bits
unsigned int getBendChi2Bits() const
Definition: TTTrack_TrackWord.h:209
TTTrack_TrackWord::kBendChi2LSB
Definition: TTTrack_TrackWord.h:66
TTTrack_TrackWord::kRinvMSB
Definition: TTTrack_TrackWord.h:81
TTTrack_TrackWord::getZ0Word
z0_t getZ0Word() const
Definition: TTTrack_TrackWord.h:176
TTTrack_TrackWord::stepD0
static constexpr double stepD0
Definition: TTTrack_TrackWord.h:97
TTTrack_TrackWord::tkword_t
ap_uint< TrackBitWidths::kTrackWordSize > tkword_t
Definition: TTTrack_TrackWord.h:131
TTTrack_TrackWord::kMVAOtherMSB
Definition: TTTrack_TrackWord.h:61
TTTrack_TrackWord::kChi2RPhiSize
Definition: TTTrack_TrackWord.h:48
TTTrack_TrackWord::kPhiLSB
Definition: TTTrack_TrackWord.h:78
HLTMuonOfflineAnalyzer_cfi.z0
z0
Definition: HLTMuonOfflineAnalyzer_cfi.py:98
TTTrack_TrackWord::setTrackWord
void setTrackWord(unsigned int valid, const GlobalVector &momentum, const GlobalPoint &POCA, double rInv, double chi2RPhi, double chi2RZ, double bendChi2, unsigned int hitPattern, unsigned int mvaQuality, unsigned int mvaOther, unsigned int sector)
Definition: TTTrack_TrackWord.cc:60
b
double b
Definition: hdecay.h:118
TTTrack_TrackWord::kZ0MSB
Definition: TTTrack_TrackWord.h:73
TTTrack_TrackWord::getMVAQualityWord
qualityMVA_t getMVAQualityWord() const
Definition: TTTrack_TrackWord.h:190
TTTrack_TrackWord::kD0Size
Definition: TTTrack_TrackWord.h:44
TTTrack_TrackWord::kTanlSize
Definition: TTTrack_TrackWord.h:47
TTTrack_TrackWord::getHitPatternWord
hit_t getHitPatternWord() const
Definition: TTTrack_TrackWord.h:187
TTTrack_TrackWord::sectorWidth
static constexpr double sectorWidth
Definition: TTTrack_TrackWord.h:109
TTTrack_TrackWord::kValidLSB
Definition: TTTrack_TrackWord.h:82
TTTrack_TrackWord::getTanlWord
tanl_t getTanlWord() const
Definition: TTTrack_TrackWord.h:175
TTTrack_TrackWord::kChi2RZLSB
Definition: TTTrack_TrackWord.h:70
TTTrack_TrackWord::getMVAOtherBits
unsigned int getMVAOtherBits() const
Definition: TTTrack_TrackWord.h:212
TTTrack_TrackWord::getMVAQualityBits
unsigned int getMVAQualityBits() const
Definition: TTTrack_TrackWord.h:211
TTTrack_TrackWord::getMVAOtherWord
otherMVA_t getMVAOtherWord() const
Definition: TTTrack_TrackWord.h:193
TTTrack_TrackWord::tanl_t
ap_uint< TrackBitWidths::kTanlSize > tanl_t
Definition: TTTrack_TrackWord.h:117
TTTrack_TrackWord::kTanlLSB
Definition: TTTrack_TrackWord.h:74
value
Definition: value.py:1
TTTrack_TrackWord::kRinvLSB
Definition: TTTrack_TrackWord.h:80
TTTrack_TrackWord::kMVAQualityLSB
Definition: TTTrack_TrackWord.h:62
TTTrack_TrackWord::kHitPatternMSB
Definition: TTTrack_TrackWord.h:65
TTTrack_TrackWord::kHitPatternLSB
Definition: TTTrack_TrackWord.h:64
TTTrack_TrackWord::otherMVA_t
ap_uint< TrackBitWidths::kMVAOtherSize > otherMVA_t
Definition: TTTrack_TrackWord.h:127
TTTrack_TrackWord::getTanlBits
unsigned int getTanlBits() const
Definition: TTTrack_TrackWord.h:204
TTTrack_TrackWord::rinv_t
ap_uint< TrackBitWidths::kRinvSize > rinv_t
Definition: TTTrack_TrackWord.h:115
TTTrack_TrackWord::stepZ0
static constexpr double stepZ0
Definition: TTTrack_TrackWord.h:96
TTTrack_TrackWord::kMVAQualityMSB
Definition: TTTrack_TrackWord.h:63
TTTrack_TrackWord::getChi2RPhiBits
unsigned int getChi2RPhiBits() const
Definition: TTTrack_TrackWord.h:207
TTTrack_TrackWord::valid_t
ap_uint< TrackBitWidths::kValidSize > valid_t
Definition: TTTrack_TrackWord.h:112
TTTrack_TrackWord::kPhiSize
Definition: TTTrack_TrackWord.h:49
relativeConstraints.value
value
Definition: relativeConstraints.py:53
TTTrack_TrackWord::digitizeSignedValue
unsigned int digitizeSignedValue(double value, unsigned int nBits, double lsb) const
Definition: TTTrack_TrackWord.h:280
TTTrack_TrackWord::getHitPatternBits
unsigned int getHitPatternBits() const
Definition: TTTrack_TrackWord.h:210
TTTrack_TrackWord::stepRinv
static constexpr double stepRinv
Definition: TTTrack_TrackWord.h:93
TTTrack_TrackWord::phi_t
ap_uint< TrackBitWidths::kPhiSize > phi_t
Definition: TTTrack_TrackWord.h:116
z0_t
ap_int< 10 > z0_t
Definition: data.h:10
TTTrack_TrackWord::kD0MSB
Definition: TTTrack_TrackWord.h:69
TTTrack_TrackWord::kMVAQualitySize
Definition: TTTrack_TrackWord.h:41
TTTrack_TrackWord::kValidSize
Definition: TTTrack_TrackWord.h:51
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
RunInfoPI::valid
Definition: RunInfoPayloadInspectoHelper.h:16
trigObjTnPSource_cfi.bins
bins
Definition: trigObjTnPSource_cfi.py:20
TTTrack_TrackWord::getBendChi2Word
bendChi2_t getBendChi2Word() const
Definition: TTTrack_TrackWord.h:184
hltrates_dqm_sourceclient-live_cfg.offset
offset
Definition: hltrates_dqm_sourceclient-live_cfg.py:82
TTTrack_TrackWord::qualityMVA_t
ap_uint< TrackBitWidths::kMVAQualitySize > qualityMVA_t
Definition: TTTrack_TrackWord.h:126
TTTrack_TrackWord::bendChi2Bins
static constexpr std::array< double, 1<< TrackBitWidths::kBendChi2Size > bendChi2Bins
Definition: TTTrack_TrackWord.h:104
TTTrack_TrackWord::kHitPatternSize
Definition: TTTrack_TrackWord.h:42
TTTrack_TrackWord::getTrackWord
tkword_t getTrackWord() const
Definition: TTTrack_TrackWord.h:196
d0
static constexpr float d0
Definition: L1EGammaCrystalsEmulatorProducer.cc:85
TTTrack_TrackWord::stepPhi0
static constexpr double stepPhi0
Definition: TTTrack_TrackWord.h:94
PV3DBase::perp
T perp() const
Definition: PV3DBase.h:69
PV3DBase::phi
Geom::Phi< T > phi() const
Definition: PV3DBase.h:66
up
Definition: BitonicSort.h:7
TTTrack_TrackWord::kZ0Size
Definition: TTTrack_TrackWord.h:46
TTTrack_TrackWord::kMVAOtherLSB
Definition: TTTrack_TrackWord.h:60
TTTrack_TrackWord::undigitizeSignedValue
double undigitizeSignedValue(unsigned int twosValue, unsigned int nBits, double lsb) const
Definition: TTTrack_TrackWord.h:306