133 log << MSG::DEBUG <<
"initGrouping "<<
endmsg;
138 log << MSG::ERROR <<
"Unknown grouping "<<
endmsg;
144 log << MSG::DEBUG <<
"Single group "<<
endmsg;
147 std::vector<HWIdentifier>::const_iterator febIt =
m_onlineHelper->feb_begin();
148 std::vector<HWIdentifier>::const_iterator febEnd =
m_onlineHelper->feb_end();
150 for (; febIt != febEnd; ++febIt) {
151 febIds.push_back((*febIt).get_identifier32().get_compact());
154 unsigned int nChanPerGain = 1;
155 unsigned int minGain = 0;
156 unsigned int nGains = 3;
162 log << MSG::DEBUG <<
"Subdetector grouping "<<
endmsg;
165 std::vector<HWIdentifier>::const_iterator febIt =
m_onlineHelper->feb_begin();
166 std::vector<HWIdentifier>::const_iterator febEnd =
m_onlineHelper->feb_end();
173 for (; febIt != febEnd; ++febIt) {
174 unsigned int febId = (*febIt).get_identifier32().get_compact();
176 emBarrel.push_back(febId);
179 emEndcap.push_back(febId);
182 hec.push_back(febId);
185 fcal.push_back(febId);
188 log << MSG::DEBUG <<
"Uassociated FEB id: "
189 << MSG::hex << (febId) << MSG::dec
196 unsigned int nChanPerGain = 4;
197 unsigned int minGain = 0;
198 unsigned int nGains = 3;
238 log << MSG::DEBUG <<
"Extended Subdetector grouping "<<
endmsg;
241 std::vector<HWIdentifier>::const_iterator febIt =
m_onlineHelper->feb_begin();
242 std::vector<HWIdentifier>::const_iterator febEnd =
m_onlineHelper->feb_end();
251 for (; febIt != febEnd; ++febIt) {
254 if(iside <0 || iside > 1) {
255 log << MSG::ERROR <<
"Wrong side id: "<< iside <<
" from: "
256 << MSG::hex << *febIt << MSG::dec <<
endmsg;
257 return (StatusCode::FAILURE);
259 unsigned int febId = (*febIt).get_identifier32().get_compact();
261 emBarrelPS[iside].push_back(febId);
264 emEndcapPS[iside].push_back(febId);
267 emBarrel[iside].push_back(febId);
270 emEndcap[iside].push_back(febId);
273 hec[iside].push_back(febId);
276 fcal[iside].push_back(febId);
279 log << MSG::DEBUG <<
"Uassociated FEB id: "
280 << MSG::hex << (febId) << MSG::dec
287 unsigned int nChanPerGain = 12;
288 unsigned int minGain = 0;
289 unsigned int nGains = 3;
291 for (
int iside=0; iside<2; ++iside) {
302 log << MSG::DEBUG <<
"FeedThrough grouping "<<
endmsg;
305 std::vector<HWIdentifier>::const_iterator febIt =
m_onlineHelper->feb_begin();
306 std::vector<HWIdentifier>::const_iterator febEnd =
m_onlineHelper->feb_end();
308 std::vector<LArCondFEBIdChanMap::FEBIdVector> ft(
m_onlineHelper->feedthroughHashMax());
311 for (; febIt != febEnd; ++febIt) {
319 if (fthash < ft.size()) {
323 log << MSG::ERROR <<
"Feedthru hash > channel map size: id, hash, size "
324 << MSG::hex << febId << MSG::dec <<
" "
325 << ftid <<
" " << ft.size()
327 return (StatusCode::FAILURE);
331 unsigned int nChanPerGain = ft.size();
332 unsigned int minGain = 0;
333 unsigned int nGains = 3;
335 for (
unsigned int i = 0; i < ft.size(); ++i) {
341 log << MSG::DEBUG <<
"Extended FeedThrough grouping (PS goes seperatly, EMEC in HEC as well)"<<
endmsg;
344 std::vector<HWIdentifier>::const_iterator febIt =
m_onlineHelper->feb_begin();
345 std::vector<HWIdentifier>::const_iterator febEnd =
m_onlineHelper->feb_end();
349 std::vector<LArCondFEBIdChanMap::FEBIdVector> ft(
m_onlineHelper->feedthroughHashMax());
351 std::vector<LArCondFEBIdChanMap::FEBIdVector> ftPS(
m_onlineHelper->feedthroughHashMax());
353 std::vector<LArCondFEBIdChanMap::FEBIdVector> ftSpecial(8);
355 for (; febIt != febEnd; ++febIt) {
365 if (fthash >= ft.size()) {
366 log << MSG::ERROR <<
"Feedthru hash > channel map size: id, hash, size "
367 << MSG::hex << febId << MSG::dec <<
" "
368 << ftid <<
" " << ft.size()
370 return (StatusCode::FAILURE);
384 ftSpecial[0].push_back(
m_onlineHelper->feb_Id(1,0,3,1).get_identifier32().get_compact());
385 ftSpecial[0].push_back(
m_onlineHelper->feb_Id(1,0,3,2).get_identifier32().get_compact());
387 ftSpecial[1].push_back(
m_onlineHelper->feb_Id(1,1,3,1).get_identifier32().get_compact());
388 ftSpecial[1].push_back(
m_onlineHelper->feb_Id(1,1,3,2).get_identifier32().get_compact());
390 ftSpecial[2].push_back(
m_onlineHelper->feb_Id(1,0,10,1).get_identifier32().get_compact());
391 ftSpecial[2].push_back(
m_onlineHelper->feb_Id(1,0,10,2).get_identifier32().get_compact());
393 ftSpecial[3].push_back(
m_onlineHelper->feb_Id(1,1,10,1).get_identifier32().get_compact());
394 ftSpecial[3].push_back(
m_onlineHelper->feb_Id(1,1,10,2).get_identifier32().get_compact());
396 ftSpecial[4].push_back(
m_onlineHelper->feb_Id(1,0,16,1).get_identifier32().get_compact());
397 ftSpecial[4].push_back(
m_onlineHelper->feb_Id(1,0,16,2).get_identifier32().get_compact());
399 ftSpecial[5].push_back(
m_onlineHelper->feb_Id(1,1,16,1).get_identifier32().get_compact());
400 ftSpecial[5].push_back(
m_onlineHelper->feb_Id(1,1,16,2).get_identifier32().get_compact());
402 ftSpecial[6].push_back(
m_onlineHelper->feb_Id(1,0,22,1).get_identifier32().get_compact());
403 ftSpecial[6].push_back(
m_onlineHelper->feb_Id(1,0,22,2).get_identifier32().get_compact());
405 ftSpecial[7].push_back(
m_onlineHelper->feb_Id(1,1,22,1).get_identifier32().get_compact());
406 ftSpecial[7].push_back(
m_onlineHelper->feb_Id(1,1,22,2).get_identifier32().get_compact());
410 unsigned int nChanPerGain = ft.size()+ftPS.size()+ftSpecial.size();
411 unsigned int minGain = 0;
412 unsigned int nGains = 3;
413 unsigned int iCoolChannel=0;
415 for (
unsigned int i = 0; i < ft.size(); ++i) {
418 for (
unsigned int i = 0; i < ftPS.size(); ++i) {
421 for (
unsigned int i = 0; i < ftSpecial.size(); ++i) {
426 return StatusCode::FAILURE;
432 log << MSG::DEBUG <<
"Number of channels per gain "
436 log << MSG::DEBUG <<
"Mininum gain value "
440 log << MSG::DEBUG <<
"Number of gain values "
444 log << MSG::DEBUG <<
"Number of offset channels "
448 log << MSG::DEBUG <<
"Total number of channels "
452 return (StatusCode::SUCCESS);