CMS 3D CMS Logo

SiPixelCPEGenericErrorParm.h
Go to the documentation of this file.
1 #ifndef CondFormats_SiPixelObjects_SiPixelCPEGenericErrorParm_h
2 #define CondFormats_SiPixelObjects_SiPixelCPEGenericErrorParm_h 1
3 
5 
6 #include <vector>
7 #include <iosfwd>
8 
9 //--- Maybe should make this a class const, but that'd be too much work.
10 //--- This usage is not worth it, since in the debugger will be obvious
11 //--- what this is! ;)
12 #define NONSENSE -99999.9
13 #define NONSENSE_I -99999
14 
16 public:
18  struct DbEntry {
19  float sigma;
20  float rms;
21  float bias; // For irradiated pixels
22  float pix_height; // For decapitation
23  float ave_Qclus; // Average cluster charge, For
25  ~DbEntry() {}
26 
28  };
29  typedef std::vector<DbEntry> DbVector;
30 
32  struct DbEntryBinSize {
40 
42  };
43  typedef std::vector<DbEntryBinSize> DbBinSizeVector;
44 
47 
49  friend std::ostream& operator<<(std::ostream& s, const SiPixelCPEGenericErrorParm& genericErrors);
50 
53 
55  inline DbVector& errors() { return errors_; }
57  inline double& version() { return version_; }
58 
60  inline const DbVector& errors() const { return errors_; }
61  inline const DbBinSizeVector& errorsBinSize() const { return errorsBinSize_; }
62  inline const double& version() const { return version_; }
63 
65  inline void reserve() {
66  errors_.reserve(1000);
67  errorsBinSize_.reserve(4);
68  }
69  // &&& Should these sizes be computed on the fly from other
70  // &&& variables (which are currently not stored in this object,
71  // &&& but maybe should be?)
72 
73  //inline void push_back( DbEntry e) {errors_.push_back(e);}
74  // inline void push_back_bin( DbEntryBinSize e) {errorsBinSize_.push_back(e);}
75  inline void set_version(double v) { version_ = v; }
76 
77  // &&& Should we be able to read this from an iostream? See PxCPEdbUploader...
78 
79 private:
82  double version_;
83 
85 };
86 
87 #endif
SiPixelCPEGenericErrorParm
Definition: SiPixelCPEGenericErrorParm.h:15
SiPixelCPEGenericErrorParm::DbEntry::~DbEntry
~DbEntry()
Definition: SiPixelCPEGenericErrorParm.h:25
SiPixelCPEGenericErrorParm::DbEntryBinSize::alphaBin_size
int alphaBin_size
Definition: SiPixelCPEGenericErrorParm.h:35
SiPixelCPEGenericErrorParm::version_
double version_
Definition: SiPixelCPEGenericErrorParm.h:82
SiPixelCPEGenericErrorParm::version
const double & version() const
Definition: SiPixelCPEGenericErrorParm.h:62
SiPixelCPEGenericErrorParm::DbEntryBinSize::partBin_size
int partBin_size
Definition: SiPixelCPEGenericErrorParm.h:33
SiPixelCPEGenericErrorParm::set_version
void set_version(double v)
Definition: SiPixelCPEGenericErrorParm.h:75
SiPixelCPEGenericErrorParm::SiPixelCPEGenericErrorParm
SiPixelCPEGenericErrorParm()
Definition: SiPixelCPEGenericErrorParm.h:45
COND_SERIALIZABLE
#define COND_SERIALIZABLE
Definition: Serializable.h:39
SiPixelCPEGenericErrorParm::errorsBinSize_
DbBinSizeVector errorsBinSize_
Definition: SiPixelCPEGenericErrorParm.h:81
findQualityFiles.v
v
Definition: findQualityFiles.py:179
SiPixelCPEGenericErrorParm::version
double & version()
Definition: SiPixelCPEGenericErrorParm.h:57
SiPixelCPEGenericErrorParm::DbVector
std::vector< DbEntry > DbVector
Definition: SiPixelCPEGenericErrorParm.h:29
SiPixelCPEGenericErrorParm::errorsBinSize
const DbBinSizeVector & errorsBinSize() const
Definition: SiPixelCPEGenericErrorParm.h:61
SiPixelCPEGenericErrorParm::DbEntry::rms
float rms
Definition: SiPixelCPEGenericErrorParm.h:20
SiPixelCPEGenericErrorParm::errors
DbVector & errors()
Accessors for the vectors – non-const version.
Definition: SiPixelCPEGenericErrorParm.h:55
SiPixelCPEGenericErrorParm::operator<<
friend std::ostream & operator<<(std::ostream &s, const SiPixelCPEGenericErrorParm &genericErrors)
Function to output the contents of the db object.
Definition: SiPixelCPEGenericErrorParm.cc:48
SiPixelCPEGenericErrorParm::reserve
void reserve()
Reserve some reasonable sizes for the vectors.
Definition: SiPixelCPEGenericErrorParm.h:65
alignCSCRings.s
s
Definition: alignCSCRings.py:92
SiPixelCPEGenericErrorParm::DbBinSizeVector
std::vector< DbEntryBinSize > DbBinSizeVector
Definition: SiPixelCPEGenericErrorParm.h:43
SiPixelCPEGenericErrorParm::errors
const DbVector & errors() const
Accessors for the vectors – const version.
Definition: SiPixelCPEGenericErrorParm.h:60
SiPixelCPEGenericErrorParm::DbEntry::bias
float bias
Definition: SiPixelCPEGenericErrorParm.h:21
SiPixelCPEGenericErrorParm::DbEntry::ave_Qclus
float ave_Qclus
Definition: SiPixelCPEGenericErrorParm.h:23
SiPixelCPEGenericErrorParm::DbEntryBinSize::DbEntryBinSize
DbEntryBinSize()
Definition: SiPixelCPEGenericErrorParm.h:37
SiPixelCPEGenericErrorParm::~SiPixelCPEGenericErrorParm
virtual ~SiPixelCPEGenericErrorParm()
Definition: SiPixelCPEGenericErrorParm.h:46
SiPixelCPEGenericErrorParm::DbEntryBinSize::sizeBin_size
int sizeBin_size
Definition: SiPixelCPEGenericErrorParm.h:34
SiPixelCPEGenericErrorParm::DbEntryBinSize
A struct to hold the binning information for (part, size, alpha, beta)
Definition: SiPixelCPEGenericErrorParm.h:32
geometryDiff.file
file
Definition: geometryDiff.py:13
SiPixelCPEGenericErrorParm::DbEntry::sigma
float sigma
Definition: SiPixelCPEGenericErrorParm.h:19
SiPixelCPEGenericErrorParm::DbEntry
A struct to hold information for a given (alpha,beta,size)
Definition: SiPixelCPEGenericErrorParm.h:18
SiPixelCPEGenericErrorParm::DbEntryBinSize::~DbEntryBinSize
~DbEntryBinSize()
Definition: SiPixelCPEGenericErrorParm.h:39
Serializable.h
NONSENSE_I
#define NONSENSE_I
Definition: SiPixelCPEGenericErrorParm.h:13
SiPixelCPEGenericErrorParm::DbEntry::pix_height
float pix_height
Definition: SiPixelCPEGenericErrorParm.h:22
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
SiPixelCPEGenericErrorParm::errorsBin
DbBinSizeVector & errorsBin()
Definition: SiPixelCPEGenericErrorParm.h:56
SiPixelCPEGenericErrorParm::DbEntry::DbEntry
DbEntry()
Definition: SiPixelCPEGenericErrorParm.h:24
NONSENSE
#define NONSENSE
Definition: SiPixelCPEGenericErrorParm.h:12
SiPixelCPEGenericErrorParm::errors_
DbVector errors_
Definition: SiPixelCPEGenericErrorParm.h:80
SiPixelCPEGenericErrorParm::fillCPEGenericErrorParm
void fillCPEGenericErrorParm(double version, std::string file)
Function to fill the db object given a filename.
Definition: SiPixelCPEGenericErrorParm.cc:4
SiPixelCPEGenericErrorParm::DbEntryBinSize::betaBin_size
int betaBin_size
Definition: SiPixelCPEGenericErrorParm.h:36