58 _filename(iConfig.getParameter<
string>(
"filename")),
59 _messageLevel(iConfig.getUntrackedParameter(
"messageLevel", 0)) {
61 edm::LogPrint(
"PixelPopConCalibChecker") <<
"********* PixelPopConCalibChecker ************" << endl;
79 edm::LogPrint(
"PixelPopConCalibChecker") <<
"Comparing SiPixelCalibConfiguration object from database for run "
80 << eventID.
run() <<
" to calib.dat file at " <<
_filename << endl;
91 string modeES = calibES->getCalibrationMode();
92 string modeFile = calibFile->getCalibrationMode();
94 edm::LogPrint(
"PixelPopConCalibChecker") <<
"*** Checking calibration mode ***" << endl;
95 edm::LogPrint(
"PixelPopConCalibChecker") <<
" mode from DB: " << modeES << endl;
96 edm::LogPrint(
"PixelPopConCalibChecker") <<
" mode from file: " << modeFile << endl;
98 if (modeES != modeFile) {
101 edm::LogPrint(
"PixelPopConCalibChecker") <<
"Mismatch in calibration mode!" << endl;
102 edm::LogPrint(
"PixelPopConCalibChecker") <<
" " << modeES <<
" in database, " << modeFile <<
" in file" << endl;
107 short ntriggerES = calibES->getNTriggers();
108 short ntriggerFile = calibFile->getNTriggers();
110 edm::LogPrint(
"PixelPopConCalibChecker") <<
"*** Checking number of triggers ***" << endl;
111 edm::LogPrint(
"PixelPopConCalibChecker") <<
" NTriggers from DB: " << ntriggerES << endl;
112 edm::LogPrint(
"PixelPopConCalibChecker") <<
" NTriggers from file: " << ntriggerFile << endl;
114 if (ntriggerES != ntriggerFile) {
117 edm::LogPrint(
"PixelPopConCalibChecker") <<
"Mismatch in number of triggers!" << endl;
119 <<
" " << ntriggerES <<
" in database, " << ntriggerFile <<
" in file" << endl;
124 vector<short> vcalES = calibES->getVCalValues();
125 vector<short> vcalFile = calibFile->getVCalValues();
127 edm::LogPrint(
"PixelPopConCalibChecker") <<
"*** Checking vcal values ***" << endl;
128 edm::LogPrint(
"PixelPopConCalibChecker") <<
" vcal values from DB: ";
129 for (vector<short>::const_iterator it = vcalES.begin(); it != vcalES.end(); ++it)
132 edm::LogPrint(
"PixelPopConCalibChecker") <<
" vcal values from file: ";
133 for (vector<short>::const_iterator it = vcalFile.begin(); it != vcalFile.end(); ++it)
137 if (vcalES != vcalFile) {
140 edm::LogPrint(
"PixelPopConCalibChecker") <<
"Mismatch in vcal values!" << endl;
145 vector<short> colES = calibES->getColumnPattern();
146 vector<short> colFile = calibFile->getColumnPattern();
148 edm::LogPrint(
"PixelPopConCalibChecker") <<
"*** Checking column pattern values ***" << endl;
149 edm::LogPrint(
"PixelPopConCalibChecker") <<
" column pattern from DB: ";
150 for (vector<short>::const_iterator it = colES.begin(); it != colES.end(); ++it)
153 edm::LogPrint(
"PixelPopConCalibChecker") <<
" column pattern from file: ";
154 for (vector<short>::const_iterator it = colFile.begin(); it != colFile.end(); ++it)
158 if (colES != colFile) {
161 edm::LogPrint(
"PixelPopConCalibChecker") <<
"Mismatch in column pattern!" << endl;
166 vector<short> rowES = calibES->getRowPattern();
167 vector<short> rowFile = calibFile->getRowPattern();
169 edm::LogPrint(
"PixelPopConCalibChecker") <<
"*** Checking row pattern values ***" << endl;
170 edm::LogPrint(
"PixelPopConCalibChecker") <<
" row pattern from DB: ";
171 for (vector<short>::const_iterator it = rowES.begin(); it != rowES.end(); ++it)
174 edm::LogPrint(
"PixelPopConCalibChecker") <<
" row pattern from file: ";
175 for (vector<short>::const_iterator it = rowFile.begin(); it != rowFile.end(); ++it)
179 if (rowES != rowFile) {
182 edm::LogPrint(
"PixelPopConCalibChecker") <<
"Mismatch in row pattern!" << endl;
189 <<
"*** Calibration configuration in database and file match. Go forth and calibrate." << endl;
192 <<
"*** WARNING! Calibration configuration is database and file DO NOT match!" << endl;
#define DEFINE_FWK_MODULE(type)
bool getData(T &iHolder) const
This class implements the steps that are used in a scan over Threshold and CalDelay.
Log< level::Warning, true > LogPrint
const std::string _filename
~PixelPopConCalibChecker() override
PixelPopConCalibChecker(const edm::ParameterSet &)
const edm::ESGetToken< SiPixelCalibConfiguration, SiPixelCalibConfigurationRcd > gainCalibToken_
void analyze(const edm::Event &, const edm::EventSetup &) override
This class implements the steps that are used in a scan over Threshold and CalDelay.