17 cout <<
"*****************************************" << endl;
18 cout <<
"******** Inserting Peds in conf-OMDS*****" << endl;
19 cout <<
"*****************************************" << endl;
21 cout <<
"creating fe record " << endl;
25 insertConfigSet(&fe_ped_info);
26 result = fe_ped_info.
getID();
29 cout <<
"*********about to insert peds *********" << endl;
30 cout <<
" map size = " << pedset.size() << endl;
31 insertDataArraySet(&pedset, &fe_ped_info);
32 cout <<
"*********Done peds *********" << endl;
38 const map<EcalLogicID, FEConfigLinParamDat>& linparamset,
43 cout <<
"*********************************************" << endl;
44 cout <<
"**Inserting Linarization coeff in conf-OMDS**" << endl;
45 cout <<
"*********************************************" << endl;
47 cout <<
"creating fe record " << endl;
51 insertConfigSet(&fe_lin_info);
52 result = fe_lin_info.
getID();
55 cout <<
"*********about to insert linearization coeff *********" << endl;
56 cout <<
" map size = " << linset.size() << endl;
57 insertDataArraySet(&linset, &fe_lin_info);
58 insertDataArraySet(&linparamset, &fe_lin_info);
59 cout <<
"*********Done lineraization coeff *********" << endl;
79 cout <<
"*********************************************" << endl;
80 cout <<
"**Inserting Main FE table in conf-OMDS **" << endl;
81 cout <<
"*********************************************" << endl;
83 cout <<
"creating fe record " << endl;
100 insertConfigSet(&fe_main);
101 result = fe_main.
getId();
103 cout <<
"*********Done Main *********" << endl;
115 cout <<
"*****************************************" << endl;
116 cout <<
"test readinf fe_ped with id=" << iconf_req << endl;
117 cout <<
"*****************************************" << endl;
120 fe_ped_info.
setId(iconf_req);
122 fetchConfigSet(&fe_ped_info);
124 map<EcalLogicID, FEConfigPedDat> dataset_ped;
125 fetchDataSet(&dataset_ped, &fe_ped_info);
127 typedef map<EcalLogicID, FEConfigPedDat>::const_iterator CIfeped;
131 for (CIfeped
p = dataset_ped.begin();
p != dataset_ped.end(); ++
p) {
141 cout <<
"*****************************************" << endl;
142 cout <<
"test read done" << iconf_req << endl;
143 cout <<
"*****************************************" << endl;
149 cout <<
"Retrieving run list from DB from run nb ... " << runNb << endl;
170 std::cout <<
"we are in read ped from condDB and runNb is " << runNb << endl;
172 mon_list = fetchMonRunListLastNRuns(my_runtag, montag, runNb, 10);
174 std::cout <<
"we are in read ped from condDB" << endl;
176 std::vector<MonRunIOV> mon_run_vec = mon_list.
getRuns();
177 cout <<
"number of ped runs is : " << mon_run_vec.size() << endl;
178 int mon_runs = mon_run_vec.size();
182 for (
int ii = 0;
ii < (
int)mon_run_vec.size();
ii++)
183 cout <<
"here is the run number: " << mon_run_vec[
ii].getRunIOV().getRunNumber() << endl;
187 cout <<
" retrieve the data for a given run" << endl;
188 cout <<
"here is the run number: " << mon_run_vec[
run].getRunIOV().getRunNumber() << endl;
189 iovId = mon_run_vec[
run].getID();
191 fetchDataSet(&dataset, &mon_run_vec[run]);
197 cout <<
"*****************************************" << endl;
198 cout <<
"************Inserting SLIDING************" << endl;
199 cout <<
"*****************************************" << endl;
205 insertConfigSet(&fe_info);
211 insertDataArraySet(&sliset, &fe_info);
213 result = fe_info.
getId();
215 cout <<
"*****************************************" << endl;
216 cout <<
"************SLI done*********************" << endl;
217 cout <<
"*****************************************" << endl;
222 const map<EcalLogicID, FEConfigLUTDat>& lutset,
223 const map<EcalLogicID, FEConfigLUTParamDat>& lutparamset,
226 cout <<
"*****************************************" << endl;
227 cout <<
"************Inserting LUT************" << endl;
228 cout <<
"*****************************************" << endl;
234 insertConfigSet(&fe_lut_info);
240 insertDataArraySet(&lutgroupset, &fe_lut_info);
242 insertDataArraySet(&lutset, &fe_lut_info);
244 insertDataArraySet(&lutparamset, &fe_lut_info);
246 result = fe_lut_info.
getId();
248 cout <<
"*****************************************" << endl;
249 cout <<
"************LUT done*********************" << endl;
250 cout <<
"*****************************************" << endl;
255 const map<EcalLogicID, FEConfigWeightDat>& lutset,
258 cout <<
"*****************************************" << endl;
259 cout <<
"************Inserting weights************" << endl;
260 cout <<
"*****************************************" << endl;
267 insertConfigSet(&fe_wei_info);
273 insertDataArraySet(&lutgroupset, &fe_wei_info);
275 insertDataArraySet(&lutset, &fe_wei_info);
277 result = fe_wei_info.
getId();
279 cout <<
"*****************************************" << endl;
280 cout <<
"************WEIGHT done******************" << endl;
281 cout <<
"*****************************************" << endl;
286 const map<EcalLogicID, FEConfigFgrDat>& fgrset,
287 const map<EcalLogicID, FEConfigFgrParamDat>& fgrparamset,
288 const map<EcalLogicID, FEConfigFgrEETowerDat>& dataset3,
289 const map<EcalLogicID, FEConfigFgrEEStripDat>& dataset4,
292 cout <<
"*****************************************" << endl;
293 cout <<
"************Inserting Fgr************" << endl;
294 cout <<
"*****************************************" << endl;
300 insertConfigSet(&fe_fgr_info);
306 insertDataArraySet(&fgrgroupset, &fe_fgr_info);
308 insertDataArraySet(&fgrset, &fe_fgr_info);
310 insertDataArraySet(&fgrparamset, &fe_fgr_info);
312 insertDataArraySet(&dataset3, &fe_fgr_info);
314 insertDataArraySet(&dataset4, &fe_fgr_info);
316 result = fe_fgr_info.
getId();
318 cout <<
"*****************************************" << endl;
319 cout <<
"************Fgr done*********************" << endl;
320 cout <<
"*****************************************" << endl;
325 cout <<
"*****************************************" << endl;
326 cout <<
"************Inserting Spike************" << endl;
327 cout <<
"*****************************************" << endl;
332 insertConfigSet(&fe_spike_info);
338 insertDataArraySet(&spikegroupset, &fe_spike_info);
340 result = fe_spike_info.
getId();
342 cout <<
"*****************************************" << endl;
343 cout <<
"************Spike done*******************" << endl;
344 cout <<
"*****************************************" << endl;
349 cout <<
"*****************************************" << endl;
350 cout <<
"************Inserting Delays************" << endl;
351 cout <<
"*****************************************" << endl;
356 insertConfigSet(&fe_time_info);
362 insertDataArraySet(&timegroupset, &fe_time_info);
364 result = fe_time_info.
getId();
366 cout <<
"*****************************************" << endl;
367 cout <<
"************Delays done******************" << endl;
368 cout <<
"*****************************************" << endl;
374 cout <<
"=============RunTag:" << endl;
378 cout <<
"====================" << endl;
383 cout <<
"=============RunIOV:" << endl;
389 cout <<
"====================" << endl;
int writeToConfDB_TPGLinearCoef(const std::map< EcalLogicID, FEConfigLinDat > &linset, const std::map< EcalLogicID, FEConfigLinParamDat > &linparamset, int iovId, std::string tag)
void setRunTypeDef(const RunTypeDef &runTypeDef)
void printIOV(const RunIOV *iov) const
LocationDef getLocationDef() const
float getPedMeanG1() const
EcalTPGDBApp(std::string host, std::string sid, std::string user, std::string pass, int port)
std::string getGeneralTag() const
std::string getRunType() const
void setIOVId(int iov_id)
int writeToConfDB_TPGSliding(const std::map< EcalLogicID, FEConfigSlidingDat > &sliset, int iovId, std::string tag)
int writeToConfDB_Delay(const std::map< EcalLogicID, FEConfigTimingDat > &delaygroupset, std::string tag)
int writeToConfDB_TPGMain(int ped, int lin, int lut, int fgr, int sli, int wei, int spi, int tim, int bxt, int btt, int bst, std::string tag, int ver)
void setGeneralTag(std::string tag)
void setRunTag(const RunTag &tag)
void setNumberOfGroups(int iov_id)
void setNumberOfGroups(int iov_id)
void setIOVId(int iov_id)
std::string getLocation() const
void setMonVersionDef(const MonVersionDef &ver)
int readFromCondDB_Pedestals(std::map< EcalLogicID, MonPedestalsDat > &pedset, int runNb)
float getPedMeanG12() const
void setLocationDef(const LocationDef &locDef)
void setIOVId(int iov_id)
int writeToConfDB_Spike(const std::map< EcalLogicID, FEConfigSpikeDat > &spikegroupset, std::string tag)
std::vector< MonRunIOV > getRuns()
int writeToConfDB_TPGPedestals(const std::map< EcalLogicID, FEConfigPedDat > &pedset, int iovId, std::string tag)
RunTypeDef getRunTypeDef() const
void setRunType(std::string runtype)
void setMonRunTag(const MonRunTag &tag)
float getPedMeanG6() const
void setMonitoringVersion(std::string ver)
run_t getRunNumber() const
void setConfigTag(std::string x)
void readFromConfDB_TPGPedestals(int iconf_req)
void setNumberOfGroups(int n)
int writeToConfDB_TPGLUT(const std::map< EcalLogicID, FEConfigLUTGroupDat > &lutgroup, const std::map< EcalLogicID, FEConfigLUTDat > &lutdat, const std::map< EcalLogicID, FEConfigLUTParamDat > &lutparamset, int iovId, std::string tag)
void setLocation(std::string loc)
int writeToConfDB_TPGFgr(const std::map< EcalLogicID, FEConfigFgrGroupDat > &lutgroup, const std::map< EcalLogicID, FEConfigFgrDat > &lutdat, const std::map< EcalLogicID, FEConfigFgrParamDat > &fgrparamset, const std::map< EcalLogicID, FEConfigFgrEETowerDat > &dataset3, const std::map< EcalLogicID, FEConfigFgrEEStripDat > &dataset4, int iovId, std::string tag)
void printTag(const RunTag *tag) const
int writeToConfDB_TPGWeight(const std::map< EcalLogicID, FEConfigWeightGroupDat > &lutgroup, const std::map< EcalLogicID, FEConfigWeightDat > &lutdat, int iovId, std::string tag)
void setGeneralTag(std::string tag)