ATLAS Offline Software
Loading...
Searching...
No Matches
LArRodBlockPhysicsV0.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5// Implementation of the LArRODBlockStructure_3 class
6// This version contains LArRawChannels (=E,t,Q)
7// and LArDigits (=5 time samples)
8// See .h file for more details.
9
14#include "GaudiKernel/Bootstrap.h"
15#include "GaudiKernel/ISvcLocator.h"
16#include "GaudiKernel/IToolSvc.h"
17#include <stdlib.h>
18#include <cstdio>
19#include <iostream>
20
21//#define LARBSDBGOUTPUT
22#ifdef LARBSDBGOUTPUT
23#define LARBSDBG(text) m_logstr<<MSG::DEBUG<<text<<endmsg
24#else
25#define LARBSDBG(text)
26#endif
27
28namespace {
29union ShortLong {
30 uint16_t s[2];
31 uint32_t l;
32};
33}
34
35const uint32_t LArRodBlockPhysicsV0::m_DummyBitMap[4]={0xffffffff,0xffffffff,0xffffffff,0xffffffff};
36
38m_logstr(Athena::getMessageSvc(), BlockType())
39{
40 // retrieve onlineHelper
41 const LArOnlineID* online_id;
42 SmartIF<StoreGateSvc> detStore{Gaudi::svcLocator()->service("DetectorStore")};
43 if (!detStore) {
44 m_logstr << MSG::ERROR << "Unable to locate DetectorStore" << endmsg;
45 std::abort();
46 }
47 StatusCode sc = detStore->retrieve(online_id, "LArOnlineID");
48 if (sc.isFailure()) {
49 m_logstr << MSG::FATAL << "Could not get LArOnlineID helper !" << endmsg;
50 std::abort();
51 }
52 else {
53 m_onlineHelper=online_id;
54 m_logstr << MSG::DEBUG << " Found the LArOnlineID helper. " << endmsg;
55 }
56
57 m_iHeadBlockSize=endtag/2; // The implicit cast rounds down to the right size
60 m_vFragment=NULL;
61 m_FebBlock=NULL;
62 m_pRODblock=NULL;
63 m_FlagPtr=NULL;
64 m_HighEPtr=NULL;
65 m_LowEPtr=NULL;
66}
67
68// clear temporary block vectors
74
83
84//For reading (to speed up the process)
86{//Set pointers to data blocks (presuming, they exist)
90 m_LowEPtr=reinterpret_cast<const int16_t*>(m_FlagPtr+m_NFlaggingWords);
91 }
92 else
93 {//m_FlagPtr=NULL;
94 //m_LowEPtr=NULL;
95 //Bugfix, 9.8.2004, WL: Set pointer to dummy map to read FEB with only high energy block
97 m_LowEPtr=reinterpret_cast<const int16_t*>(m_FlagPtr);
98 }
101 else
102 m_HighEPtr=NULL;
103 }
104 else
105 {m_FlagPtr=NULL;
106 m_LowEPtr=NULL;
107 m_HighEPtr=NULL;
108 }
109#ifdef LARBSDBGOUTPUT
110 std::cout << "Fragment offsets: (m_NFlaggingWords=" << m_NFlaggingWords << ")" << std::endl;
111 std::cout << "Raw Data: " << LE_getHeader16(RawDataBlkOffset)<< std::endl;
112 if (m_FlagPtr)
113 std::cout << "Flags: " << LE_getHeader16(LowEBlkOffset)<< std::endl;
114 else
115 std::cout << "Flags: not present" << std::endl;
116
117 if (m_LowEPtr)
118 std::cout << "Low Energy: " << LE_getHeader16(LowEBlkOffset)+m_NFlaggingWords << std::endl;
119 else
120 std::cout << "Low Energy: not present" << std::endl;
121
122
123 if (m_HighEPtr)
124 std::cout << "High Energy: " << LE_getHeader16(HighEBlkOffset)<< std::endl;
125 else
126 std::cout << "High Energy: not present" << std::endl;
127#endif
128 return true;
129}
130
132{ uint16_t oldword=LE_getVectorHeader16(NGainNSamples);
133 LE_setHeader16(NGainNSamples,(oldword & 0xFF00) | n);
134}
135
137{ uint16_t oldword=LE_getVectorHeader16(NGainNSamples);
138 LE_setHeader16(NGainNSamples,(oldword & 0x00FF) | (n<<8));
139}
140
141
142void LArRodBlockPhysicsV0::setNextEnergy(const int channel, const int32_t energy,
143 const int32_t time, const int32_t quality, const uint32_t gain) {
144 int rcNb=FebToRodChannel(channel);
145 //rcNb ist supposed to equal or bigger than m_EIndex.
146 //In the latter case, we fill up the missing channels with zero
147 if (rcNb<m_EIndex) {
148 m_logstr << MSG::ERROR << "LArRODBlockStructure Error: Internal error. Channels not ordered correctly. rcNb=" << rcNb
149 << " m_EIndex=" << m_EIndex << endmsg;
150 return;
151 }
152 //Fill up missing channels with zeros:
153 while (m_EIndex<rcNb)
154 setNextEnergy(0,0,-1,0);
155 //Add data...
156 setNextEnergy(energy,time,quality,gain);
157 //std::cout << "SetNextEnergy " << channel << " : " << energy << std::endl;
158 return;
159}
160//Private function, expects channel number is rod-style ordering
161void LArRodBlockPhysicsV0::setNextEnergy(const int32_t energy, const int32_t time, const int32_t quality, const uint32_t gain)
162{
163 if (m_EIndex>=m_channelsPerFEB) //Use m_EIndex to count total number of channels
164 {m_logstr << MSG::ERROR << "LArRodBlockStructure Error: Attempt to write Energy for channel "
165 << m_EIndex << " channels into a FEB!" <<endmsg;
166 return;
167 }
168 LARBSDBG("LArRodBlockStructure: Setting Energy for channel " << m_EIndex << ". E=" << energy);
169 if (quality<0 && energy<0x7FFE && gain==0) { //Write into Low Energy block
170 m_LowEIndex++; //Use m_LowEIndex to count the channels in the Low Energy block
171 ShortLong twoValues{};
172 twoValues.s[0]=0;
173 twoValues.s[1]=0;
174 if (m_LowEIndex%2==1) { //This is an odd number, simply add data at the bottom of the block
175 twoValues.s[0]=(int16_t)energy;
176 }
177 else { //Even number: Merging with previous block
178 uint32_t oneValue=m_LowEnergyBlock[m_LowEnergyBlock.size()-1]; //Take last element of vector
179 m_LowEnergyBlock.pop_back();
180 int16_t* valptr=reinterpret_cast<int16_t*>(&oneValue);
181 twoValues.s[0]=valptr[0];
182 twoValues.s[1]=(int16_t)energy;
183 }
184 LARBSDBG("Writing words: val0= " << twoValues.s[0] << " val1= " << twoValues.s[1]);
185 m_LowEnergyBlock.push_back(twoValues.l);
186 LARBSDBG("Writing Raw data to Low E block. E=" << energy);
187 }
188 else //Write into High Energy block
190 m_HighEnergyBlock.push_back(*((uint32_t*)(&energy)));
191 uint32_t t_sign;
192 uint32_t abs_time;
193 if (time<0)
194 t_sign=1;
195 else
196 t_sign=0;
197 abs_time=abs(time);
198 if (abs_time>0x1fff)
199 abs_time=0x1fff;
200 //uint32_t gtQ = (gain << 30) | ((time & 0x3fff)<<16) | (0xffff & quality);
201 uint32_t gtQ = (gain << 30) | (t_sign<<29) | ((abs_time & 0x1fff)<<16) | (0xffff & quality);
202 m_HighEnergyBlock.push_back(gtQ);
203 LARBSDBG("Writing Raw data to High E block. E=" << energy << " Q=" << quality);
204 }
205 m_EIndex++;
206 // if (energy>0)
207 //m_ECounter++;
208}
209
210
211void LArRodBlockPhysicsV0::setRawData(const int channel, const std::vector<short>& samples, const uint32_t gain) {
212 //Convert Feb to Rod Channel Number:
213 //int rcNb=(channel>>3) + ((channel&0x7)<<4);
214 int rcNb=FebToRodChannel(channel);
215 if (rcNb>=m_channelsPerFEB)
216 {m_logstr << MSG::ERROR << "Attempt to write Energy for channel " << rcNb << " channels into a FEB!" << endmsg;
217 return;
218 }
219 unsigned int nsamples = LE_getVectorHeader16(NGainNSamples) & 0x00FF;
220 if(samples.size() != nsamples) {
221 m_logstr << MSG::ERROR << "Number of samples mismatch!\n";
222 m_logstr << " nsamples =" << nsamples;
223 m_logstr << " samples.size() =" << samples.size() << endmsg;
224 std::abort();
225 }
226
227 setBit(&m_RawDataBlock[0],rcNb);
228 //Samples have 12 bit and are shifted to the left by 2 bits.
229 // odd samples in high bits, even samples in low bits
230 if((nsamples/2)*2!=nsamples) { //odd number of samples - gain is alone
231 m_RawDataBlock.push_back((gain<<30) | samples[0]<<2);
232 for (unsigned int i=1;i<nsamples;i+=2)
233 m_RawDataBlock.push_back((samples[i+1]<<18) | samples[i]<<2);
234 }
235 else { //even number of samples - gain is packed with sample 0
236 m_RawDataBlock.push_back((gain<<30) | (samples[1]<<18) | samples[0]<<2);
237 for (unsigned int i=2;i<nsamples;i+=2)
238 m_RawDataBlock.push_back((samples[i+1]<<18) | samples[i]<<2);
239 }
240}
241
242
243//For writing: takes existing Fragment and splits it into Feb-Blocks
244void LArRodBlockPhysicsV0::initializeFragment(std::vector<uint32_t>& fragment)
245{
246 m_pRODblock=&fragment; //remember pointer to fragment
247 if (fragment.size()>m_iHeadBlockSize) { //Got filled fragment
248 unsigned int sizeRead=0;
249 //Store existing data in the FEB-Map
250 while (sizeRead<fragment.size()) {
251 std::vector<uint32_t>::iterator FebIter;
252 FebIter=fragment.begin()+sizeRead; //Store pointer to current Feb-Header
253 m_FebBlock=&(*FebIter); //Set m_FebBlock in order to use getHeader-functions.
254 uint32_t currFEBid=getHeader32(FEBID); //Get this FEB-ID
255 uint16_t currFebSize=getNumberOfWords(); //Size of this FEB-Block
256 //std::cout << "FebID=" << currFEBid << " FEBSize=" << currFebSize << " Vector size=" << fragment.size() << std::endl;
257 if (FebIter+currFebSize>fragment.end()) {
258 fragment.clear(); //Clear existing vector
259 m_logstr << MSG::ERROR << "Got inconsistent ROD-Fragment!" << endmsg;
260 return;
261 }
262 m_mFebBlocks[currFEBid].assign(FebIter,FebIter+currFebSize); //Copy data from ROD-fragment into FEB-Block
263 sizeRead+=currFebSize+m_MiddleHeaderSize;//6 is the middle header size
264 LARBSDBG("Found FEB-id " << currFEBid << " in existing ROD-Fragment");
265 } // end while
266 }
267 fragment.clear(); //Clear existing vector
268 return;
269}
270
271//For writing: Initalizes a single FEB-Block
274 if (m_vFragment->size()<m_iHeadBlockSize) //Got empty or spoiled fragment
275 {m_vFragment->resize(m_iHeadBlockSize,0); //Initialize FEB-Header
276 setHeader32(FEBID,id); //Set Feb ID
277 }
278
282}
283
285{
286//Complete non-complete Energy block
288 setNextEnergy(0,0,-1,0);//E=0,t=0,q=-1,G=0
289 // Energies
290 unsigned int n;
291 uint16_t BlockOffset;
292 //Low energy block....
293 n = m_LowEnergyBlock.size();
295 //Check if Low Energy Block exists and is not yet part of the fragment
296 LARBSDBG("Checking Low Energy Block n=" << n << "BlockOffset=" << BlockOffset);
297 if (n>m_NFlaggingWords && !BlockOffset)
299 for (unsigned i=0;i<n;i++)
300 m_vFragment->push_back(m_LowEnergyBlock[i]);
301 }
302 //High energy block...
303 n = m_HighEnergyBlock.size();
305 LARBSDBG("Checking High Energy Block n=" << n << "BlockOffset=" << BlockOffset);
306 //Check if High Energy-Block exists and is not yet part of the fragment
307 if (n && !BlockOffset)
309 for(unsigned int i=0;i<n;i++)
310 m_vFragment->push_back(m_HighEnergyBlock[i]);
311 }
312
313 // Raw data
314 LARBSDBG("Checking Raw Data Block");
315 n = m_RawDataBlock.size();
317 LARBSDBG("Checking Raw Data Block. n=" << n << "BlockOffset=" << BlockOffset);
318 //Check if Raw Data block exists and is not yet part of the fragment
319 if (n>m_NFlaggingWords && !BlockOffset)
321 for(unsigned int i=0;i<n;i++)
322 m_vFragment->push_back(m_RawDataBlock[i]);
323 }
325 LARBSDBG("Offsets:" << std::endl
326 << "Raw Data: " << LE_getVectorHeader16(RawDataBlkOffset) << std::endl
327 <<"Low Energy: " << LE_getVectorHeader16(LowEBlkOffset)<< std::endl
328 << "High Energy: " << LE_getVectorHeader16(HighEBlkOffset)<< std::endl
329 << "Energy-index:" << m_EIndex << std::endl
330 << "Filled channels: " << m_ECounter << std::endl);
331 clearBlocks();
332 return;
333}
334
335
337{
338 //std::cout << "Concatinating FEBs. Have "<< m_mFebBlocks.size() <<" febs." << std::endl;
339 FEBMAPTYPE::const_iterator feb_it_b=m_mFebBlocks.begin();
340 FEBMAPTYPE::const_iterator feb_it_e=m_mFebBlocks.end();
341 FEBMAPTYPE::const_iterator feb_it;
342 for (feb_it=feb_it_b;feb_it!=feb_it_e;++feb_it) {
343 if (feb_it!=feb_it_b) //Not first Feb
344
345/*
346 if (fullHeader) {//Add middle header
347 m_pRODblock->push_back(fullHeader->version().full());//Format Version number
348 m_pRODblock->push_back(fullHeader->source_id()); //Source identifer
349 m_pRODblock->push_back(fullHeader->run_no());
350 m_pRODblock->push_back(fullHeader->lvl1_id()); //Level 1 identifer
351 m_pRODblock->push_back(fullHeader->bc_id()); //Bunch Crossing identifer
352 m_pRODblock->push_back(fullHeader->lvl1_type()); //Level 1 trigger type
353 m_pRODblock->push_back(fullHeader->detev_type()); //Detector event type
354 }
355 else //No ROD-Header
356*/
358
359 //Add feb data to rod data block
360 m_pRODblock->insert (m_pRODblock->end(),
361 feb_it->second.begin(), feb_it->second.end());
362 } //end for feb_it
363
364 m_mFebBlocks.clear();
365 return;
366}
367
368int LArRodBlockPhysicsV0::getNextRawData(int& channelNumber, std::vector<short>& samples, uint32_t& gain)
369{
370 LARBSDBG("in LArRodBlockPhysicsV0::getNextRawData.");
371 LARBSDBG("m_RawDataCounter=" << m_RawDataCounter << " m_RawDataIndex="<< m_RawDataIndex);
372 LARBSDBG("m_channelsPerFEB=" << m_channelsPerFEB);
373 const int flags=(int) LE_getHeader16(RawDataBlkOffset);
374 if (!flags)
375 return 0; //Block not existing
376 if (m_RawDataCounter>=m_channelsPerFEB) //Already beyond maximal number of channels
377 return 0;
378
379 LARBSDBG("Flags="<<flags);
380 while (!getBit(m_FebBlock+flags,m_RawDataCounter)) //Look for next filled channel
382 LARBSDBG("RawDataCounter ist now " << m_RawDataCounter);
383 if (m_RawDataCounter>=m_channelsPerFEB) //No more channel availible
384 return 0;
385 }
386 LARBSDBG("Found filled channel at positon " << m_RawDataCounter);
387 //Found next filled channel
388 channelNumber=(m_RawDataCounter>>4) + ((m_RawDataCounter&0xf)<<3); //Convert ROD to FEB channel ordering
389 unsigned int nsamples = LE_getHeader16(NGainNSamples) & 0x00FF;
390 LARBSDBG("This run has " << nsamples << " samples");
391 int index = flags+m_NFlaggingWords+m_RawDataIndex*((int) (nsamples+1)/2);
392 LARBSDBG( "index="<<index);
394 LARBSDBG("In getnextRawData(). index= " << index);
395 if((nsamples/2)*2!=nsamples) { //odd number of samples
396 const uint32_t& x = m_FebBlock[index];
397 gain = x >> 30;
398 samples.push_back((short) (x>>2 & 0xfff));
399 for(unsigned int i=1;i<=(nsamples-1)/2;i++) {
400 const uint32_t& x = m_FebBlock[index+i];
401 samples.push_back((short) (x>>2 & 0xfff));
402 samples.push_back((short) (x>>18));
403 }
404 }
405 else { //even number of samples
406 const uint32_t& x = m_FebBlock[index];
407 gain = x >> 30;
408 samples.push_back((short) (x>>2 & 0xfff));
409
410 samples.push_back((short) ((x>>18) & 0xfff));
411
412 for (unsigned int i=1;i<nsamples/2;i++) {
413 const uint32_t& x = m_FebBlock[index+i];
414 samples.push_back((short) (x>>2 & 0xfff));
415 samples.push_back((short) (x >> 18));
416 }
417 } //end even numer of sample
419 return 1;
420}
421
422
423
424/*
425void LArRodBlockPhysicsV0::dumpFragment()
426{
427 if (m_pRODblock)
428 std::cout << "Dump of LArRodFragment. Block Type=3. Size of vector=" << m_pRODblock->size() <<std::endl;
429 else
430 std::cout << "Dumping FEB block" << std::endl;
431 int size_read=0;
432 int size_tot=0;
433 if (m_pRODblock)
434 size_tot=m_pRODblock->size();
435 do {
436 std::cout <<"Begin of do-while loop:" << std::endl;
437 if (m_pRODblock)
438 m_FebBlock=&m_pRODblock->at(size_read);
439 char s[33];
440 int i;
441 int FlagPosition;
442 int CurrentPosition = 0;
443
444 std::cout << " Head Block size = " << m_iHeadBlockSize << std::endl;
445 for (i=0;i<m_iHeadBlockSize;i++) {
446 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
447 std::cout << " " << CurrentPosition << " " << s
448 << " = " << (m_FebBlock[CurrentPosition]>>16)
449 << " " << (m_FebBlock[CurrentPosition] &0xffff) << std::endl;
450 CurrentPosition++;
451 }
452 std::cout << "Energy Block offset: " << LE_getHeader16(EBlkOffset) << std::endl;
453 std::cout << "tQ Block offset: " << LE_getHeader16(tQBlkOffset) << std::endl;
454 std::cout << "Raw Data Block offset " << LE_getHeader16(RawDataBlkOffset) << std::endl;
455
456 while (CurrentPosition<getNumberOfWords())
457 {FlagPosition=CurrentPosition;
458 if (CurrentPosition==LE_getHeader16(EBlkOffset))
459 {std::cout << " Found Energy Block at offset = " << LE_getHeader16(EBlkOffset) << std::endl;
460 for (i=0; i<m_NFlaggingWords; i++) {
461 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
462 std::cout << " " << CurrentPosition << " " << s
463 << " Flag word" << std::endl;
464 CurrentPosition++;
465 }
466 for (i=0; i<m_NFlaggingWords*32; i++) {
467 if(getBit(&m_FebBlock[FlagPosition],i)) {
468 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
469 std::cout << " " << CurrentPosition << " " << s
470 << " ROD Channel " << i << " FEB Channel " << RodToFebChannel(i)
471 << " = " << m_FebBlock[CurrentPosition] << std::endl;
472 CurrentPosition++;
473 }
474 }
475 } // end if energy block
476 else if (CurrentPosition==LE_getHeader16(tQBlkOffset))
477 {std::cout << " Found tQ Block at position = " << LE_getHeader16(tQBlkOffset) << std::endl;
478 FlagPosition = CurrentPosition;
479 for (i=0; i<m_NFlaggingWords; i++) {
480 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
481 std::cout << " " << CurrentPosition << " " << s
482 << " Flag word" << std::endl;
483 CurrentPosition++;
484 }
485 for (i=0; i<m_NFlaggingWords*32; i++) {
486 if(getBit(&m_FebBlock[FlagPosition],i)) {
487 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
488 std::cout << " " << CurrentPosition << " " << s
489 << " ROD Channel " << i << " FEB Channel " << RodToFebChannel(i)
490 << " = " << (m_FebBlock[CurrentPosition]>>16)
491 << " " << (m_FebBlock[CurrentPosition] &0xffff) << std::endl;
492 CurrentPosition++;
493 }
494 }
495 }// end if tQ block
496 else if (CurrentPosition==LE_getHeader16(RawDataBlkOffset))
497 {std::cout << "Found Raw Data Block at position = " <<LE_getHeader16(RawDataBlkOffset) << std::endl;
498 FlagPosition = CurrentPosition;
499 for (i=0; i<m_NFlaggingWords; i++) {
500 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
501 std::cout << " " << CurrentPosition << " " << s
502 << " Flag word" << std::endl;
503 CurrentPosition++;
504 }
505 for (i=0; i<m_NFlaggingWords*32; i++) {
506 if(getBit(&m_FebBlock[FlagPosition],i)) {
507 int nsamples = LE_getHeader16(NSamples);
508 for(int j=0;j<nsamples;j+=2) {
509 sprintf(s,"%8.8x",m_FebBlock[CurrentPosition]);
510 std::cout << " " << CurrentPosition << " " << s
511 << " ROD Channel " << i << " FEB Channel " << RodToFebChannel(i)
512 << " samples " << j << " and " << j+1 << " = "
513 << ((m_FebBlock[CurrentPosition]>>16) & 0x3fff) << " " //Mask gain!
514 << (m_FebBlock[CurrentPosition] & 0xffff) << std::endl;
515 CurrentPosition++;
516 }
517 }
518 }
519 }// end if Raw Data block
520 else
521 {std::cout << "UNKNOWN block found at position" << CurrentPosition << std::endl;
522 return;
523 }
524 }// end while
525 size_read+=CurrentPosition+6;
526 std::cout << " ------- End of FEB-Block (size_read=" <<size_read << ", size_tot=" << size_tot << ") -------" << std::endl;
527 } while(size_read<size_tot);
528 std::cout << " ------------------ End Of ROD-Framgent -----------------" << std::endl;
529}
530*/
531
532/*
533void LArRodBlockPhysicsV0::dumpFragment(const std::vector<uint32_t>& v)
534{
535 uint32_t size_tot = v.size();
536 uint32_t size_read = 0;
537 std::cout << "LAr ROD vector size = " << size_tot << std::endl;
538
539 int ifeb=0;
540 while(size_read<size_tot)
541 {
542 m_FebBlock = &(v[0]);
543 m_FebBlock+= size_read;
544 std::cout << "LAr ROD - FEB " << ifeb << std::endl;
545 dumpFragment();
546 // next FEB
547 size_read += getNumberOfWords()+6;
548 ifeb++;
549 }
550 std::cout << "End of ROD-Fragment" << std::endl;
551}
552*/
553
554
555//Sort functions & ordering relation:
556template<class RAWDATA>
557bool LArRodBlockPhysicsV0::operator ()
558 //(const LArRawChannel* ch1, const LArRawChannel* ch2) const
559 (const RAWDATA* ch1, const RAWDATA* ch2) const
560{
561 HWIdentifier id1 = ch1->channelID();
562 HWIdentifier id2 = ch2->channelID();
563
564 HWIdentifier febId1= m_onlineHelper->feb_Id(id1);
565 HWIdentifier febId2= m_onlineHelper->feb_Id(id2);
566
567 if(febId1 == febId2 ){
568 int cId1 = m_onlineHelper->channel(id1);
569 int cId2 = m_onlineHelper->channel(id2);
570 return FebToRodChannel(cId1) < FebToRodChannel(cId2);
571 }
572
573 return febId1 < febId2 ;
574}
575
576
577void LArRodBlockPhysicsV0::sortDataVector(std::vector<const LArRawChannel*>& vRC)
578{std::sort(vRC.begin(),vRC.end(),*this);}
579
580void LArRodBlockPhysicsV0::sortDataVector( std::vector<const LArDigit*>& vDigit)
581{std::sort(vDigit.begin(),vDigit.end(),*this);
582}
#define endmsg
static Double_t sc
HWIdentifier febId1
HWIdentifier febId2
HWIdentifier id2
#define LARBSDBG(text)
This class provides decoding/encoding from/to ROD format.
#define x
virtual void sortDataVector(std::vector< const LArRawChannel * > &)
std::vector< uint32_t > m_RawDataBlock
virtual int getNextRawData(int &channelNumber, std::vector< short > &samples, uint32_t &gain)
virtual void setRawData(const int channel, const std::vector< short > &samples, const uint32_t gain)
virtual void initializeFEB(const uint32_t id)
virtual void setNumberOfSamples(const uint8_t n)
int FebToRodChannel(int ch) const
static const uint32_t m_DummyBitMap[4]
virtual void setNextEnergy(const int channel, const int32_t energy, const int32_t time, const int32_t quality, const uint32_t gain)
virtual void initializeFragment(std::vector< uint32_t > &fragment)
virtual void setNumberOfGains(const uint8_t n)
std::vector< uint32_t > m_LowEnergyBlock
std::vector< uint32_t > m_HighEnergyBlock
int getBit(const uint32_t *const p, const unsigned chan) const
void setHeader32(const unsigned n, const uint32_t w)
uint16_t LE_getVectorHeader16(const unsigned n) const
void LE_setHeader16(const unsigned n, const uint16_t w)
uint32_t getHeader32(const unsigned n) const
void setBit(uint32_t *const p, const unsigned chan)
std::vector< uint32_t > * m_pRODblock
std::vector< uint32_t > * m_vFragment
uint16_t LE_getHeader16(const unsigned n) const
uint32_t getNumberOfWords() const
Some weak symbol referencing magic... These are declared in AthenaKernel/getMessageSvc....
Definition index.py:1
void sort(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of sort for DataVector/List.
setEventNumber uint32_t