Changeset 17597 for trunk/DataCheck/Processing/FillAuxThresholds.sh
- Timestamp:
- 03/02/14 13:41:25 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DataCheck/Processing/FillAuxThresholds.sh
r17596 r17597 50 50 runnumber=`echo $date | sed -e 's/\///g'` 51 51 52 # check if aux files are available from that night53 if ! [ -d $auxdir ]54 then55 printprocesslog "INFO no data available in "$auxdir56 continue57 else58 printprocesslog "INFO processing files in "$auxdir59 fi60 61 rawdir=$rawdata/$date62 # check if raw files are available from that night63 if ! [ -d $rawdir ]64 then65 logtext="INFO"66 else67 logtext="WARN"68 fi69 70 thresholdfile=$auxdir/$runnumber.RATE_CONTROL_THRESHOLD.fits71 printprocesslog "INFO processing "$thresholdfile72 echo "INFO processing "$thresholdfile >> $logfile 2>&173 if ! [ -e $thresholdfile ]74 then75 printprocesslog $logtext" "$thresholdfile" not found."76 continue77 else78 threshnumerrors=`fverify $thresholdfile 2>/dev/null | grep -o '[0-9][ ]error(s)' | grep -E -o '[0-9]'`79 if [ $threshnumerrors -gt 0 ]80 then81 printprocesslog "WARN for $thresholdfile fverify returned "$threshnumerrors" error(s)."82 fi83 fi84 85 thresholdfile2=$auxdir/$runnumber.FTM_CONTROL_STATIC_DATA.fits86 #ls $thresholdfile287 if ! [ -e $thresholdfile2 ]88 then89 printprocesslog $logtext" "$thresholdfile2" not found."90 continue91 else92 threshnumerrors2=`fverify $thresholdfile2 2>/dev/null | grep -o '[0-9][ ]error(s)' | grep -E -o '[0-9]'`93 if [ $threshnumerrors2 -gt 0 ]94 then95 printprocesslog "WARN for $thresholdfile2 fverify returned "$threshnumerrors2" error(s)."96 fi97 fi98 99 100 101 52 # get file numbers from DB 102 53 # but only for not-corrupted files … … 106 57 query=$query" AND ISNULL(fThresholdMedMean) AND ISNULL(fThresholdMinSet) " 107 58 fi 108 109 59 printprocesslog "DEBUG get filenumbers from DB: QUERY: "$query 110 60 filenumbers=( `sendquery $query` ) 61 # proceed only if there are files available 111 62 if [ ${#filenumbers} -eq 0 ] 112 63 then 113 64 printprocesslog "INFO No files found in the DB for night "$date 114 65 continue 66 fi 67 68 # check if aux files are available from that night 69 if ! [ -d $auxdir ] 70 then 71 printprocesslog "INFO no data available in "$auxdir 72 continue 73 else 74 printprocesslog "INFO processing files in "$auxdir 75 fi 76 77 thresholdfile=$auxdir/$runnumber.RATE_CONTROL_THRESHOLD.fits 78 printprocesslog "INFO processing "$thresholdfile 79 echo "INFO processing "$thresholdfile >> $logfile 2>&1 80 if ! [ -e $thresholdfile ] 81 then 82 printprocesslog "WARN "$thresholdfile" not found." 83 continue 84 else 85 threshnumerrors=`fverify $thresholdfile 2>/dev/null | grep -o '[0-9][ ]error(s)' | grep -E -o '[0-9]'` 86 if [ $threshnumerrors -gt 0 ] 87 then 88 printprocesslog "WARN for $thresholdfile fverify returned "$threshnumerrors" error(s)." 89 fi 90 fi 91 92 thresholdfile2=$auxdir/$runnumber.FTM_CONTROL_STATIC_DATA.fits 93 #ls $thresholdfile2 94 if ! [ -e $thresholdfile2 ] 95 then 96 printprocesslog "WARN "$thresholdfile2" not found." 97 continue 98 else 99 threshnumerrors2=`fverify $thresholdfile2 2>/dev/null | grep -o '[0-9][ ]error(s)' | grep -E -o '[0-9]'` 100 if [ $threshnumerrors2 -gt 0 ] 101 then 102 printprocesslog "WARN for $thresholdfile2 fverify returned "$threshnumerrors2" error(s)." 103 fi 115 104 fi 116 105
Note:
See TracChangeset
for help on using the changeset viewer.