14 : m_name(ps.getUntrackedParameter<
std::
string>(
"name",
"EcalLaser_weekly_Handler")) {
15 std::cout <<
"EcalLaser Source handler constructor\n" << std::endl;
27 std::cout <<
"------- Ecal -> getNewObjects\n";
30 unsigned long long max_since= 1;
35 Tm max_since_tm(max_since);
53 std::cout <<
" which input IOV do you want " << std::endl;
56 std::ostringstream oss;
58 std::string fname =
"/afs/cern.ch/cms/ECAL/triggerTransp/TPG_beamv6_trans_" + oss.str() +
"_spikekill.txt";
69 fWeek.open(fname.c_str());
70 if(!fWeek.is_open()) {
71 std::cout <<
"ERROR : can't open file '" << fname << std::endl;
74 std::cout <<
" file " << fname <<
" opened" << std::endl;
78 for(
int i = 0;
i < 85;
i++) getline (fWeek, line);
82 for (
int iChannel = 0; iChannel <
kEBChannels; iChannel++) {
83 getline (fWeek, line);
86 sscanf(line.c_str(),
"%s %u", cryst, &
id);
91 getline (fWeek, line);
93 sscanf(line.c_str(),
"%X %X %X", &ped[
gain], &mult[
gain], &shift[
gain]);
98 item.mult_x6 = mult[1];
99 item.mult_x12 = mult[0];
100 item.shift_x1 = shift[2];
101 item.shift_x6 = shift[1];
102 item.shift_x12 = shift[0];
104 linC->
insert(std::make_pair(
id, item));
109 getline (fWeek, line);
110 std::cout <<
" comment line " << line << std::endl;
111 for (
int iChannel = 0; iChannel <
kEEChannels; iChannel++) {
112 getline (fWeek, line);
114 sscanf(line.c_str(),
"%s %u", cryst, &
id);
118 getline (fWeek, line);
120 sscanf(line.c_str(),
"%X %X %X", &ped[
gain], &mult[
gain], &shift[
gain]);
127 item.mult_x6 = mult[1];
128 item.mult_x12 = mult[0];
129 item.shift_x1 = shift[2];
130 item.shift_x6 = shift[1];
131 item.shift_x12 = shift[0];
133 linC->
insert(std::make_pair(
id, item));
142 std::cout <<
"Ecal -> end of getNewObjects -----------\n";
edm::Ref< Container > Ref
OldContainer m_to_transfer
cond::ValidityInterval lastInterval
EcalLaser_weekly_Linearization(edm::ParameterSet const &)
void insert(std::pair< uint32_t, Item > const &a)
~EcalLaser_weekly_Linearization() override
static unsigned int const shift
std::string id() const override
void getNewObjects() override
cond::TagInfo_t const & tagInfo() const
EcalTPGLinearizationConstMap EcalTPGLinearizationConst