preprocessor with write protectiona nd new file simulated DAQ output for laser runs
authoralla <alla@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 16 Nov 2009 08:02:20 +0000 (08:02 +0000)
committeralla <alla@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 16 Nov 2009 08:02:20 +0000 (08:02 +0000)
T0/AliT0CalibWalk.cxx
T0/AliT0Preprocessor.cxx
T0/daLaser.root [new file with mode: 0644]

index 4f42b6b..43f2910 100644 (file)
@@ -227,14 +227,16 @@ void AliT0CalibWalk::MakeWalkCorrGraph(const char *laserFile)
              if(!hCFDvsQTC[i][im] || !hCFDvsLED[i][im]) 
                AliWarning(Form(" no walk correction data in LASER DA for channel %i for amplitude %f MIPs",i,mips[im]));
              
+             Float_t qtc0 = hCFDvsQTC[i][0]->GetMean(2);             
              if(hCFDvsQTC[i][im])
                {         
                  x1[im] = hCFDvsQTC[i][im]->GetMean(1);
-                 y1[im] = hCFDvsQTC[i][im]->GetMean(2);
+                 y1[im] =  hCFDvsQTC[i][im]->GetMean(2) - qtc0;
                }
+             Float_t led0 = hCFDvsLED[i][0]->GetMean(2);
              if( hCFDvsLED[i][im]){
                  x2[im] = hCFDvsLED[i][im]->GetMean(1);
-                 y2[im] = hCFDvsLED[i][im]->GetMean(2);
+                 y2[im] =  hCFDvsLED[i][im]->GetMean(2) - led0;
                }
              xx[im]=mips[im];
            }
index 0dce10b..9bec53e 100644 (file)
@@ -164,24 +164,20 @@ UInt_t AliT0Preprocessor::ProcessLaser(){
     Log(Form("Cannot find any AliCDBEntry for [Calib, SlewingWalk]!"));
   else {
     clb =dynamic_cast<AliT0CalibWalk*>(entryCalib->GetObject());
-    if(entryCalib->GetObject()->Class()->GetClassVersion() >3)
+    for(Int_t i=0; i<24; i++)
       {
-       //   std::cout<<" clb->Class()->GetClassVersion() < 4  "<<entryCalib->GetObject()->Class()->GetClassVersion()<<std::endl;
-       clbold=false;
-       for(Int_t i=0; i<24; i++)
+       for(Int_t ipar=0; ipar<2; ipar++)
          {
-           for(Int_t ipar=0; ipar<2; ipar++)
-             {
-               //    std::cout<<"parqtcold "<<parqtcold[i][ipar]<<std::endl;
-               parqtcold[i][ipar] = clb->GetQTCpar(i,ipar);
-               parledold[i][ipar] = clb->GetLEDpar(i, ipar);
-               goodqtc[i][ipar] = 999;
-               goodled[i][ipar] = 999;
-               //          cout<<" old "<<i<<" "<<ipar<<" qtc "<< parqtcold[i][ipar]<<" led "<<parledold[i][ipar]<<endl;
-             }
+           //    std::cout<<"parqtcold "<<parqtcold[i][ipar]<<std::endl;
+           parqtcold[i][ipar] = clb->GetQTCpar(i,ipar);
+           parledold[i][ipar] = clb->GetLEDpar(i, ipar);
+           goodqtc[i][ipar] = 999;
+           goodled[i][ipar] = 999;
+           //      cout<<" old "<<i<<" "<<ipar<<" qtc "<< parqtcold[i][ipar]<<" led "<<parledold[i][ipar]<<endl;
          }
       }
-  } // object in existing OCDB
+  }
+
 
     Bool_t resultLaser=kFALSE;
     //processing DAQ
@@ -199,7 +195,7 @@ UInt_t AliT0Preprocessor::ProcessLaser(){
                 AliT0CalibWalk *laser = new AliT0CalibWalk();
                 laser->MakeWalkCorrGraph(laserFile);
                //check difference with what was before
-               if(laser && clb && !clbold){
+               if(laser && clb ){
                  iStore = 1;                           
                  for(Int_t i=0; i<24; i++)
                    {
diff --git a/T0/daLaser.root b/T0/daLaser.root
new file mode 100644 (file)
index 0000000..b925c1b
Binary files /dev/null and b/T0/daLaser.root differ