]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AlirootRun_MUONtest.sh
Updated list of MUON libraries
[u/mrichter/AliRoot.git] / MUON / AlirootRun_MUONtest.sh
CommitLineData
fa701981 1#!/bin/sh
2# $Id$
3bc0b4a4 3# with galice.root, galice_sim.root
fa701981 4
5CURDIR=`pwd`
6OUTDIR=test_out
7
8rm -fr $OUTDIR
9mkdir $OUTDIR
7430be1c 10cp $ALICE_ROOT/MUON/.rootrc $ALICE_ROOT/MUON/rootlogon.C $OUTDIR
fa701981 11cd $OUTDIR
12
3c465f70 13RUN=0
7430be1c 14FULLPATH="$CURDIR/$OUTDIR"
e40c984d 15NEVENTS=100
b7368825 16SEED=1234567
17
fa701981 18echo "Running simulation ..."
19
7430be1c 20aliroot -b >& testSim.out << EOF
f6d516e9 21// Uncoment following lines to run simulation with local residual mis-alignment
22// (generated via MUONGenerateGeometryData.C macro)
23// AliCDBManager* man = AliCDBManager::Instance();
24// man->SetDefaultStorage("local://$ALICE_ROOT");
0d24599f 25// man->SetSpecificStorage("MUON/Align/Data","local://$ALICE_ROOT/MUON/ResMisAlignCDB");
b7368825 26gRandom->SetSeed($SEED);
3c465f70 27AliCDBManager::Instance()->SetRun($RUN);
7430be1c 28AliSimulation MuonSim("$ALICE_ROOT/MUON/Config.C");
10c8d1ce 29MuonSim.SetMakeTrigger("MUON");
3bc0b4a4 30// MuonSim.SetWriteRawData("MUON","raw.root");
7430be1c 31MuonSim.SetWriteRawData("MUON");
5c6f99c2 32MuonSim.Run($NEVENTS);
fa701981 33.q
34EOF
35
7aef07e5 36echo "Removing Digits files ..."
37mkdir MUON.Digits
38mv MUON.Digits*.root MUON.Digits/
3bc0b4a4 39mv galice.root MUON.Digits/
7aef07e5 40
fa701981 41echo "Running reconstruction ..."
42
43aliroot -b >& testReco.out << EOF
3c465f70 44AliCDBManager::Instance()->SetRun($RUN);
7430be1c 45gRandom->SetSeed($SEED);
bd0cb923 46AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 1, 1., 10., AliMagFMaps::k5kG);
b6675e8f 47AliTracker::SetFieldMap(field, kFALSE);
5c6f99c2 48AliReconstruction MuonRec("galice.root");
7430be1c 49MuonRec.SetInput("$FULLPATH/");
5c6f99c2 50MuonRec.SetRunVertexFinder(kFALSE);
51MuonRec.SetRunLocalReconstruction("MUON");
196471e9 52MuonRec.SetRunTracking("MUON");
5c6f99c2 53MuonRec.SetFillESD("MUON");
de2cd600 54MuonRec.SetLoadAlignData("MUON");
3bc0b4a4 55MuonRec.SetNumberOfEventsPerFile($NEVENTS);
de2cd600 56// Uncoment following line to run reconstruction with the orginal tracking method
57// instead of the kalman one (default)
8dc57946 58//MuonRec.SetOption("MUON","Original");
5c31bbf9 59// Use the following to change clustering method
ee103e97 60//MuonRec.SetOption("MUON","MLEM"); // new scheme AZs clustering
5c31bbf9 61//MuonRec.SetOption("MUON","SIMPLEFIT"); // new scheme simple fitting
62//MuonRec.SetOption("MUON","COG"); // new scheme basic center-of-gravity only
ee103e97 63// Use the following to disconnect the status map creation (only for debug!)
64// as this speeds up startup a bit...
65//MuonRec.SetOption("MUON","NOSTATUSMAP");
7771752e 66// Use the following to write to disk the digits (from raw data)
67//MuonRec.SetOption("MUON","SAVEDIGITS");
7430be1c 68MuonRec.Run();
fa701981 69.q
70EOF
71
7771752e 72if [ ! -e MUON.Digits.root ]; then
73 echo "Moving Digits files back ..."
74 mv MUON.Digits/MUON.Digits.root .
75fi
3bc0b4a4 76mv MUON.Digits/galice.root ./galice_sim.root
8dc57946 77
858e5b75 78echo "Running Trigger efficiency ..."
858e5b75 79aliroot -b >& testTriggerResults.out << EOF
5c6f99c2 80.L $ALICE_ROOT/MUON/MUONTriggerEfficiency.C+
3bc0b4a4 81MUONTriggerEfficiency("galice_sim.root", "galice.root", 1);
858e5b75 82.q
83EOF
84
72a7d831 85echo "Running efficiency ..."
fa701981 86
87aliroot -b >& testResults.out << EOF
5c6f99c2 88.L $ALICE_ROOT/MUON/MUONefficiency.C+
72a7d831 89// no argument assumes Upsilon but MUONefficiency(443) works on Jpsi
3bc0b4a4 90MUONefficiency("galice_sim.root");
fa701981 91.q
92EOF
93
8dc57946 94echo "Running check ..."
5c6f99c2 95
8dc57946 96aliroot -b >& testCheck.out << EOF
97gSystem->Load("libMUONevaluation");
5c6f99c2 98.L $ALICE_ROOT/MUON/MUONCheck.C+
3bc0b4a4 99MUONCheck(0, 9, "galice_sim.root", "galice.root", "AliESDs.root");
5c6f99c2 100.q
7430be1c 101EOF
858e5b75 102
8dc57946 103echo "Running dumps for selected event (5) ..."
104
3bc0b4a4 105aliroot -b << EOF
106AliMUONSimData simData("galice_sim.root");
107simData.DumpKine(5); > dump.kine
108simData.DumpHits(5); > dump.hits
109simData.DumpDigits(5); > dump.digits
110simData.DumpSDigits(5); > dump.sdigits
111
112AliMUONRecData recData("galice.root");
113recData.DumpRecPoints(5); > dump.recpoints
135fcffc 114recData.DumpTracks(5); > dump.tracks
3bc0b4a4 115recData.DumpRecTrigger(5); > dump.rectrigger
8dc57946 116.q
117EOF
858e5b75 118
fa701981 119echo "Finished"
120echo "... see results in test_out"
121
122cd $CURDIR