CMS 3D CMS Logo

VpspScanSummaryFactory.cc
Go to the documentation of this file.
5 #include <iostream>
6 #include <sstream>
7 
8 using namespace sistrip;
9 
10 // -----------------------------------------------------------------------------
11 //
13 
14  VpspScanAnalysis* anal = dynamic_cast<VpspScanAnalysis*>( iter->second );
15  if ( !anal ) { return; }
16 
17  std::vector<float> value( 2, 1. * sistrip::invalid_ );
18  std::vector<float> error( 2, 1. * sistrip::invalid_ );
19 
20  bool two = true;
21  if ( mon_ == sistrip::VPSP_SCAN_APV_SETTINGS ) {
22  value[0] = 1. * anal->vpsp()[0];
23  value[1] = 1. * anal->vpsp()[1];
24  } else if ( mon_ == sistrip::VPSP_SCAN_APV0_SETTING ) {
25  value[0] = 1. * anal->vpsp()[0];
26  two = false;
27  } else if ( mon_ == sistrip::VPSP_SCAN_APV1_SETTING ) {
28  value[0] = 1. * anal->vpsp()[1];
29  two = false;
30  } else if ( mon_ == sistrip::VPSP_SCAN_ADC_LEVEL ) {
31  value[0] = 1. * anal->adcLevel()[0];
32  value[1] = 1. * anal->adcLevel()[1];
33  } else if ( mon_ == sistrip::VPSP_SCAN_DIGITAL_HIGH ) {
34  value[0] = 1. * anal->topLevel()[0];
35  value[1] = 1. * anal->topLevel()[1];
36  } else if ( mon_ == sistrip::VPSP_SCAN_DIGITAL_LOW ) {
37  value[0] = 1. * anal->bottomLevel()[0];
38  value[1] = 1. * anal->bottomLevel()[1];
39  } else {
41  << "[SummaryPlotFactory::" << __func__ << "]"
42  << " Unexpected monitorable: "
44  return;
45  }
46 
49  iter->first,
50  value[0],
51  error[0] );
52 
53  if ( two ) {
56  iter->first,
57  value[1],
58  error[1] );
59  }
60 
61 }
62 
63 // -----------------------------------------------------------------------------
64 //
66 
67  if ( mon_ == sistrip::VPSP_SCAN_APV_SETTINGS ) {
68  } else if ( mon_ == sistrip::VPSP_SCAN_APV0_SETTING ) {
69  } else if ( mon_ == sistrip::VPSP_SCAN_APV1_SETTING ) {
70  } else if ( mon_ == sistrip::VPSP_SCAN_ADC_LEVEL ) {
71  } else if ( mon_ == sistrip::VPSP_SCAN_DIGITAL_HIGH ) {
72  } else if ( mon_ == sistrip::VPSP_SCAN_DIGITAL_LOW ) {
73  } else {
75  << "[SummaryPlotFactory::" << __func__ << "]"
76  << " Unexpected SummaryHisto value: "
78  }
79 
80 }
static std::string monitorable(const sistrip::Monitorable &)
sistrip::Monitorable mon_
sistrip classes
void fillMap(const std::string &top_level_dir, const sistrip::Granularity &, const uint32_t &key, const float &value, const float &error=0.)
const VInt & topLevel() const
sistrip::Granularity gran_
const VInt & vpsp() const
void extract(Iterator) override
Histogram-based analysis for VPSP scan.
static const char mlSummaryPlots_[]
const VInt & adcLevel() const
SummaryGenerator * generator_
static const uint16_t invalid_
Definition: Constants.h:16
const VInt & bottomLevel() const