]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Merge branch 'master' of https://git.cern.ch/reps/AliRoot
authormorsch <andreas.morsch@cern.ch>
Fri, 21 Feb 2014 17:30:58 +0000 (18:30 +0100)
committermorsch <andreas.morsch@cern.ch>
Fri, 21 Feb 2014 17:30:58 +0000 (18:30 +0100)
12 files changed:
HMPID/HMPIDda.cxx
ITS/ITSSPDFOda.cxx
ITS/ITSSPDPHYSda.cxx
ITS/ITSSPDSCANda.cxx
ITS/ITSSPDVertexDiamondda.cxx
ITS/UPGRADE/testITSU/DetectorK.cxx
PWGGA/EMCALTasks/AliAnalysisTaskEMCALTriggerQA.h
PWGPP/QA/detectorQAscripts/EXAMPLE.sh
PWGPP/QA/detectorQAscripts/TOF.sh [new file with mode: 0755]
PWGPP/QA/scripts/runQA.example.config
PWGPP/QA/scripts/runQA.sh
cmake/CMakeDA.cmake

index e5baad333c2e909185dd8af3166eb81d7ab5e9c7..735ae149f3aae5769475317941569604ef8f752b 100644 (file)
@@ -22,7 +22,7 @@ extern "C" {
 #include "monitor.h"
 
 #include <Riostream.h>
-#include "fstream.h"
+#include <fstream>
 #include <stdio.h>
 #include <stdlib.h>
 
index e8353474287f297d06dfe6307945fa10fb1cbac8..ad4a8ed3967ef212c75d5d6162719ab2a2e9038a 100644 (file)
@@ -47,6 +47,7 @@ extern "C" {
 #include <TString.h>
 #include <TFitter.h>
 #include <TFile.h>
+#include <cstdlib>
 
 int main(int argc, char **argv) {
   if (argc<2) {
index 2ed9a18cd8cfac8d692df24e640ea048d543ac1d..7654da9fb0a7b30b968fc991b83489ed613fdb81 100644 (file)
@@ -41,6 +41,7 @@ extern "C" {
 #include <TObjArray.h>
 #include <TObjString.h>
 #include <TString.h>
+#include <cstdlib>
 
 
 int main(int argc, char **argv) {
index a57286a72d393ac41cea14cd4f3bd13b7d5e24b3..97f9e8a514d20bf2ab12c4cfbcea199037adb2de 100644 (file)
@@ -46,6 +46,7 @@ extern "C" {
 #include <TObjString.h>
 #include <TString.h>
 #include <TFitter.h>
+#include <cstdlib>
 
 int main(int argc, char **argv) {
   if (argc<2) {
index c886ca28f3aa0989140664735f5b1c63166b27d3..adb7e42b70b5d49f3464ae41e30714d81a5fe7b5 100644 (file)
@@ -40,6 +40,7 @@ extern "C" {
 #include "AliRawReaderDate.h"
 #include "AliCDBManager.h"
 #include "AliITSMeanVertexer.h"
+#include <cstdlib>
 
 int main(int argc, char **argv) {
 
index e3ab3b7621c865dab3454e4dd077d93c41a61c64..34b0970827e8ff7ffe2397160e60344ea3a88adc 100644 (file)
@@ -2256,7 +2256,7 @@ Double_t* DetectorK::PrepareEffFakeKombinations(TMatrixD *probKomb, TMatrixD *pr
     }
 
   }
-  Double_t *probs = new Double_t(2);
+  Double_t *probs = new Double_t[2];
   probs[0] = probEff; probs[1] = probFake;
   return probs;
 
index 1d12596f7a8414c0fe64f61fcc77a57190cb1c2c..a83c8044dffdfbfe5e282a687e69f0dbdcc10f1a 100644 (file)
@@ -254,11 +254,12 @@ private:
   Float_t           fMaxClusterE      ;     // Maximum value for E cluster histograms
 
   //Constants needed by the class: EMCAL 
-  static const int  fgkFALTRORows = AliEMCALGeoParams::fgkEMCALRows*(AliEMCALGeoParams::fgkEMCALModules-7)/2;   // total number 
+  //static const int  fgkFALTRORows = AliEMCALGeoParams::fgkEMCALRows*(AliEMCALGeoParams::fgkEMCALModules-7)/2;   // total number
+  static const int  fgkFALTRORows = 60; //AliEMCALGeoParams::fgkEMCALSTURows-4; // total number, temporary, not considers DCal
   // of fake altro rows    in EMCAL
   // (ALTRO channels in one SM times 5 SM divided by 2 per FALTRO)
   
-  static const int  fgkFALTROCols = AliEMCALGeoParams::fgkEMCALCols; // total number of fake altro columns in EMCAL 
+  static const int  fgkFALTROCols = AliEMCALGeoParams::fgkEMCALSTUCols; // total number of fake altro columns in EMCAL
   // (ALTRO channels in one SM times 2 SM divided by 2 per FALTRO)
   
   // cell, patch maps
index 1bed99e1dc3789fde2308bf513362c4747b8a199..2e3ec4fafb9324ff903f1241edc7729d54e3ac31 100755 (executable)
@@ -5,7 +5,7 @@
 #  $dataType     e.g. data or sim
 #  $year         e.g. 2011
 #  $period       e.g. LHC13g
-#  $runNumer     e.g. 169123
+#  $runNumber     e.g. 169123
 #  $pass         e.g. cpass1,pass1,passMC
 
 runLevelQA()
@@ -27,5 +27,7 @@ periodLevelQA()
   #the running dir contains all the run sub directories
   #named like 000123123 with the outputs of runLevelQA
 
+  
+
   #aliroot...
 }
diff --git a/PWGPP/QA/detectorQAscripts/TOF.sh b/PWGPP/QA/detectorQAscripts/TOF.sh
new file mode 100755 (executable)
index 0000000..e9e127b
--- /dev/null
@@ -0,0 +1,24 @@
+#available variables:
+#  $dataType     e.g. data or sim
+#  $year         e.g. 2011
+#  $period       e.g. LHC13g
+#  $runNumber     e.g. 169123
+#  $pass         e.g. cpass1,pass1,passMC
+
+runLevelQA()
+{
+  qaFile=$1
+
+  #cp $ALICE_ROOT/TOF/macrosQA/MakeTrendingTOFQA.C .
+  #aliroot -b -q -l "MakeTrendingTOFQA.C(\"$qaFile\",${runNumber})" 
+}
+
+periodLevelQA()
+{
+  trendingFile=$1
+
+  #cp $ALICE_ROOT/TOF/macrosQA/DrawTrending.C .
+  #rm trending.root
+  #ls 000*/trending.root > trending.list
+  #aliroot -b -q -l "DrawTrending.C(\"trending.list\")"
+}
index 156d5f33cec811c74dcdeb96f58dee83f157f069..008279202d73998cbc65a9a29c053ed9bae3baeb 100755 (executable)
@@ -2,11 +2,11 @@
 inputList=qaFile.list
 
 #working directory
-workingDirectory="/home/mkrzewic/cern/qaPlots/"
+workingDirectory="${PWD}"
 
 #where to place the final qa plots
 #outputDirectory="/afs/cern.ch/work/a/aliqa%det/www/"
-outputDirectory="/home/mkrzewic/cern/qaPlots/output/%det"
+outputDirectory="${PWD}/output/aliceqa%det"
 
 #filter out detector option
 
@@ -16,3 +16,5 @@ logDirectory=${workingDirectory}/logs
 #set aliroot
 alirootEnv="/home/mkrzewic/alisoft/balice_master.sh"
 
+#OCDB storage
+ocdbStorage="raw://"
index 7b2adfe4c1e4d72c65272f3d841d750cfab94bae..9779f8463fd0a261ddf926c3de0d5e280bf72fb6 100755 (executable)
@@ -6,12 +6,18 @@ main()
     echo "  - optionalStuff overrides config file, e.g.:"
     echo "       $0 configFile inputList=somefile.list outputDirectory='${PWD}'/output"
     exit 1
-  [[ ! -f $1 ]] && echo "argument not a file" && exit 1
+  fi
+  [[ ! -f $1 ]] && echo "argument not a file" && exit 1  
+
  
   configFile=${1}
   shift 1
 
-  
+  [[ -z $ALICE_ROOT ]] && source $alirootEnv
+  [[ -z $ALICE_ROOT ]] && echo "ALICE_ROOT not defined" && exit 1
+
+  ocdbregex='raw://'
+  [[ ${ocdbStorage} =~ ${ocdbregex} ]] && alien-token-init
 
   updateQA ${configFile} $@
 }
@@ -25,12 +31,16 @@ updateQA()
   shift 1
   parseConfig $configFile $@
 
+  dateString=$(date +%Y-%m-%d-%H-%M)
+  echo "Start time QA process: $dateString"
+
   #logging
   mkdir -p $logDirectory
   [[ ! -d $logDirectory ]] && echo "no log dir $logDirectory" && exit 1
-  logFile="$logDirectory/${0##*/}.$dateString.log"
+  logFile="$logDirectory/${0##*/}.${dateString}.log"
   touch ${logFile}
   [[ ! -f ${logFile} ]] && echo "cannot write logfile $logfile" && exit 1
+  echo "logFile = $logFile"
   exec &>${logFile}
 
   #check lock
@@ -49,12 +59,6 @@ updateQA()
   fi
   cd ${workingDirectory}
 
-  [[ -z $ALICE_ROOT ]] && source $alirootEnv
-  [[ -z $ALICE_ROOT ]] && echo "ALICE_ROOT not defined" && exit 1
-
-  dateString=$(date +%Y-%m-%d-%H-%M)
-  echo "Start time QA process: $dateString"
-
   ################################################################
   #ze detector loop
   for detectorScript in $ALICE_ROOT/PWGPP/QA/detectorQAscripts/*; do
@@ -71,9 +75,9 @@ updateQA()
     cd ${tmpRunDir}
 
     tmpPrefix=${tmpRunDir}/${outputDir}
-    echo outputDir=$outputDir
-    echo tmpPrefix=$tmpPrefix
-    echo detector=$detector
+    echo "running QA for ${detector}"
+    echo "  outputDir=$outputDir"
+    echo "  tmpPrefix=$tmpPrefix"
     
     unset -f runLevelQA
     unset -f periodLevelQA
@@ -86,14 +90,14 @@ updateQA()
       guessRunData ${qaFile}
 
       runDir=${tmpPrefix}/${dataType}/${year}/${period}/${pass}/000${runNumber}
-      echo runDir=$runDir
       mkdir -p ${runDir}
       cd ${runDir}
 
       #handle the case of a zip archive
       [[ "$qaFile" =~ .*.zip$ ]] && qaFile="${qaFile}#QAresults.root"
       
-      runLevelQA ${qaFile}
+      echo running ${detector} runLevelQA for run ${runNumber} from ${qaFile}
+      runLevelQA ${qaFile} &> runLevelQA.log
 
       cd ${tmpRunDir}
     
@@ -102,37 +106,49 @@ updateQA()
     #################################################################
     #cache which productions were (re)done
     arrOfTouchedProductions=( $(/bin/ls -d ${tmpPrefix}/*/*/*/*) )
-    echo arrOfTouchedProductions=${arrOfTouchedProductions[@]}
-    
+    echo "list of processed productions:"
+    echo "    ${arrOfTouchedProductions[@]}"
+    echo
     #################################################################
     #(re)do the merging/trending in the final destination
     for tmpProductionDir in ${arrOfTouchedProductions[@]}; do
     
-      echo productionDir=${outputDir}/${tmpProductionDir#${tmpPrefix}}
       productionDir=${outputDir}/${tmpProductionDir#${tmpPrefix}}
       
       echo mkdir -p ${productionDir}
       mkdir -p ${productionDir}
       if [[ ! -d ${productionDir} ]]; then 
-        echo "cannot make productionDir $productionDir" && return 1
+        echo "cannot make productionDir $productionDir" && continue
       fi
       
-      echo mv -f ${tmpProductionDir}/* ${productionDir}
-      mv -f ${tmpProductionDir}/* ${productionDir}
+      #move to final destination
+      for dir in ${tmpProductionDir}/*; do
+        oldRunDir=${outputDir}/${dir#${tmpPrefix}}
+        if [[ -d ${oldRunDir} ]]; then
+          echo "removing old run: rm -rf ${oldRunDir}"
+          rm -rf ${oldRunDir}
+        fi
+        echo "moving output to final destination"
+        echo mv -f ${dir} ${productionDir}
+        mv -f ${dir} ${productionDir}
+      done
     
       guessRunData "${productionDir}/dummyName"
 
       cd ${productionDir}
 
+      rm -f trending.root
       hadd trending.root 000*/trending.root
 
-      periodLevelQA trending.root
+      echo running ${detector} periodLevelQA for production ${period}/${pass}
+      periodLevelQA trending.root &> periodLevelQA.log
       
       cd ${tmpRunDir}
     
     done
 
     cd ${workingDirectory}
+    echo cleaning up: rm -rf ${tmpRunDir}
     rm -rf ${tmpRunDir}
   done
 
index ad646147ba6782d7dcc876db26fc03908dcc8686..25d2cf8f16e3808348491fe0cb8f14a7559db4a1 100644 (file)
@@ -68,7 +68,7 @@ foreach(oldetect ${ONLINEDETECTORS})
 detector_module(h_module ${oldetect})
   list(APPEND mod "-I${CMAKE_SOURCE_DIR}/${h_module}")
 endforeach(oldetect ${ONLINEDETECTORS})
-list(APPEND mod "-I${CMAKE_SOURCE_DIR}/include" "-I${CMAKE_SOURCE_DIR}/STEER" "-I${CMAKE_SOURCE_DIR}/ANALYSIS" "-I${CMAKE_SOURCE_DIR}/RAW" "-I${CMAKE_SOURCE_DIR}/STEER/STEER" "-I${CMAKE_SOURCE_DIR}/STEER/CDB" "-I${ROOTINCDIR}" "-I${CMAKE_SOURCE_DIR}/STEER/STEERBase" "-I${CMAKE_SOURCE_DIR}/STEER/AOD" "-I${CMAKE_SOURCE_DIR}/STEER/ESD" "-I${CMAKE_SOURCE_DIR}/MUON/mapping" "-I$ENV{AMORE}/include/amore")
+list(APPEND mod "-I${CMAKE_SOURCE_DIR}/include" "-I${CMAKE_SOURCE_DIR}/STEER" "-I${CMAKE_SOURCE_DIR}/ANALYSIS" "-I${CMAKE_SOURCE_DIR}/RAW" "-I${CMAKE_SOURCE_DIR}/STEER/STEER" "-I${CMAKE_SOURCE_DIR}/STEER/CDB" "-I${ROOTINCDIR}" "-I${CMAKE_SOURCE_DIR}/STEER/STEERBase" "-I${CMAKE_SOURCE_DIR}/STEER/AOD" "-I${CMAKE_SOURCE_DIR}/STEER/ESD" "-I${CMAKE_SOURCE_DIR}/MUON/mapping" "-I${CMAKE_SOURCE_DIR}/TPC/Base" "-I$ENV{AMORE}/include/amore")
 
 # ----------Common stuff-------------------