#include "AliRawReaderRoot.h"
#include "AliRawReaderDate.h"
#include "AliTPCRawStream.h"
-#include "AliTPCRawStreamFast.h"
#include "AliTPCCalROC.h"
#include "AliTPCROC.h"
#include "AliMathBase.h"
#include "TTreeStream.h"
+#include "AliTPCRawStreamFast.h"
//date
#include "event.h"
fOldRCUformat(kTRUE),
fTimeAnalysis(kFALSE),
fROC(AliTPCROC::Instance()),
+ fMapping(NULL),
fCalRocArrayPedestal(72),
fCalRocArrayRMS(72),
fHistoPedestalArray(72),
fOldRCUformat(ped.fOldRCUformat),
fTimeAnalysis(ped.fTimeAnalysis),
fROC(AliTPCROC::Instance()),
+ fMapping(NULL),
fCalRocArrayPedestal(72),
fCalRocArrayRMS(72),
fHistoPedestalArray(72),
delete [] fTimeSignal;
fTimeSignal = 0;
}
+
+ // do not delete fMapping, because we do not own it.
+
}
Int_t iChannel = fROC->GetRowIndexes(icsector)[icRow]+icPad; // global pad position in sector
- // fast filling methode.
+ // fast filling method
// Attention: the entry counter of the histogram is not increased
// this means that e.g. the colz draw option gives an empty plot
Int_t bin = (iChannel+1)*(fAdcMax-fAdcMin+2)+((Int_t)csignal-fAdcMin+1);
return 0;
}
+
+
//_____________________________________________________________________
Bool_t AliTPCCalibPedestal::ProcessEventFast(AliTPCRawStreamFast *rawStreamFast)
{
//
// Event processing loop - AliRawReader
//
- printf("ProcessEventFast - raw reader\n");
-
- AliTPCRawStreamFast *rawStreamFast = new AliTPCRawStreamFast(rawReader);
+ AliTPCRawStreamFast *rawStreamFast = new AliTPCRawStreamFast(rawReader, (AliAltroMapping**)fMapping);
Bool_t res=ProcessEventFast(rawStreamFast);
delete rawStreamFast;
return res;
}
+
//_____________________________________________________________________
Bool_t AliTPCCalibPedestal::ProcessEvent(AliTPCRawStream *rawStream)
{
Bool_t withInput = kFALSE;
while (rawStream->Next()) {
+
Int_t iSector = rawStream->GetSector(); // current ROC
Int_t iRow = rawStream->GetRow(); // current row
Int_t iPad = rawStream->GetPad(); // current pad
Update(iSector,iRow,iPad,iTimeBin,signal);
withInput = kTRUE;
}
+
return withInput;
}
+
+
//_____________________________________________________________________
Bool_t AliTPCCalibPedestal::ProcessEvent(AliRawReader *rawReader)
{
// Event processing loop - AliRawReader
//
- AliTPCRawStream rawStream(rawReader);
+ // if fMapping is NULL the rawstream will crate its own mapping
+ AliTPCRawStream rawStream(rawReader, (AliAltroMapping**)fMapping);
rawReader->Select("TPC");
return ProcessEvent(&rawStream);
}
//_____________________________________________________________________
TH2F* AliTPCCalibPedestal::GetHisto(Int_t sector, TObjArray *arr, /*FOLD00*/
- Int_t nbinsY, Float_t ymin, Float_t ymax,
- Char_t *type, Bool_t force)
+ Int_t nbinsY, Float_t ymin, Float_t ymax,
+ Char_t *type, Bool_t force)
{
//
// return pointer to Q histogram