46 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"Started GetNewObjects!!!";
51 std::cout <<
"got offlineInfo = " << std::endl;
55 std::cout <<
" First object for this tag " << std::endl;
58 unsigned int max_since = 0;
60 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"max_since : " << max_since;
61 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"retrieved last payload ";
65 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"Retrieving run list from ONLINE DB ... ";
67 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"Making connection...";
69 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"Done.";
96 if (min_run < max_since) {
97 min_run = max_since + 1;
104 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"min_run= " << min_run <<
"max_run= " << max_run;
110 std::vector<RunIOV> run_vec = my_list.
getRuns();
111 size_t num_runs = run_vec.size();
113 std::cout <<
"number of runs is : " << num_runs << std::endl;
115 unsigned int irun = 0;
118 std::vector<EcalLogicID> my_StripEcalLogicId_EE;
119 my_StripEcalLogicId_EE =
121 std::cout <<
" GOT the logic ID for the EE trigger strips " << std::endl;
123 for (
size_t kr = 0; kr < run_vec.size(); kr++) {
124 irun =
static_cast<unsigned int>(run_vec[kr].getRunNumber());
126 std::cout <<
" **************** " << std::endl;
127 std::cout <<
" **************** " << std::endl;
128 std::cout <<
" run= " << irun << std::endl;
131 std::map<EcalLogicID, RunTPGConfigDat>
dataset;
135 int the_config_version = 0;
137 std::map<EcalLogicID, RunTPGConfigDat>::const_iterator it;
150 std::cout <<
" run= " << irun <<
" tag " << the_config_tag <<
" version=" << the_config_version << std::endl;
155 std::cout <<
"the tag is different from last transferred run ... retrieving last config set from DB" 163 std::cout <<
" before fetch config set" << std::endl;
165 std::cout <<
" after fetch config set" << std::endl;
168 int fgrId = fe_main_info.
getFgrId();
172 fe_fgr_info.
setId(fgrId);
174 std::map<EcalLogicID, FEConfigFgrEEStripDat> dataset_TpgFineGrainStripEE;
178 typedef std::map<EcalLogicID, FEConfigFgrEEStripDat>::const_iterator CIfefgr;
184 for (CIfefgr
p = dataset_TpgFineGrainStripEE.begin();
p != dataset_TpgFineGrainStripEE.end();
p++) {
191 if (ecid_name ==
"EB_VFE") {
192 int sm = ecid_xt.
getID1();
201 unsigned int stripEBId = 303176 + (
tt - 1) * 64 + (
strip - 1) * 8 + (tcc - 37) * 8192;
210 }
else if (ecid_name ==
"ECAL_readout_strip") {
217 int id3 = ecid_xt.
getID3();
219 bool set_the_strip =
false;
221 for (
size_t istrip = 0; istrip < my_StripEcalLogicId_EE.size(); istrip++) {
222 if (!set_the_strip) {
223 if (my_StripEcalLogicId_EE[istrip].getID1() ==
id1 &&
224 my_StripEcalLogicId_EE[istrip].getID2() ==
id2 &&
225 my_StripEcalLogicId_EE[istrip].getID3() == id3) {
226 stripEEId = my_StripEcalLogicId_EE[istrip].getLogicID();
227 set_the_strip =
true;
240 std::cout <<
" these may be the additional towers TCC/TT " <<
id1 <<
"/" <<
id2 << std::endl;
255 writeFile(
"last_tpg_fgrStripEE_settings.txt");
262 writeFile(
"last_tpg_fgrStripEE_settings.txt");
264 std::cout <<
" even if the tag/version is not the same, the fgrStripEEestals id is the same -> no transfer " 272 std::cout <<
"ERROR: THIS CONFIG DOES NOT EXIST: tag=" << the_config_tag <<
" version=" << the_config_version
277 std::cout <<
" **************** " << std::endl;
279 }
else if (
nr == 0) {
281 std::cout <<
" no tag saved to RUN_TPGCONFIG_DAT by EcalSupervisor -> no transfer needed " << std::endl;
282 std::cout <<
" **************** " << std::endl;
287 std::cout <<
" the tag/version is the same -> no transfer needed " << std::endl;
288 std::cout <<
" **************** " << std::endl;
289 writeFile(
"last_tpg_fgrStripEE_settings.txt");
296 edm::LogInfo(
"EcalTPGFineGrainStripEEHandler") <<
"Ecal - > end of getNewObjects -----------";
void setRunTypeDef(const RunTypeDef &runTypeDef)
EcalCondDBInterface * econn
std::vector< RunIOV > getRuns()
unsigned int getLUTFgr() const
RunList fetchGlobalRunListByLocation(const RunTag &tag, int min_run, int max_run, const LocationDef &locDef) noexcept(false)
unsigned int getThreshold() const
void writeFile(const char *inputFile)
std::string getName() const
void readFromFile(const char *inputFile)
void fetchConfigSet(ICONF *iconf) noexcept(false)
void fetchDataSet(std::map< EcalLogicID, DATT > *fillMap, IOVT *iov) noexcept(false)
void setValue(const uint32_t &id, const Item &value)
cond::TagInfo_t const & tagInfo() const
std::vector< EcalLogicID > getEcalLogicIDSetOrdered(std::string name, int fromId1, int toId1, int fromId2=EcalLogicID::NULLID, int toId2=EcalLogicID::NULLID, int fromId3=EcalLogicID::NULLID, int toId3=EcalLogicID::NULLID, std::string mapsTo="", int orderedBy=EcalLogicID::NULLID) noexcept(false)
std::vector< std::pair< EcalTPGFineGrainStripEE *, Time_t > > m_to_transfer
void setLocationDef(const LocationDef &locDef)
Log< level::Info, false > LogInfo
std::string getConfigTag() const
void setConfigTag(std::string x)
unsigned int m_i_run_number
void setGeneralTag(std::string tag)