-//=============================================================================
-//
-// *** AddTaskTPCCalib
-//
-// This macros setup the TPC calibration task
-//
-//=============================================================================
-
-
-
+/// \file AddTaskTPCCalib.C
+/// \brief This macros setup the TPC calibration task
Int_t debugLevel = 2;
Int_t streamLevel = 20;
void AddCalibCalib(TObject* task){
- //
- // Responsible: Marian Ivanov
- // Description:
- // calibCalib is a prefilter
- // The current OCDB entries transformation are applied on cluster, tracks are refitted
- //
+ /// Responsible: Marian Ivanov
+ /// Description:
+ /// calibCalib is a prefilter
+ /// The current OCDB entries transformation are applied on cluster, tracks are refitted
+
AliTPCAnalysisTaskcalib* myTask = (AliTPCAnalysisTaskcalib*) task;
AliTPCcalibCalib *calibCalib = new AliTPCcalibCalib("calibTPC","calibTPC");
calibCalib->SetDebugLevel(debugLevel);
}
void AddCalibTimeGain(TObject* task){
- //
- // Responsible: Alexander Kalweit
- // Description:
- // Parameters to set
+ /// Responsible: Alexander Kalweit
+ /// Description:
+ /// Parameters to set
+
AliTPCAnalysisTaskcalib* myTask = (AliTPCAnalysisTaskcalib*) task;
AliTPCcalibTimeGain *calibTimeGain = new AliTPCcalibTimeGain("calibTimeGain","calibTimeGain", startTime.GetSec(), stopTime.GetSec(), 30*60);
//calibTimeGain->SetLowMemoryConsumption(kTRUE);
}
void AddCalibTime(TObject* task){
- //
- // Responsible: Dag Larsen
- // Description:
- //
- //
+ /// Responsible: Dag Larsen
+ /// Description:
+
AliTPCAnalysisTaskcalib* myTask = (AliTPCAnalysisTaskcalib*) task;
AliTPCcalibTime *calibTime = new AliTPCcalibTime("calibTime","calibTime", startTime.GetSec(), stopTime.GetSec(), 20*60);
calibTime->SetDebugLevel(debugLevel);
void SetupCalibTaskTrain1(TObject* task){
- //
- //
- //
+ ///
+
AliTPCAnalysisTaskcalib* myTask = (AliTPCAnalysisTaskcalib*) task;
//AddCalibCalib(task);
AddCalibTimeGain(task);
void ConfigOCDB(Int_t run){
- //
+ ///
+
printf("SETUP OCBD for TPC\n");
printf("SETUP OCBD for TPC\n");
printf("SETUP OCBD for TPC\n");
-/*
+/// \file AliEveTree.C
+///
+/// ~~~{.cpp}
+/// .L $ALICE_ROOT/TPC/macros/AliEveTree.C+
+/// MakeEveTree();
+///
+/// TFile fesd("AliESDs.root");
+/// TTree * treeESD = (TTree*)fesd.Get("esdTree");
+///
+/// TFile ftpc("TPCdebug.root");
+/// TFile fits("ITSdebug.root");
+/// TTree * treeTPC = (TTree*)ftpc.Get("Transform");
+/// TTree * treeITS = (TTree*)fits.Get("Clusters");
+///
+/// treeTPC->Draw("gx2/sqrt(gx0^2+gx1^2):sqrt(gx0^2+gx1^2)>>his(100,0,200,100,-1,1)","event==4","")
+/// treeITS->Draw("gz/sqrt(gx^2+gy^2):sqrt(gx^2+gy^2)>>his(100,0,200,100,-1,1)","event==4","same")
+///
+/// treeTPC->Draw("atan2(gx1,gx0):sqrt(gx0^2+gx1^2)>>his(100,0,200,100,-1,1)","event==4","*")
+/// treeITS->Draw("atan2(gy,gx):sqrt(gx^2+gy^2)>>his(100,0,200,100,-1,1)","event==4","same*");
+/// ~~~
- .L $ALICE_ROOT/TPC/macros/AliEveTree.C+
- MakeEveTree();
-
- TFile fesd("AliESDs.root");
- TTree * treeESD = (TTree*)fesd.Get("esdTree");
-
-
-
- TFile ftpc("TPCdebug.root");
- TFile fits("ITSdebug.root");
- TTree * treeTPC = (TTree*)ftpc.Get("Transform");
- TTree * treeITS = (TTree*)fits.Get("Clusters");
-
- treeTPC->Draw("gx2/sqrt(gx0^2+gx1^2):sqrt(gx0^2+gx1^2)>>his(100,0,200,100,-1,1)","event==4","")
- treeITS->Draw("gz/sqrt(gx^2+gy^2):sqrt(gx^2+gy^2)>>his(100,0,200,100,-1,1)","event==4","same")
-
- treeTPC->Draw("atan2(gx1,gx0):sqrt(gx0^2+gx1^2)>>his(100,0,200,100,-1,1)","event==4","*")
- treeITS->Draw("atan2(gy,gx):sqrt(gx^2+gy^2)>>his(100,0,200,100,-1,1)","event==4","same*");
-
-*/
#include "TFile.h"
#include "TTree.h"
#include "TTreeStream.h"
void MakeESDTree(AliESDEvent*esd, TTreeSRedirector &cstream){
- //
- //
- //
+ ///
+
Float_t bz = esd->GetMagneticField();
//AliTPCseed dummyTPC;
//AliTPCseed dummyTRD;
AliTrackPointArray *MakeArray(TPolyMarker3D *pol){
- //
- // Make a aray of points with errors
- //
+ /// Make a aray of points with errors
+
Int_t entries = pol->GetN();
AliTrackPointArray * array = new AliTrackPointArray(entries);
for (Int_t i=0;i<entries;i++){
-/*
-
- .L $ALICE_ROOT/TPC/macros/AliMagFDraw.cxx+
- AliMagFDraw draw;
- draw.RegisterField(0,new AliMagWrapCheb("Maps","Maps", 2, 1., 10., AliMagWrapCheb::k5kG));
- draw.RegisterField(1,new AliMagFMaps("Maps","Maps", 2, 1., 10., 2));
-
- TF2 fbz_rz_0pi("fbz_rz_0pi","AliMagFDraw::GetBz(x,0*pi,y)",0,250,-250,250);
- fbz_rz_0pi->Draw("surf2");
-
- TF1 fbz_z_90_00pi("fbz_z_90_00pi","AliMagFDraw::GetBz(90,0*pi,x)",-250,250);
- TF1 fbz_z_90_05pi("fbz_z_90_05pi","AliMagFDraw::GetBz(90,0.5*pi,x)",-250,250);
- TF1 fbz_z_90_10pi("fbz_z_90_10pi","AliMagFDraw::GetBz(90,1.0*pi,x)",-250,250);
- TF1 fbz_z_90_15pi("fbz_z_90_15pi","AliMagFDraw::GetBz(90,1.5*pi,x)",-250,250);
- fbz_z_90_00pi->SetLineColor(2);
- fbz_z_90_05pi->SetLineColor(3);
- fbz_z_90_10pi->SetLineColor(4);
- fbz_z_90_15pi->SetLineColor(5);
- fbz_z_90_00pi->Draw()
- fbz_z_90_05pi->Draw("same")
- fbz_z_90_15pi->Draw("same")
- fbz_z_90_10pi->Draw("same")
-
-
- TF1 fbr_z_90_00pi("fbz_z_90_00pi","AliMagFDraw::GetBr(90,0*pi,x)",-250,250);
- TF1 fbr_z_90_05pi("fbz_z_90_05pi","AliMagFDraw::GetBr(90,0.5*pi,x)",-250,250);
- TF1 fbr_z_90_10pi("fbz_z_90_10pi","AliMagFDraw::GetBr(90,1.0*pi,x)",-250,250);
- TF1 fbr_z_90_15pi("fbz_z_90_15pi","AliMagFDraw::GetBr(90,1.5*pi,x)",-250,250);
- fbr_z_90_00pi->SetLineColor(2);
- fbr_z_90_05pi->SetLineColor(3);
- fbr_z_90_10pi->SetLineColor(4);
- fbr_z_90_15pi->SetLineColor(5);
- fbr_z_90_00pi->Draw()
- fbr_z_90_05pi->Draw("same")
- fbr_z_90_15pi->Draw("same")
- fbr_z_90_10pi->Draw("same")
-
- //
- TF2 fbz_xy_0z("fbz_xy_0z","AliMagFDraw::GetBz(sqrt(x^2+y^2),atan2(y,x),0)",-250,250,-250,250);
- fbz_xy_0z.SetNpy(100);
- fbz_xy_0z.SetNpx(100);
- fbz_xy_0z->Draw("colz");
- //
- TF2 fbz_xy_250z("fbz_xy_250z","AliMagFDraw::GetBz(sqrt(x^2+y^2),atan2(y,x),250)",-250,250,-250,250);
- fbz_xy_250z.SetNpy(100);
- fbz_xy_250z.SetNpx(100)
- fbz_xy_250z->Draw("colz");
- //
- TF2 fbz_xy_m250z("fbz_xy_m250z","AliMagFDraw::GetBz(sqrt(x^2+y^2),atan2(y,x),-250)",-250,250,-250,250);
- fbz_xy_m250z.SetNpy(100);
- fbz_xy_m250z.SetNpx(100)
- fbz_xy_m250z->Draw("colz");
- //
-
+/// \class AliMagFDraw
+///
+/// ~~~{.cpp}
+/// .L $ALICE_ROOT/TPC/macros/AliMagFDraw.cxx+
+/// AliMagFDraw draw;
+/// draw.RegisterField(0,new AliMagWrapCheb("Maps","Maps", 2, 1., 10., AliMagWrapCheb::k5kG));
+/// draw.RegisterField(1,new AliMagFMaps("Maps","Maps", 2, 1., 10., 2));
+///
+/// TF2 fbz_rz_0pi("fbz_rz_0pi","AliMagFDraw::GetBz(x,0*pi,y)",0,250,-250,250);
+/// fbz_rz_0pi->Draw("surf2");
+///
+/// TF1 fbz_z_90_00pi("fbz_z_90_00pi","AliMagFDraw::GetBz(90,0*pi,x)",-250,250);
+/// TF1 fbz_z_90_05pi("fbz_z_90_05pi","AliMagFDraw::GetBz(90,0.5*pi,x)",-250,250);
+/// TF1 fbz_z_90_10pi("fbz_z_90_10pi","AliMagFDraw::GetBz(90,1.0*pi,x)",-250,250);
+/// TF1 fbz_z_90_15pi("fbz_z_90_15pi","AliMagFDraw::GetBz(90,1.5*pi,x)",-250,250);
+/// fbz_z_90_00pi->SetLineColor(2);
+/// fbz_z_90_05pi->SetLineColor(3);
+/// fbz_z_90_10pi->SetLineColor(4);
+/// fbz_z_90_15pi->SetLineColor(5);
+/// fbz_z_90_00pi->Draw()
+/// fbz_z_90_05pi->Draw("same")
+/// fbz_z_90_15pi->Draw("same")
+/// fbz_z_90_10pi->Draw("same")
+///
+/// TF1 fbr_z_90_00pi("fbz_z_90_00pi","AliMagFDraw::GetBr(90,0*pi,x)",-250,250);
+/// TF1 fbr_z_90_05pi("fbz_z_90_05pi","AliMagFDraw::GetBr(90,0.5*pi,x)",-250,250);
+/// TF1 fbr_z_90_10pi("fbz_z_90_10pi","AliMagFDraw::GetBr(90,1.0*pi,x)",-250,250);
+/// TF1 fbr_z_90_15pi("fbz_z_90_15pi","AliMagFDraw::GetBr(90,1.5*pi,x)",-250,250);
+/// fbr_z_90_00pi->SetLineColor(2);
+/// fbr_z_90_05pi->SetLineColor(3);
+/// fbr_z_90_10pi->SetLineColor(4);
+/// fbr_z_90_15pi->SetLineColor(5);
+/// fbr_z_90_00pi->Draw()
+/// fbr_z_90_05pi->Draw("same")
+/// fbr_z_90_15pi->Draw("same")
+/// fbr_z_90_10pi->Draw("same")
+///
+/// TF2 fbz_xy_0z("fbz_xy_0z","AliMagFDraw::GetBz(sqrt(x^2+y^2),atan2(y,x),0)",-250,250,-250,250);
+/// fbz_xy_0z.SetNpy(100);
+/// fbz_xy_0z.SetNpx(100);
+/// fbz_xy_0z->Draw("colz");
+///
+/// TF2 fbz_xy_250z("fbz_xy_250z","AliMagFDraw::GetBz(sqrt(x^2+y^2),atan2(y,x),250)",-250,250,-250,250);
+/// fbz_xy_250z.SetNpy(100);
+/// fbz_xy_250z.SetNpx(100)
+/// fbz_xy_250z->Draw("colz");
+///
+/// TF2 fbz_xy_m250z("fbz_xy_m250z","AliMagFDraw::GetBz(sqrt(x^2+y^2),atan2(y,x),-250)",-250,250,-250,250);
+/// fbz_xy_m250z.SetNpy(100);
+/// fbz_xy_m250z.SetNpx(100)
+/// fbz_xy_m250z->Draw("colz");
+/// ~~~
-*/
#include "TObjArray.h"
#include "TMath.h"
#include "AliMagF.h"
};
+/// \cond CLASSIMP
ClassImp(AliMagFDraw)
+/// \endcond
TObjArray AliMagFDraw::fgArray;
void AliMagFDraw::RegisterField(Int_t index, AliMagF * magf){
- //
- // add the filed to the list
- //
+ /// add the filed to the list
+
fgArray.AddAt(magf,index);
}
Double_t AliMagFDraw::GetBz(Double_t r, Double_t phi, Double_t z,Int_t index){
- //
- //
- //
+ ///
+
AliMagF *mag = (AliMagF*)fgArray.At(index);
if (!mag) return 0;
Float_t xyz[3]={r*TMath::Cos(phi),r*TMath::Sin(phi),z};
}
Double_t AliMagFDraw::GetBy(Double_t r, Double_t phi, Double_t z,Int_t index){
- //
- //
- //
+ ///
+
AliMagF *mag = (AliMagF*)fgArray.At(index);
if (!mag) return 0;
Float_t xyz[3]={r*TMath::Cos(phi),r*TMath::Sin(phi),z};
Double_t AliMagFDraw::GetBx(Double_t r, Double_t phi, Double_t z,Int_t index){
- //
- //
- //
+ ///
+
AliMagF *mag = (AliMagF*)fgArray.At(index);
if (!mag) return 0;
Float_t xyz[3]={r*TMath::Cos(phi),r*TMath::Sin(phi),z};
Double_t AliMagFDraw::GetBr(Double_t r, Double_t phi, Double_t z,Int_t index){
- //
- //
- //
+ ///
+
AliMagF *mag = (AliMagF*)fgArray.At(index);
if (!mag) return 0;
Float_t xyz[3]={r*TMath::Cos(phi),r*TMath::Sin(phi),z};
}
Double_t AliMagFDraw::GetBrfi(Double_t r, Double_t phi, Double_t z,Int_t index){
- //
- //
- //
+ ///
+
AliMagF *mag = (AliMagF*)fgArray.At(index);
if (!mag) return 0;
Float_t xyz[3]={r*TMath::Cos(phi),r*TMath::Sin(phi),z};
TObjArray * AliMagFDraw::Fit(const char *formula, Int_t index){
- //
- /*
- formula="1++x+x^2++cos(y)++cos(y)^2++z++z^2"
- index=0
- */
- //
+ /// formula=`1++x+x^2++cos(y)++cos(y)^2++z++z^2`
+ /// index=0
TObjArray *fstrings = TString(formula).Tokenize("++");
Int_t ndim = fstrings->GetEntries();
TObjArray *formulas = new TObjArray(ndim);
-/*
-char *storage = "local://OCDBres"
- Int_t RunNumber=0;
- AliCDBManager::Instance()->SetDefaultStorage(storage);
- AliCDBManager::Instance()->SetRun(RunNumber)
- AliTPCExBFirst * exb = AliTPCcalibDB::Instance()->GetExB();
- //
- // See example macro $ALICE_ROOT/TPC/macros/AliTPCExBdraw.C
- //
- .L $ALICE_ROOT/TPC/macros/AliTPCExBdraw.C
- DrawPrim(0)
- DrawLaser(0)
-*/
-
+/// \file AliTPCExBdraw.C
+//////
+/// ~~~{.cpp}
+/// char *storage = "local://OCDBres"
+/// Int_t RunNumber=0;
+/// AliCDBManager::Instance()->SetDefaultStorage(storage);
+/// AliCDBManager::Instance()->SetRun(RunNumber)
+/// AliTPCExBFirst * exb = AliTPCcalibDB::Instance()->GetExB();
+/// // See example macro $ALICE_ROOT/TPC/macros/AliTPCExBdraw.C
+/// .L $ALICE_ROOT/TPC/macros/AliTPCExBdraw.C
+/// DrawPrim(0)
+/// DrawLaser(0)
+/// ~~~
void DrawPrim(Double_t theta,Float_t magf=5){
- //
- // Draw "primary track distortion"
- //
- //Double_t theta=0.5;
+ /// Draw "primary track distortion"
+ ///
+ /// Double_t theta=0.5;
TF1 *fdrfi_rpi0=new TF1("fdrfi_rpi0",Form("AliTPCExB::GetDrphi(x,0*pi/2,%f*x)",theta),20,250);
TF1 *fdrfi_rpi1=new TF1("fdrfi_rpi1",Form("AliTPCExB::GetDrphi(x,1*pi/2,%f*x)",theta),20,250);
void DrawLaser(Double_t fipi2,Float_t magf=5){
- //
- // Draw "primary track distortion"
- //
- //Double_t fipi2=0.5;
+ /// Draw "primary track distortion"
+ ///
+ /// Double_t fipi2=0.5;
TF2 *fdistout = new TF1("fdistout","[0]+[1]*(x-250)+[2]*(x-250)*(x-250)",90,250);
void DrawDpt(Float_t d1pt, Float_t ptmin, Float_t ptmax){
- //
- //
- //
-
+ ///
+
}
+/// \file AnalyzeLaser.C
+
gSystem->Load("libSTAT");
TStatToolkit stat;
-/*
- // Macro for merging of the calibration classes:
-// marain.ivanov@cern.ch
-// //
-// //
-// Example usage:
-// 1. Make a list of the calibration files
-// 2. Load libraries
-// 3. Merge - the output is stored in the current directory
-// //
-//
- gSystem->AddIncludePath("-I$ALICE_ROOT/TPC")
- gSystem->Load("libANALYSIS");
- gSystem->Load("libTPCcalib");
- .L $ALICE_ROOT/TPC/macros/CalibFileMerger.C+g
-// CalibFileMerger();
-*/
+/// \file CalibFileMerger.C
+/// Macro for merging of the calibration classes:
+/// \author marain.ivanov@cern.ch
+///
+/// Example usage:
+/// 1. Make a list of the calibration files
+/// 2. Load libraries
+/// 3. Merge - the output is stored in the current directory
+///
+/// ~~~{.cpp}
+/// gSystem->AddIncludePath("-I$ALICE_ROOT/TPC")
+/// gSystem->Load("libANALYSIS");
+/// gSystem->Load("libTPCcalib");
+/// .L $ALICE_ROOT/TPC/macros/CalibFileMerger.C+g
+/// CalibFileMerger();
+/// ~~~
#include <fstream>
#include "TSystem.h"
-//
-// Macro to Setup OCDB
-// This is just example macro
-// Responsible: marian.ivanov@cern.ch
-// To be used:
-// 1. Before invocation of the calibration - in the calibration trains
-// 2. To setup calibration viewer.
-//
-// ConfigOCDB - setup default and specific data storage
-// SetupCustom - user sepcific configuration
-// - Values in local cache of OCDB are overwritten
+/// \file ConfigOCDB.C
+///
+/// Macro to Setup OCDB
+/// This is just example macro
+/// \author marian.ivanov@cern.ch
+/// To be used:
+/// 1. Before invocation of the calibration - in the calibration trains
+/// 2. To setup calibration viewer.
+///
+/// ConfigOCDB - setup default and specific data storage
+/// SetupCustom - user sepcific configuration
+/// - Values in local cache of OCDB are overwritten
void SetupCustom(Int_t run);
void ConfigOCDB(Int_t crun=-1){
- //
+ ///
+
printf("SETUP OCBD for TPC\n");
//
AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
void SetupCustom(Int_t run){
- //
- //
- // Custom part - to be empty once we are happy with the calibration
- //
- //
- // Setup magnetic field
- //
+ /// Custom part - to be empty once we are happy with the calibration
+ ///
+ /// Setup magnetic field
+
AliGRPObject *grp = AliTPCcalibDB::GetGRP(run);
Float_t current = 0;
Float_t bz = 0;
-//
-// Macro to Setup OCDB
-// This is just example macro - using the alien OCDB
-// Responsible: marian.ivanov@cern.ch
-// To be used:
-// 1. Before invocation of the calibration - in the calibration trains
-// 2. To setup calibration viewer.
-//
-// ConfigOCDB - setup default and specific data storage
-// SetupCustom - user sepcific configuration
-// - Values in local cache of OCDB are overwritten
+/// \file ConfigOCDBAlien.C
+///
+/// Macro to Setup OCDB
+/// This is just example macro - using the alien OCDB
+/// \author marian.ivanov@cern.ch
+/// To be used:
+/// 1. Before invocation of the calibration - in the calibration trains
+/// 2. To setup calibration viewer.
+///
+/// ConfigOCDB - setup default and specific data storage
+/// SetupCustom - user sepcific configuration
+/// - Values in local cache of OCDB are overwritten
void SetupCustom(Int_t run);
void ConfigOCDBAlien(Int_t crun=-1){
- //
+ ///
+
TGrid * alien = TGrid::Connect("alien://",0,0,"t");
printf("SETUP OCBD for TPC\n");
//
void SetupCustom(Int_t run){
- //
- //
- // Custom part - to be empty once we are happy with the calibration
- //
- //
- // Setup magnetic field - In future this should be part of GRP functionality
- //
+ /// Custom part - to be empty once we are happy with the calibration
+ ///
+ /// Setup magnetic field - In future this should be part of GRP functionality
+
AliGRPObject *grp = AliTPCcalibDB::GetGRP(run);
Float_t current = 0;
Float_t bz = 0;
-/*
- Example macro to build AliTPCClusterParam
- postprocessing the output of the calibration using tracks
- In the future this macro will be part of the Preprocesor
- ..
+/// \file MakeClusterParam.C
+/// Example macro to build AliTPCClusterParam
+/// postprocessing the output of the calibration using tracks
+/// In the future this macro will be part of the Preprocesor
-*/
void StoreObject(AliTPCClusterParam *param);
void MakeClusterParam(const char *fnresolc="Output.root", const char *fnresolg="Output.root"){
void StoreObject(AliTPCClusterParam *clParam)
{
- //
- //
- //
+ ///
+
Int_t gkDummyRun = 0;
char *gCDBpath = "local://$ALICE_ROOT/OCDB";
AliCDBMetaData *md1= new AliCDBMetaData();
-/*
- .L $ALICE_ROOT/TPC/macros//MakeOCDBDiff.C
-*/
+/// \file MakeOCDBDiff.C
+///
+/// ~~~{.cpp}
+/// .L $ALICE_ROOT/TPC/macros//MakeOCDBDiff.C
+/// ~~~
Bool_t MakeOCDBDiff(const char *ocdb1, const char *ocdb2){
- //
- // Compare by by byte the content of the OCDB entry
- // Input parameters:
- // ocdb1 - path to the OCDB file1
- // ocdb2 - path to the OCDB file2
- // Return value:
- // kTRUE - in case the content of the OCDB object (persistent part) is exactly the same
- // kFALSE - othewise
+ /// Compare by by byte the content of the OCDB entry
+ /// Input parameters:
+ /// ocdb1 - path to the OCDB file1
+ /// ocdb2 - path to the OCDB file2
+ /// Return value:
+ /// kTRUE - in case the content of the OCDB object (persistent part) is exactly the same
+ /// kFALSE - othewise
+
/*
ocdb1="Run188720_192738_v2_s0.root"
ocdb1="Run0_188719_v2_s0.root"
-/****************************************************************************
- Macro to get the size of the Tree
- As a improvment to tree->Print() function, this algorithm
- gives the size of all of the branchces and in addition print them
- sorted according total tree size (MEMORY USAGE if one event in tree)
- or zip size (THE storage size on disk
+/// \file MakeTreeStat.C
+///
+/// Macro to get the size of the Tree
+/// As a improvment to tree->Print() function, this algorithm
+/// gives the size of all of the branchces and in addition print them
+/// sorted according total tree size (MEMORY USAGE if one event in tree)
+/// or zip size (THE storage size on disk)
+///
+/// Printed statistic:
+/// 1. Order
+/// 2. TotSize (in memory) + fraction of total size
+/// 3. ZipSize (in memory) + fraction of zip size
+/// 4. Compression ratio
+///
+/// Usage:
+///
+/// 1. Enable macro
+///
+/// ~~~
+/// .L $ALICE_ROOT/TPC/macros/MakeTreeStat.C+
+/// ~~~
+///
+/// 2. Open the tree (eg.)
+///
+/// ~~~{.cpp}
+/// TFile f("AliESDs.root");
+/// TTree * tree = (TTree*)f.Get("esdTree");
+/// ~~~
+///
+/// 3. Print statistic (sorting according secon argument - either zip Bytes (kTRUE or TotSize (kFALSE)
+///
+/// ~~~{.cpp}
+/// MakeStat(tree, kTRUE);
+/// ~~~
+///
+/// \author M.Ivanov, GSI, m.ivanov@gsi.de
- Printed statistic:
- 1. Order
- 2. TotSize (in memory) + fraction of total size
- 3. ZipSize (in memory) + fraction of zip size
- 4. Compression ratio
-
- Usage:
- // 1. Enable macro
- .L $ALICE_ROOT/TPC/macros/MakeTreeStat.C+
- // 2. Open the tree (eg.)
- TFile f("AliESDs.root");
- TTree * tree = (TTree*)f.Get("esdTree");
- // 3. Print statistic (sorting according secon argument - either zip Bytes (kTRUE or TotSize (kFALSE)
- MakeStat(tree, kTRUE);
-
- Origin: M.Ivanov, GSI, m.ivanov@gsi.de
-
-****************************************************************************/
void PrintSorted(Bool_t zipSort){
- //
- //print statistic
- //
+ /// print statistic
+
Int_t entries = aReport.GetEntries();
Int_t* indexes = new Int_t[entries];
if (zipSort) TMath::Sort(entries,zipSize.GetArray(),indexes,kTRUE);
void AddToReport(const char *prefix,const char * name, Float_t size[2], Float_t ratio){
- //
- // add branch info to array
- //
+ /// add branch info to array
+
char fullname[10000];
sprintf(fullname,"%s.%s",prefix,name);
aReport.AddLast(new TObjString(fullname));
void MakeStat(TTree *tree, Bool_t zipSort){
- //
- // make recursve loop over tree branches
- //
+ /// make recursve loop over tree branches
+
fTree= tree;
aReport.Clear();
TObjArray * array = tree->GetListOfBranches();
void MakeStat(const char *prefix, TBranch * branch, Float_t *size, Float_t mratio){
- //
- // Recursive function to get size of the branches
- // and ratios
- //
+ /// Recursive function to get size of the branches
+ /// and ratios
+
TObjArray * array = branch->GetListOfBranches();
Float_t bsizeSum[2]={0,0};
-/* ModifyRecoParamHLTUsage
- * Changes the Input for Reconstruction ( TPC RAW data or HLT TPC clusters )
- * 1 -> only TPC raw/sim data
- * 2 -> if present TPC raw/sim data, otherwise HLT clusters
- * 3 -> only HLT clusters
- * 4 -> if present HLT clusters, otherwise TPC raw/sim data
- *
- * Usage : aliroot -b -q ModifyRecoParamHLTUsage.C'("/lustre/alice/alien/alice/data/2011/OCDB/TPC/Calib/RecoParam/Run136844_999999999_v2_s0.root",3,"local:///tmp/ocdb/")'
- *
- */
+/// \file ModifyRecoParamHLTUsage.C
+///
+/// ModifyRecoParamHLTUsage
+/// Changes the Input for Reconstruction ( TPC RAW data or HLT TPC clusters )
+/// 1 -> only TPC raw/sim data
+/// 2 -> if present TPC raw/sim data, otherwise HLT clusters
+/// 3 -> only HLT clusters
+/// 4 -> if present HLT clusters, otherwise TPC raw/sim data
+///
+/// Usage:
+/// ~~~
+/// aliroot -b -q ModifyRecoParamHLTUsage.C'("/lustre/alice/alien/alice/data/2011/OCDB/TPC/Calib/RecoParam/Run136844_999999999_v2_s0.root",3,"local:///tmp/ocdb/")'
+/// ~~~
void ModifyRecoParamHLTUsage( const Char_t* lastOCDBEntry,
Int_t iHLTusage,
-/*
- Origin: marian.ivanov@cern.ch
- Make sys watch default plots (see $ALICE_ROOT/STEER/AliSysInfo.cxx):
- Input - syswatch.log - text log file created by process to be monitored
- Output - syswatch.root - root files with default histograms
- Number of top violators - only top consumer displayed
-
- Default histogram:
-
- TOP violateors - CPU and Virtual memory usage
- Detector reports - CPU and Virtual memory usage per detector
-
-
-
-
-
- Usage example:
- .x ~/rootlogon.C
- gROOT->LoadMacro("$ALICE_ROOT/macros/PlotSys.C+");
- MakePlots("syswatch.log","syswatch.root",10);
- TFile f("syswatch.root");
- TBrowser b;
-*/
+/// \file PlotSys.C
+/// \author marian.ivanov@cern.ch
+/// \brief Make sys watch default plots
+///
+/// See `$ALICE_ROOT/STEER/AliSysInfo.cxx`.
+/// Input - syswatch.log - text log file created by process to be monitored
+/// Output - syswatch.root - root files with default histograms
+/// Number of top violators - only top consumer displayed
+///
+/// Default histogram:
+///
+/// TOP violateors - CPU and Virtual memory usage
+/// Detector reports - CPU and Virtual memory usage per detector
+///
+///
+///
+///
+///
+/// Usage example:
+/// ~~~{.cpp}
+/// .x ~/rootlogon.C
+/// gROOT->LoadMacro("$ALICE_ROOT/macros/PlotSys.C+");
+/// MakePlots("syswatch.log","syswatch.root",10);
+/// TFile f("syswatch.root");
+/// TBrowser b;
+/// ~~~
#include "TMath.h"
#include "TH1F.h"
void TopCPUDetector();
void PInit(const char *log="syswatch.log", const char *out="syswatch.root"){
- //
- // Set Input output
- //
+ /// Set Input output
+
tree = AliSysInfo::MakeTree(log);
fout = new TFile(out,"recreate");
}
void MakePlots(const char *log="syswatch.log", const char *out="syswatch.root", Int_t top=10){
- //
- //
- //
+ ///
+
ctop=top;
PInit(log,out);
gStyle->SetOptStat(0);
}
void TopVM(){
- //
- // select top user of virtual Memory
- // MakeReport - ASCII and histogram
- //
+ /// select top user of virtual Memory
+ /// MakeReport - ASCII and histogram
+
TH1 * his=0;
TH2 * his2=0;
Float_t thVM = TopUsage(tree,"deltaVM","",ctop);
}
void TopCPU(){
- //
- // select top user of CPU
- // MakeReport - ASCII and histogram
- //
+ /// select top user of CPU
+ /// MakeReport - ASCII and histogram
+
TH2 * his2=0;
Float_t thDT = TopUsage(tree,"deltaT","id2<3",ctop);
cutDT = TCut("cutDT",Form("deltaT>%f",thDT));
void TopVMDetector(){
- //
- // Draw usage of VM
- //
+ /// Draw usage of VM
+
TH2 * his2=0;
//
//
void TopCPUDetector(){
- //
- // Draw usage of CPU
- //
+ /// Draw usage of CPU
+
TH2 * his2=0;
//
//
Float_t TopUsage(TTree* tree, const char *exp, const char*cut, Int_t order){
- //
- //
- // Find value for given order
- // Used to select top violator
- //
+ /// Find value for given order
+ /// Used to select top violator
+
Int_t entries = tree->Draw(Form("%s>>hhh1",exp),cut,"goff");
if (entries<=1) {
if (tree->GetHistogram()) delete tree->GetHistogram();
-/*
- Example usage:
-
- 0. Load neccessary libraries
-
- gSystem->Load("libANALYSIS");
- gSystem->Load("libANALYSISalice");
- gSystem->Load("libTPCcalib");
- gSystem->Load("libXrdClient");
- gSystem->Load("libNetx");
- TGrid::Connect("alien://",0,0,"t");
- gSystem->Load("$ROOTSYS/lib/libXrdClient");
- //
- // 1. Make list of the files
- //
- .L $ALICE_ROOT/TPC/macros/testTPC/AlienToolkit.cxx+
- gSystem->Load("libXrdClient");
- gSystem->Load("libNetx");
- AlienToolkit toolkit;
- char *path = "/alice/cern.ch/user/a/amatyja/alice/data/"
- toolkit.MakeCollection(path,"32129*Krypton.root");
- toolkit.MakeCollection(path,"32231*Krypton.root");
- toolkit.MakeCollection(path,"32284*Krypton.root");
- toolkit.PrintPFN(); > list.txt
-
- //
- // 2. Initialization of proof
- //
- TProofMgr * proofmgr = TProof::Mgr("lxgrid5.gsi.de");
- TProof * proof = proofmgr->CreateSession();
- proof->SetParameter("PROOF_MaxSlavesPerNode", (Long_t)1000);
- .L /u/miranov/macros/ProofEnableAliRoot.C
- ProofEnableAliRoot("/usr/local/grid/AliRoot/HEAD0108");
- gProof->Exec("gSystem->Load(\"libANALYSIS\")",kTRUE);
- gProof->Exec("gSystem->Load(\"libSTAT\")",kTRUE);
- gProof->Exec("gSystem->Load(\"libTPCcalib\")",kTRUE);
- gProof->Exec(".x $ALICE_ROOT/TPC/macros/ConfigOCDB.C");
-
- //
- // 3 Run analysis on PROOF
- //
- //
- // Create chain of input files
- //
- gSystem->AddIncludePath("-I$ALICE_ROOT/TPC/macros");
- gROOT->LoadMacro("$ALICE_ROOT/TPC/macros/AliXRDPROOFtoolkit.cxx+");
- .L $ALICE_ROOT/TPC/macros/RunAliTPCCalibKrTask.C
- RunAliTPCCalibKrTask(kTRUE);
-
-
- //
- // Check the cuts for clusters
- //
- AliXRDPROOFtoolkit tool;
- TChain * chain = tool.MakeChain("list.txt","Kr",0,1000);
- chain->Lookup();
- chain->SetProof(kTRUE);
-
- TCut cutR0("cutR0","fADCcluster/fSize<200"); // adjust it according v seetings -
- TCut cutR1("cutR1","fADCcluster/fSize>7"); // cosmic tracks and noise removal
- TCut cutR2("cutR2","fMax.fAdc/fADCcluster<0.4"); // digital noise removal
- TCut cutR3("cutR3","fMax.fAdc/fADCcluster>0.01"); // noise removal
- TCut cutR4("cutR4","fMax.fTime>200"); // noise removal
- TCut cutR5("cutR5","fMax.fTime<600"); // noise removal
- TCut cutS1("cutS1","fSize<200"); // adjust it according v seetings - cosmic tracks
- TCut cutAll = cutR0+cutR1+cutR2+cutR3+cutR4+cutR5+cutS1;
-
-
-
-
- //..
- //
- //
-
- //Example usage
- TFile f("KrHisto.root");
- AliTPCCalibKr *kr = f.Get("AliTPCCalibKr");
-
- kr->ProjectHisto(kr->GetHistoKr(71),"aaa",30,36,30,40)->Draw()
- //
- //
- //
- MakeTree();
- //default cuts
- TCut cutKr("cutKr","entries.fElements<5000&&fitNormChi2.fElements<3&&fitNormChi2.fElements>0.2&&abs(fitRMS.fElements/fitMean.fElements-0.06)<0.025");
-
-TObjArray * array = AliTPCCalibViewerGUI::ShowGUI("kryptonTree.root");
-AliTPCCalibViewerGUI * viewer = (AliTPCCalibViewerGUI*)array->At(0);
-TTree * tree = viewer->GetViewer()->GetTree();
-
-tree->SetAlias("cutAll","abs(fitNormChi2.fElements-2.)<1.8&&entries.fElements/entries_Median.fElements<4&&entries.fElements/entries_Median.fElements>0.4&&fitRMS.fElements/fitMean.fElements<0.09&&fitRMS.fElements/fitMean.fElements>0.02")
-
-*/
+/// \file RunAliTPCCalibKrTask.C
+///
+/// Example usage:
+///
+/// 0. Load neccessary libraries
+///
+/// ~~~{.cpp}
+/// gSystem->Load("libANALYSIS");
+/// gSystem->Load("libANALYSISalice");
+/// gSystem->Load("libTPCcalib");
+/// gSystem->Load("libXrdClient");
+/// gSystem->Load("libNetx");
+/// TGrid::Connect("alien://",0,0,"t");
+/// gSystem->Load("$ROOTSYS/lib/libXrdClient");
+/// ~~~
+///
+/// 1. Make list of the files
+///
+/// ~~~{.cpp}
+/// .L $ALICE_ROOT/TPC/macros/testTPC/AlienToolkit.cxx+
+/// gSystem->Load("libXrdClient");
+/// gSystem->Load("libNetx");
+/// AlienToolkit toolkit;
+/// char *path = "/alice/cern.ch/user/a/amatyja/alice/data/"
+/// toolkit.MakeCollection(path,"32129*Krypton.root");
+/// toolkit.MakeCollection(path,"32231*Krypton.root");
+/// toolkit.MakeCollection(path,"32284*Krypton.root");
+/// toolkit.PrintPFN(); > list.txt
+/// ~~~
+///
+/// 2. Initialization of proof
+///
+/// ~~~{.cpp}
+/// TProofMgr * proofmgr = TProof::Mgr("lxgrid5.gsi.de");
+/// TProof * proof = proofmgr->CreateSession();
+/// proof->SetParameter("PROOF_MaxSlavesPerNode", (Long_t)1000);
+/// .L /u/miranov/macros/ProofEnableAliRoot.C
+/// ProofEnableAliRoot("/usr/local/grid/AliRoot/HEAD0108");
+/// gProof->Exec("gSystem->Load(\"libANALYSIS\")",kTRUE);
+/// gProof->Exec("gSystem->Load(\"libSTAT\")",kTRUE);
+/// gProof->Exec("gSystem->Load(\"libTPCcalib\")",kTRUE);
+/// gProof->Exec(".x $ALICE_ROOT/TPC/macros/ConfigOCDB.C");
+/// ~~~
+///
+/// 3. Run analysis on PROOF
+///
+/// ~~~{.cpp}
+/// // Create chain of input files
+/// gSystem->AddIncludePath("-I$ALICE_ROOT/TPC/macros");
+/// gROOT->LoadMacro("$ALICE_ROOT/TPC/macros/AliXRDPROOFtoolkit.cxx+");
+/// .L $ALICE_ROOT/TPC/macros/RunAliTPCCalibKrTask.C
+/// RunAliTPCCalibKrTask(kTRUE);
+///
+/// // Check the cuts for clusters
+/// AliXRDPROOFtoolkit tool;
+/// TChain * chain = tool.MakeChain("list.txt","Kr",0,1000);
+/// chain->Lookup();
+/// chain->SetProof(kTRUE);
+///
+/// TCut cutR0("cutR0","fADCcluster/fSize<200"); // adjust it according v seetings -
+/// TCut cutR1("cutR1","fADCcluster/fSize>7"); // cosmic tracks and noise removal
+/// TCut cutR2("cutR2","fMax.fAdc/fADCcluster<0.4"); // digital noise removal
+/// TCut cutR3("cutR3","fMax.fAdc/fADCcluster>0.01"); // noise removal
+/// TCut cutR4("cutR4","fMax.fTime>200"); // noise removal
+/// TCut cutR5("cutR5","fMax.fTime<600"); // noise removal
+/// TCut cutS1("cutS1","fSize<200"); // adjust it according v seetings - cosmic tracks
+/// TCut cutAll = cutR0+cutR1+cutR2+cutR3+cutR4+cutR5+cutS1;
+///
+/// // Example usage
+/// TFile f("KrHisto.root");
+/// AliTPCCalibKr *kr = f.Get("AliTPCCalibKr");
+///
+/// kr->ProjectHisto(kr->GetHistoKr(71),"aaa",30,36,30,40)->Draw()
+///
+/// MakeTree();
+///
+/// //default cuts
+/// TCut cutKr("cutKr","entries.fElements<5000&&fitNormChi2.fElements<3&&fitNormChi2.fElements>0.2&&abs(fitRMS.fElements/fitMean.fElements-0.06)<0.025");
+///
+/// TObjArray * array = AliTPCCalibViewerGUI::ShowGUI("kryptonTree.root");
+/// AliTPCCalibViewerGUI * viewer = (AliTPCCalibViewerGUI*)array->At(0);
+/// TTree * tree = viewer->GetViewer()->GetTree();
+///
+/// tree->SetAlias("cutAll","abs(fitNormChi2.fElements-2.)<1.8&&entries.fElements/entries_Median.fElements<4&&entries.fElements/entries_Median.fElements>0.4&&fitRMS.fElements/fitMean.fElements<0.09&&fitRMS.fElements/fitMean.fElements>0.02")
+/// ~~~
TChain * chain = 0;
void RunAliTPCCalibKrTask(Bool_t bProof = kFALSE)
{
- //
- AliXRDPROOFtoolkit tool;
+ ///
+
+ AliXRDPROOFtoolkit tool;
chain = tool.MakeChain("list.txt","Kr","",20000,0);
chain->Lookup();
- chain->SetBranchStatus("Cl.fCluster",kFALSE);
-
+ chain->SetBranchStatus("Cl.fCluster",kFALSE);
+
//
// Create the analysis manager
//
AliAnalysisManager *mgr = new AliAnalysisManager("testAnalysis");
- // Calibration component
+ // Calibration component
AliTPCCalibKr *calibObj = new AliTPCCalibKr;
//calibObj->SetASide(kFALSE);
- // Add task
+ // Add task
AliTPCCalibKrTask *task = new AliTPCCalibKrTask;
task->SetInputChain(chain);
task->SetTPCCalibKr(calibObj);
- mgr->AddTask(task);
+ mgr->AddTask(task);
// Attach input
cInput = mgr->CreateContainer("cInput", TChain::Class(), AliAnalysisManager::kInputContainer);
if (!mgr->InitAnalysis()) return;
mgr->PrintStatus();
mgr->SetDebugLevel(1);
-
+
if(bProof) {
mgr->StartAnalysis("proof", chain);
}
void MakeTree(){
TFile fpad("calibKr.root");
- AliTPCPreprocessorOnline * preprocesor = new AliTPCPreprocessorOnline;
+ AliTPCPreprocessorOnline * preprocesor = new AliTPCPreprocessorOnline;
preprocesor->AddComponent(spectrMean->Clone());
preprocesor->AddComponent(spectrRMS->Clone());
preprocesor->AddComponent(fitMean->Clone());
preprocesor->AddComponent(fitNormChi2->Clone());
preprocesor->AddComponent(entries->Clone());
preprocesor->DumpToFile("kryptonTree.root");
-
+
}
-/*
-
-.L $ALICE_ROOT/TPC/macros/TTreeSelection.cxx++
-
-TFile f("eveTree.root");
-Tracks;
-
-TTreeDraw draw("draw",Tracks);
-draw.AddSelection("TPC clusters","Tr.fTPCncls>0");
-draw.AddSelection("TRD clusters","Tr.fTRDncls>0");
-
-*/
+/// \class TTreeSelection
+///
+/// ~~~{.cpp}
+/// .L $ALICE_ROOT/TPC/macros/TTreeSelection.cxx++
+///
+/// TFile f("eveTree.root");
+/// Tracks;
+///
+/// TTreeDraw draw("draw",Tracks);
+/// draw.AddSelection("TPC clusters","Tr.fTPCncls>0");
+/// draw.AddSelection("TRD clusters","Tr.fTRDncls>0");
+/// ~~~
#include "TMath.h"
#include "TFile.h"
class TTreePoint: public TNamed{
-public:
+public:
TTreePoint();
TTreePoint(const char *alias, const char * px, const char * py, const char *pz, Int_t mColor, Int_t mSize, Int_t mType);
// TString GetSelection();
public:
- TString fPx; // point X
- TString fPy; // point Y
- TString fPz; // point Z
- Int_t fMColor; //color
- Int_t fMSize; //marker size
- Int_t fMType; //marker type
- Bool_t fIsOn; //is On
+ TString fPx; ///< point X
+ TString fPy; ///< point Y
+ TString fPz; ///< point Z
+ Int_t fMColor; ///< color
+ Int_t fMSize; ///< marker size
+ Int_t fMType; ///< marker type
+ Bool_t fIsOn; ///< is On
ClassDef(TTreePoint,1)
};
class TTreeCutAtom: public TNamed{
-public:
+public:
enum ExprType { kBool=0, kInt=1, kRange=2};
TTreeCutAtom();
TTreeCutAtom(const char *alias, const char *expr, ExprType type, Double_t val0, Double_t val1=0);
TString GetSelection();
public:
- Double_t fInt0; // interval value 0
- Double_t fInt1; // interval value 1
- Double_t fVal0; // selection value 0
- Double_t fVal1; // selection value 1
- ExprType fType; // selection type
+ Double_t fInt0; ///< interval value 0
+ Double_t fInt1; ///< interval value 1
+ Double_t fVal0; ///< selection value 0
+ Double_t fVal1; ///< selection value 1
+ ExprType fType; ///< selection type
ClassDef(TTreeCutAtom,1)
};
void AddDraw(const char *alias, const char * px, const char * py, const char *pz, Int_t mColor, Int_t mSize, Int_t mType);
// TGCompositeFrame * MakeFrame();
public:
- TTree * fTree; // tree
- TObjArray fCutAtoms; // array of axpressions
- TObjArray fDraws; // array of draw experssions
-private:
+ TTree * fTree; ///< tree
+ TObjArray fCutAtoms; ///< array of axpressions
+ TObjArray fDraws; ///< array of draw experssions
+private:
TTreeDraw();
ClassDef(TTreeDraw,1)
};
ClassImp(TTreePoint)
ClassImp(TTreeCutAtom)
+/// \cond CLASSIMP
ClassImp(TTreeDraw)
+/// \endcond
-TTreePoint::TTreePoint():
+TTreePoint::TTreePoint():
TNamed(),
fPx(), // point X
fPy(), // point Y
fPz(), // point Z
fMColor(1), //color
fMSize(1), //marker size
- fMType(22), //marker type
- fIsOn(kTRUE) //is On
+ fMType(22), //marker type
+ fIsOn(kTRUE) //is On
{
}
TTreePoint::TTreePoint(const char *alias, const char * px, const char * py, const char *pz, Int_t mColor, Int_t mSize, Int_t mType)
-:
+:
TNamed(alias,alias),
fPx(px), // point X
fPy(py), // point Y
fPz(pz), // point Z
fMColor(mColor), //color
fMSize(mSize), //marker size
- fMType(mType), //marker type
- fIsOn(kTRUE) //is On
+ fMType(mType), //marker type
+ fIsOn(kTRUE) //is On
{
}
{
//
//
- //
+ //
}
TTreeCutAtom::TTreeCutAtom(const char *alias, const char *expr, ExprType type, Double_t val0, Double_t val1):
{
//
//
- //
+ //
}
TString TTreeCutAtom::GetSelection(){
//
- //
+ //
//
TString str;
char command[1000];
if (fType==kBool) str = fTitle;
if (fType==kInt){
- sprintf(command,"(%s==%d)",GetTitle(), TMath::Nint(fVal0));
+ sprintf(command,"(%s==%d)",GetTitle(), TMath::Nint(fVal0));
str = command;
}
if (fType==kRange){
- sprintf(command,"((%s>%f) &&(%s<%f))",GetTitle(), fVal0,GetTitle(),fVal1);
+ sprintf(command,"((%s>%f) &&(%s<%f))",GetTitle(), fVal0,GetTitle(),fVal1);
str = command;
}
return str;
}
-
+
TTreeDraw::TTreeDraw():
TNamed(),
void TTreeDraw::AddSelectionRange(const char *alias, const char*expr, Float_t min, Float_t max){
//
//
- //
+ //
TTreeCutAtom * atom = new TTreeCutAtom(alias,expr,TTreeCutAtom::kRange,min,max);
fCutAtoms.AddLast(atom);
}
-/*
- Simple test of the V0 finder
- //
- //0. Setup memory chcecker if you want
- //
- gSystem->Load("$ROOTSYS/lib/libGui");
- gSystem->Load("$ROOTSYS/lib/libTree");
- gSystem->Load("$MEMSTAT/libMemStat");
- TMemStat *memstat = new TMemStat(100000000,10000000,kTRUE);
- AliSysInfo::AddCallBack(TMemStatManager::GetInstance()->fStampCallBack);
- AliSysInfo::AddStamp("Start");
- //
-
- //1. Load needed libraries
- gSystem->Load("libANALYSIS");
- gSystem->Load("libTPCcalib");
- //
- // Setup analysis manager
- //
- .L $ALICE_ROOT/TPC/macros/CalibrateTPC.C
- AliAnalysisManager * mgr = SetupCalibTask();
- //
- // Process data - chain
- //
- gSystem->AddIncludePath("-I$ALICE_ROOT/TPC/macros");
- gROOT->LoadMacro("$ALICE_ROOT/TPC/macros/AliXRDPROOFtoolkit.cxx+")
- AliXRDPROOFtoolkit tool;
- TChain * chain = tool.MakeChain("esd.txt","esdTree",0,50000);
- chain->Lookup();
- // memory
- mgr->SetNSysInfo(100);
- //
- mgr->SetDebugLevel(1);
- mgr->StartAnalysis("proof",chain);
- //mgr->StartAnalysis("local",chain);
- // delete manager
- //
- delete mgr;
- AliSysInfo::AddStamp("End");
- //
- // analyze memstat report
- //
- delete memstat;
- TMemStat draw("memstat.root");
- draw.MakeReport(0,0,"order 0 sortstat 3 sortstamp 0 sortdeep 10 stackdeep 15 maxlength 50")
-*/
-
+/// \file TestV0.C
+/// \brief Simple test of the V0 finder
+///
+/// 0. Setup memory chcecker if you want
+///
+/// ~~~{.cpp}
+/// gSystem->Load("$ROOTSYS/lib/libGui");
+/// gSystem->Load("$ROOTSYS/lib/libTree");
+/// gSystem->Load("$MEMSTAT/libMemStat");
+/// TMemStat *memstat = new TMemStat(100000000,10000000,kTRUE);
+/// AliSysInfo::AddCallBack(TMemStatManager::GetInstance()->fStampCallBack);
+/// AliSysInfo::AddStamp("Start");
+/// ~~~
+///
+/// 1. Load needed libraries
+///
+/// ~~~{.cpp}
+/// gSystem->Load("libANALYSIS");
+/// gSystem->Load("libTPCcalib");
+/// ~~~
+///
+/// 2. Setup analysis manager
+///
+/// ~~~{.cpp}
+/// .L $ALICE_ROOT/TPC/macros/CalibrateTPC.C
+/// AliAnalysisManager * mgr = SetupCalibTask();
+/// ~~~
+///
+/// 3. Process data - chain
+///
+/// ~~~{.cpp}
+/// gSystem->AddIncludePath("-I$ALICE_ROOT/TPC/macros");
+/// gROOT->LoadMacro("$ALICE_ROOT/TPC/macros/AliXRDPROOFtoolkit.cxx+")
+/// AliXRDPROOFtoolkit tool;
+/// TChain * chain = tool.MakeChain("esd.txt","esdTree",0,50000);
+/// chain->Lookup();
+/// // memory
+/// mgr->SetNSysInfo(100);
+///
+/// mgr->SetDebugLevel(1);
+/// mgr->StartAnalysis("proof",chain);
+/// //mgr->StartAnalysis("local",chain);
+/// // delete manager
+///
+/// delete mgr;
+/// AliSysInfo::AddStamp("End");
+///
+/// // analyze memstat report
+///
+/// delete memstat;
+/// TMemStat draw("memstat.root");
+/// draw.MakeReport(0,0,"order 0 sortstat 3 sortstamp 0 sortdeep 10 stackdeep 15 maxlength 50")
+/// ~~~
AliAnalysisManager * SetupV0Task() {
- //
- //
- //
+ ///
+
TStopwatch stopwatch;
stopwatch.Start();
//
AliESDInputHandler* esdH=new AliESDInputHandler;
esdH->SetActiveBranches("ESDfriend");
- mgr->SetInputEventHandler(esdH);
+ mgr->SetInputEventHandler(esdH);
//
//
AliCDBManager::Instance()->SetRun(1) ;
AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
AliTPCAnalysisTaskcalib *task1=new AliTPCAnalysisTaskcalib("TPC calibration task");
-
+
AliTPCcalibTracksCuts *cuts = new AliTPCcalibTracksCuts(20, 0.4, 0.5, 0.13, 0.018);
//
calibV0->SetDebugLevel(20);
calibV0->SetStreamLevel(2);
//
-
+
task1->AddJob(calibV0);
-
+
TString path=gSystem->pwd();
path+="/V0/";
gSystem->mkdir(path);
mgr->ConnectOutput(task1,0,coutput1);
if (!mgr->InitAnalysis()) return;
- mgr->PrintStatus();
-
+ mgr->PrintStatus();
+
stopwatch.Stop();
stopwatch.Print();
return mgr;
-//
+/// \file filterESD.C
+
void filterESD(){
//
//
-/*
- Small macro to show perforamance of the gain calibration
- tHe list of the files with tpc calib tracks is supposed to be in cosmic.txt file
- Supposing the
-
-
- gSystem->Load("libSTAT")
- .x ~/rootlogon.C
- .L $ALICE_ROOT/TPC/macros/AliXRDPROOFtoolkit.cxx+
- AliXRDPROOFtoolkit tool;
- //gSystem->Load("/usr/local/grid/XRootd/GSI/lib/libXrdClient");
- //TProof * proof = TProof::Open("miranov@lxgrid2.gsi.de");
-
-*/
+/// \file gainCalib.C
+/// \brief Small macro to show perforamance of the gain calibration
+///
+/// The list of the files with tpc calib tracks is supposed to be in cosmic.txt file
+///
+/// ~~~{.cpp}
+/// gSystem->Load("libSTAT")
+/// .x ~/rootlogon.C
+/// .L $ALICE_ROOT/TPC/macros/AliXRDPROOFtoolkit.cxx+
+/// AliXRDPROOFtoolkit tool;
+/// gSystem->Load("/usr/local/grid/XRootd/GSI/lib/libXrdClient");
+/// TProof * proof = TProof::Open("miranov@lxgrid2.gsi.de");
+/// ~~~
TChain * chain = 0;
TChain * chaing = 0;
void MakePlotsTY(){
- //
- //
- //
+ ///
+
chain->Draw("dedxQ.fElements[2]:ty>>hisQ_ty(20,0,1.5)","IPad==0&&P>1","prof*",1000000);
chain->Draw("dedxQ.fElements[2]/corrg:ty>>hisQ_ty_corrg(20,0,1.5)","IPad==0&&P>1","prof*",1000000);
chain->Draw("dedxQ.fElements[2]/AliTPCClusterParam::SQnorm(0,0,dr,ty,tz):ty>>hisQ_ty_corrcal(20,0,1.5)","IPad==0&&P>1","prof*",1000000);
void MakePlotsTZ(){
- //
- //
- //
+ ///
+
chain->Draw("dedxQ.fElements[2]:tz>>hisQ_tz(20,0,1.5)","IPad==0&&P>1","prof*",1000000);
chain->Draw("dedxQ.fElements[2]/corrg:tz>>hisQ_tz_corrg(20,0,1.5)","IPad==0&&P>1","prof*",1000000);
chain->Draw("dedxQ.fElements[2]/AliTPCClusterParam::SQnorm(0,0,dr,ty,tz):tz>>hisQ_tz_corrcal(20,0,1.5)","IPad==0&&P>1","prof*",1000000);
}
void MakePlotsDR(){
- //
- //
- //
+ ///
+
chain->Draw("dedxQ.fElements[2]:dr>>hisQ_dr(20,0,1.)","IPad==0&&P>1","prof*",1000000);
chain->Draw("dedxQ.fElements[2]/corrg:dr>>hisQ_dr_corrg(20,0,1.)","IPad==0&&P>1","prof*",1000000);
chain->Draw("dedxQ.fElements[2]/AliTPCClusterParam::SQnorm(0,0,dr,ty,dr):dr>>hisQ_dr_corrcal(20,0,1.)","IPad==0&&P>1","prof*",1000000);
void MakePlotsQ(){
- //
- //
- //
- //
+ ///
+
chaing->Draw("Track.fdEdx>>his0dedx(100,0,200)","Track.fN>100&&abs(Track.P()-15)<3","",20000);
chaing->Draw("Track.CookdEdxNorm(0.02,0.6,0,0,160)/3.71>>his0dedxnormQ(100,0,200)","Track.fN>100&&abs(Track.P()-15)<3","",20000);
TH1F * his0dedx = gROOT->FindObject("his0dedx");
+/// \file printCalibObjectsInfo.C
+
printCalibObjectsInfo(const char* filename="CalibObjects.root")
{
gROOT->Macro("$ALICE_ROOT/PWGPP/CalibMacros/CPass0/LoadLibraries.C");
+/// \file recMag5.C
+
void recMag5(const char *filename="data.root")
{
- /////////////////////////////////////////////////////////////////////////////////////////
- //
- // First version of the reconstruction
- // script for the FDR'08
+ /// First version of the reconstruction
+ /// script for the FDR'08
// Set the CDB storage location
// AliLog::SetModuleDebugLevel("STEER",2);
+/// \file setNominalVoltagesInAliTPCParam.C
+
void setNominalVoltagesInAliTPCParam()
{
//LHC11h
-/*
- Simple macro to make pedstal calibration
- and visualize calibration data
-
- .L $ALICE_ROOT/TPC/macros/testDataQA.C
-
-*/
-
-
-
+/// \file testDataQA.C
+///
+/// Simple macro to make pedstal calibration
+/// and visualize calibration data
+///
+/// ~~~
+/// .L $ALICE_ROOT/TPC/macros/testDataQA.C
+/// ~~~
void testDataQA(Char_t *fileName, Int_t maxevent=10)
{
AliRawReaderRoot *rawReader = new AliRawReaderRoot(fileName);
if ( !rawReader ) return;
- AliTPCdataQA *calib = new AliTPCdataQA;
- AliTPCdataQA *calibFast = new AliTPCdataQA;
+ AliTPCdataQA *calib = new AliTPCdataQA;
+ AliTPCdataQA *calibFast = new AliTPCdataQA;
calib->SetRangeTime(1,1000);
calibFast->SetRangeTime(1,1000);
printf("Processing data\n");
TFile file2("dataQATestAnalyse.root");
AliTPCdataQA* cal = (AliTPCdataQA*)file2.Get("AliTPCdataQA");
AliTPCdataQA* calFast = (AliTPCdataQA*)file2.Get("AliTPCdataQAFast");
-
+
AliTPCPreprocessorOnline preprocesor;
preprocesor.AddComponent(cal->GetNoThreshold());
preprocesor.AddComponent(cal->GetOverThreshold10());
preprocesor.AddComponent(calNTime );
preprocesor.AddComponent(calNPad );
preprocesor.AddComponent(calTimePos );
-
+
preprocesor.DumpToFile("CalibTreeTestAnalyse.root");
AliTPCCalibViewerGUI::ShowGUI("CalibTreeTestAnalyse.root");
}
-/*
- Simple macro to make pedstal calibration
- and visualize calibration data
-
-*/
-
-
-
+/// \file testPed.C
+///
+/// Simple macro to make pedstal calibration
+/// and visualize calibration data
void testPed(Char_t *fileName)
{
calib->DumpToFile("PedestalData.root");
delete rawReader;
delete calib;
-
+
//
TFile f("PedestalData.root");
AliTPCCalibPedestal* ped = (AliTPCCalibPedestal*)f.Get("AliTPCCalibPedestal");
void testPed0(Char_t *fileName)
{
- //
- //
- //
+ ///
+
AliRawReaderRoot *rawReader = new AliRawReaderRoot(fileName);
if ( !rawReader ) return;
- AliTPCCalibPedestal *calib = new AliTPCCalibPedestal;
+ AliTPCCalibPedestal *calib = new AliTPCCalibPedestal;
printf("Processing data\n");
Int_t event=0;
while (rawReader->NextEvent()){
- calib->ProcessEvent(rawReader);
+ calib->ProcessEvent(rawReader);
printf("Processing event\t%d\n",event);
event++;
}
- calib->Analyse();
+ calib->Analyse();
//
AliTPCCalPad * pad0 = new AliTPCCalPad(calib->GetCalPadRMS());
AliTPCCalPad * pad1 = new AliTPCCalPad(calib->GetCalPadPedestal());
+/// \file tpc_tracks.C
+
class TEveProjectionManager;
class TEveGeoShape;
void tpc_tracks(const char *input=0)
{
- //
- //
- //
+ ///
+
if (input){
TString ipath(input);
if (ipath.Contains(".zip")){
@CMAKE_SOURCE_DIR@/TPC/Cal \
@CMAKE_SOURCE_DIR@/TPC/CalibMacros \
@CMAKE_SOURCE_DIR@/TPC/DA \
- @CMAKE_SOURCE_DIR@/TPC/fastSimul
+ @CMAKE_SOURCE_DIR@/TPC/fastSimul \
+ @CMAKE_SOURCE_DIR@/TPC/macros
# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses