40 edm::LogInfo(
"SiStripSummaryBuilder") <<
"... creating dummy SiStripSummary Data for Run " << run <<
"\n "
48 std::vector<std::string> userDBContent;
49 typedef std::vector<edm::ParameterSet> VParameters;
51 VParameters::iterator ithistoList = histoList.begin();
52 VParameters::iterator ithistoListEnd = histoList.end();
54 for (; ithistoList != ithistoListEnd; ++ithistoList) {
56 std::vector<std::string> Quantities =
57 ithistoList->getUntrackedParameter<std::vector<std::string> >(
"quantitiesToExtract");
58 for (
size_t i = 0;
i < Quantities.size(); ++
i) {
59 if (Quantities[
i] ==
"landau") {
64 }
else if (Quantities[
i] ==
"gauss") {
68 }
else if (Quantities[
i] ==
"stat") {
74 <<
"Quantity " << Quantities[
i] <<
" cannot be handled\nAllowed quantities are"
75 <<
"\n 'stat' that includes: entries, mean, rms"
76 <<
"\n 'landau' that includes: landauPeak, landauPeakErr, landauSFWHM, landauChi2NDF"
77 <<
"\n 'gauss' that includes: gaussMean, gaussSigma, gaussChi2NDF" << std::endl;
83 std::stringstream ss1;
84 ss1 <<
"QUANTITIES TO BE INSERTED IN DB :"
87 for (
size_t i = 0;
i < userDBContentA.size(); ++
i)
88 ss1 << userDBContentA[
i] << std::endl;
93 std::stringstream ss2;
94 for (uint32_t detid = 0; detid < 430; detid++) {
96 for (
unsigned int i = 0;
i < userDBContent.size();
i++)
97 values.push_back((
float)CLHEP::RandGauss::shoot(50., 30.));
99 ss2 <<
"\n\tdetid " << detid;
100 for (
size_t j = 0;
j < values.size(); ++
j)
101 ss2 <<
"\n\t\t " << userDBContent[
j] <<
" " << values[
j];
103 obj.
put(detid, values, userDBContent);
138 edm::LogError(
"SiStripSummaryBuilder") <<
"Service is unavailable" << std::endl;
void setRunNr(int inputRunNr)
Log< level::Error, false > LogError
void createOneIOV(const T &payload, cond::Time_t firstSinceTime, const std::string &recordName)
void appendOneIOV(const T &payload, cond::Time_t sinceTime, const std::string &recordName)
bool isNewTagRequest(const std::string &recordName)
cond::Time_t beginOfTime() const
std::vector< float > InputVector
Log< level::Info, false > LogInfo
bool put(const uint32_t &detID, InputVector &input, std::vector< std::string > &userContent)
std::vector< std::string > getUserDBContent() const
T getParameter(std::string const &) const
edm::ParameterSet iConfig_
cond::Time_t currentTime() const
void setUserDBContent(const std::vector< std::string > &userDBContent)