13 #include <AliESDInputHandlerRP.h> 57 fOptions.
Add(
"trig",
"NAME",
"Trigger to use",
"V0AND");
58 fOptions.
Add(
"cent",
"METHOD",
"Centrality selector",
"V0M");
59 fOptions.
Add(
"cent-bins",
"BINS",
"Centrality bins", defCent);
60 fOptions.
Add(
"eta-bins",
"BINS",
"Eta bins",
"r16:-2:+2");
61 fOptions.
Add(
"ipz-bins",
"BINS",
"IPz bins",
"u15");
62 fOptions.
Add(
"max-delta",
"X",
"Cut on weighted distance",25.);
63 fOptions.
Add(
"tail-delta",
"X",
"Tail cut on distance", 5.);
64 fOptions.
Add(
"tail-max",
"X",
"Tail cut on distance", -1.);
65 fOptions.
Add(
"delta-cut",
"X",
"Cut on weighted distance",1.5);
66 fOptions.
Add(
"dphi-shift",
"RADIANS",
"Bending shift", 0.0045);
67 fOptions.
Add(
"shifted-dphi-cut",
"RADIANS",
"Cut on dPhi-phiBent", -1.);
69 fOptions.
Add(
"multsel",
"Enable MultSelection",
false);
70 fOptions.
Add(
"abs-min-cent",
"PERCENT",
"Absolute least cent.", -1);
71 fOptions.
Add(
"max-ntracklet",
"N",
"For FAKE centrality", 6000);
72 fOptions.
Add(
"reweigh",
"FILE",
"File with weights",
"");
73 fOptions.
Add(
"reweigh-calc",
"MODE",
"prod,square,sum",
"prod");
74 fOptions.
Add(
"reweigh-mask",
"MASK",
"Tracklet mask for weighing", 0xFF);
75 fOptions.
Add(
"reweigh-veto",
"VETO",
"Tracklet veto for weighing", 0x0);
87 return "0-5-10-20-30-40-50-60-70-80-90";
118 Info(
"CreateTasks",
"Loading code");
130 gROOT->ProcessLine(Form(
"AliTrackletAODdNdeta::Create(%d,\"%s\")",mc,
137 UInt_t sel = AliVEvent::kINT7;
138 if (trg.EqualTo(
"MB")) sel = AliVEvent::kMB;
139 else if (trg.EqualTo(
"V0AND")) sel = AliVEvent::kINT7;
140 else if (trg.EqualTo(
"V0OR")) sel = AliVEvent::kCINT5;
141 else if (trg.EqualTo(
"ANY")) sel = AliVEvent::kAny;
142 task->SelectCollisionCandidates(sel);
147 if (calc.BeginsWith(
"PROD")) mcal = 0;
148 else if (calc.BeginsWith(
"SQ")) mcal = 1;
149 else if (calc.BeginsWith(
"SUM")) mcal = 2;
150 else if (calc.BeginsWith(
"AV")) mcal = 3;
154 FromOption(task,
"CentralityMethod",
"cent",
"V0M");
155 FromOption(task,
"CentralityAxis",
"cent-bins", defCent);
156 FromOption(task,
"AbsMinCent",
"abs-min-cent", -1.);
157 FromOption(task,
"MaxNTracklet",
"max-ntracklet", 6000.);
158 FromOption(task,
"EtaAxis",
"eta-bins",
"r16:2");
159 FromOption(task,
"IPzAxis",
"ipz-bins",
"u15");
160 FromOption(task,
"DeltaCut",
"delta-cut", 1.5);
161 FromOption(task,
"TailDelta",
"tail-delta", 5.);
162 FromOption(task,
"TailMaximum",
"tail-max", -1);
163 FromOption(task,
"MaxDelta",
"max-delta", 25.);
164 FromOption(task,
"DPhiShift",
"dphi-shift", 0.0045);
165 FromOption(task,
"ShiftedDPhiCut",
"shifted-dphi-cut",-1.);
166 FromOption(task,
"WeightMask",
"reweigh-mask", 0xFF);
167 FromOption(task,
"WeightVeto",
"reweigh-veto", 0x0);
169 FromOption(task,
"WeightInverse",
"reweigh-inv",
false);
192 std::ofstream o(
"Collect.C");
194 Error(
"TrackletAODdNdeta::SavePost",
"Failed to open Collect.C");
197 o <<
"// Created by " <<
ClassName() <<
"\n" 198 <<
"// Will draw dN/deta results from produced files\n" 201 <<
"// other Directory of other result (MC or real)\n" 202 <<
"// output Optional output directory name\n" 203 <<
"// proc Bit mask of processing options\n" 204 <<
"// - 0x1 Unit normalisation of C\n" 205 <<
"// - 0x2 Constant normalisation of C\n" 206 <<
"// - 0x4 eta-dependent normalisation of C\n" 207 <<
"// - 0x8 (eta,IPz)-dependent normalisation of C\n" 208 <<
"// viz Bit mask of visualisation options\n" 209 <<
"// - 0x0001 General information\n" 210 <<
"// - 0x0002 Parameters used\n" 211 <<
"// - 0x0004 Show weights if used\n" 212 <<
"// - 0x0008 Show dN/deta \n" 213 <<
"// - 0x0010 Show species\n" 214 <<
"// - 0x0020 Show delta distribtions\n" 215 <<
"// - 0x0040 Show details of the calculation\n" 216 <<
"// - 0x0080 Reserved\n" 217 <<
"// - 0x0100 Generate PDF and PNGs\n" 218 <<
"// - 0x0200 Pause after each page\n" 219 <<
"// - 0x0400 Generate plots in landscape orientation\n" 220 <<
"// - 0x0800 Use an alternate marker\n" 221 <<
"// n Number of centrality bins to process\n" 223 <<
"// Output is generated in the sub-directory\n" 230 <<
"// where <other> is the first argument given\n" 231 <<
"void Collect(const char* other,\n" 232 <<
" const char* output=0\n" 233 <<
" UInt_t proc=0x2,\n" 234 <<
" UInt_t viz=0x32f,\n" 238 <<
" \"$ALICE_PHYSICS/PWGLF/FORWARD/analysis2/dndeta/tracklets3\";\n" 239 <<
" gSystem->AddIncludePath(Form(\"-I%s\",fwd.Data()));\n" 240 <<
" gROOT->LoadMacro(Form(\"%s/AliTrackletAODUtils.C+g\",fwd.Data()));" 242 <<
" gROOT->LoadMacro(Form(\"%s/AliTrackletdNdeta2.C+g\",fwd.Data()));" 244 TString oName(fEscapedName); oName.Append(
"/AnalysisResults.root");
246 o <<
" TString realFile = Form(\"%s/AnalysisResults.root\",other);\n" 247 <<
" TString simFile = \"" << oName <<
"\";\n" 248 <<
" TString outFile = Form(\""<<fEscapedName <<
"_%s\",other);\n";
250 o <<
" TString realFile = \"" << oName <<
"\";\n" 251 <<
" TString simFile = Form(\"%s/AnalysisResults.root\",other);\n" 252 <<
" TString outFile = Form(\"%s_"<<fEscapedName <<
"\",other);\n";
253 o <<
" if (output && output[0] != '\0') outFile = output;\n" 254 <<
" AliTrackletdNdeta2* p = new AliTrackletdNdeta2;\n" 255 <<
" if (proc & 0x1) outFile.Append(\"_unit\");\n" 256 <<
" if (proc & 0x2) outFile.Append(\"_const\");\n" 257 <<
" if (proc & 0x4) outFile.Append(\"_eta\");\n" 258 <<
" if (proc & 0x8) outFile.Append(\"_etaipz\");\n" 260 <<
" p->Run(proc,viz,n,realFile,simFile,outFile);\n" 262 <<
" gROOT->LoadMacro(Form(\"%s/ExtractGSE2.C\",fwd.Data()));\n" 263 <<
" ExtractGSE2(outFile);\n" 274 const char*
ClassName()
const {
return "TrackletAODdNdeta"; }
virtual void CreateCentralitySelection(Bool_t mc)
Bool_t AsBool(const TString &name) const
const char * AsString(const TString &name, const TString &def="") const
void SaveSetup(Bool_t asShellScript)
const TString & Get(const TString &name) const
const char * ClassName() const
Bool_t Has(const TString &name) const
void CreateTasks(AliAnalysisManager *mgr)
TrackletAODdNdeta(const char *name)
virtual void CreateCentralitySelection(Bool_t mc)
void Set(const TString &name, const TString &value)
virtual Bool_t IsMC() const
void SetDescription(const TString &d)
Base classs for train specifications.
Option * Add(const TString &name, const TString &arg, const TString &desc, const TString &val="")
virtual void SaveSetup(Bool_t asShellScript)
const char * DefaultCentBins() const
void FromOption(AliAnalysisTaskSE *task, const char *what, const char *opt, Double_t defval)
virtual AliVEventHandler * CreateOutputHandler(UShort_t)
virtual Bool_t LoadSource(const TString &name, bool copy=false)
void SetOnTask(AliAnalysisTaskSE *task, const char *what, UInt_t val)