81 using namespace edm::es;
88 "GCT_PHYS_PARAMS.CONFIG_KEY",
91 std::string scalesKey ;
93 if( scalesKeyResults.queryFailed() ) {
95 <<
"Problem with key for L1HtMissScaleRcd : GCT scales key query failed ";
97 else if( scalesKeyResults.numberRows() != 1 ) {
99 <<
"Problem with key for L1HtMissScaleRcd : "
100 << (scalesKeyResults.numberRows()) <<
" rows were returned when getting GCT scales key";
103 scalesKeyResults.fillVariable( scalesKey );
106 edm::LogInfo(
"L1-O2O") <<
"L1 scales key : " << scalesKey << std::endl;
117 std::string htmScaleKey ;
119 if( htmScaleKeyResults.queryFailed() ) {
121 <<
"Problem with key for L1HtMissEtScaleRcd : HtMiss scale key query failed ";
123 else if( htmScaleKeyResults.numberRows() != 1 ) {
125 <<
"Problem with key for L1HtMissScaleRcd : "
126 << (htmScaleKeyResults.numberRows()) <<
" rows were returned when getting HtMiss scale key";
129 htmScaleKeyResults.fillVariable( htmScaleKey ) ;
132 edm::LogInfo(
"L1-O2O") <<
"L1HtMiss scale key : " << htmScaleKey << std::endl;
135 std::vector< std::string > queryStrings ;
136 queryStrings.push_back(
"E_GEV_BIN_LOW_0");
137 queryStrings.push_back(
"E_GEV_BIN_LOW_1");
138 queryStrings.push_back(
"E_GEV_BIN_LOW_2");
139 queryStrings.push_back(
"E_GEV_BIN_LOW_3");
140 queryStrings.push_back(
"E_GEV_BIN_LOW_4");
141 queryStrings.push_back(
"E_GEV_BIN_LOW_5");
142 queryStrings.push_back(
"E_GEV_BIN_LOW_6");
143 queryStrings.push_back(
"E_GEV_BIN_LOW_7");
144 queryStrings.push_back(
"E_GEV_BIN_LOW_8");
145 queryStrings.push_back(
"E_GEV_BIN_LOW_9");
146 queryStrings.push_back(
"E_GEV_BIN_LOW_10");
147 queryStrings.push_back(
"E_GEV_BIN_LOW_11");
148 queryStrings.push_back(
"E_GEV_BIN_LOW_12");
149 queryStrings.push_back(
"E_GEV_BIN_LOW_13");
150 queryStrings.push_back(
"E_GEV_BIN_LOW_14");
151 queryStrings.push_back(
"E_GEV_BIN_LOW_15");
152 queryStrings.push_back(
"E_GEV_BIN_LOW_16");
153 queryStrings.push_back(
"E_GEV_BIN_LOW_17");
154 queryStrings.push_back(
"E_GEV_BIN_LOW_18");
155 queryStrings.push_back(
"E_GEV_BIN_LOW_19");
156 queryStrings.push_back(
"E_GEV_BIN_LOW_20");
157 queryStrings.push_back(
"E_GEV_BIN_LOW_21");
158 queryStrings.push_back(
"E_GEV_BIN_LOW_22");
159 queryStrings.push_back(
"E_GEV_BIN_LOW_23");
160 queryStrings.push_back(
"E_GEV_BIN_LOW_24");
161 queryStrings.push_back(
"E_GEV_BIN_LOW_25");
162 queryStrings.push_back(
"E_GEV_BIN_LOW_26");
163 queryStrings.push_back(
"E_GEV_BIN_LOW_27");
164 queryStrings.push_back(
"E_GEV_BIN_LOW_28");
165 queryStrings.push_back(
"E_GEV_BIN_LOW_29");
166 queryStrings.push_back(
"E_GEV_BIN_LOW_30");
167 queryStrings.push_back(
"E_GEV_BIN_LOW_31");
168 queryStrings.push_back(
"E_GEV_BIN_LOW_32");
169 queryStrings.push_back(
"E_GEV_BIN_LOW_33");
170 queryStrings.push_back(
"E_GEV_BIN_LOW_34");
171 queryStrings.push_back(
"E_GEV_BIN_LOW_35");
172 queryStrings.push_back(
"E_GEV_BIN_LOW_36");
173 queryStrings.push_back(
"E_GEV_BIN_LOW_37");
174 queryStrings.push_back(
"E_GEV_BIN_LOW_38");
175 queryStrings.push_back(
"E_GEV_BIN_LOW_39");
176 queryStrings.push_back(
"E_GEV_BIN_LOW_40");
177 queryStrings.push_back(
"E_GEV_BIN_LOW_41");
178 queryStrings.push_back(
"E_GEV_BIN_LOW_42");
179 queryStrings.push_back(
"E_GEV_BIN_LOW_43");
180 queryStrings.push_back(
"E_GEV_BIN_LOW_44");
181 queryStrings.push_back(
"E_GEV_BIN_LOW_45");
182 queryStrings.push_back(
"E_GEV_BIN_LOW_46");
183 queryStrings.push_back(
"E_GEV_BIN_LOW_47");
184 queryStrings.push_back(
"E_GEV_BIN_LOW_48");
185 queryStrings.push_back(
"E_GEV_BIN_LOW_49");
186 queryStrings.push_back(
"E_GEV_BIN_LOW_50");
187 queryStrings.push_back(
"E_GEV_BIN_LOW_51");
188 queryStrings.push_back(
"E_GEV_BIN_LOW_52");
189 queryStrings.push_back(
"E_GEV_BIN_LOW_53");
190 queryStrings.push_back(
"E_GEV_BIN_LOW_54");
191 queryStrings.push_back(
"E_GEV_BIN_LOW_55");
192 queryStrings.push_back(
"E_GEV_BIN_LOW_56");
193 queryStrings.push_back(
"E_GEV_BIN_LOW_57");
194 queryStrings.push_back(
"E_GEV_BIN_LOW_58");
195 queryStrings.push_back(
"E_GEV_BIN_LOW_59");
196 queryStrings.push_back(
"E_GEV_BIN_LOW_60");
197 queryStrings.push_back(
"E_GEV_BIN_LOW_61");
198 queryStrings.push_back(
"E_GEV_BIN_LOW_62");
199 queryStrings.push_back(
"E_GEV_BIN_LOW_63");
200 queryStrings.push_back(
"E_GEV_BIN_LOW_64");
201 queryStrings.push_back(
"E_GEV_BIN_LOW_65");
202 queryStrings.push_back(
"E_GEV_BIN_LOW_66");
203 queryStrings.push_back(
"E_GEV_BIN_LOW_67");
204 queryStrings.push_back(
"E_GEV_BIN_LOW_68");
205 queryStrings.push_back(
"E_GEV_BIN_LOW_69");
206 queryStrings.push_back(
"E_GEV_BIN_LOW_70");
207 queryStrings.push_back(
"E_GEV_BIN_LOW_71");
208 queryStrings.push_back(
"E_GEV_BIN_LOW_72");
209 queryStrings.push_back(
"E_GEV_BIN_LOW_73");
210 queryStrings.push_back(
"E_GEV_BIN_LOW_74");
211 queryStrings.push_back(
"E_GEV_BIN_LOW_75");
212 queryStrings.push_back(
"E_GEV_BIN_LOW_76");
213 queryStrings.push_back(
"E_GEV_BIN_LOW_77");
214 queryStrings.push_back(
"E_GEV_BIN_LOW_78");
215 queryStrings.push_back(
"E_GEV_BIN_LOW_79");
216 queryStrings.push_back(
"E_GEV_BIN_LOW_80");
217 queryStrings.push_back(
"E_GEV_BIN_LOW_81");
218 queryStrings.push_back(
"E_GEV_BIN_LOW_82");
219 queryStrings.push_back(
"E_GEV_BIN_LOW_83");
220 queryStrings.push_back(
"E_GEV_BIN_LOW_84");
221 queryStrings.push_back(
"E_GEV_BIN_LOW_85");
222 queryStrings.push_back(
"E_GEV_BIN_LOW_86");
223 queryStrings.push_back(
"E_GEV_BIN_LOW_87");
224 queryStrings.push_back(
"E_GEV_BIN_LOW_88");
225 queryStrings.push_back(
"E_GEV_BIN_LOW_89");
226 queryStrings.push_back(
"E_GEV_BIN_LOW_90");
227 queryStrings.push_back(
"E_GEV_BIN_LOW_91");
228 queryStrings.push_back(
"E_GEV_BIN_LOW_92");
229 queryStrings.push_back(
"E_GEV_BIN_LOW_93");
230 queryStrings.push_back(
"E_GEV_BIN_LOW_94");
231 queryStrings.push_back(
"E_GEV_BIN_LOW_95");
232 queryStrings.push_back(
"E_GEV_BIN_LOW_96");
233 queryStrings.push_back(
"E_GEV_BIN_LOW_97");
234 queryStrings.push_back(
"E_GEV_BIN_LOW_98");
235 queryStrings.push_back(
"E_GEV_BIN_LOW_99");
236 queryStrings.push_back(
"E_GEV_BIN_LOW_100");
237 queryStrings.push_back(
"E_GEV_BIN_LOW_101");
238 queryStrings.push_back(
"E_GEV_BIN_LOW_102");
239 queryStrings.push_back(
"E_GEV_BIN_LOW_103");
240 queryStrings.push_back(
"E_GEV_BIN_LOW_104");
241 queryStrings.push_back(
"E_GEV_BIN_LOW_105");
242 queryStrings.push_back(
"E_GEV_BIN_LOW_106");
243 queryStrings.push_back(
"E_GEV_BIN_LOW_107");
244 queryStrings.push_back(
"E_GEV_BIN_LOW_108");
245 queryStrings.push_back(
"E_GEV_BIN_LOW_109");
246 queryStrings.push_back(
"E_GEV_BIN_LOW_110");
247 queryStrings.push_back(
"E_GEV_BIN_LOW_111");
248 queryStrings.push_back(
"E_GEV_BIN_LOW_112");
249 queryStrings.push_back(
"E_GEV_BIN_LOW_113");
250 queryStrings.push_back(
"E_GEV_BIN_LOW_114");
251 queryStrings.push_back(
"E_GEV_BIN_LOW_115");
252 queryStrings.push_back(
"E_GEV_BIN_LOW_116");
253 queryStrings.push_back(
"E_GEV_BIN_LOW_117");
254 queryStrings.push_back(
"E_GEV_BIN_LOW_118");
255 queryStrings.push_back(
"E_GEV_BIN_LOW_119");
256 queryStrings.push_back(
"E_GEV_BIN_LOW_120");
257 queryStrings.push_back(
"E_GEV_BIN_LOW_121");
258 queryStrings.push_back(
"E_GEV_BIN_LOW_122");
259 queryStrings.push_back(
"E_GEV_BIN_LOW_123");
260 queryStrings.push_back(
"E_GEV_BIN_LOW_124");
261 queryStrings.push_back(
"E_GEV_BIN_LOW_125");
262 queryStrings.push_back(
"E_GEV_BIN_LOW_126");
263 queryStrings.push_back(
"E_GEV_BIN_LOW_127");
268 "L1T_SCALE_HTM_ENERGY",
269 "L1T_SCALE_HTM_ENERGY.ID",
275 std::vector<double> thresholds;
277 if( scaleResults.queryFailed() ||
278 scaleResults.numberRows() != 1 )
280 edm::LogError(
"L1-O2O" ) <<
"Problem with L1HtMissScale key : when reading scale." ;
283 for( std::vector< std::string >::iterator
thresh = queryStrings.begin();
285 float tempScale = 0.;
286 scaleResults.fillVariable(*
thresh,tempScale);
287 thresholds.push_back(tempScale);
298 "GCT_PHYS_PARAMS.CONFIG_KEY",
301 if( lsbResults.queryFailed() ) {
302 edm::LogError(
"L1-O2O" ) <<
"Problem with L1HtMissScale key." ;
305 lsbResults.fillVariable(
"GCT_RGN_ET_LSB", rgnEtLsb );
309 return boost::shared_ptr< L1CaloEtScale >(
new L1CaloEtScale( 0, 0x7f, rgnEtLsb, thresholds ) );
const QueryResults singleAttribute(const T &data) const
const QueryResults basicQuery(const std::vector< std::string > &columnNames, const std::string &schemaName, const std::string &tableName, const std::string &conditionLHS="", const QueryResults conditionRHS=QueryResults(), const std::string &conditionRHSName="") const
l1t::OMDSReader m_omdsReader