Major upgrade (P. Cerello)
authormasera <masera@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 17 Apr 2008 16:53:36 +0000 (16:53 +0000)
committermasera <masera@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 17 Apr 2008 16:53:36 +0000 (16:53 +0000)
ITS/AliITSQASDDDataMakerRec.cxx
ITS/AliITSQASDDDataMakerRec.h

index 32857cc..d6c789d 100644 (file)
@@ -24,6 +24,7 @@
 //  INFN Torino\r
 \r
 // --- ROOT system ---\r
+#include <TProfile2D.h>\r
 #include <TH2D.h>\r
 #include <TBranch.h>\r
 #include <TTree.h>\r
@@ -64,9 +65,6 @@ fSDDDDLModuleMap(0)
   if(fLDC < 0 || fLDC > 4) {\r
        AliError("Error: LDC number out of range; return\n");\r
   }\r
-  for(Int_t i=0;i<2*fgknSDDmodules;i++){\r
-    fModuleChargeMap[i] = NULL;\r
-  }\r
 }\r
 \r
 //____________________________________________________________________________ \r
@@ -89,11 +87,7 @@ fSDDDDLModuleMap(0)
 //____________________________________________________________________________ \r
 AliITSQASDDDataMakerRec::~AliITSQASDDDataMakerRec(){\r
   // destructor\r
-\r
-  for(Int_t i=0;i<2*fgknSDDmodules;i++){\r
-    if(fModuleChargeMap[i]) delete fModuleChargeMap[i];\r
-  }\r
-  \r
+       if(fSDDDDLModuleMap) delete fSDDDDLModuleMap;\r
 }\r
 //__________________________________________________________________\r
 AliITSQASDDDataMakerRec& AliITSQASDDDataMakerRec::operator = (const AliITSQASDDDataMakerRec& qac )\r
@@ -112,12 +106,10 @@ void AliITSQASDDDataMakerRec::StartOfDetectorCycle()
 }\r
 \r
 //____________________________________________________________________________ \r
-void AliITSQASDDDataMakerRec::EndOfDetectorCycle(AliQA::TASKINDEX_t /*task*/, TObjArray* /*list*/)\r
+void AliITSQASDDDataMakerRec::EndOfDetectorCycle(AliQA::TASKINDEX_t task, TObjArray* list)\r
 {\r
   // launch the QA checking\r
   AliDebug(1,"AliITSDM instantiates checker with Run(AliQA::kITS, task, list)\n"); \r
-  \r
-  //AliQAChecker::Instance()->Run( AliQA::kITS , task, list);\r
 }\r
 \r
 //____________________________________________________________________________ \r
@@ -149,44 +141,47 @@ void AliITSQASDDDataMakerRec::InitRaws()
   else {\r
     AliInfo("Book Offline Histograms for SDD\n ");\r
   }\r
-  TH1F *h0 = new TH1F("ModPattern","Modules pattern",fgknSDDmodules,-0.5,259.5);\r
+  TH1D *h0 = new TH1D("ModPattern","HW Modules pattern",fgknSDDmodules,-0.5,259.5);\r
   h0->GetXaxis()->SetTitle("Module Number");\r
   h0->GetYaxis()->SetTitle("Counts");\r
-  fAliITSQADataMakerRec->Add2RawsList(h0,0+fRawsOffset);\r
+  fAliITSQADataMakerRec->Add2RawsList((new TH1D(*h0)),0+fRawsOffset);\r
+  delete h0;\r
   fSDDhRaws++;\r
   if(fLDC==0 || fLDC==1 || fLDC==2){\r
-    TH1F *h1 = new TH1F("LadPatternL3","Ladder pattern L3",14,0.5,14.5);  \r
+    TH1D *h1 = new TH1D("LadPatternL3","Ladder pattern L3",14,0.5,14.5);  \r
     h1->GetXaxis()->SetTitle("Ladder Number on Lay3");\r
     h1->GetYaxis()->SetTitle("Counts");\r
-    fAliITSQADataMakerRec->Add2RawsList(h1,1+fRawsOffset);\r
+    fAliITSQADataMakerRec->Add2RawsList((new TH1D(*h1)),1+fRawsOffset);\r
+       delete h1;\r
     fSDDhRaws++;\r
   }    \r
   if(fLDC==0 || fLDC==3 || fLDC==4){\r
-    TH1F *h2 = new TH1F("LadPatternL4","Ladder pattern L4",22,0.5,22.5);  \r
+    TH1D *h2 = new TH1D("LadPatternL4","Ladder pattern L4",22,0.5,22.5);  \r
     h2->GetXaxis()->SetTitle("Ladder Number on Lay4");\r
     h2->GetYaxis()->SetTitle("Counts");\r
-    fAliITSQADataMakerRec->Add2RawsList(h2,2+fRawsOffset);\r
+    fAliITSQADataMakerRec->Add2RawsList((new TH1D(*h2)),2+fRawsOffset);\r
+       delete h2;\r
     fSDDhRaws++;\r
   }\r
   if(fLDC==0 || fLDC==1 || fLDC==2){\r
-    TH1D *h3[fgkLADDonLAY3] ; \r
-    for(Int_t i=1; i<=fgkLADDonLAY3; i++) {\r
+       for(Int_t i=1; i<=fgkLADDonLAY3; i++) {\r
       sprintf(hname0,"ModPattern_L3_%d",i);\r
-      h3[i-1] = new TH1D(hname0,hname0,6,0.5,6.5);\r
-      h3[i-1]->GetXaxis()->SetTitle("Channel Number");\r
-      h3[i-1]->GetYaxis()->SetTitle("Counts");\r
-      fAliITSQADataMakerRec->Add2RawsList(h3[i-1],i-1+3+fRawsOffset);\r
+      TH1D *h3 = new TH1D(hname0,hname0,6,0.5,6.5);\r
+      h3->GetXaxis()->SetTitle("Module Number");\r
+      h3->GetYaxis()->SetTitle("Counts");\r
+      fAliITSQADataMakerRec->Add2RawsList((new TH1D(*h3)),i-1+3+fRawsOffset);\r
+         delete h3;\r
       fSDDhRaws++;\r
     }\r
   }\r
   if(fLDC==0 || fLDC==3 || fLDC==4){\r
-    TH1D *h4[fgkLADDonLAY4] ; \r
     for(Int_t i=1; i<=fgkLADDonLAY4; i++) {\r
       sprintf(hname0,"ModPattern_L4_%d",i);\r
-      h4[i-1] = new TH1D(hname0,hname0,8,0.5,8.5);\r
-      h4[i-1]->GetXaxis()->SetTitle("Channel Number");\r
-      h4[i-1]->GetYaxis()->SetTitle("Counts");\r
-      fAliITSQADataMakerRec->Add2RawsList(h4[i-1],i-1+17+fRawsOffset);\r
+         TH1D *h4 = new TH1D(hname0,hname0,8,0.5,8.5);\r
+      h4->GetXaxis()->SetTitle("Module Number");\r
+      h4->GetYaxis()->SetTitle("Counts");\r
+      fAliITSQADataMakerRec->Add2RawsList((new TH1D(*h4)),i-1+17+fRawsOffset);\r
+         delete h4;\r
       fSDDhRaws++;\r
     }\r
   }\r
@@ -196,148 +191,46 @@ void AliITSQASDDDataMakerRec::InitRaws()
 \r
   if(fkOnline) {\r
     indexlast = 0;\r
-    TH1D *h5[fgknSDDmodules*2] ; \r
     index1 = 0;\r
-\r
-/*\r
-    if(fLDC == 0 || fLDC == 1 || fLDC == 4){\r
-      \r
-       for(Int_t lad=0; lad<fgkLADDonLAY3; lad++){\r
-       for(Int_t ichan=0; det<3; det++){\r
-         for(Int_t iside=0; iside<fgknSide; iside++){\r
-           sprintf(hname0,"ProjYMap_L%d_%d_%d_%d",lay,lad,det+sideflag*3,iside);  //need to define "lay"\r
-           h5[index1] = new TH1D(hname0,hname0,256,-0.5,255.5);\r
-           h5[index1]->GetXaxis()->SetTitle("Anode Number");\r
-           h5[index1]->GetYaxis()->SetTitle("Counts");\r
-           fAliITSQADataMakerRec->Add2RawsList(h5[index1],index1+39+fRawsOffset);\r
-               fSDDhRaws++;\r
-           index1++;\r
-           indexlast = index1+39;\r
-         }\r
-       }       \r
-      }\r
-    }\r
-*/  \r
-    for(Int_t moduleSDD=0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
-      if((moduleSDD >= 0 && moduleSDD < 36) || (moduleSDD >= 84 && moduleSDD < 180)) {\r
-       for(Int_t iside=0; iside<fgknSide; iside++){\r
-         AliITSgeomTGeo::GetModuleId(moduleSDD+fgkmodoffset, lay, lad, det);\r
-         //if(fLDC == 0 || ((fLDC == 1 || fLDC == 2) && lay == 2) || ((fLDC == 3 || fLDC == 4) && lay == 3)\r
-         sprintf(hname0,"ProjYMap_L%d_%d_%d_%d",lay,lad,det,iside);\r
-         h5[index1] = new TH1D(hname0,hname0,256,-0.5,255.5);\r
-         h5[index1]->GetXaxis()->SetTitle("Anode Number");\r
-         h5[index1]->GetYaxis()->SetTitle("Counts");\r
-         fAliITSQADataMakerRec->Add2RawsList(h5[index1],index1+39+fRawsOffset);\r
-         fSDDhRaws++;\r
-         index1++;\r
-         indexlast = index1+39;\r
-       }\r
-      }\r
-    }\r
-    \r
-    TH1D *h6[fgknSDDmodules*8] ; \r
-    Int_t indextot = 0;\r
-    indexlast1 = 0;\r
-    for(Int_t htype=0; htype<4; htype++){\r
-      for(Int_t moduleSDD=0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
-       if((moduleSDD >= 0 && moduleSDD < 36) || (moduleSDD >= 84 && moduleSDD < 180)) {         \r
-         for(Int_t iside=0; iside<fgknSide; iside++){\r
-           AliITSgeomTGeo::GetModuleId(moduleSDD+fgkmodoffset, lay, lad, det);\r
-           if(htype == 0) sprintf(hname0,"CountsVSAnode_L%d_%d_%d_%d",lay,lad,det,iside);\r
-           if(htype == 1) sprintf(hname0,"ChargeVSAnode_L%d_%d_%d_%d",lay,lad,det,iside);\r
-           if(htype == 2) sprintf(hname0,"CountsVSTbin_L%d_%d_%d_%d",lay,lad,det,iside);\r
-           if(htype == 3) sprintf(hname0,"ChargeVSTbin_L%d_%d_%d_%d",lay,lad,det,iside);\r
-           h6[indextot] = new TH1D(hname0,hname0,256,-0.5,255.5);\r
-           if(htype == 0){\r
-             h6[indextot]->GetXaxis()->SetTitle("Anode Number");\r
-             h6[indextot]->GetYaxis()->SetTitle("Counts");\r
-           }\r
-           if(htype == 1){\r
-             h6[indextot]->GetXaxis()->SetTitle("Anode Number");\r
-             h6[indextot]->GetYaxis()->SetTitle("Charge (ADC)");\r
-           }\r
-           if(htype == 2){\r
-             h6[indextot]->GetXaxis()->SetTitle("Time bin");\r
-             h6[indextot]->GetYaxis()->SetTitle("Counts");\r
-           }\r
-           if(htype == 3){\r
-             h6[indextot]->GetXaxis()->SetTitle("Time bin");\r
-             h6[indextot]->GetYaxis()->SetTitle("Charge (ADC)");\r
-           }\r
-           fAliITSQADataMakerRec->Add2RawsList(h6[indextot],indexlast + indextot + fRawsOffset);\r
-           fSDDhRaws++;\r
-           indextot++;\r
-           indexlast1 = indexlast + indextot;\r
-         }\r
-       }\r
-      }\r
-    }\r
-\r
-\r
+       indexlast1 = fSDDhRaws;\r
     indexlast2 = 0;\r
-    index1 = 0;\r
     char *hname[3];\r
     for(Int_t i=0; i<3; i++) hname[i]= new char[50];\r
     for(Int_t moduleSDD =0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
-      if((moduleSDD >= 0 && moduleSDD < 36) || (moduleSDD >= 84 && moduleSDD < 180)) {\r
-       for(Int_t iside=0;iside<fgknSide;iside++){\r
-       AliITSgeomTGeo::GetModuleId(moduleSDD+fgkmodoffset, lay, lad, det);\r
-       sprintf(hname[0],"chargeMap_L%d_%d_%d_%d",lay,lad,det,iside);\r
-       sprintf(hname[1],"TotalCharge_L%d_%d_%d_%d",lay,lad,det,iside);\r
-       sprintf(hname[2],"hmonoDMap_L%d_%d_%d_%d",lay,lad,det,iside);\r
-       fModuleChargeMap[index1] = new TH2D(hname[0],hname[1],256,-0.5,255.5,256,-0.5,255.5);\r
-       fModuleChargeMap[index1]->GetXaxis()->SetTitle("Time Bin");\r
-       fModuleChargeMap[index1]->GetYaxis()->SetTitle("Anode");\r
-       fAliITSQADataMakerRec->Add2RawsList((new TH2D(*fModuleChargeMap[index1])),indexlast1 + index1 + fRawsOffset);\r
-       fSDDhRaws++;\r
-               index1++;        \r
-       indexlast2 = indexlast1 + index1;\r
-      }\r
-    }\r
-  }\r
-  \r
-  \r
-  TH2D *h7[fgknSDDmodules*2] ;\r
-  index1 = 0;\r
-  for(Int_t moduleSDD=0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
-    if((moduleSDD >= 0 && moduleSDD < 36) || (moduleSDD >= 84 && moduleSDD < 180)) {\r
-      for(Int_t iside=0; iside<fgknSide; iside++){\r
-       AliITSgeomTGeo::GetModuleId(moduleSDD+fgkmodoffset, lay, lad, det);\r
-       sprintf(hname0,"Anode_vs_Charge_L%d_%d_%d_%d",lay,lad,det,iside);\r
-       h7[index1] = new TH2D(hname0,hname0,fgknSDDmodules*2,-0.5,-0.5+fgknSDDmodules*2,256,0.5,256.5);\r
-       h7[index1]->GetXaxis()->SetTitle("Charge Value (ADC)");\r
-       h7[index1]->GetYaxis()->SetTitle("Anode");\r
-       fAliITSQADataMakerRec->Add2RawsList(h7[index1],indexlast2 + index1 + fRawsOffset);\r
-       fSDDhRaws++;\r
-       index1++;\r
-      }\r
-    }\r
-  }\r
-  /*\r
-  TH2F *h8[3];\r
-  for(Int_t htype =0; htype<3; htype++){\r
-    if(htype == 0) sprintf(hname0,"BLcompare");\r
-    if(htype == 1) sprintf(hname0,"NoiseCompare");\r
-    if(htype == 2) sprintf(hname0,"VdriftCompare");\r
-    h8[htype]= new TH2F(hname0,hname0,520,0,260,100,-0.5,99.5);\r
-    if(htype == 0){\r
-      h8[htype]->GetXaxis()->SetTitle("Module Number");\r
-      h8[htype]->GetYaxis()->SetTitle("Time #");\r
-    }\r
-    if(htype == 1){\r
-      h8[htype]->GetXaxis()->SetTitle("Module Number");\r
-      h8[htype]->GetYaxis()->SetTitle("Time #)");\r
-    }\r
-    if(htype == 2){\r
-      h8[htype]->GetXaxis()->SetTitle("Module Number");\r
-      h8[htype]->GetYaxis()->SetTitle("Time #");\r
-    }\r
+               for(Int_t iside=0;iside<fgknSide;iside++){\r
+                       AliITSgeomTGeo::GetModuleId(moduleSDD+fgkmodoffset, lay, lad, det);\r
+                       sprintf(hname[0],"chargeMapFSE_L%d_%d_%d_%d",lay,lad,det,iside);\r
+                       sprintf(hname[1],"ChargeMapForSingleEvent_L%d_%d_%d_%d",lay,lad,det,iside);\r
+                       sprintf(hname[2],"hmonoDMap_L%d_%d_%d_%d",lay,lad,det,iside);\r
+                       TProfile2D *fModuleChargeMapFSE = new TProfile2D(hname[0],hname[1],128,-0.5,255.5,256,-0.5,255.5);\r
+                       fModuleChargeMapFSE->GetXaxis()->SetTitle("Time Bin");\r
+                       fModuleChargeMapFSE->GetYaxis()->SetTitle("Anode");\r
+                       fAliITSQADataMakerRec->Add2RawsList((new TProfile2D(*fModuleChargeMapFSE)),indexlast1 + index1 + fRawsOffset);\r
+                       delete fModuleChargeMapFSE;\r
+                       \r
+                       fSDDhRaws++;\r
+                       index1++;        \r
+                       indexlast2 = indexlast1 + index1;\r
+               }\r
+       }\r
 \r
-    fAliITSQADataMakerRec->Add2RawsList(h8[htype],indexlast2 + index1 + htype+1 + fRawsOffset);\r
-    fSDDhRaws++;\r
-    printf("added histos %c, at position %d \n", hname0, indexlast2 + index1 + htype+1 + fRawsOffset);\r
-  }\r
-  */\r
+    for(Int_t moduleSDD =0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
+               for(Int_t iside=0;iside<fgknSide;iside++){\r
+                       AliITSgeomTGeo::GetModuleId(moduleSDD+fgkmodoffset, lay, lad, det);\r
+                       sprintf(hname[0],"chargeMap_L%d_%d_%d_%d",lay,lad,det,iside);\r
+                       sprintf(hname[1],"ChargeMap_L%d_%d_%d_%d",lay,lad,det,iside);\r
+                       TProfile2D *fModuleChargeMap = new TProfile2D(hname[0],hname[1],128,-0.5,255.5,256,-0.5,255.5);\r
+                       fModuleChargeMap->GetXaxis()->SetTitle("Time Bin");\r
+                       fModuleChargeMap->GetYaxis()->SetTitle("Anode");\r
+                       fAliITSQADataMakerRec->Add2RawsList((new TProfile2D(*fModuleChargeMap)),indexlast1 + index1 + fRawsOffset);\r
+                       delete fModuleChargeMap;\r
+\r
+                       fSDDhRaws++;\r
+                       index1++;        \r
+                       indexlast2 = indexlast1 + index1;\r
+               }\r
+       }\r
+  \r
 }  // kONLINE\r
 \r
 \r
@@ -377,19 +270,17 @@ void AliITSQASDDDataMakerRec::MakeRaws(AliRawReader* rawReader)
   Int_t index=0;\r
   if(fkOnline) {\r
     for(Int_t moduleSDD =0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
-      if((moduleSDD >= 0 && moduleSDD < 36) || (moduleSDD >= 84 && moduleSDD < 180)) {\r
         for(Int_t iside=0;iside<fgknSide;iside++) {\r
-          if(fSDDhRaws > 39+12 * 132 + index) fAliITSQADataMakerRec->GetRawsData(39+12 * 132 + index +fRawsOffset)->Reset();\r
+          if(fSDDhRaws > 39 + index) fAliITSQADataMakerRec->GetRawsData(39 + index +fRawsOffset)->Reset();\r
           index++;\r
         }\r
-      }\r
     }\r
   }\r
   Int_t cnt = 0;\r
   Int_t ildcID = -1;\r
   Int_t iddl = -1;\r
   Int_t isddmod = -1;\r
-  Int_t coord1, coord2, signal, moduleSDD, ioffset, iorder, activeModule, index1 ,nBins , iside, bin ;\r
+  Int_t coord1, coord2, signal, moduleSDD, ioffset, iorder, activeModule, index1;\r
   while(s.Next()) {\r
     ildcID = rawReader->GetLDCId();\r
     iddl = rawReader->GetDDLID() - fgkDDLIDshift;\r
@@ -426,7 +317,6 @@ void AliITSQASDDDataMakerRec::MakeRaws(AliRawReader* rawReader)
     \r
     Short_t iside = s.GetChannel();\r
     activeModule = moduleSDD;\r
-    if(moduleSDD > 35) activeModule -= 48;\r
     index1 = activeModule * 2 + iside;\r
     \r
     if(index1<0){\r
@@ -435,15 +325,9 @@ void AliITSQASDDDataMakerRec::MakeRaws(AliRawReader* rawReader)
     }\r
     \r
     if(fkOnline) {\r
-      if(fSDDhRaws > 39+12 * 132 + index1) {\r
-       \r
-        fAliITSQADataMakerRec->GetRawsData(39+ 2 * 132 + index1 +fRawsOffset)->Fill(coord1); \r
-        fAliITSQADataMakerRec->GetRawsData(39+ 4 * 132 + index1 +fRawsOffset)->Fill(coord1,signal); \r
-        fAliITSQADataMakerRec->GetRawsData(39+ 6 * 132 + index1 +fRawsOffset)->Fill(coord2);   \r
-        fAliITSQADataMakerRec->GetRawsData(39+ 8 * 132 + index1 +fRawsOffset)->Fill(coord2,signal); \r
-        fAliITSQADataMakerRec->GetRawsData(39+12 * 132 + index1 +fRawsOffset)->Fill(signal,coord1);\r
-        ((TH2D *)(fAliITSQADataMakerRec->GetRawsData(39+10 * 132 + index1 +fRawsOffset)))->Fill(coord2, coord1, signal);\r
-\r
+      if(fSDDhRaws > 39 + index1) {\r
+        ((TProfile2D *)(fAliITSQADataMakerRec->GetRawsData(39 + index1 +fRawsOffset)))->Fill(coord2, coord1, signal);\r
+        ((TProfile2D *)(fAliITSQADataMakerRec->GetRawsData(39 + index1 + 260*2 +fRawsOffset)))->Fill(coord2, coord1, signal);\r
       }\r
     }\r
     cnt++;\r
@@ -451,28 +335,6 @@ void AliITSQASDDDataMakerRec::MakeRaws(AliRawReader* rawReader)
   }\r
   AliDebug(1,Form("Event completed, %d raw digits read",cnt));  \r
 \r
-  if(fkOnline) {\r
-    TH1D *ptr = NULL;\r
-    nBins = 256;\r
-    for(moduleSDD=0; moduleSDD<fgknSDDmodules; moduleSDD++){\r
-      if((moduleSDD >= 0 && moduleSDD < 36) || (moduleSDD >= 84 && moduleSDD < 180)) {\r
-       for(iside=0; iside<fgknSide; iside++){\r
-         activeModule = moduleSDD;\r
-         if(moduleSDD > 35) activeModule -= 48;\r
-         index1 = activeModule * 2 + iside;\r
-         if(fSDDhRaws > 39 + 2 * 132 + index1) {\r
-           ptr = ((TH2D *) (fAliITSQADataMakerRec->GetRawsData(39+10 * 132 + index1 +fRawsOffset)))->ProjectionY();\r
-           for(bin=0; bin<nBins; bin++) fAliITSQADataMakerRec->GetRawsData(index1+39 +fRawsOffset)->Fill(bin,ptr->GetBinContent(bin+1) );\r
-         }  \r
-       }\r
-      }\r
-    }\r
-    for(Int_t i=0; i<fSDDhRaws; i++){\r
-      Int_t entries = static_cast<Int_t>(fAliITSQADataMakerRec->GetRawsData(i +fRawsOffset)->GetEntries());\r
-      if(entries != 0)\r
-       AliDebug(1,Form("histo %d, name %s , entries %d ",i,fAliITSQADataMakerRec->GetRawsData(i +fRawsOffset)->GetName(),entries));\r
-    }\r
-  }\r
 }\r
 \r
 //____________________________________________________________________________ \r
@@ -481,80 +343,88 @@ void AliITSQASDDDataMakerRec::InitRecPoints()
   // Initialization for RECPOINTS - SDD -\r
   fRecsOffset = (fAliITSQADataMakerRec->fRecPointsQAList)->GetEntries();\r
   \r
-  TH1F * h0 = new TH1F("Lay3TotCh","Layer 3 total charge",1000,-0.5, 499.5);\r
+  TH1F *h0 = new TH1F("Lay3TotCh","Layer 3 total charge",1000,-0.5, 499.5);\r
   h0->GetXaxis()->SetTitle("ADC value");\r
   h0->GetYaxis()->SetTitle("Entries");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h0, 0 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h0)), 0 +fRecsOffset);\r
+  delete h0;\r
   fSDDhRecs++;\r
  \r
-  TH1F * h1 = new TH1F("Lay4TotCh","Layer 4 total charge",1000,-0.5, 499.5);\r
+  TH1F *h1 = new TH1F("Lay4TotCh","Layer 4 total charge",1000,-0.5, 499.5);\r
   h1->GetXaxis()->SetTitle("ADC value");\r
   h1->GetYaxis()->SetTitle("Entries");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h1, 1 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h1)), 1 +fRecsOffset);\r
+  delete h1;\r
   fSDDhRecs++;\r
 \r
     \r
   char hisnam[50];\r
-  TH1F *h2[3]; \r
   for(Int_t i=1; i<=3; i++){\r
     sprintf(hisnam,"Charge_L3_Strip%d",i);\r
-    h2[i] = new TH1F(hisnam,hisnam,1000,-0.5, 499.5);\r
-    fAliITSQADataMakerRec->Add2RecPointsList(h2[i],i+1 +fRecsOffset);\r
+    TH1F *h2 = new TH1F(hisnam,hisnam,1000,-0.5, 499.5);\r
+    fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h2)),i+1 +fRecsOffset);\r
+       delete h2;\r
     fSDDhRecs++;\r
   }\r
   \r
-  TH1F *h3[4]; \r
   for(Int_t i=1; i<=4; i++){\r
     sprintf(hisnam,"Charge_L4_Strip%d",i);\r
-    h3[i] = new TH1F(hisnam,hisnam,1000,-0.5, 499.5);\r
-    fAliITSQADataMakerRec->Add2RecPointsList(h3[i],i+4 +fRecsOffset);\r
+    TH1F *h3 = new TH1F(hisnam,hisnam,1000,-0.5, 499.5);\r
+    fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h3)),i+4 +fRecsOffset);\r
+       delete h3;\r
     fSDDhRecs++;\r
   }\r
   \r
   TH1F *h4 = new TH1F("ModPatternRP","Modules pattern RP",fgknSDDmodules,239.5,499.5); \r
   h4->GetXaxis()->SetTitle("Module number");\r
   h4->GetYaxis()->SetTitle("Entries");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h4,9 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h4)),9 +fRecsOffset);\r
+  delete h4;\r
   fSDDhRecs++;\r
   TH1F *h5 = new TH1F("ModPatternL3 RP","Ladder pattern L3 RP",14,0.5,14.5);  \r
   h5->GetXaxis()->SetTitle("Ladder #, Layer 3");\r
   h5->GetYaxis()->SetTitle("Entries");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h5,10 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h5)),10 +fRecsOffset);\r
+  delete h5;\r
   fSDDhRecs++;\r
   TH1F *h6 = new TH1F("ModPatternL4 RP","Ladder pattern L4 RP",22,0.5,22.5); \r
   h6->GetXaxis()->SetTitle("Ladder #, Layer 4");\r
   h6->GetYaxis()->SetTitle("Entries");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h6,11 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h6)),11 +fRecsOffset);\r
+  delete h6;\r
   fSDDhRecs++;\r
   TH2F *h7 = new TH2F("Local Coord Distrib","Local Coord Distrib",1000,-4,4,1000,-4,4);\r
   h7->GetXaxis()->SetTitle("X local coord, drift, cm");\r
   h7->GetYaxis()->SetTitle("Z local coord, anode, cm");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h7,12 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH2F(*h7)),12 +fRecsOffset);\r
+  delete h7;\r
   fSDDhRecs++;\r
   TH2F *h8 = new TH2F("Global Coord Distrib","Global Coord Distrib",6000,-30,30,6000,-30,30);\r
   h8->GetYaxis()->SetTitle("Y glob coord, cm");\r
   h8->GetXaxis()->SetTitle("X glob coord, cm");\r
-  fAliITSQADataMakerRec->Add2RecPointsList(h8,13 +fRecsOffset);\r
+  fAliITSQADataMakerRec->Add2RecPointsList((new TH2F(*h8)),13 +fRecsOffset);\r
+  delete h8;\r
   fSDDhRecs++;\r
-  \r
-  TH1F *h9[2]; \r
+   \r
   for(Int_t iLay=0; iLay<=1; iLay++){\r
     sprintf(hisnam,"hr_Layer%d",iLay+3);\r
-    h9[iLay] = new TH1F(hisnam,hisnam,100,10.,30.);\r
-    h9[iLay]->GetXaxis()->SetTitle("r (cm)");\r
-    h9[iLay]->GetXaxis()->CenterTitle();\r
-    h9[iLay]->GetYaxis()->SetTitle("Entries");\r
-    fAliITSQADataMakerRec->Add2RecPointsList(h9[iLay],iLay+14 +fRecsOffset);\r
+    TH1F *h9 = new TH1F(hisnam,hisnam,100,10.,30.);\r
+    h9->GetXaxis()->SetTitle("r (cm)");\r
+    h9->GetXaxis()->CenterTitle();\r
+    h9->GetYaxis()->SetTitle("Entries");\r
+    fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h9)),iLay+14 +fRecsOffset);\r
+       delete h9;\r
     fSDDhRecs++;\r
   }\r
-  TH1F *h10[2]; \r
+\r
   for(Int_t iLay=0; iLay<=1; iLay++){\r
     sprintf(hisnam,"hphi_Layer%d",iLay+3);\r
-    h10[iLay] = new TH1F(hisnam,hisnam,100,-TMath::Pi(),TMath::Pi());\r
-    h10[iLay]->GetXaxis()->SetTitle("#varphi (rad)");\r
-    h10[iLay]->GetXaxis()->CenterTitle();\r
-    h10[iLay]->GetYaxis()->SetTitle("Entries");\r
-    fAliITSQADataMakerRec->Add2RecPointsList(h10[iLay],iLay+16 +fRecsOffset);\r
+    TH1F *h10 = new TH1F(hisnam,hisnam,100,-TMath::Pi(),TMath::Pi());\r
+    h10->GetXaxis()->SetTitle("#varphi (rad)");\r
+    h10->GetXaxis()->CenterTitle();\r
+    h10->GetYaxis()->SetTitle("Entries");\r
+    fAliITSQADataMakerRec->Add2RecPointsList((new TH1F(*h10)),iLay+16 +fRecsOffset);\r
+       delete h10;\r
     fSDDhRecs++;\r
   }\r
 \r
index 4255954..64bbfd8 100644 (file)
@@ -17,7 +17,7 @@
 #include "AliITSQADataMakerRec.h"\r
 class TObjArray;\r
 class TH1D;\r
-class TH2D;\r
+class TProfile2D;\r
 class AliRawReader;\r
 class AliITSgeomTGeo;\r
 class AliITSDDLModuleMapSDD;\r
@@ -60,9 +60,11 @@ private:
   Int_t   fRawsOffset;                     // number of histo booked when SDD start\r
   Int_t   fRecsOffset;                     // number of histo booked when SDD start\r
   AliITSDDLModuleMapSDD  *fSDDDDLModuleMap;// SDD Detector configuration for the decoding\r
-  TH2D *fModuleChargeMap[2*fgknSDDmodules];//module map\r
\r
-  ClassDef(AliITSQASDDDataMakerRec,2)      // description \r
+/*\r
+  TProfile2D *fModuleChargeMap[2*fgknSDDmodules];//module map\r
+  TProfile2D *fModuleChargeMapFSE[2*fgknSDDmodules];//module map for one event \r
+*/ \r
+  ClassDef(AliITSQASDDDataMakerRec,3)      // description \r
 \r
 };\r
 \r