]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG1/PilotTrain/PilotAnalysis.C
593de9ba2b3e7f47e859cdcadbd959d0784dee4f
[u/mrichter/AliRoot.git] / PWG1 / PilotTrain / PilotAnalysis.C
1 #include "Riostream.h"
2 void LoadLibraries();
3 void AddAnalysisTasks(); 
4 class AliAnalysisAlien;                                                                                                                    
5 AliAnalysisAlien* CreateAlienHandler(const char *plugin_mode);
6
7 // Collision type: 0 = p-p   1 = Pb-Pb
8 Int_t  iCollisionType = 1;
9 Int_t runNumbers[5] = {137844};
10
11 Bool_t doCDBconnect   = 1;
12 Bool_t doEventStat    = 1;
13 Bool_t doCentrality   = 1;
14 Bool_t doQAsym        = 1;
15 Bool_t doVZERO        = 1;   // there is a 2nd file
16 Bool_t doVertex       = 1;
17 Bool_t doSPD          = 1;   // needs RP   
18 Bool_t doTPC          = 1;
19 Bool_t doSDD          = 1;   // needs RP
20 Bool_t doSSDdEdx      = 1;
21 // new 
22 Bool_t doTRD          = 1;
23 Bool_t doITS          = 1;
24 Bool_t doCALO         = 1;
25 Bool_t doMUONTrig     = 1;
26 Bool_t doImpParRes    = 1;
27 Bool_t doMUON         = 1;
28 Bool_t doTOF          = 1;
29 Bool_t doHMPID        = 1;
30 Bool_t doZDC          = 1;
31
32 Bool_t doMUONEff      = 0;   // NEEDS geometry
33 Bool_t doV0           = 0;   // NEEDS MCtruth 
34
35 TString     train_name         = "QA";      // QA local folder name
36 TString     train_tag          = "_Pb-Pb_";        // Train special tag appended to 
37                                             // visible name. ("sim", "pp", ...)
38                // Name in train page (DON'T CHANGE)
39 TString     visible_name       = Form("QA$2_$3%s", train_tag.Data()); //# FIXED #
40 TString     job_comment        = "PWG1 QA train "; // Can add observations here
41                // Job tag (DON'T CHANGE)
42 TString     job_tag            = Form("%s: %s", visible_name.Data(), job_comment.Data());
43                // Package versions - Modify as needed
44 TString     root_version       = "v5-27-06c";
45 TString     aliroot_version    = "v4-21-15-AN";
46                // Production directory - change as needed for test mode
47 TString     grid_datadir       = "/alice/data/2010/LHC10h";
48                // Work directory in GRID (DON'T CHANGE)
49 TString     grid_workdir       = "/alice/cern.ch/user/a/alidaq/QA/QA$2";
50                // Job splitting
51 Int_t       grid_split         = 20;       // Splitting
52                // Debug level
53 Int_t       debug_level        = 1;        // Debugging
54                // File merging
55 Int_t       maxMergeFiles      = 10;       // Max files to merge in a chunk
56                // Data pattern - change as needed for test mode
57 TString     data_pattern       = "*ESDs/pass1/*ESDs.root";
58                // Output directory (DON'T CHANGE)
59 TString     alien_outdir       = "$1/QA$2";
60                // Input collection (production mode)
61 TString     data_collection    = "$1/qa1.xml";
62 TString     mergeExcludes      = ""; // Files to be excluded for merging
63 TString     mergeDirName       = "QA$2";
64 TString     terminateFiles     = "trending.root"; // Files produced during Terminate
65
66 Bool_t useProductionMode       = kTRUE;
67 Bool_t useMergeViaJDL          = kTRUE;
68 Bool_t useFastReadOption       = kFALSE;
69 Bool_t useOverwriteMode        = kTRUE;
70 Bool_t useDevelopmentVersion   = kFALSE;
71
72 void PilotAnalysis(const char *plugin_mode = "full")
73 {
74   TString smode(plugin_mode);
75   smode.ToLower();
76   if (smode == "test") useProductionMode = kFALSE;
77   if (!useProductionMode) {
78      TGrid::Connect("alien://");
79      if (!gGrid || !gGrid->IsConnected()) {
80        ::Error("PilotAnalysis", "No grid connection");
81        return;
82      }
83   }   
84   // Write configuration
85   TString cdir = gSystem->WorkingDirectory();
86   gSystem->MakeDirectory(train_name);
87   gSystem->ChangeDirectory(train_name);
88   ofstream out;
89   out.open(Form("%sConfig.C",train_name.Data()), ios::out);
90   out << "{" << endl;
91   out << "   train_name      = " << "\"" << train_name.Data() << "\";" << endl;
92   out << "   root_version    = " << "\"" << root_version.Data() << "\";" << endl;
93   out << "   aliroot_version = " << "\"" << aliroot_version.Data() << "\";" << endl;
94   out << "   grid_datadir   = " << "\"" << grid_datadir.Data() << "\";" << endl;
95   if (!alien_outdir.Length()) alien_outdir = Form("output_%s",train_name.Data());
96   out << "   alien_outdir    = " << "\"" << alien_outdir.Data() << "\";" << endl;
97   out << "   doQAsim         = " << doQAsym << ";" << endl;
98   out << "   doVZERO         = " << doVZERO << ";" << endl;
99   out << "   doVertex        = " << doVertex << ";" << endl;
100   out << "   doSPD           = " << doSPD << ";" << endl;
101   out << "   doSDD           = " << doSDD << ";" << endl;
102   out << "   doSSDdEdx       = " << doSSDdEdx << ";" << endl;
103   out << "   doTPC           = " << doTPC << ";" << endl;
104   out << "   doTRD           = " << doTRD << ";" << endl;
105   out << "   doZDC           = " << doZDC << ";" << endl;
106   out << "   doImpParRes     = " << doImpParRes << ";" << endl;
107   out << "   doMUON          = " << doMUON << ";" << endl;
108   out << "   doTOF           = " << doTOF << ";" << endl;
109   out << "   doHMPID         = " << doHMPID << ";" << endl;
110   out << "   doEventStat     = " << doEventStat << ";" << endl;
111   out << "   doCentrality    = " << doCentrality << ";" << endl;
112   out << "}" << endl;
113   out.close();
114   
115   // Load libraries
116   gSystem->SetIncludePath("-I. -I$ROOTSYS/include -I$ALICE_ROOT/include -I$ALICE_ROOT -I$ALICE_ROOT/ITS -I$ALICE_ROOT/TRD -I$ALICE_ROOT/PWG1");
117   LoadLibraries();
118   // Create manager
119   AliAnalysisManager *mgr  = new AliAnalysisManager("PilotAnalysis", "Production train");
120   mgr->SetNSysInfo(100);
121   mgr->SetDebugLevel(1);
122   // Input handler
123   AliESDInputHandlerRP *esdHandler = new AliESDInputHandlerRP();
124   esdHandler->SetReadFriends(kTRUE);
125   esdHandler->SetActiveBranches("ESDfriend");
126   mgr->SetInputEventHandler(esdHandler);
127   mgr->SetDebugLevel(debug_level);
128   
129   // AnalysisTasks
130   AddAnalysisTasks();
131   // Grid handler
132   AliAnalysisAlien *alienHandler = CreateAlienHandler(plugin_mode);
133   mgr->SetGridHandler(alienHandler);
134   if (mgr->InitAnalysis()) {                                                                                                              
135     mgr->PrintStatus(); 
136     if (!strcmp(plugin_mode, "local")) mgr->StartAnalysis("local");
137     else mgr->StartAnalysis("grid");
138   }
139 }
140
141 void LoadLibraries()
142 {
143   gSystem->Load("libANALYSIS");
144   gSystem->Load("libANALYSISalice");
145   gSystem->Load("libCORRFW");
146   gSystem->Load("libTENDER");
147   gSystem->Load("libPWG0base.so");
148   gSystem->Load("libPWG0dep.so");
149   gSystem->Load("libPWG0selectors.so");
150   gSystem->Load("libPWG1.so");
151   gSystem->Load("libPWG2.so");
152   gSystem->Load("libPWG2forward.so");
153
154   if (doCALO) {
155      gSystem->Load("libEMCALUtils");
156      gSystem->Load("libPWG4PartCorrBase");
157      gSystem->Load("libPWG4PartCorrDep");
158   }  
159   if(doMUONTrig) {
160      gSystem->Load("libPWG3base");
161      gSystem->Load("libPWG3muon");
162      gSystem->Load("libPWG3muondep");
163   }   
164 }
165
166 void AddAnalysisTasks()
167 {
168   AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
169   mgr->SetCommonFileName("QAresults.root");
170   // Statistics task
171   mgr->AddStatisticsTask(AliVEvent::kMB);
172   //
173   // CDB connection
174   //
175   if (doCDBconnect) {
176     gROOT->LoadMacro("$ALICE_ROOT/PWG1/PilotTrain/AddTaskCDBconnect.C");
177     AliTaskCDBconnect *taskCDB = AddTaskCDBconnect();
178     if (!taskCDB) return;
179     taskCDB->SetRunNumber(runNumbers[0]);
180   }    
181   
182   //
183   // Event Statistics (Jan Fiete)
184   //
185   if (doEventStat) {
186       gROOT->LoadMacro("$ALICE_ROOT/ANALYSIS/macros/AddTaskPhysicsSelection.C");
187       AliPhysicsSelectionTask* physSelTask = AddTaskPhysicsSelection(kFALSE /*MC*/);
188 //      mgr->RegisterExtraFile("event_stat.root");
189       if (!terminateFiles.IsNull()) terminateFiles += ",";
190       terminateFiles += "event_stat.root";
191   }
192   
193   //
194   // Centrality (A. Toia)
195   //
196   if (doCentrality) {
197      gROOT->LoadMacro("$ALICE_ROOT/ANALYSIS/macros/AddTaskCentrality.C");
198      AliCentralitySelectionTask *taskCentrality = AddTaskCentrality();
199 // J.Thaeder
200 //     gROOT->LoadMacro("$ALICE_ROOT/PWG1/Centrality/AddTaskHIMultCorr.C");
201 //     AliAnalysisTaskHIMultCorr *taskHIcentrality = AddTaskHIMultCorr();
202   }   
203   
204   // Vertexing (A. Dainese)
205   // 
206   if (doVertex) {
207     gROOT->LoadMacro("$ALICE_ROOT/PWG1/macros/AddTaskVertexESD.C");
208     AliAnalysisTaskVertexESD* taskvertexesd =  AddTaskVertexESD();
209     taskvertexesd->SelectCollisionCandidates();
210   }  
211
212   // TPC QA (E. Sicking)
213   //
214   if (doQAsym) {
215     gROOT->LoadMacro("$ALICE_ROOT/PWG1/PilotTrain/AddTaskQAsym.C");
216     AliAnalysisTaskSE * taskqasim = AddTaskQAsym(0);
217     taskqasim->SelectCollisionCandidates();
218   }  
219   //
220   // VZERO QA  (C. Cheshkov)
221   //
222   if (doVZERO) {
223     gROOT->LoadMacro("$ALICE_ROOT/PWG1/PilotTrain/AddTaskVZEROQA.C");
224     AliAnalysisTaskSE * taskv0qa = AddTaskVZEROQA(0);
225 //  taskv0qa->SelectCollisionCandidates();
226   }
227   //
228   // TPC (Jacek Otwinowski & Michael Knichel)
229   //
230   //
231   // Optionally MC information can be used by setting the 1st argument to true
232   // Optionally friends information can be switched off by setting the 2st argument 
233   // to false
234   // Optionally highMult axis can be used by setting the 3st argument to true (for PbPb)
235   if (doTPC) {
236     gROOT->LoadMacro("$ALICE_ROOT/PWG1/TPC/macros/AddTaskPerformanceTPCdEdxQA.C");
237     AliPerformanceTask *tpcQA = AddTaskPerformanceTPCdEdxQA(kFALSE, kTRUE, kFALSE);
238     tpcQA->SelectCollisionCandidates();
239   }  
240   //
241   // SPD (A. Mastroserio)
242   //
243   if (doSPD) {
244     gROOT->LoadMacro("$ALICE_ROOT/PWG1/PilotTrain/AddTaskSPDQA.C");
245     AliAnalysisTaskSE* taskspdqa = AddTaskSPDQA();
246     taskspdqa->SelectCollisionCandidates();
247   }  
248   //
249   // SDD (F. Prino)
250   //
251   if (doSDD) {
252     gROOT->LoadMacro("$ALICE_ROOT/PWG1/PilotTrain/AddSDDPoints.C");
253     AliAnalysisTaskSE* tasksdd = AddSDDPoints();
254     tasksdd->SelectCollisionCandidates();
255   }
256   //
257   // SSD dEdx (Marek Chojnacki)
258   //
259   if (doSSDdEdx) {
260     gROOT->LoadMacro("$ALICE_ROOT/PWG1/PilotTrain/AddTaskdEdxSSDQA.C");
261     AliAnalysisTaskSE* taskssddedx = AddTaskdEdxSSDQA();
262     taskssddedx->SelectCollisionCandidates();
263   }
264
265   //
266   // ITS
267   //
268   if (doITS) {
269       gROOT->LoadMacro("$ALICE_ROOT/PWG1/macros/AddTaskPerformanceITS.C");
270       AliAnalysisTaskITSTrackingCheck *itsQA = 0;
271       AliAnalysisTaskITSTrackingCheck *itsQACent0010 = 0;
272       AliAnalysisTaskITSTrackingCheck *itsQACent3050 = 0;
273       AliAnalysisTaskITSTrackingCheck *itsQACent6080 = 0;
274       if(iCollisionType==0) {
275         itsQA = AddTaskPerformanceITS(kFALSE);
276       } else {
277         itsQA = AddTaskPerformanceITS(kFALSE);
278         itsQACent0010 = AddTaskPerformanceITS(kFALSE,kFALSE,kFALSE,3500,10000);
279         itsQACent3050 = AddTaskPerformanceITS(kFALSE,kFALSE,kFALSE,590,1570);
280         itsQACent6080 = AddTaskPerformanceITS(kFALSE,kFALSE,kFALSE,70,310);
281       }
282   }
283   //
284   // TRD (Alex Bercuci, M. Fasel) 
285   //
286   if(doTRD) {
287       gROOT->LoadMacro("$ALICE_ROOT/PWG1/macros/AddTrainPerformanceTRD.C");
288       // steer individual TRD tasks
289       Bool_t 
290       doCheckESD(kTRUE),  // AliTRDcheckESD
291       doCheckDET(kTRUE),  // AliTRDcheckDET
292       doEffic(kTRUE),     // AliTRDefficiency
293       doResolution(kTRUE),// AliTRDresolution
294       doCheckPID(kTRUE),  // AliTRDcheckPID
295       doV0Monitor(kFALSE);// AliTRDv0Monitor
296       AddTrainPerformanceTRD(Translate(doCheckESD, doCheckDET, doEffic, doResolution, doCheckPID, doV0Monitor));
297   }
298
299   //
300   // ZDC (Chiara Oppedisano) 
301   //
302   if(doZDC) {
303      gROOT->LoadMacro("$ALICE_ROOT/PWG1/ZDC/AddTaskZDCQA.C");
304      AliAnalysisTaskSE *taskZDC = AddTaskZDCQA();
305   }   
306   //
307   // Calorimetry (Gustavo Conesa)
308   //
309
310   if(doCALO) {
311       gROOT->LoadMacro("$ALICE_ROOT/PWG4/macros/QA/AddTaskCalorimeterQA.C");
312       AliAnalysisTaskParticleCorrelation *taskCaloQA = AddTaskCalorimeterQA("ESD", kTRUE, kFALSE);
313       taskCaloQA->SetDebugLevel(0);
314   }
315
316   //
317   // Muon Trigger
318   //
319   
320   if(doMUONTrig) {
321       gROOT->LoadMacro("$ALICE_ROOT/PWG1/macros/AddTaskMTRchamberEfficiency.C");
322       AliAnalysisTaskTrigChEff *taskMuonTrig = AddTaskMTRchamberEfficiency();
323   }
324
325   //
326   // Muon Efficiency
327   //
328
329   if(doMUONEff) {
330       gROOT->LoadMacro("$ALICE_ROOT/PWG3/muondep/AddTaskMUONTrackingEfficiency.C");
331       AliAnalysisTaskMuonTrackingEff *taskMuonTrackEff = AddTaskMUONTrackingEfficiency();
332   }
333   
334   //
335   // V0-Decay Reconstruction (Ana Marin)
336   // 
337
338   if (doV0) {
339       gROOT->LoadMacro("$ALICE_ROOT/PWG1/macros/AddTaskV0QA.C");
340       AliAnalysisTaskV0QA *taskv0QA = AddTaskV0QA(kFALSE);
341   }
342   //
343   // Impact parameter resolution (xianbao.yuan@pd.infn.it, andrea.dainese@pd.infn.it)
344   //
345   if (doImpParRes) {
346     gROOT->LoadMacro("$ALICE_ROOT/PWG1/macros/AddTaskImpParRes.C");
347     AliAnalysisTaskSE* taskimpparres=0;
348     if(iCollisionType==0) {
349        taskimpparres= AddTaskImpParRes();
350     } else {
351        taskimpparres= AddTaskImpParRes(kFALSE,-1,kFALSE,kFALSE);
352     }
353     taskimpparres->SelectCollisionCandidates();
354   }  
355   //
356   // MUON QA (Philippe Pillot)
357   //
358   if (doMUON) {
359     gROOT->LoadMacro("$ALICE_ROOT/PWG3/muon/AddTaskMuonQA.C");
360     AliAnalysisTaskSE* taskmuonqa= AddTaskMuonQA();
361   }  
362   //
363   // TOF (Francesca Bellini)
364   //
365   if (doTOF) {
366     gROOT->LoadMacro("$ALICE_ROOT/PWG1/TOF/AddTaskTOFQA.C");
367     AliAnalysisTaskTOFqa *tofQA = AddTaskTOFQA();
368     tofQA->SelectCollisionCandidates();
369   }  
370   //
371   // HMPID QA (Giacomo Volpe)
372   //
373   if (doHMPID) {
374     gROOT->LoadMacro("$ALICE_ROOT/PWG1/HMPID/AddTaskHmpidQA.C");
375     AliAnalysisTaskSE* taskhmpidqa= AddTaskHmpidQA(kFALSE);
376   }      
377 }
378
379 //______________________________________________________________________________
380 AliAnalysisAlien* CreateAlienHandler(const char *plugin_mode)
381 {
382 // Check if user has a valid token, otherwise make one. This has limitations.
383 // One can always follow the standard procedure of calling alien-token-init then
384 //   source /tmp/gclient_env_$UID in the current shell.
385    if (!AliAnalysisGrid::CreateToken()) return NULL;
386    AliAnalysisAlien *plugin = new AliAnalysisAlien();
387 // Set the run mode (can be "full", "test", "offline", "submit" or "terminate")
388    plugin->SetRunMode(plugin_mode);
389    if (useProductionMode) {
390       plugin->SetProductionMode();
391       plugin->AddDataFile(data_collection);
392    }   
393    plugin->SetJobTag(job_tag);
394    plugin->SetNtestFiles(10);
395    plugin->SetCheckCopy(kFALSE);
396    plugin->SetMergeDirName(mergeDirName);
397 //   plugin->SetOneStageMerging(kTRUE);
398 // Set versions of used packages
399    plugin->SetAPIVersion("V1.1x");
400    plugin->SetROOTVersion(root_version);
401    plugin->SetAliROOTVersion(aliroot_version);
402 // Declare input data to be processed.
403 // Method 1: Create automatically XML collections using alien 'find' command.
404 // Define production directory LFN
405    plugin->SetGridDataDir(grid_datadir);
406 // Set data search pattern
407    plugin->SetDataPattern(data_pattern);
408 // ...then add run numbers to be considered
409 //   if (!iAODanalysis) plugin->SetRunRange(run_range[0], run_range[1]);
410 //   plugin->SetOutputSingleFolder("output");
411    if (!useProductionMode) {
412       plugin->SetRunPrefix("000");
413       plugin->SetOutputToRunNo();
414       for (Int_t i=0; i<2; i++) {
415          if (!runNumbers[i]) break;
416          plugin->AddRunNumber(runNumbers[i]);
417       }   
418    }
419 // Define alien work directory where all files will be copied. Relative to alien $HOME.
420    plugin->SetGridWorkingDir(grid_workdir);
421 // Declare alien output directory. Relative to working directory.
422    if (alien_outdir.IsNull()) alien_outdir = Form("output_%s",train_name.Data());
423    plugin->SetGridOutputDir(alien_outdir);
424
425    if (useDevelopmentVersion) {
426      plugin->EnablePackage("STEERBase");
427      plugin->EnablePackage("ESD");
428      plugin->EnablePackage("AOD");
429      plugin->EnablePackage("ANALYSIS");
430      plugin->EnablePackage("ANALYSISalice");
431    }
432
433 // Declare the analysis source files names separated by blancs. To be compiled runtime
434 // using ACLiC on the worker nodes.
435 // Declare all libraries (other than the default ones for the framework. These will be
436 // loaded by the generated analysis macro. Add all extra files (task .cxx/.h) here.
437    plugin->AddIncludePath("-I. -I$ROOTSYS/include -I$ALICE_ROOT/include -I$ALICE_ROOT/ITS -I$ALICE_ROOT/TRD");
438    
439    plugin->SetAdditionalLibs("libCORRFW.so libTENDER.so libPWG0base.so libPWG0dep.so libPWG0selectors.so libPWG1.so libPWG2.so \
440                               libPWG2forward.so libEMCALUtils.so libPWG4PartCorrBase.so libPWG4PartCorrDep.so \
441                               libPWG3base.so libPWG3muon.so libPWG3muondep.so");
442      
443 // Declare the output file names separated by blancs.
444 // (can be like: file.root or file.root@ALICE::Niham::File)
445    plugin->SetDefaultOutputs();
446    plugin->SetMaxMergeFiles(maxMergeFiles);
447    plugin->SetNrunsPerMaster(1);
448    
449    // Put default output files to archive
450    AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
451    TIter next(mgr->GetOutputs());
452    AliAnalysisDataContainer *output;
453    if (!mergeExcludes.IsNull()) plugin->SetMergeExcludes(mergeExcludes);
454    if (!terminateFiles.IsNull()) plugin->SetTerminateFiles(terminateFiles);
455 // Set friends
456 // Optionally set a name for the generated analysis macro (default MyAnalysis.C)
457    plugin->SetAnalysisMacro(Form("%s.C", train_name.Data()));
458 // Optionally set a name for the generated validation script
459    plugin->SetValidationScript("validation.sh");
460 // Optionally set maximum number of input files/subjob (default 100, put 0 to ignore)
461    plugin->SetSplitMaxInputFileNumber(grid_split);
462 // Optionally set number of failed jobs that will trigger killing waiting sub-jobs.
463 //   plugin->SetMaxInitFailed(5);
464 // Optionally modify the number of replicas
465    plugin->SetNumberOfReplicas(4);
466 // Optionally resubmit threshold.
467 //   plugin->SetMasterResubmitThreshold(90);
468 // Optionally set time to live (default 30000 sec)
469    plugin->SetTTL(70000);
470 // Optionally set input format (default xml-single)
471    plugin->SetInputFormat("xml-single");
472 // Optionally modify the name of the generated JDL (default analysis.jdl)
473    plugin->SetJDLName(Form("%s.jdl", train_name.Data()));
474 // Optionally modify the executable name (default analysis.sh)
475    plugin->SetExecutable(Form("%s.sh", train_name.Data()));
476 // Optionally modify job price (default 1)
477    plugin->SetPrice(1);      
478 // Optionally modify split mode (default 'se')    
479    plugin->SetSplitMode("se");
480    plugin->SetExecutableCommand("aliroot -b -q");
481 // Merge via JDL
482    plugin->SetMergeViaJDL(useMergeViaJDL);
483 // Use fastread option
484    plugin->SetFastReadOption(useFastReadOption);
485 // UseOverwrite mode
486    plugin->SetOverwriteMode(useOverwriteMode);   
487 /*********************************************************
488  ***     PROOF MODE SPECIFIC SETTINGS         ************
489  *********************************************************/
490 // Proof cluster
491 //   plugin->SetProofCluster("alice-caf");
492    plugin->SetProofCluster("skaf.saske.sk");
493 // Dataset to be used   
494    plugin->SetProofDataSet("/alice/data/LHC10e_000128175_p1#esdTree");
495 // May need to reset proof. Supported modes: 0-no reset, 1-soft, 2-hard
496    plugin->SetProofReset(0);
497 // May limit number of workers
498    plugin->SetNproofWorkers(1);   
499 // May use a specific version of root installed in proof
500    plugin->SetRootVersionForProof("current_dbg");
501 // May set the aliroot mode. Check http://aaf.cern.ch/node/83 
502    plugin->SetAliRootMode("ALIROOT"); // Loads AF libs by default
503 // May request ClearPackages (individual ClearPackage not supported)
504    plugin->SetClearPackages(kFALSE);
505 // Plugin test mode works only providing a file containing test file locations
506    plugin->SetFileForTestMode(gSystem->ExpandPathName("$ALICE_ROOT/PWG1/PilotTrain/files.txt"));
507    return plugin;
508 }