]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Minor corrections after big transformer changes
authorloizides <loizides@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 5 May 2002 07:51:03 +0000 (07:51 +0000)
committerloizides <loizides@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 5 May 2002 07:51:03 +0000 (07:51 +0000)
HLT/programs/runit.cxx

index f2cf811359a75bf96c526244894e6ab9ed528e24..50a5e1abac74b4db4202aa5ad7a397986ba534bc 100644 (file)
@@ -1,9 +1,18 @@
-#include "stream.h"
+/* $Id$
+   Author: Constantin Loizides <loizides@ikf.physik.uni-frankfurt.de>
+*/
+
+#include <stream.h>
+#include <libgen.h>
+#include "AliL3Transform.h"
 #include "AliL3ClustFinderNew.h"
 #include "AliL3MemHandler.h"
 #include "AliL3SpacePointData.h"
 
-//Example program how to run the "standalone" clusterfinder.
+/**
+ Example program how to run the "standalone" clusterfinder.
+*/
+
 int main(int argc,char **argv)
 {
   if(argc!=2)
@@ -11,13 +20,12 @@ int main(int argc,char **argv)
       cout<<"Usage: runit datafile"<<endl;
       return -1;
     }
-  
+
   AliL3DigitRowData *digits = 0;
   unsigned int ndigits=0;
   
-  AliL3MemHandler file; //Does all the file/data handling
-  //AliL3Transform::Init(path); //Storing all detector-spesific quantities, needed by the clusterfinder.
-  AliL3ClustFinderNew cf; //The cluster finder itself.
+  //Does all the file/data handling  
+  AliL3MemHandler file; 
 
   //Open the data file:
   if(!file.SetBinaryInput(argv[1]))
@@ -26,33 +34,35 @@ int main(int argc,char **argv)
       return -1;
     }
 
+  //Store the data in memory, and get the pointer to it:
+  digits = file.CompBinary2Memory(ndigits);
+  file.CloseBinaryInput();
+
+  //Storing all detector-spesific quantities, needed by the clusterfinder.
+  AliL3Transform::Init(dirname(argv[1])); 
+
+  //The cluster finder itself.
+  AliL3ClustFinderNew cf; 
+
+  //Init cluster finder
+  cf.InitSlice(0,0,0,ndigits-1,10000);
+  cf.SetXYError(0.2);
+  cf.SetZError(0.3);
+
   //Allocate memory to store found spacepoints 
   AliL3MemHandler fpoints;
   AliL3SpacePointData *points=(AliL3SpacePointData*)fpoints.Allocate(10000*sizeof(AliL3SpacePointData));
   cf.SetOutputArray(points);
 
-  //Store the data in memory, and get the pointer to it:
-  digits = file.CompBinary2Memory(ndigits);
-  file.CloseBinaryInput();
-  
   //Switch off deconvolution:
   cf.SetDeconv(false);
   
-  //Init cluster finder
-  cf.InitSlice(0,0,0,20,10000);
-  cf.SetXYError(0.2);
-  cf.SetZError(0.3);
-
   //Give the data pointer to the cluster finder
   cf.Read(ndigits,digits);
-  
+
   //Start processing:
   cf.ProcessDigits();
   
   return 0;
 }
 
-
-
-
-