Commit 948f898e authored by Norbert Herrmann's avatar Norbert Herrmann
Browse files

reformat

parent 6e451905
......@@ -73,7 +73,7 @@ using std::endl;
using std::vector;
const Int_t DetMask = 0x001FFFFF; // for v21a geometries
const Double_t DTDMAX = 6.; // diamond inspection range in ns
const Double_t DTDMAX = 6.; // diamond inspection range in ns
Double_t dTDia;
Double_t dDTD4Min = 1.E8;
......@@ -4917,14 +4917,15 @@ Bool_t CbmTofAnaTestbeam::FillHistos() {
fhTIR_all->Fill(dTIR);
LOG(debug) << Form(
" FoundMatches: %d with first chi2s = %12.1f, %12.1f, %12.1f, %12.1f",
iNbMatchedHits,
Chi2List[0],
Chi2List[1],
Chi2List[2],
Chi2List[3])
<< Form(", Muls %4.0f, %4.0f, %4.0f", dMulD, dMul0, dMul4);
LOG(debug)
<< Form(
" FoundMatches: %d with first chi2s = %12.1f, %12.1f, %12.1f, %12.1f",
iNbMatchedHits,
Chi2List[0],
Chi2List[1],
Chi2List[2],
Chi2List[3])
<< Form(", Muls %4.0f, %4.0f, %4.0f", dMulD, dMul0, dMul4);
if (BSel[0]) {
......@@ -6638,7 +6639,7 @@ Bool_t CbmTofAnaTestbeam::FillHistos() {
Double_t dDX =
pHit->GetX()
- pTrk->GetFitX(
pHit->GetZ()); // - tPar->GetX() - tPar->GetTx()*dDZ;
pHit->GetZ()); // - tPar->GetX() - tPar->GetTx()*dDZ;
Double_t dDXB = pTrk->GetXdif(
fiDutAddr, pHit); // ignore pHit in calc of reference
Double_t dDY =
......@@ -6649,7 +6650,7 @@ Bool_t CbmTofAnaTestbeam::FillHistos() {
Double_t dDT =
pHit->GetTime()
- pTrk->GetFitT(
pHit->GetZ()); // pTrk->GetTdif(fStationType[iSt]);
pHit->GetZ()); // pTrk->GetTdif(fStationType[iSt]);
Double_t dDTB = pTrk->GetTdif(
fiDutAddr, pHit); // ignore pHit in calc of reference
......@@ -6996,13 +6997,13 @@ Bool_t CbmTofAnaTestbeam::FillHistos() {
fhLHTime[iDet]->FindBin(hitpos_local[0], hitpos_local[1]);
Int_t iBinA = iBin - 1; // index in pointer array
if (0)
LOG(info) << Form(
"Insert Dut hit for Det %d, Bin %d, x %f, y %f, poi ",
iDet,
iBinA,
hitpos_local[0],
hitpos_local[1])
<< fhLHTime[iDet];
LOG(info)
<< Form("Insert Dut hit for Det %d, Bin %d, x %f, y %f, poi ",
iDet,
iBinA,
hitpos_local[0],
hitpos_local[1])
<< fhLHTime[iDet];
if (iBin <= 0
|| iBin > fhLHTime[iDet]->GetNbinsX()
......@@ -7404,7 +7405,8 @@ Bool_t CbmTofAnaTestbeam::FillHistos() {
} else {
fhSelMCTrackEfficiency->Fill(kFALSE, fiNAccRefTracks);
fhSelMCTrackEfficiencyTIS->Fill(kFALSE, (dTAv - fdStartSpillTime) / 1.E9);
fhSelMCTrackEfficiencyTIS->Fill(kFALSE,
(dTAv - fdStartSpillTime) / 1.E9);
}
}
}
......@@ -7575,7 +7577,7 @@ Bool_t CbmTofAnaTestbeam::FillHistos() {
for (Int_t iHit = 0; iHit < tTracklet->GetNofHits(); iHit++) {
if (5
== CbmTofAddress::GetSmType(
(tTracklet->GetTofHitPointer(iHit))->GetAddress())) {
(tTracklet->GetTofHitPointer(iHit))->GetAddress())) {
iNTrackletHits--;
}
}
......
......@@ -729,14 +729,15 @@ private:
Double_t fdMulDMax; // max multiplicity in Diamond counter
Double_t fdSpillDuration; // min. spill length in sec
Double_t fdSpillBreak; // min. spill break in sec
Double_t fdStartSpillTime; // Start of Spill, if negative find begin of first spill
Double_t fdDTDia; // max time difference between diamonds
Double_t fdDTD4MAX; // max time difference between reference & diamond
Double_t fdMul0Max; // max multiplicity in Dut
Double_t fdMul4Max; // max multiplicity in HD/Buc Ref counter
Double_t fdCh4Sel; // Center of selected strip numbers
Double_t fdDCh4Sel; // Width of selected strip numbers
Double_t fdPosY4Sel; // Fraction of Y-Size
Double_t
fdStartSpillTime; // Start of Spill, if negative find begin of first spill
Double_t fdDTDia; // max time difference between diamonds
Double_t fdDTD4MAX; // max time difference between reference & diamond
Double_t fdMul0Max; // max multiplicity in Dut
Double_t fdMul4Max; // max multiplicity in HD/Buc Ref counter
Double_t fdCh4Sel; // Center of selected strip numbers
Double_t fdDCh4Sel; // Width of selected strip numbers
Double_t fdPosY4Sel; // Fraction of Y-Size
Double_t fdPosY4SelOff; // Offset of selection interval in cm
Double_t fdChS2Sel; // Center of selected strip numbers
Double_t fdDChS2Sel; // Width of selected strip numbers
......
......@@ -29,10 +29,10 @@
#include <TEveVector.h> // for TEveVector, TEveVectorT
#include <TGLAnnotation.h>
#include <TGLViewer.h>
#include <TGenericClassInfo.h> // for TGenericClassInfo
#include <TObjArray.h> // for TObjArray
#include <TParticle.h> // for TParticle
#include <TString.h> // for Form, TString
#include <TGenericClassInfo.h> // for TGenericClassInfo
#include <TObjArray.h> // for TObjArray
#include <TParticle.h> // for TParticle
#include <TString.h> // for Form, TString
#include <string.h> // for strcmp
......@@ -122,7 +122,7 @@ void CbmEvDisTracks::Exec(Option_t* option) {
Reset();
LOG(debug4) << " CbmEvDisTracks:: NTrks " << fTrackList->GetEntries();
Int_t TMul[10]={10*0}; //FIXME - don't use constants in code
Int_t TMul[10] = {10 * 0}; //FIXME - don't use constants in code
for (Int_t iOpt = 0; iOpt < 2; iOpt++)
for (Int_t i = 0; i < fTrackList->GetEntriesFast(); i++) {
......@@ -132,7 +132,7 @@ void CbmEvDisTracks::Exec(Option_t* option) {
Int_t Np = tr->GetNofHits();
#if TOFDisplay == 1 //List for TEvePointSets
if(iOpt==0) TMul[Np]++;
if (iOpt == 0) TMul[Np]++;
fPSList = GetPSGroup(Np, iOpt);
#endif
......@@ -266,18 +266,24 @@ void CbmEvDisTracks::Exec(Option_t* option) {
fEventManager->SetEvtMaxEnergy(MaxEnergyLimit);
fEventManager->SetEvtMinEnergy(MinEnergyLimit);
TString cEventInfo=Form("ev# %d ",fEventManager->GetCurrentEvent());
TString cTrackInfo="trkl mul: "; // to be completed while building the display
for (Int_t i=9; i>0; i--) if(TMul[i]>0) cTrackInfo += Form("M%d %d/",i,TMul[i]);
TString cEventInfo = Form("ev# %d ", fEventManager->GetCurrentEvent());
TString cTrackInfo =
"trkl mul: "; // to be completed while building the display
for (Int_t i = 9; i > 0; i--)
if (TMul[i] > 0) cTrackInfo += Form("M%d %d/", i, TMul[i]);
TGLViewer* v = gEve->GetDefaultGLViewer();
if(NULL != anne) anne->SetText(cEventInfo);
else anne = new TGLAnnotation(v,cEventInfo,0.01,0.95);
if(NULL != annt) annt->SetText(cTrackInfo);
else annt = new TGLAnnotation(v,cTrackInfo,0.01,0.92);
anne->SetTextSize(0.03);// % of window diagonal
annt->SetTextSize(0.03);// % of window diagonal
if (NULL != anne)
anne->SetText(cEventInfo);
else
anne = new TGLAnnotation(v, cEventInfo, 0.01, 0.95);
if (NULL != annt)
annt->SetText(cTrackInfo);
else
annt = new TGLAnnotation(v, cTrackInfo, 0.01, 0.92);
anne->SetTextSize(0.03); // % of window diagonal
annt->SetTextSize(0.03); // % of window diagonal
anne->SetTextColor(4);
annt->SetTextColor(4);
......
......@@ -100,7 +100,9 @@ void CbmPointSetArray::ApplyColorMode() {
* (nCol - binCol - 1)
/ (eveTime - binTime)));
}
LOG(info) << "Color for id " << id << ", ind " << fIndex[id] << ", t "<<fTime[id]<<": " << this->GetBin(fIndex[id])->GetMainColor();
LOG(info) << "Color for id " << id << ", ind " << fIndex[id] << ", t "
<< fTime[id] << ": "
<< this->GetBin(fIndex[id])->GetMainColor();
break;
case 2: //according to Tot of hit
......
......@@ -142,7 +142,7 @@ Int_t CbmPointSetArrayDraw::GetClusterSize(TObject* obj) {
CbmTofHit* p = (CbmTofHit*) obj;
Double_t cluSize = p->GetFlag();
//Flag= #digis = 2*cluSize +100 if used for track
cluSize=((int)cluSize%100)/2;
cluSize = ((int) cluSize % 100) / 2;
LOG(debug3) << "-I- CbmPointSetArrayDraw::GetClusterSize(): " << cluSize;
return cluSize;
}
......
......@@ -133,10 +133,16 @@ Bool_t CbmTofCalibrator::CreateCalHist() {
fhCalR0 = new TH1D(
"hCalR0", "Tracklet distance to nominal vertex; R_0 [cm]", 100, 0., 0.5);
fhCalDX0 = new TH1D(
"hCalDX0", "Tracklet distance to nominal vertex; #DeltaX_0 [cm]", 100, -0.5, 0.5);
fhCalDY0 = new TH1D(
"hCalDY0", "Tracklet distance to nominal vertex; #DeltaY_0 [cm]", 100, -0.5, 0.5);
fhCalDX0 = new TH1D("hCalDX0",
"Tracklet distance to nominal vertex; #DeltaX_0 [cm]",
100,
-0.5,
0.5);
fhCalDY0 = new TH1D("hCalDY0",
"Tracklet distance to nominal vertex; #DeltaY_0 [cm]",
100,
-0.5,
0.5);
fhCalPos.resize(iNbDet);
fhCalTOff.resize(iNbDet);
......@@ -370,9 +376,9 @@ void CbmTofCalibrator::FillCalHist(CbmTofTracklet* pTrk, Int_t iOpt) {
+ (1. - 2. * tDigi0->GetSide()) * hlocal_d[1]
/ fDigiBdfPar->GetSigVel(iSmType, iSm, iRpc)
- pTrk->GetFitT(
pHit
->GetZ()) //-fTrackletTools->GetTexpected(pTrk, iDetId, pHit)
+ fTofFindTracks->GetTOff(iDetId)
pHit
->GetZ()) //-fTrackletTools->GetTexpected(pTrk, iDetId, pHit)
+ fTofFindTracks->GetTOff(iDetId)
+ 2. * (1. - 2. * tDigi0->GetSide()) * (hlocal_d[1] - hlocal_f[1])
/ fDigiBdfPar->GetSigVel(iSmType, iSm, iRpc));
/*
......@@ -391,8 +397,8 @@ void CbmTofCalibrator::FillCalHist(CbmTofTracklet* pTrk, Int_t iOpt) {
+ (1. - 2. * tDigi1->GetSide()) * hlocal_d[1]
/ fDigiBdfPar->GetSigVel(iSmType, iSm, iRpc)
- pTrk->GetFitT(
pHit
->GetZ()) //-fTrackletTools->GetTexpected(pTrk, iDetId, pHit)
pHit
->GetZ()) //-fTrackletTools->GetTexpected(pTrk, iDetId, pHit)
+ fTofFindTracks->GetTOff(iDetId)
+ 2. * (1. - 2. * tDigi1->GetSide()) * (hlocal_d[1] - hlocal_f[1])
/ fDigiBdfPar->GetSigVel(iSmType, iSm, iRpc));
......@@ -400,8 +406,8 @@ void CbmTofCalibrator::FillCalHist(CbmTofTracklet* pTrk, Int_t iOpt) {
case 0: {
Double_t dDeltaT = 0.5 * (tDigi0->GetTime() + tDigi1->GetTime())
+ fTofFindTracks->GetTOff(iDetId)
- pTrk->GetFitT(pHit->GetZ());
+ fTofFindTracks->GetTOff(iDetId)
- pTrk->GetFitT(pHit->GetZ());
fhCalWalk[iDetIndx][iCh0][iSide0]->Fill(tDigi0->GetTot(), dDeltaT);
fhCalWalk[iDetIndx][iCh1][iSide1]->Fill(tDigi1->GetTot(), dDeltaT);
} break;
......@@ -488,8 +494,8 @@ Bool_t CbmTofCalibrator::UpdateCalHist(Int_t iOpt) {
}
}
} break;
case 2: // update individual channel walks
if(iSmType==5) continue; // no walk correction for beam counter
case 2: // update individual channel walks
if (iSmType == 5) continue; // no walk correction for beam counter
const Double_t MinCounts = 10.;
Int_t iNbCh = fDigiBdfPar->GetNbChan(iSmType, iRpc);
for (Int_t iCh = 0; iCh < iNbCh; iCh++) {
......
......@@ -351,7 +351,7 @@ void CbmTofEventClusterizer::Exec(Option_t* option) {
LOG(info) << "CbmTofEventClusterizer::Exec => New timeslice " << iNbTs
<< " with " << fEventsColl->GetEntriesFast() << " events, "
<< fDigiMan->GetNofDigis(ECbmModuleId::kTof) << " TOF digis + "
<< fDigiMan->GetNofDigis(ECbmModuleId::kT0) << " T0 digis ";
<< fDigiMan->GetNofDigis(ECbmModuleId::kT0) << " T0 digis ";
iNbTs++;
Int_t iNbHits = 0;
......@@ -364,17 +364,18 @@ void CbmTofEventClusterizer::Exec(Option_t* option) {
fTofDigiVec.clear();
//if (fTofDigisColl) fTofDigisColl->Clear("C");
//Int_t iNbDigis=0; (VF) not used
LOG(debug) << "TS event "<<iEvent<<" with "
<<tEvent->GetNofData(ECbmDataType::kT0Digi) << " T0 and "
<<tEvent->GetNofData(ECbmDataType::kTofDigi) << " Tof digis ";
LOG(debug) << "TS event " << iEvent << " with "
<< tEvent->GetNofData(ECbmDataType::kT0Digi) << " T0 and "
<< tEvent->GetNofData(ECbmDataType::kTofDigi) << " Tof digis ";
for (Int_t iDigi = 0; iDigi < tEvent->GetNofData(ECbmDataType::kT0Digi);
iDigi++) {
Int_t iDigiIndex =
static_cast<Int_t>(tEvent->GetIndex(ECbmDataType::kT0Digi, iDigi));
const CbmTofDigi* tDigi = fDigiMan->Get<CbmTofDigi>(iDigiIndex);
if( tDigi->GetType() != 5 )
LOG(fatal) << "Wrong T0 type " << tDigi->GetType() << ", Addr 0x" <<std::hex<< tDigi->GetAddress();
if (tDigi->GetType() != 5)
LOG(fatal) << "Wrong T0 type " << tDigi->GetType() << ", Addr 0x"
<< std::hex << tDigi->GetAddress();
fTofDigiVec.push_back(CbmTofDigi(*tDigi));
}
for (Int_t iDigi = 0; iDigi < tEvent->GetNofData(ECbmDataType::kTofDigi);
......@@ -2797,8 +2798,9 @@ Bool_t CbmTofEventClusterizer::FillHistos() {
|| (TMath::Sqrt(
TMath::Power(
pHit->GetX() - dzscal * pTrig[iSel]->GetX(), 2.)
+ TMath::Power(
pHit->GetY() - dzscal * pTrig[iSel]->GetY(), 2.))
+ TMath::Power(pHit->GetY()
- dzscal * pTrig[iSel]->GetY(),
2.))
< fdCaldXdYMax)) {
BSel[iSel] = kTRUE;
Double_t dX2Y2 = TMath::Sqrt(dSEl2dXdz * dSEl2dXdz
......@@ -3241,11 +3243,11 @@ Bool_t CbmTofEventClusterizer::FillHistos() {
* (pHit->GetZ() - (pTrig[iSel]->GetZ()))),
2.)
+ TMath::Power(
pHit->GetY()
- (pTrig[iSel]->GetY()
+ ddYdZ[iSel]
* (pHit->GetZ() - (pTrig[iSel]->GetZ()))),
2.))
pHit->GetY()
- (pTrig[iSel]->GetY()
+ ddYdZ[iSel]
* (pHit->GetZ() - (pTrig[iSel]->GetZ()))),
2.))
> 0.5 * fdCaldXdYMax)
continue; // refine position selection cut in cosmic measurement
dTcor[iSel] = 0.; // precaution
......@@ -5422,8 +5424,7 @@ Bool_t CbmTofEventClusterizer::BuildClusters() {
(0 == pDigi->GetSide()) ? 1 : 0,
pDigi->GetType());
LOG(debug) << "Duplicated digi " << fTofDigiVec.size()
<< " with address 0x" << std::hex
<< pDigiN->GetAddress();
<< " with address 0x" << std::hex << pDigiN->GetAddress();
}
}
iNbTofDigi = fTofDigiVec.size();
......@@ -6936,55 +6937,72 @@ Bool_t CbmTofEventClusterizer::BuildHits() {
(CbmTofHit*) fTofHitsColl->At(fiNbHits - 1);
if (iDetId == pHitL->GetAddress()
&& dWeightedTime == pHitL->GetTime()) {
LOG(debug) << "Store Hit twice? "
<< " fiNbHits " << fiNbHits << ", "
<< Form("0x%08x, MatchCollSize %d, IndRefSize %lu ",
iDetId, fTofDigiMatchColl->GetEntriesFast(),vDigiIndRef.size());
LOG(debug)
<< "Store Hit twice? "
<< " fiNbHits " << fiNbHits << ", "
<< Form("0x%08x, MatchCollSize %d, IndRefSize %lu ",
iDetId,
fTofDigiMatchColl->GetEntriesFast(),
vDigiIndRef.size());
for (UInt_t i = 0; i < vDigiIndRef.size(); i++) {
if(vDigiIndRef.at(i) < (Int_t) fTofCalDigiVec->size()) {
CbmTofDigi* pDigiC = &(fTofCalDigiVec->at(vDigiIndRef.at(i)));
LOG(debug) << " Digi " <<i<<" "<< pDigiC->ToString();
} else {
LOG(fatal) << "Insufficient CalDigiVec size for i "
<< i <<", Ind " << vDigiIndRef.at(i);
}
if (vDigiIndRef.at(i)
< (Int_t) fTofCalDigiVec->size()) {
CbmTofDigi* pDigiC =
&(fTofCalDigiVec->at(vDigiIndRef.at(i)));
LOG(debug)
<< " Digi " << i << " " << pDigiC->ToString();
} else {
LOG(fatal)
<< "Insufficient CalDigiVec size for i " << i
<< ", Ind " << vDigiIndRef.at(i);
}
}
if(NULL == fTofDigiMatchColl) assert("No DigiMatchColl");
CbmMatch* digiMatchL=NULL;
if( fTofDigiMatchColl->GetEntriesFast() >= fiNbHits-1) {
digiMatchL=(CbmMatch*) fTofDigiMatchColl->At(fiNbHits-1);
}else{
LOG(fatal) << "DigiMatchColl has insufficient size "
<< fTofDigiMatchColl->GetEntriesFast();
if (NULL == fTofDigiMatchColl)
assert("No DigiMatchColl");
CbmMatch* digiMatchL = NULL;
if (fTofDigiMatchColl->GetEntriesFast()
>= fiNbHits - 1) {
digiMatchL =
(CbmMatch*) fTofDigiMatchColl->At(fiNbHits - 1);
} else {
LOG(fatal) << "DigiMatchColl has insufficient size "
<< fTofDigiMatchColl->GetEntriesFast();
}
if(NULL != digiMatchL)
for (Int_t i = 0; i < digiMatchL->GetNofLinks(); i++) {
CbmLink L0 = digiMatchL->GetLink(i);
LOG(debug) << "report link "<<i<<"("<<digiMatchL->GetNofLinks()<<"), ind "<<L0.GetIndex();
Int_t iDigIndL = L0.GetIndex();
if (iDigIndL >= (Int_t) vDigiIndRef.size()) {
if (iDetId != fiBeamRefAddr) {
LOG(warn) << Form(
"Invalid DigiRefInd for det 0x%08x", iDetId);
if (NULL != digiMatchL)
for (Int_t i = 0; i < digiMatchL->GetNofLinks();
i++) {
CbmLink L0 = digiMatchL->GetLink(i);
LOG(debug) << "report link " << i << "("
<< digiMatchL->GetNofLinks()
<< "), ind " << L0.GetIndex();
Int_t iDigIndL = L0.GetIndex();
if (iDigIndL >= (Int_t) vDigiIndRef.size()) {
if (iDetId != fiBeamRefAddr) {
LOG(warn)
<< Form("Invalid DigiRefInd for det 0x%08x",
iDetId);
continue;
}
}
if (vDigiIndRef.at(iDigIndL)
>= (Int_t) fTofCalDigiVec->size()) {
LOG(warn) << "Invalid CalDigiInd";
continue;
}
CbmTofDigi* pDigiC =
&(fTofCalDigiVec->at(vDigiIndRef.at(iDigIndL)));
LOG(debug) << " DigiL " << pDigiC->ToString();
}
if (vDigiIndRef.at(iDigIndL)
>= (Int_t) fTofCalDigiVec->size()) {
LOG(warn) << "Invalid CalDigiInd";
continue;
}
CbmTofDigi* pDigiC =
&(fTofCalDigiVec->at(vDigiIndRef.at(iDigIndL)));
LOG(debug) << " DigiL " << pDigiC->ToString();
} else {
LOG(warn) << "Invalid digMatch Link at Index " << fiNbHits-1;
else {
LOG(warn) << "Invalid digMatch Link at Index "
<< fiNbHits - 1;
}
}
LOG(debug)<< "Current HitsColl length " << fTofHitsColl->GetEntriesFast();
LOG(debug) << "Current HitsColl length "
<< fTofHitsColl->GetEntriesFast();
}
CbmTofHit* pHit = new CbmTofHit(
iDetId,
......@@ -6992,7 +7010,8 @@ Bool_t CbmTofEventClusterizer::BuildHits() {
hitPosErr, //local detector coordinates
fiNbHits, // this number is used as reference!!
dWeightedTime,
vDigiIndRef.size(), // number of linked digis = 2*CluSize
vDigiIndRef
.size(), // number of linked digis = 2*CluSize
//vPtsRef.size(), // flag = number of TofPoints generating the cluster
Int_t(dWeightsSum * 10.)); //channel -> Tot
//0) ; //channel
......@@ -7542,11 +7561,12 @@ Bool_t CbmTofEventClusterizer::CalibRawDigis() {
<< fDigiBdfPar->GetNbChan(pDigi->GetType(), 0);
}
if (0) // (bAddBeamCounterSideDigi)
if (0) // (bAddBeamCounterSideDigi)
if (pCalDigi->GetType() == 5
|| pCalDigi->GetType()
== 8) { // for Pad counters generate fake digi to mockup a strip
LOG(debug) << "add Pad counter 2. Side digi for 0x" << std::hex << pCalDigi->GetAddress();
LOG(debug) << "add Pad counter 2. Side digi for 0x" << std::hex
<< pCalDigi->GetAddress();
fTofCalDigiVec->push_back(CbmTofDigi(*pCalDigi));
CbmTofDigi* pCalDigi2 = &(fTofCalDigiVec->back());
iDigIndCal++;
......
......@@ -289,18 +289,19 @@ InitStatus CbmTofFindTracks::Init() {
for (Int_t iCell = 0; iCell < fDigiPar->GetNrOfModules(); iCell++) {
Int_t iCellId = fDigiPar->GetCellId(iCell);
Int_t iCh = fTofId->GetCell(iCellId);
if ( 0 == iCh ) {
LOG(info) << Form(
"Init found RpcInd %d, %lu at Addr 0x%08x, ModType %d, ModId %d, RpcId %d ",
iRpc, fRpcAddr.size(),
iCellId,
fTofId->GetSMType(iCellId),
fTofId->GetSModule(iCellId),
fTofId->GetCounter(iCellId));
if (0 == iCh) {
LOG(info) << Form("Init found RpcInd %d, %lu at Addr 0x%08x, ModType %d, "
"ModId %d, RpcId %d ",
iRpc,
fRpcAddr.size(),
iCellId,
fTofId->GetSMType(iCellId),
fTofId->GetSModule(iCellId),
fTofId->GetCounter(iCellId));
if (fTofId->GetSMType(iCellId) == 5) {
bBeamCounter = kTRUE;
LOG(info) << "Found beam counter in setup! at RpcInd " << iRpc
<< ", Addr.size " << fRpcAddr.size();
<< ", Addr.size " << fRpcAddr.size();
}
fMapRpcIdParInd[iCellId] = iRpc;
fRpcAddr.push_back(iCellId);
......@@ -738,7 +739,7 @@ Bool_t CbmTofFindTracks::WriteHistos() {
TF1* fg = hpy->GetFunction("gaus");
Double_t dFMeanError = fg->GetParError(1);
LOG(info) << "Update hPullT_Smt_Off3 Ind " << ix
<< Form(", 0x%08x: ",fRpcAddr[ix])
<< Form(", 0x%08x: ", fRpcAddr[ix])
<< fhPullT_Smt_Off->GetBinContent(ix + 1) << " + "
<< dFMean << ", Err " << dFMeanError << " -> " << dVal
<< ", Width " << dRMS << ", Chi2 " << fg->GetChisquare();
......@@ -749,7 +750,8 @@ Bool_t CbmTofFindTracks::WriteHistos() {
!= fiBeamCounter) // don't correct beam counter time
fhPullT_Smt_Off->SetBinContent(ix + 1, dVal);
else
LOG(info)<<"No Off3 correction for beam counter at index "<<ix;
LOG(info) << "No Off3 correction for beam counter at index "
<< ix;
fhPullT_Smt_Width->SetBinContent(ix + 1, dRMS);
}
} else {
......@@ -812,7 +814,8 @@ Bool_t CbmTofFindTracks::WriteHistos() {
<< fhPullX_Smt_Off->GetBinContent(ix + 1) << " + "
<< htmp1D->GetBinContent(ix + 1) << " -> " << dVal
<< ", Width " << dRMS;
if( fRpcAddr[ix] != fiBeamCounter ) // don't correct beam counter position
if (fRpcAddr[ix]
!= fiBeamCounter) // don't correct beam counter position
fhPullX_Smt_Off->SetBinContent(ix + 1, dVal);
fhPullX_Smt_Width->SetBinContent(ix + 1, dRMS);
}
......@@ -835,7 +838,8 @@ Bool_t CbmTofFindTracks::WriteHistos() {
for (Int_t ix = 0; ix < nx; ix++) {
Double_t dVal = fhPullY_Smt_Off->GetBinContent(ix + 1);
dVal -= htmp1D->GetBinContent(ix + 1);
if( fRpcAddr[ix] != fiBeamCounter ) // don't correct beam counter position
if (fRpcAddr[ix]
!= fiBeamCounter) // don't correct beam counter position
fhPullY_Smt_Off->SetBinContent(ix + 1, dVal);
TH1D* hpy = fhPullY_Smt->ProjectionY("_py", ix + 1, ix + 1);
......@@ -1746,7 +1750,9 @@ void CbmTofFindTracks::FindVertex() {
w,
fMinNofHits);
if (w > (Double_t)
if (
w
> (Double_t)
fMinNofHits) { // for further analysis request minimum number of hits
fVTXNorm += w;
fVTX_T += w * pTrk->GetFitT(0.);
......@@ -1900,13 +1906,13 @@ void CbmTofFindTracks::FillHistograms() {
Double_t dDX =
pHit->GetX()
- pTrk->GetFitX(
pHit->GetZ()); // - tPar->GetX() - tPar->GetTx()*dDZ;
pHit->GetZ()); // - tPar->GetX() - tPar->GetTx()*dDZ;
Double_t dDY =
pHit->GetY() - pTrk->GetFitY(pHit->GetZ()); // - tPar->GetTy()*dDZ;
Double_t dDT =
pHit->GetTime()
- pTrk->GetFitT(
pHit->GetZ()); // pTrk->GetTdif(fMapStationRpcId[iSt]);
pHit->GetZ()); // pTrk->GetTdif(fMapStationRpcId[iSt]);
Double_t dDTB =
fTrackletTools->GetTdif(pTrk,
fMapStationRpcId[iSt],
......@@ -1914,20 +1920,21 @@ void CbmTofFindTracks::FillHistograms() {
Double_t dTOT = pHit->GetCh() / 10.; // misuse of channel field
Double_t dZZ = pHit->GetZ() - tPar->GetZy(pHit->GetY());
LOG(debug) << Form(
" St %d Id 0x%08x Hit %2d, Z %6.2f - DX %6.2f, DY %6.2f, "
"Z %6.2f, DT %6.2f, %6.2f, ZZ %6.2f, Tt %6.4f ",
iSt,
fMapStationRpcId[iSt],
iH,
pHit->GetZ(),
dDX,
dDY,
dDZ,
dDT,
dDTB,
dZZ,
dTt) << tPar->ToString();
LOG