CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes | Friends
VpspScanAnalysis Class Reference

Histogram-based analysis for VPSP scan. More...

#include <VpspScanAnalysis.h>

Inheritance diagram for VpspScanAnalysis:
CommissioningAnalysis

Public Member Functions

const VIntadcLevel () const
 
const VIntbottomEdge () const
 
const VIntbottomLevel () const
 
const VIntfraction () const
 
bool isValid () const override
 
void print (std::stringstream &, uint32_t not_used=0) override
 
void reset () override
 
void summary (std::stringstream &) const override
 
const VInttopEdge () const
 
const VInttopLevel () const
 
const VIntvpsp () const
 
 VpspScanAnalysis ()
 
 VpspScanAnalysis (const uint32_t &key)
 
 ~VpspScanAnalysis () override
 
- Public Member Functions inherited from CommissioningAnalysis
virtual void addErrorCode (const std::string &error)
 
 CommissioningAnalysis (const std::string &my_name)
 
 CommissioningAnalysis (const uint32_t &key, const std::string &my_name)
 
const uint32_t & dcuId () const
 
void dcuId (const uint32_t &)
 
const uint32_t & detId () const
 
void detId (const uint32_t &)
 
const uint32_t & fecKey () const
 
void fecKey (const uint32_t &)
 
const uint32_t & fedKey () const
 
void fedKey (const uint32_t &)
 
const VStringgetErrorCodes () const
 
virtual void header (std::stringstream &) const
 
const std::string & myName () const
 
void setErrorCodes (const VString &errors)
 
virtual ~CommissioningAnalysis ()
 

Private Attributes

VInt adcLevel_
 
VInt bottomEdge_
 
VInt bottomLevel_
 
VInt fraction_
 
VInt topEdge_
 
VInt topLevel_
 
VInt vpsp_
 

Friends

class VpspScanAlgorithm
 

Additional Inherited Members

- Public Types inherited from CommissioningAnalysis
typedef std::vector< bool > VBool
 
typedef std::vector< float > VFloat
 
typedef std::vector< uint16_t > VInt
 
typedef std::vector< std::string > VString
 
typedef std::vector< VBoolVVBool
 
typedef std::vector< VFloatVVFloat
 
typedef std::vector< VIntVVInt
 

Detailed Description

Histogram-based analysis for VPSP scan.

Author
M. Wingham, R.Bainbridge

Definition at line 15 of file VpspScanAnalysis.h.

Constructor & Destructor Documentation

◆ VpspScanAnalysis() [1/2]

VpspScanAnalysis::VpspScanAnalysis ( const uint32_t &  key)

Definition at line 14 of file VpspScanAnalysis.cc.

◆ VpspScanAnalysis() [2/2]

VpspScanAnalysis::VpspScanAnalysis ( )

Definition at line 28 of file VpspScanAnalysis.cc.

◆ ~VpspScanAnalysis()

VpspScanAnalysis::~VpspScanAnalysis ( )
inlineoverride

Definition at line 23 of file VpspScanAnalysis.h.

23 { ; }

Member Function Documentation

◆ adcLevel()

const VpspScanAnalysis::VInt & VpspScanAnalysis::adcLevel ( ) const
inline

Signal levels [ADC] for VPSP settings.

Definition at line 86 of file VpspScanAnalysis.h.

86 { return adcLevel_; }

References adcLevel_.

◆ bottomEdge()

const VpspScanAnalysis::VInt & VpspScanAnalysis::bottomEdge ( ) const
inline

VPSP setting where baseline leaves "D0" level.

Definition at line 89 of file VpspScanAnalysis.h.

89 { return bottomEdge_; }

References bottomEdge_.

◆ bottomLevel()

const VpspScanAnalysis::VInt & VpspScanAnalysis::bottomLevel ( ) const
inline

Signal level [ADC] for "digital zero".

Definition at line 91 of file VpspScanAnalysis.h.

91 { return bottomLevel_; }

References bottomLevel_.

◆ fraction()

const VpspScanAnalysis::VInt & VpspScanAnalysis::fraction ( ) const
inline

Not used.

Definition at line 87 of file VpspScanAnalysis.h.

87 { return fraction_; }

References fraction_.

◆ isValid()

bool VpspScanAnalysis::isValid ( void  ) const
overridevirtual

Identifies if analysis is valid or not.

Reimplemented from CommissioningAnalysis.

Definition at line 46 of file VpspScanAnalysis.cc.

46  {
47  return (vpsp_[0] < 1. * sistrip::valid_ && vpsp_[1] < 1. * sistrip::valid_ && adcLevel_[0] < 1. * sistrip::valid_ &&
48  adcLevel_[1] < 1. * sistrip::valid_ && topLevel_[0] < 1. * sistrip::valid_ &&
49  topLevel_[1] < 1. * sistrip::valid_ && bottomLevel_[0] < 1. * sistrip::valid_ &&
51 }

References adcLevel_, bottomLevel_, relativeConstraints::empty, CommissioningAnalysis::getErrorCodes(), topLevel_, sistrip::valid_, and vpsp_.

Referenced by ntupleDataFormat._Object::_checkIsValid(), print(), core.AutoHandle.AutoHandle::ReallyLoad(), and summary().

◆ print()

void VpspScanAnalysis::print ( std::stringstream &  ss,
uint32_t  not_used = 0 
)
overridevirtual

Prints analysis results.

Implements CommissioningAnalysis.

Definition at line 93 of file VpspScanAnalysis.cc.

93  {
94  if (iapv == 1 || iapv == 2) {
95  iapv--;
96  } else {
97  iapv = 0;
98  }
99  header(ss);
100  ss << " Monitorables for APV : " << iapv;
101  if (iapv == 0) {
102  ss << " (first of pair)";
103  } else if (iapv == 1) {
104  ss << " (second of pair)";
105  }
106  ss << std::endl;
107  ss << std::fixed << std::setprecision(2) << " VPSP setting : " << vpsp_[iapv] << std::endl
108  << " Signal level [ADC] : " << adcLevel_[iapv] << std::endl
109  << " Fraction [%] : "
110  << "(N/A)" /*fraction_[iapv]*/ << std::endl
111  << " Top edge [bin] : " << topEdge_[iapv] << std::endl
112  << " Bottom edge [bin] : " << bottomEdge_[iapv] << std::endl
113  << " Top level [ADC] : " << topLevel_[iapv] << std::endl
114  << " Bottom level [ADC] : " << bottomLevel_[iapv] << std::endl
115  << std::boolalpha << " isValid : " << isValid() << std::endl
116  << std::noboolalpha << " Error codes (found " << std::setw(2) << std::setfill(' ') << getErrorCodes().size()
117  << "): ";
118  if (getErrorCodes().empty()) {
119  ss << "(none)";
120  } else {
121  VString::const_iterator istr = getErrorCodes().begin();
122  VString::const_iterator jstr = getErrorCodes().end();
123  for (; istr != jstr; ++istr) {
124  ss << *istr << " ";
125  }
126  }
127  ss << std::endl;
128 }

References adcLevel_, bottomEdge_, bottomLevel_, relativeConstraints::empty, alignBH_cfg::fixed, CommissioningAnalysis::getErrorCodes(), CommissioningAnalysis::header(), isValid(), contentValuesCheck::ss, topEdge_, topLevel_, and vpsp_.

◆ reset()

void VpspScanAnalysis::reset ( void  )
overridevirtual

Resets analysis member data.

Implements CommissioningAnalysis.

Definition at line 42 of file VpspScanAnalysis.cc.

42 { vpsp_ = VInt(2, sistrip::invalid_); }

References sistrip::invalid_, and vpsp_.

Referenced by MatrixReader.MatrixReader::__init__(), and MatrixReader.MatrixReader::showRaw().

◆ summary()

void VpspScanAnalysis::summary ( std::stringstream &  ss) const
overridevirtual

Overrides base method.

Reimplemented from CommissioningAnalysis.

Definition at line 55 of file VpspScanAnalysis.cc.

55  {
56  SiStripFecKey fec_key(fecKey());
57  SiStripFedKey fed_key(fedKey());
58 
60 
61  std::stringstream extra1, extra2;
62  extra1 << sistrip::apv_ << "0";
63  extra2 << sistrip::apv_ << "1";
64 
66  type,
68  fed_key.key(),
70  fec_key.lldChan(),
71  extra1.str())
72  .title();
74  type,
76  fed_key.key(),
78  fec_key.lldChan(),
79  extra2.str())
80  .title();
81 
82  ss << " Summary"
83  << ":" << (isValid() ? "Valid" : "Invalid") << ":" << sistrip::controlView_ << ":" << fec_key.fecCrate() << "/"
84  << fec_key.fecSlot() << "/" << fec_key.fecRing() << "/" << fec_key.ccuAddr() << "/" << fec_key.ccuChan() << ":"
85  << sistrip::dqmRoot_ << sistrip::dir_ << "Collate" << sistrip::dir_
86  << SiStripFecKey(fec_key.fecCrate(), fec_key.fecSlot(), fec_key.fecRing(), fec_key.ccuAddr(), fec_key.ccuChan())
87  .path()
88  << ":" << title1 << ";" << title2 << std::endl;
89 }

References sistrip::apv_, SiStripFecKey::ccuAddr(), SiStripFecKey::ccuChan(), sistrip::controlView_, sistrip::dir_, sistrip::dqmRoot_, sistrip::EXPERT_HISTO, SiStripFecKey::fecCrate(), CommissioningAnalysis::fecKey(), SiStripFecKey::fecRing(), SiStripFecKey::fecSlot(), sistrip::FED_KEY, CommissioningAnalysis::fedKey(), isValid(), SiStripKey::key(), sistrip::LLD_CHAN, SiStripFecKey::lldChan(), CommissioningAnalysis::myName(), castor_dqm_sourceclient_file_cfg::path, SiStripEnumsAndStrings::runType(), contentValuesCheck::ss, AlCaHLTBitMon_QueryRunRegistry::string, and runGCPTkAlMap::title.

◆ topEdge()

const VpspScanAnalysis::VInt & VpspScanAnalysis::topEdge ( ) const
inline

VPSP setting where baseline leaves "D1" level.

Definition at line 88 of file VpspScanAnalysis.h.

88 { return topEdge_; }

References topEdge_.

◆ topLevel()

const VpspScanAnalysis::VInt & VpspScanAnalysis::topLevel ( ) const
inline

Signal level [ADC] for "digital one".

Definition at line 90 of file VpspScanAnalysis.h.

90 { return topLevel_; }

References topLevel_.

◆ vpsp()

const VpspScanAnalysis::VInt & VpspScanAnalysis::vpsp ( ) const
inline

VPSP settings for both APVs.

Definition at line 85 of file VpspScanAnalysis.h.

85 { return vpsp_; }

References vpsp_.

Friends And Related Function Documentation

◆ VpspScanAlgorithm

friend class VpspScanAlgorithm
friend

Definition at line 25 of file VpspScanAnalysis.h.

Member Data Documentation

◆ adcLevel_

VInt VpspScanAnalysis::adcLevel_
private

Definition at line 70 of file VpspScanAnalysis.h.

Referenced by adcLevel(), isValid(), and print().

◆ bottomEdge_

VInt VpspScanAnalysis::bottomEdge_
private

Definition at line 76 of file VpspScanAnalysis.h.

Referenced by bottomEdge(), and print().

◆ bottomLevel_

VInt VpspScanAnalysis::bottomLevel_
private

Definition at line 80 of file VpspScanAnalysis.h.

Referenced by bottomLevel(), isValid(), and print().

◆ fraction_

VInt VpspScanAnalysis::fraction_
private

Definition at line 72 of file VpspScanAnalysis.h.

Referenced by fraction().

◆ topEdge_

VInt VpspScanAnalysis::topEdge_
private

Definition at line 74 of file VpspScanAnalysis.h.

Referenced by print(), and topEdge().

◆ topLevel_

VInt VpspScanAnalysis::topLevel_
private

Definition at line 78 of file VpspScanAnalysis.h.

Referenced by isValid(), print(), and topLevel().

◆ vpsp_

VInt VpspScanAnalysis::vpsp_
private

VPSP settings

Definition at line 68 of file VpspScanAnalysis.h.

Referenced by isValid(), print(), reset(), and vpsp().

CommissioningAnalysis::getErrorCodes
const VString & getErrorCodes() const
Definition: CommissioningAnalysis.h:131
SiStripEnumsAndStrings::runType
static std::string runType(const sistrip::RunType &)
Definition: SiStripEnumsAndStrings.cc:39
alignBH_cfg.fixed
fixed
Definition: alignBH_cfg.py:54
runGCPTkAlMap.title
string title
Definition: runGCPTkAlMap.py:94
CommissioningAnalysis::fedKey
const uint32_t & fedKey() const
Definition: CommissioningAnalysis.h:134
VpspScanAnalysis::fraction_
VInt fraction_
Definition: VpspScanAnalysis.h:72
sistrip::dir_
static const char dir_[]
Definition: ConstantsForDqm.h:17
VpspScanAnalysis::bottomLevel_
VInt bottomLevel_
Definition: VpspScanAnalysis.h:80
sistrip::RunType
RunType
Definition: ConstantsForRunType.h:70
SiStripFedKey
A container class for generic run and event-related info, information required by the commissioning a...
Definition: SiStripFedKey.h:56
sistrip::valid_
static const uint16_t valid_
Definition: Constants.h:17
contentValuesCheck.ss
ss
Definition: contentValuesCheck.py:33
VpspScanAnalysis::topEdge_
VInt topEdge_
Definition: VpspScanAnalysis.h:74
CommissioningAnalysis::header
virtual void header(std::stringstream &) const
Definition: CommissioningAnalysis.cc:33
sistrip::EXPERT_HISTO
Definition: ConstantsForHistoType.h:29
VpspScanAnalysis::vpsp_
VInt vpsp_
Definition: VpspScanAnalysis.h:68
SiStripFecKey
Utility class that identifies a position within the strip tracker control structure,...
Definition: SiStripFecKey.h:45
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
CommissioningAnalysis::CommissioningAnalysis
CommissioningAnalysis()
Definition: CommissioningAnalysis.h:105
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
VpspScanAnalysis::isValid
bool isValid() const override
Definition: VpspScanAnalysis.cc:46
sistrip::controlView_
static const char controlView_[]
Definition: ConstantsForView.h:21
VpspScanAnalysis::topLevel_
VInt topLevel_
Definition: VpspScanAnalysis.h:78
VpspScanAnalysis::adcLevel_
VInt adcLevel_
Definition: VpspScanAnalysis.h:70
sistrip::invalid_
static const uint16_t invalid_
Definition: Constants.h:16
sistrip::dqmRoot_
static const char dqmRoot_[]
Definition: ConstantsForDqm.h:28
CommissioningAnalysis::VInt
std::vector< uint16_t > VInt
Definition: CommissioningAnalysis.h:34
sistrip::apv_
static const char apv_[]
Definition: ConstantsForGranularity.h:40
CommissioningAnalysis::fecKey
const uint32_t & fecKey() const
Definition: CommissioningAnalysis.h:133
relativeConstraints.empty
bool empty
Definition: relativeConstraints.py:46
CommissioningAnalysis::myName
const std::string & myName() const
Definition: CommissioningAnalysis.h:139
SiStripHistoTitle
Utility class that holds histogram title.
Definition: SiStripHistoTitle.h:20
castor_dqm_sourceclient_file_cfg.path
path
Definition: castor_dqm_sourceclient_file_cfg.py:37
sistrip::FED_KEY
Definition: ConstantsForKeyType.h:30
crabWrapper.key
key
Definition: crabWrapper.py:19
sistrip::LLD_CHAN
Definition: ConstantsForGranularity.h:78
VpspScanAnalysis::bottomEdge_
VInt bottomEdge_
Definition: VpspScanAnalysis.h:76