Scripts for PHOS alignment
[u/mrichter/AliRoot.git] / PHOS / macros / AlignmentDB / AliPHOSDisalign.C
CommitLineData
49c37ad8 1/* $Id$ */
2
3// Run simulations with PHOS alignment parameters read from CDB
4// located in the local file
5// InitAlignDB/PHOS/Align/IdealGeometry2007/RunXXX.root
6//
7// Author: Yuri Kharlov
8// 4 March 2006
9
10void AliPHOSDisalign(char *path="InitAlignDB", Int_t nevents=1)
11{
12
13 //Load alignment database into aliroot session
14
15 TString localPath="local://";
16 localPath += path;
17 AliPHOSAlignData* alignda = (AliPHOSAlignData*)(AliCDBManager::Instance()
18 ->GetStorage(localPath)->Get("PHOS/Alignment/Geometry",0)
19 ->GetObject());
20 alignda->Print();
21
22 // Create PHOS geometry instance with alignment object read from CDB
23
24 AliPHOSGeometry* geom = AliPHOSGeometry::GetInstance("IHEP","",alignda);
25
26 // Run simulations
27
28 AliSimulation sim ;
29// sim.SetMakeSDigits("PHOS") ;
30// sim.SetMakeDigits("PHOS") ;
31 sim.Run(nevents) ;
32}