pad->SetLeftMargin(0.15); pad->SetRightMargin(0.02);\r
pad->SetTopMargin(0.02); pad->SetBottomMargin(0.15);\r
pad->SetGridx(kFALSE); pad->SetGridy(kFALSE);\r
- hFeffP = TRDEfficiency(+1);\r
- hFeffN = TRDEfficiency(-1);\r
+ hFeffP = EfficiencyTRD(1);\r
+ hFeffN = EfficiencyTRD(-1);\r
h2F=new TH2F("rangeEffPt", "",10,0.,10.,10,0.,1.1);\r
h2F->SetStats(kFALSE);\r
h2F->GetXaxis()->SetTitle("p_{T} [GeV/c]");\r
return projHisto;\r
}\r
//____________________________________________________________________\r
-TH1F* AliTRDcheckESD::TRDEfficiency(Short_t positives) {\r
+TH1F* AliTRDcheckESD::EfficiencyTRD(Short_t positives) {\r
//\r
// Calculate the TRD-TPC matching efficiency as function of pt\r
//\r
class AliMCEvent;
class TH1;
class TH2;
+class TH1F;
+class TH2F;
+class TH3F;
class TH3;
class TObjArray;
class TGraph;
void Process2D(TH2 * const h, TGraphErrors **g);
void PrintStatus(ULong_t s);
TH2F* Proj3D(TH3F* hist, TH2F* accMap, Int_t binLow, Int_t binHigh, Float_t &entries);
- TH1F* TRDEfficiency(Short_t positives=+1);
+ TH1F* EfficiencyTRD(Short_t positives=1);
Int_t fStatus; // bit mask for controlling the task
Int_t fNRefFigures; // number of current ref plots
}
//________________________________________________________________________
-void AliTRDcheckPID::EvaluateEfficiency(TObjArray * const histoContainer, TObjArray *results, Int_t species, Float_t electronEfficiency){
+void AliTRDcheckPID::EvaluateEfficiency(const TObjArray * const histoContainer, TObjArray *results, Int_t species, Float_t electronEfficiency){
// Process PID information for pion efficiency
fUtil->SetElectronEfficiency(electronEfficiency);
static Char_t const* MethodName(Int_t id) { return fgMethod[id]; };
//TObjArray *GetHistos() { return fContainer; };
virtual TObjArray *Histos();
- void EvaluateEfficiency(TObjArray* const histoContainer, TObjArray *results, Int_t species, Float_t electronEfficiency);
+ void EvaluateEfficiency(const TObjArray* const histoContainer, TObjArray *results, Int_t species, Float_t electronEfficiency);
inline void SetMomentumBinning(Int_t nBins, Double_t *bins);
inline Int_t FindBin(Int_t species, Double_t momentum);
inline Bool_t IsInRange(Double_t momentum);
//_______________________________________________________
Bool_t AliTRDclusterResolution::PostProcess()
{
+// Steer processing of various cluster resolution dependences :
+//
+// - process resolution dependency cluster charge
+// if(HasProcess(kQRes)) ProcessCharge();
+// - process resolution dependency on y displacement
+// if(HasProcess(kCenter)) ProcessCenterPad();
+// - process resolution dependency on drift legth and drift cell width
+// if(HasProcess(kSigm)) ProcessSigma();
+// - process systematic shift on drift legth and drift cell width
+// if(HasProcess(kMean)) ProcessMean();
+
if(!fContainer) return kFALSE;
if(!IsCalibrated()){
AliWarning("Not calibrated.");
#ifndef ALITRDRECOTASK_H
#include "AliTRDrecoTask.h"
#endif
+#ifndef ALILOG_H
#include "AliLog.h"
+#endif
class TCanvas;
class TObjArray;
}
//_____________________________________________________________________________
-Int_t AliTRDefficiencyMC::IsRegistered(AliTRDtrackInfo * const trkInf, Int_t *indices, Int_t nTracks){
+Int_t AliTRDefficiencyMC::IsRegistered(const AliTRDtrackInfo * const trkInf, Int_t *indices, Int_t nTracks){
//
// Checks if track is registered in a given mode
//
void FillStreamTrackWOMC(AliTRDtrackInfo * const trkInf);
Int_t IsFindableNot(AliTRDtrackInfo * const trkInf);
- Int_t IsRegistered(AliTRDtrackInfo * const trkInf, Int_t *indices, Int_t nTracks);
+ Int_t IsRegistered(const AliTRDtrackInfo * const trkInf, Int_t *indices, Int_t nTracks);
static Float_t fgPCut; // lower momentum cut
static Float_t fgPhiCut; // higher phi cut
// set V0pid info
for(Int_t iv(0); iv<fV0List->GetEntriesFast(); iv++){
if(!(v0info = (AliTRDv0Info*)fV0List->At(iv))) continue;
- if(!v0info->fTrackP && !v0info->fTrackN) continue;
+ if(!v0info->GetV0Daughter(1) && !v0info->GetV0Daughter(-1)) continue;
if(!v0info->HasTrack(fTrackInfo)) continue;
memset(v0pid, 0, AliPID::kSPECIES*sizeof(Int_t));
fTrackInfo->SetV0();
#ifndef ALITRDRECOTASK_H
#include "AliTRDrecoTask.h"
#endif
-#ifndef ALIPID_H
-#include "AliPID.h"
-#endif
-#ifndef ALITRDCALPID_H
-#include "AliTRDCalPID.h"
-#endif
#ifndef ALITRDPIDUTIL_H
#include "AliTRDpidUtil.h"
#endif
-#ifndef ALITRDGEOMETRY_H
-#include "AliTRDgeometry.h"
-#endif
class TTree;
class TObjArray;
//________________________________________________________________________
Bool_t AliTRDpidRefMakerLQ::Load(const Char_t *file, const Char_t *dir)
{
+// Load tree with data in case of detached PostProcess processing.
+
if(gSystem->AccessPathName(file, kReadPermission)){
AliError(Form("File %s not readable", file));
return kFALSE;
// //
///////////////////////////////////////////////////////////////////////////////
-#ifndef ALIPID_H
-#include "AliPID.h"
-#endif
-
#ifndef ALITRDPIDREFMAKER_H
#include "AliTRDpidRefMaker.h"
#endif
-#ifndef ALITRDPIDUTIL_H
-#include "AliTRDpidUtil.h"
-#endif
+// #ifndef ALITRDPIDUTIL_H
+// #include "AliTRDpidUtil.h"
+// #endif
+// #ifndef ALIPID_H
+// #include "AliPID.h"
+// #endif
class TKDNodeInfo;
class TKDInterpolator;
//________________________________________________________________________
Bool_t AliTRDpidRefMakerNN::MakeTrainingSample()
{
-
+ // convert AnalysisResults.root to training file
TFile *fCalib = TFile::Open(Form("AnalysisResults.root"));
if (!fCalib) {
AliError("Calibration file not available");
for(Int_t iEvent = 0; iEvent < fTrain[mombin] -> GetN(); iEvent++ ){
fTrainData[mombin] -> GetEntry(fTrain[mombin] -> GetEntry(iEvent));
// use event only if it is electron or pion
- if(!(fPID[is] == 1.0)) continue;
+ if(fPID[is] <1.e-5) continue;
// get the probabilities for each particle type in each chamber
for(Int_t iPart = 0; iPart < AliPID::kSPECIES; iPart++){
like[iPart][iChamb] = fNet -> Result(fTrain[mombin] -> GetEntry(iEvent), iPart);
for(Int_t iEvent = 0; iEvent < fTest[mombin] -> GetN(); iEvent++ ){
fTrainData[mombin] -> GetEntry(fTest[mombin] -> GetEntry(iEvent));
// use event only if it is electron or pion
- if(!(fPID[is] == 1.0)) continue;
+ if(TMath::Abs(fPID[is]- 1.)<1.e-5) continue;
// get the probabilities for each particle type in each chamber
for(Int_t iPart = 0; iPart < AliPID::kSPECIES; iPart++){
#ifndef ALITRDPIDREFMAKER_H
#include "AliTRDpidRefMaker.h"
#endif
+#ifndef ALITRDCALPID_H
+#include "Cal/AliTRDCalPID.h"
+#endif
class TEventList;
class TMultiLayerPerceptron;
Bool_t fContinueTraining; // checks if training from an older run should be continued
Int_t fTrainPath; // sets the path for continuing the training
- Float_t fScale;
+ Float_t fScale; // scaling factor
Int_t fLy; // TRD layer
Int_t fNtrkl; // No. tracklets
- TTree *fTrainData[AliTRDCalPID::kNMom];
- TFile *fRef;
+ TTree *fTrainData[AliTRDCalPID::kNMom];//Tree for reference data for all momentum bins
+ TFile *fRef; //file containing reference data
- ClassDef(AliTRDpidRefMakerNN, 3); // TRD reference maker for NN
+ ClassDef(AliTRDpidRefMakerNN, 3); // TRD reference maker for NN
};
#endif
}
//_______________________________________________________
-void AliTRDrecoTask::MakeSummary(){
+void AliTRDrecoTask::MakeSummary()
+{
// To be implemented by particular tasks
AliWarning("Summary not available");
}
// Authors:
// Markus Heide <mheide@uni-muenster.de>
//////////////////////////////////////////////////////
-
-//#include "TPDGCode.h"
-/*#include "TFile.h"
-#include "TTree.h"
-#include "TEventList.h"*/
+
#include "TObjArray.h"
#include "TH2.h"
#include "TH2F.h"
#include "TH1I.h"
#include "TCanvas.h"
-// #include "TPad.h"
-// #include "TLegend.h"
#include "AliLog.h"
#include "AliESDtrack.h"
//____________________________________________________________________
-void AliTRDv0Monitor::MakeSummary(){
- TCanvas *cOut = new TCanvas("v0MonitorSummary1", "Summary 1 for task V0Monitor", 1024, 768);
- cOut->cd();
+void AliTRDv0Monitor::MakeSummary(){//makes a summary with potentially nice reference figures
+ //TCanvas *cOut = new TCanvas("v0MonitorSummary1", "Summary 1 for task V0Monitor", 1024, 768);
+ //cOut->cd();
//GetRefFigure(4);
- cOut->SaveAs("V0MonitorSummary.gif");
+ //cOut->SaveAs("V0MonitorSummary.gif");
- cOut = new TCanvas("v0MonitorSummary2","Summary 2 for task V0Monitor", 1024, 768);
- cOut->cd();
+ //cOut = new TCanvas("v0MonitorSummary2","Summary 2 for task V0Monitor", 1024, 768);
+ //cOut->cd();
//GetRefFigure(5);
- cOut->SaveAs("V0MonitorSummary2.gif");
+ //cOut->SaveAs("V0MonitorSummary2.gif");
}
//________________________________________________________________________
Bool_t AliTRDv0Monitor::GetRefFigure(Int_t /*ifig*/)
{
+ //creating reference figures
AliInfo("Implementation on going ...");
return kTRUE;
{
// Create histograms
// Called once
-
if(fContainer) return fContainer;
fContainer = new TObjArray(kNPlots);
{
// Main loop
// Called for each event
-
if(!(fTracks = dynamic_cast<TObjArray*>(GetInputData(1)))) return;
if(!(fV0s = dynamic_cast<TObjArray*>(GetInputData(2)))) return;
if(!(fInfo = dynamic_cast<TObjArray*>(GetInputData(3)))) return;
AliTRDtrackInfo *track = NULL;
AliTRDv0Info *v0(NULL);
-
-
for(Int_t itrk=0; itrk<fTracks->GetEntriesFast(); itrk++){
track = (AliTRDtrackInfo*)fTracks->UncheckedAt(itrk);
for(Int_t iv(0); iv<fV0s->GetEntriesFast(); iv++){
ULong_t status = track->GetStatus();
if(!(status&AliESDtrack::kTRDpid)) continue;
- fhQualityReductions->Fill(v0->fQuality);//fills integer codes for tracks cut out by track/V0 quality cuts
+ fhQualityReductions->Fill(v0->GetQuality());//fills integer codes for tracks cut out by track/V0 quality cuts
- if(!(v0->fQuality == 1)) continue;
+ if(!(v0->GetQuality() == 1)) continue;
for(Int_t part = 0; part < AliPID::kSPECIES; part++){
fhCutReductions[part]->Fill(v0->GetPID(part,track));//fill in numbers of tracks eliminated by different PID cuts
}
//fill histograms with track/V0 quality cuts only
- fhPsiPair[idecay][0]->Fill(v0->fV0Momentum,v0->fPsiPair);//Angle between daughter momentum plane and plane perpendicular to magnetic field
- fhInvMass[idecay]->Fill(v0->fV0Momentum,v0->fInvMass[idecay]);//Invariant mass
- fhPointAngle[idecay][0]->Fill(v0->fV0Momentum,v0->fPointingAngle);// = TMath::ACos(esdv0->GetV0CosineOfPointingAngle()); // Cosine of pointing angle
- fhOpenAngle[idecay][0]->Fill(v0->fV0Momentum,v0->fOpenAngle);// opening angle between daughters
- fhDCA[idecay][0]->Fill(v0->fV0Momentum,v0->fDCA);// Distance of closest approach of daughter tracks
- fhV0Chi2ndf[idecay][0]->Fill(v0->fV0Momentum,v0->fChi2ndf[idecay]);//Kalman Filter Chi2/NDF
- fhRadius[idecay][0]->Fill(v0->fV0Momentum,v0->fRadius);//distance of decay/conversion from primary vertex in x-y plane
+ fhPsiPair[idecay][0]->Fill(v0->GetV0Momentum(),v0->GetPsiPair());//Angle between daughter momentum plane and plane perpendicular to magnetic field
+ fhInvMass[idecay]->Fill(v0->GetV0Momentum(),v0->GetInvMass(idecay));//Invariant mass
+ fhPointAngle[idecay][0]->Fill(v0->GetV0Momentum(),v0->GetPointingAngle());// = TMath::ACos(esdv0->GetV0CosineOfPointingAngle()); // Cosine of pointing angle
+ fhOpenAngle[idecay][0]->Fill(v0->GetV0Momentum(),v0->GetOpenAngle());// opening angle between daughters
+ fhDCA[idecay][0]->Fill(v0->GetV0Momentum(),v0->GetDCA());// Distance of closest approach of daughter tracks
+ fhV0Chi2ndf[idecay][0]->Fill(v0->GetV0Momentum(),v0->GetChi2ndf(idecay));//Kalman Filter Chi2/NDF
+ fhRadius[idecay][0]->Fill(v0->GetV0Momentum(),v0->GetRadius());//distance of decay/conversion from primary vertex in x-y plane
if(v0->HasTrack(track) == -1){
- fhTPCdEdx[part][0]->Fill(v0->fTrackN->P(),v0->fTPCdEdx[AliTRDv0Info::kNeg]);//TPC dE/dx for negative track
+ fhTPCdEdx[part][0]->Fill(v0->GetV0Daughter(-1)->P(),v0->GetTPCdEdx(AliTRDv0Info::kNeg));//TPC dE/dx for negative track
} else if(v0->HasTrack(track) == 1){
- fhTPCdEdx[part][0]->Fill(v0->fTrackP->P(),v0->fTPCdEdx[AliTRDv0Info::kPos]);//TPC dE/dx for positive track
+ fhTPCdEdx[part][0]->Fill(v0->GetV0Daughter(1)->P(),v0->GetTPCdEdx(AliTRDv0Info::kPos));//TPC dE/dx for positive track
}
//fill histograms after invariant mass cuts
- if((v0->fInvMass[idecay] < v0->fUpInvMass[idecay][0])&&(v0->fInvMass[idecay]> v0->fDownInvMass[idecay])){
- fhV0Chi2ndf[idecay][1]->Fill(v0->fV0Momentum,v0->fChi2ndf[idecay]);
- fhPsiPair[idecay][1]->Fill(v0->fV0Momentum,v0->fPsiPair);
- fhPointAngle[idecay][1]->Fill(v0->fV0Momentum,v0->fPointingAngle);
- fhOpenAngle[idecay][1]->Fill(v0->fV0Momentum,v0->fOpenAngle);
- fhDCA[idecay][1]->Fill(v0->fV0Momentum,v0->fDCA);
- fhRadius[idecay][1]->Fill(v0->fV0Momentum,v0->fRadius);
+ if((v0->GetInvMass(idecay) < v0->GetUpInvMass(idecay,0))&&(v0->GetInvMass(idecay)> v0->GetDownInvMass(idecay))){
+ fhV0Chi2ndf[idecay][1]->Fill(v0->GetV0Momentum(),v0->GetChi2ndf(idecay));
+ fhPsiPair[idecay][1]->Fill(v0->GetV0Momentum(),v0->GetPsiPair());
+ fhPointAngle[idecay][1]->Fill(v0->GetV0Momentum(),v0->GetPointingAngle());
+ fhOpenAngle[idecay][1]->Fill(v0->GetV0Momentum(),v0->GetOpenAngle());
+ fhDCA[idecay][1]->Fill(v0->GetV0Momentum(),v0->GetDCA());
+ fhRadius[idecay][1]->Fill(v0->GetV0Momentum(),v0->GetRadius());
if(v0->HasTrack(track) == -1)
- fhTPCdEdx[part][1]->Fill(v0->fTrackN->P(),v0->fTPCdEdx[AliTRDv0Info::kNeg]);
+ fhTPCdEdx[part][1]->Fill(v0->GetV0Daughter(-1)->P(),v0->GetTPCdEdx(AliTRDv0Info::kNeg));
else if(v0->HasTrack(track) == 1)
- fhTPCdEdx[part][1]->Fill(v0->fTrackP->P(),v0->fTPCdEdx[AliTRDv0Info::kPos]);
+ fhTPCdEdx[part][1]->Fill(v0->GetV0Daughter(1)->P(),v0->GetTPCdEdx(AliTRDv0Info::kPos));
}
//fill histograms after all reference selection cuts
if(v0->GetPID(part,track)==1){
- fhV0Chi2ndf[idecay][2]->Fill(v0->fV0Momentum,v0->fChi2ndf[idecay]);
- fhPsiPair[idecay][2]->Fill(v0->fV0Momentum,v0->fPsiPair);
- fhPointAngle[idecay][2]->Fill(v0->fV0Momentum,v0->fPointingAngle);
- fhOpenAngle[idecay][2]->Fill(v0->fV0Momentum,v0->fOpenAngle);
- fhDCA[idecay][2]->Fill(v0->fV0Momentum,v0->fDCA);
- fhRadius[idecay][2]->Fill(v0->fV0Momentum,v0->fRadius);
+ fhV0Chi2ndf[idecay][2]->Fill(v0->GetV0Momentum(),v0->GetChi2ndf(idecay));
+ fhPsiPair[idecay][2]->Fill(v0->GetV0Momentum(),v0->GetPsiPair());
+ fhPointAngle[idecay][2]->Fill(v0->GetV0Momentum(),v0->GetPointingAngle());
+ fhOpenAngle[idecay][2]->Fill(v0->GetV0Momentum(),v0->GetOpenAngle());
+ fhDCA[idecay][2]->Fill(v0->GetV0Momentum(),v0->GetDCA());
+ fhRadius[idecay][2]->Fill(v0->GetV0Momentum(),v0->GetRadius());
if(v0->HasTrack(track) == -1)
- fhTPCdEdx[part][2]->Fill(v0->fTrackN->P(),v0->fTPCdEdx[AliTRDv0Info::kNeg]);
+ fhTPCdEdx[part][2]->Fill(v0->GetV0Daughter(-1)->P(),v0->GetTPCdEdx(AliTRDv0Info::kNeg));
else if(v0->HasTrack(track) == 1)
- fhTPCdEdx[part][2]->Fill(v0->fTrackP->P(),v0->fTPCdEdx[AliTRDv0Info::kPos]);
+ fhTPCdEdx[part][2]->Fill(v0->GetV0Daughter(1)->P(),v0->GetTPCdEdx(AliTRDv0Info::kPos));
}
}
}
,fMagField(0)
,fRadius(0)
,fV0Momentum(0)
- ,fTrackP(NULL)
- ,fTrackN(NULL)
,fNindex(0)
,fPindex(0)
,fInputEvent(NULL)
,fPrimaryVertex(NULL)
+ ,fTrackP(NULL)
+ ,fTrackN(NULL)
{
//
// Default constructor
//
- memset(fPplus, 0, 2*kNlayer*sizeof(Float_t));
- memset(fPminus, 0, 2*kNlayer*sizeof(Float_t));
memset(fDetPID, 0, 2*kNDaughters*kNDetectors*AliPID::kSPECIES*sizeof(Float_t));
memset(fComPID, 0, 2*kNDaughters*AliPID::kSPECIES*sizeof(Float_t));
memset(fInvMass, 0, kNDecays*sizeof(Double_t));
,fMagField(ref.fMagField)
,fRadius(ref.fRadius)
,fV0Momentum(ref.fV0Momentum)
- ,fTrackP(ref.fTrackP)
- ,fTrackN(ref.fTrackN)
,fNindex(ref.fNindex)
,fPindex(ref.fPindex)
,fInputEvent(ref.fInputEvent)
,fPrimaryVertex(ref.fPrimaryVertex)
+ ,fTrackP(ref.fTrackP)
+ ,fTrackN(ref.fTrackN)
{
//
// Copy constructor
//
-
- memcpy(fPplus, ref.fPplus, 2*kNlayer*sizeof(Float_t));
- memcpy(fPminus, ref.fPminus, 2*kNlayer*sizeof(Float_t));
+
memcpy(fDetPID, ref.fDetPID, 2*kNDaughters*kNDetectors*AliPID::kSPECIES*sizeof(Float_t));
memcpy(fComPID, ref.fComPID, 2*kNDaughters*AliPID::kSPECIES*sizeof(Float_t));
memcpy(fInvMass, ref.fInvMass, kNDecays*sizeof(Double_t));
//_________________________________________________
void AliTRDv0Info::SetV0Info(AliESDv0 *esdv0)
-{//Gets values of ESDv0 and daughter track properties
+{
+ //Gets values of ESDv0 and daughter track properties
//See header file for description of variables
fQuality = Quality(esdv0);//Attributes an Int_t to the V0 due to quality cuts (= 1 if V0 is accepted, other integers depending on cut which excludes the vertex)
}
//_________________________________________________
Float_t AliTRDv0Info::OpenAngle(AliESDv0 *esdv0)
-{//Opening angle between two daughter tracks
+{
+ //Opening angle between two daughter tracks
Double_t mn[3] = {0,0,0};
Double_t mp[3] = {0,0,0};
//_________________________________________________
Float_t AliTRDv0Info::PsiPair(AliESDv0 *esdv0)
-{//Angle between daughter momentum plane and plane perpendicular to magnetic field
+{
+ //Angle between daughter momentum plane and plane perpendicular to magnetic field
Double_t x, y, z;
esdv0->GetXYZ(x,y,z);//Reconstructed coordinates of V0; to be replaced by Markus Rammler's method in case of conversions!
return chi2ndf;
}
//________________________________________________________________
-AliKFParticle *AliTRDv0Info::CreateMotherParticle(AliESDtrack *pdaughter, AliESDtrack *ndaughter, Int_t pspec, Int_t nspec){
+AliKFParticle *AliTRDv0Info::CreateMotherParticle(const AliESDtrack *pdaughter, const AliESDtrack *ndaughter, Int_t pspec, Int_t nspec){
//
// Creates a mother particle
//
return m;
}
//_________________________________________________
-Int_t AliTRDv0Info::HasTrack(AliTRDtrackInfo * const track)
+Int_t AliTRDv0Info::HasTrack(const AliTRDtrackInfo * const track) const
{
-//Checks if track is a secondary vertex daughter (due to V0 finder)
+ //Checks if track is a secondary vertex daughter (due to V0 finder)
if(!track) return 0;
if(!fTrackP->GetID()) return 0;
}
//_________________________________________________
-Int_t AliTRDv0Info::HasTrack(Int_t trackID)
+Int_t AliTRDv0Info::HasTrack(Int_t trackID) const
{
//comparing index of track with indices of pos./neg. V0 daughter :
if(fNindex==trackID) return -1;
//_________________________________________________
void AliTRDv0Info::GetDetectorPID()
-{//PID likelihoods from TPC, TOF, and ITS, for all particle species
+{
+ //PID likelihoods from TPC, TOF, and ITS, for all particle species
fTrackN->GetTPCpid(fDetPID[kNeg][kTPC]);
fTrackP->GetTPCpid(fDetPID[kPos][kTPC]);
//____________________________________________________________________________________
void AliTRDv0Info::CombinePID()
{
+ //combined bayesian PID from TPC and TOF
Double_t partrat[AliPID::kSPECIES] = {0.208, 0.010, 0.662, 0.019, 0.101};
for(Int_t iSign = 0; iSign < kNDaughters; iSign++)
//_________________________________________________
Bool_t AliTRDv0Info::GetTPCdEdx()
{
+ //gets the TPC dE/dx for both daughter tracks
if(!fTrackP->GetID()) return 0;
if(!fTrackN->GetID()) return 0;
//_________________________________________________
Bool_t AliTRDv0Info::TPCdEdxCuts(Int_t part, AliTRDtrackInfo * const track)
{
+ //applies cuts on TPC dE/dx according to particle species; cutting lines are drawn shifted to the Bethe-Bloch paremeterization
if(!fTrackP->GetID()) return 0;
if(!fTrackN->GetID()) return 0;
}
//_________________________________________________
Float_t AliTRDv0Info::Radius(AliESDv0 *esdv0)
-{//distance from secondary vertex to primary vertex in x-y plane
+{
+ //distance from secondary vertex to primary vertex in x-y plane
Double_t x, y, z;
esdv0->GetXYZ(x,y,z); //Reconstructed coordinates of V0
fRadius = TMath::Sqrt(x*x + y*y);
ap[0] = alfa;
ap[1] = qt;
- Double_t LcutAP[2];//Lambda/Anti-Lambda cuts
+ Double_t lCutAP[2];//Lambda/Anti-Lambda cuts
if(decay == 0){
// armenteros cuts
const Double_t cutAlpha[2] = {0.35, 0.45}; // [0.35, 0.45]
else if(decay == 2){
const Double_t cutQT = 0.03;
const Double_t cutAlpha = 0.7; // VERY strong - should supress the overlap with K0
- LcutAP[0] = 1.0 - (ap[0]-0.7 * ap[0]-0.7)*1.1 - 0.87;
+ lCutAP[0] = 1.0 - (ap[0]-0.7 * ap[0]-0.7)*1.1 - 0.87;
if(TMath::Abs(ap[0]) > cutAlpha) return kFALSE;
if(ap[1] < cutQT) return kFALSE;
- if(ap[1] > LcutAP[0]) return kFALSE;
+ if(ap[1] > lCutAP[0]) return kFALSE;
}
else if(decay == 3){
const Double_t cutQT = 0.03;
const Double_t cutAlpha = 0.7; // VERY strong - should supress the overlap with K0
- LcutAP[1] = 1.0 - (ap[0]+0.7 * ap[0]+0.7)*1.1 - 0.87;
+ lCutAP[1] = 1.0 - (ap[0]+0.7 * ap[0]+0.7)*1.1 - 0.87;
if(TMath::Abs(ap[0]) > cutAlpha) return kFALSE;
if(ap[1] < cutQT) return kFALSE;
- if(ap[1] > LcutAP[1]) return kFALSE;
+ if(ap[1] > lCutAP[1]) return kFALSE;
}
return kTRUE;
}
//_________________________________________________
void AliTRDv0Info::Print(Option_t *opt) const
{
+ //prints text for debugging etc.
printf("V0 P[%d] N[%d]\n", fPindex, fNindex);
printf(" DCA[%5.3f] Radius[%5.3f]\n", fDCA, fRadius);
printf(" Angles : Pointing[%5.3f] Open[%5.3f] Psi[%5.3f]\n", fPointingAngle, fOpenAngle, fPsiPair);
//_________________________________________________
void AliTRDv0Info::SetV0tracks(AliESDtrack *p, AliESDtrack *n)
{
+ //sets the two daughter trex and their indices
fTrackP = p; fPindex = p->GetID();
fTrackN = n; fNindex = n->GetID();
}
+//_________________________________________________
+AliESDtrack *AliTRDv0Info::GetV0Daughter(Int_t sign)
+{
+ //Gets positive of negative daughter of decay
+ if(sign>0)
+ return fTrackP;
+ else if(sign < 0)
+ return fTrackN;
+ return 0;
+}
AliTRDv0Info(const AliTRDv0Info &ref);
virtual ~AliTRDv0Info(){}
- Int_t GetPID(Int_t ipart, AliTRDtrackInfo *track);
- Int_t HasTrack(AliTRDtrackInfo * const track);
- Int_t HasTrack(Int_t ti);
+ Int_t GetQuality(){return fQuality;}
+ Float_t GetDCA(){return fDCA;}
+ Float_t GetPointingAngle(){return fPointingAngle;}
+ Float_t GetOpenAngle(){return fOpenAngle;}
+ Float_t GetPsiPair(){return fPsiPair;}
+ Float_t GetRadius(){return fRadius;}
+ Float_t GetV0Momentum(){return fV0Momentum;}
+ Double_t GetInvMass(Int_t iDecay){return fInvMass[iDecay];}
+ Float_t GetDetPID(Int_t iDaughter, Int_t iDetector, Int_t iSpecies){return fDetPID[iDaughter][iDetector][iSpecies];}
+ Float_t GetComPID(Int_t iDaughter, Int_t iSpecies){return fComPID[iDaughter][iSpecies];}
+ Float_t GetTPCdEdx(Int_t iDaughter){return fTPCdEdx[iDaughter];}
+ Float_t GetChi2ndf(Int_t decay){return fChi2ndf[decay];}
+
+ //Get Cut values:
+
+ Float_t GetUpDCA(Int_t iDecay){return fUpDCA[iDecay];}
+ Float_t GetUpPointingAngle(Int_t iDecay){return fUpPointingAngle[iDecay];}
+ Float_t GetUpOpenAngle(Int_t iDecay){return fUpOpenAngle[iDecay];}
+ Float_t GetDownOpenAngle(Int_t iDecay){return fDownOpenAngle[iDecay];}
+ Float_t GetUpPsiPair(Int_t iDecay){return fUpPsiPair[iDecay];}
+ Float_t GetDownPsiPair(Int_t iDecay){return fDownPsiPair[iDecay];}
+ Float_t GetUpRadius(Int_t iDecay){return fUpRadius[iDecay];}
+ Float_t GetDownRadius(Int_t iDecay){return fDownRadius[iDecay];}
+ Double_t GetUpInvMass(Int_t iDecay, Int_t iMomentum){return fUpInvMass[iDecay][iMomentum];}
+ Double_t GetDownInvMass(Int_t iDecay){return fDownInvMass[iDecay];}
+ Float_t GetDownTPCPIDneg(Int_t iPart){return fDownTPCPIDneg[iPart];}
+ Float_t GetDownTPCPIDpos(Int_t iPart){return fDownTPCPIDpos[iPart];}
+ Float_t GetDownComPIDneg(Int_t iPart){return fDownComPIDneg[iPart];}
+ Float_t GetDownComPIDpos(Int_t iPart){return fDownComPIDpos[iPart];}
+ Float_t GetDownComPIDnegPart(Int_t iPart){return fDownComPIDnegPart[iPart];}
+ Float_t GetDownComPIDposPart(Int_t iPart){return fDownComPIDposPart[iPart];}
+
+
+ Int_t GetPID(Int_t ipart, AliTRDtrackInfo *track);
+ Int_t HasTrack(const AliTRDtrackInfo * const track) const;
+ Int_t HasTrack(Int_t ti) const;
+ AliESDtrack *GetV0Daughter(Int_t sign); //Get positive of negative daughter of decay
+
void Print(Option_t *opt="") const;
-
+
void SetMagField(Float_t b) {fMagField = b;}
void SetV0tracks(AliESDtrack *p, AliESDtrack *n);
void SetInputEvent(AliVEvent *e) { fInputEvent = e; };
void SetPrimaryVertex(AliKFVertex *v) { fPrimaryVertex = v; };
-
+
//Set values of measured/calculated variables:
void SetQuality(Int_t SQuality){fQuality = SQuality;}
- void SetPplus(Int_t iLayer, Float_t SPplus){fPplus[iLayer] = SPplus;}
- void SetPminus(Int_t iLayer, Float_t SPminus){fPminus[iLayer] = SPminus;}
void SetDCA(Float_t SDCA){fDCA = SDCA;}
void SetPointingAngle(Float_t SPointingAngle){fPointingAngle = SPointingAngle;}
void SetOpenAngle(Float_t SOpenAngle){fOpenAngle = SOpenAngle;}
void SetDetPID(Int_t iDaughter, Int_t iDetector, Int_t iSpecies, Float_t SDetPID){fDetPID[iDaughter][iDetector][iSpecies] = SDetPID;}
void SetComPID(Int_t iDaughter, Int_t iSpecies, Float_t SComPID){fComPID[iDaughter][iSpecies] = SComPID;}
void SetTPCdEdx(Int_t iDaughter, Float_t STpcdEdx){fTPCdEdx[iDaughter] = STpcdEdx;}
+ void SetV0Momentum(Float_t SV0Momentum){fV0Momentum = SV0Momentum;}
+ void SetChi2ndf(Int_t decay, Float_t SChi2ndf){fChi2ndf[decay]=SChi2ndf;}
//____________________________________________________________
//Set cut values:
void SetDownComPIDpos(Int_t iPart, Double_t DownComPIDpos){fDownComPIDpos[iPart] = DownComPIDpos;}
void SetDownComPIDnegPart(Int_t iPart, Double_t DownComPIDnegPart){fDownComPIDnegPart[iPart] = DownComPIDnegPart;}
void SetDownComPIDposPart(Int_t iPart, Double_t DownComPIDposPart){fDownComPIDposPart[iPart] = DownComPIDposPart;}
-
+
+
void SetV0Info(AliESDv0 *v0);//gets most of the variables below
- Double_t fChi2ndf[kNDecays];//Chi2/NDF from KF
- Double_t fInvMass[kNDecays]; // invariant mass for different decay scenarios (conversions, K0s, Lambda->p+pi-, Lambda->p-pi+)
- Int_t fQuality; // track quality status for both V0 daughters; OnFly, TPCrefit, Kinks, TPC clusters
-
- Double_t fDetPID[kNDaughters][kNDetectors][AliPID::kSPECIES]; // PID provided by TPC, TOF and ITS
- Double_t fComPID[kNDaughters][AliPID::kSPECIES];//Combined PID, momentarily from TPC and TOF only
-
- Float_t fDCA; // Distance of closest approach of daughter tracks
- Float_t fPointingAngle;// = TMath::ACos(esdv0->GetV0CosineOfPointingAngle()); // Cosine of pointing angle
- Float_t fOpenAngle; // opening angle between daughters
- Float_t fPsiPair; // /Angle between daughter momentum plane and plane perpendicular to magnetic field
-
- Bool_t fArmenteros[kNDecays];// Array for the Armenteros yes/no decision for all decays
- Double_t fMagField; //magnetic field strength
- Float_t fRadius; //distance of decay/conversion from primary vertex in x-y plane
- Float_t fV0Momentum; //V0 mother's momentum
- Float_t fTPCdEdx[kNDaughters]; //Energy deposition in the TPC
-
- Double_t fUpInvMass[kNDecays][kNMomBins]; // invariant mass, upper limit
- Double_t fDownInvMass[kNDecays]; // invariant mass, lower limit
-
- AliESDtrack *fTrackP; //!positive daughter
- AliESDtrack *fTrackN; //!negative daughter
-
private:
AliTRDv0Info& operator=(const AliTRDv0Info&);
Bool_t V0SignCheck();//checks if daughters have opposite signs
Bool_t Armenteros(AliESDv0 *esdv0, Int_t species);//the famous Armenteros-Polanski cut
Double_t KFChi2ndf(Int_t part1, Int_t part2,Int_t decay);//Chi2ndf from KF
- AliKFParticle *CreateMotherParticle(AliESDtrack *pdaughter, AliESDtrack *ndaughter, Int_t pspec, Int_t nspec);//Mother Particle from KF
-
- Float_t fPplus[2*kNlayer]; // momentum and variance for the positive daughter
- Float_t fPminus[2*kNlayer]; // momentum and variance for the negative daughter
+ AliKFParticle *CreateMotherParticle(const AliESDtrack *pdaughter, const AliESDtrack *ndaughter, Int_t pspec, Int_t nspec);//Mother Particle from KF
//____________________________________________________________
Float_t fUpPsiPair[kNDecays]; // psi angle, upper limit
Float_t fDownPsiPair[kNDecays]; // psi angle, lower limit
- Double_t fUpChi2ndf[kNDecays];
+ Double_t fUpChi2ndf[kNDecays]; // upper Chi2/NDF limit
Float_t fUpRadius[kNDecays]; // radius, upper limit
Float_t fDownRadius[kNDecays]; // radius, lower limit
Float_t fDownTPCPIDneg[AliPID::kSPECIES]; // TPC PID negatives, lower limit
Float_t fDownComPIDpos[AliPID::kSPECIES]; // Combined PID positives, lower limit
Float_t fDownComPIDnegPart[AliPID::kSPECIES]; // Combined PID positive partner daughters (NOT the daughter track that would go into the reference data; here: pion daughters from Lambda decays; lower limit
Float_t fDownComPIDposPart[AliPID::kSPECIES]; // Combined PID positive partner daughters (NOT the daughter track that would go into the reference data; here: pion daughters from Lambda decays; lower limit
+ Double_t fUpInvMass[kNDecays][kNMomBins]; // invariant mass, upper limit
+ Double_t fDownInvMass[kNDecays]; // invariant mass, lower limit
+
+
+ Double_t fChi2ndf[kNDecays];//Chi2/NDF from KF
+
+
+ Double_t fInvMass[kNDecays]; // invariant mass for different decay scenarios (conversions, K0s, Lambda->p+pi-, Lambda->p-pi+)
+ Int_t fQuality; // track quality status for both V0 daughters; OnFly, TPCrefit, Kinks, TPC clusters
+
+ Double_t fDetPID[kNDaughters][kNDetectors][AliPID::kSPECIES]; // PID provided by TPC, TOF and ITS
+ Double_t fComPID[kNDaughters][AliPID::kSPECIES];//Combined PID, momentarily from TPC and TOF only
+ Float_t fDCA; // Distance of closest approach of daughter tracks
+ Float_t fPointingAngle;// = TMath::ACos(esdv0->GetV0CosineOfPointingAngle()); // Cosine of pointing angle
+ Float_t fOpenAngle; // opening angle between daughters
+ Float_t fPsiPair; // /Angle between daughter momentum plane and plane perpendicular to magnetic field
+
+ Bool_t fArmenteros[kNDecays];// Array for the Armenteros yes/no decision for all decays
+ Double_t fMagField; //magnetic field strength
+ Float_t fRadius; //distance of decay/conversion from primary vertex in x-y plane
+ Float_t fV0Momentum; //V0 mother's momentum
Int_t fNindex; //indices of positive and negative daughter track
Int_t fPindex; //indices of positive and negative daughter track
+ Float_t fTPCdEdx[kNDaughters]; //Energy deposition in the TPC
+
+
AliVEvent *fInputEvent; // Input Event
AliKFVertex *fPrimaryVertex; // primary vertex
+ AliESDtrack *fTrackP; //!positive daughter
+ AliESDtrack *fTrackN; //!negative daughter
+
+
ClassDef(AliTRDv0Info, 1) // extracted V0 MC information
};
-#include "AliTRDpwg1Helper.h"
-void mergeResults(Char_t *files, Char_t *file="QAresults.root"){
+void mergeResults(Char_t *files, Char_t *file="QAresults.root")
+{
+ gSystem->Load("libANALYSIS.so");
+ gSystem->Load("libANALYSISalice.so");
+ gSystem->Load("libTENDER.so");
+ gSystem->Load("libPWG1.so");
+
AliTRDpwg1Helper::MergeProd(file, files, 10);
}
\ No newline at end of file