Changeset 15401 for trunk/DataCheck
- Timestamp:
- 04/21/13 01:51:13 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DataCheck/QuickLook/Step3.sh
r15390 r15401 32 32 fi 33 33 34 # get last 3, 6 or 9 nights 35 dates=( `date +%Y/%m/%d --date="-12hour"` `date +%Y/%m/%d --date="-36hour"` `date +%Y/%m/%d --date="-60hour"` \ 36 # `date +%Y/%m/%d --date="-84hour"` `date +%Y/%m/%d --date="-108hour"` `date +%Y/%m/%d --date="-132hour"` \ 37 # `date +%Y/%m/%d --date="-156hour"` `date +%Y/%m/%d --date="-180hour"` `date +%Y/%m/%d --date="-204hour"` \ 38 ) 39 #dates=( `find -L $ziprawdata -mindepth 3 -type d | sort -r | sed "s/\${ziprawdata_for_sed}//g" | sed -e 's/^\///'` ) #all available dates in /loc_data/zipraw 34 # get current hour 35 hour=`date +%k` 36 if [ $hour -le 7 ] || [ $hour -ge 19 ] 37 then 38 dates=( `date +%Y/%m/%d --date="-12hour"` ) 39 else 40 # get last 3, 6 or 9 nights 41 dates=( `date +%Y/%m/%d --date="-12hour"` `date +%Y/%m/%d --date="-36hour"` `date +%Y/%m/%d --date="-60hour"` \ 42 # `date +%Y/%m/%d --date="-84hour"` `date +%Y/%m/%d --date="-108hour"` `date +%Y/%m/%d --date="-132hour"` \ 43 # `date +%Y/%m/%d --date="-156hour"` `date +%Y/%m/%d --date="-180hour"` `date +%Y/%m/%d --date="-204hour"` \ 44 ) 45 fi 46 dates=( `find -L $auxdata -mindepth 3 -type d | sort -r | sed "s/\${auxdata_for_sed}//g" | sed -e 's/^\///'` ) #all available dates in /loc_data/zipraw 40 47 41 dates=( "2013/04/19" )48 #dates=( "2013/04/19" ) 42 49 43 50 # source info on daq in /loc_data/analysis/sources.txt … … 46 53 timebins=( 5 10 20 30 40 60 90 120 180 240 300 360 ) 47 54 55 echo ${dates[@]} 48 56 for date in ${dates[@]} 49 57 do … … 51 59 query="SELECT fSourceKEY FROM RunInfo WHERE fNight="$date2" AND fSourceKey > 0 AND fRunTypeKEY=1 GROUP BY fSourceKey " 52 60 sources=( `sendquery` ) 61 echo "process "$date" -> sources: "${sources[@]} 53 62 for source in ${sources[@]} 54 63 do … … 75 84 ;; 76 85 *) printprocesslog "ERROR lightcurve.C failed for source "$source" timebin "$timebin" night "$date2" (check1=$check1)" 86 ;; 87 esac 88 89 90 # doing the plots for last week 91 lastweek=`date +%Y%m%d --date="$date -1 week"` 92 logfile=$outpath"/lightcurve"$source"_"$timebin"min_week.log" 93 outfile=$outpath"/lightcurve"$source"_"$timebin"min_week.root" 94 echo $outfile 95 printprocesslog "INFO starting lightcurve.C+ for source "$source" timebin "$timebin" night "$date2" last week ("$lastweek")" 96 97 check1=`root -q -b $mars2/fact/analysis/lightcurve.C+\($source\,$lastweek\\,$date2\,$timebin\,"\"$resulttable1"\"\,"\"$outfile\""\) | tee $logfile | intgrep` 98 99 case $check1 in 100 0) printprocesslog "INFO lightcurve.C was successful for source "$source" timebin "$timebin" night "$date2" last week (check1=$check1)" 101 ./showplot -b --save-as-png $outfile 102 ;; 103 1) printprocesslog "INFO lightcurve.C was successful for source "$source" timebin "$timebin" night "$date2" last week, but nothing to plot (check1=$check1)" 104 ;; 105 *) printprocesslog "ERROR lightcurve.C failed for source "$source" timebin "$timebin" night "$date2" last week (check1=$check1)" 77 106 ;; 78 107 esac
Note:
See TracChangeset
for help on using the changeset viewer.