Jpp - the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JAHRS.sh
Go to the documentation of this file.
1 #!/bin/zsh
2 #
3 #
4 # \author mdejong
5 #
6 version=1.0
7 script=${0##*/}
8 
9 if [ -z $JPP_DIR ]; then
10  echo "Variable JPP_DIR undefined."
11  exit
12 fi
13 
14 source $JPP_DIR/setenv.sh $JPP_DIR
15 
16 set_variable: DEBUG COMPASS_DEBUG 2
17 set_variable: WORKDIR COMPASS_WORKDIR ./
18 
19 if do_usage $*; then
20  usage "$script <detector file> (run[-run])+"
21 fi
22 
23 if (( $# > 1 )); then
24  set_variable DETECTOR_ID $argv[1]
25  set_array RUNS $argv[2,-1]
26 else
27  fatal "Wrong number of arguments."
28 fi
29 
30 JCookie.sh
31 
32 for RANGE in $RUNS[*]; do
33 
34  for (( RUN = ${RANGE%%-*}; $RUN <= ${RANGE##*-}; RUN += 1 )); do
35 
36  set_variable AHRS_FILE $WORKDIR/KM3NeT_${(l:8::0::0:)DETECTOR_ID}_${(l:8::0::0:)RUN}_ahrs.root
37 
38  if [[ ! -f $AHRS_FILE ]]; then
39 
40  echo -n "Writing $AHRS_FILE... "
41 
42  JConvertDB \
43  -q "ahrs" \
44  -@ "detid = $DETECTOR_ID" \
45  -@ "minrun = $RUN" \
46  -@ "maxrun = $RUN" \
47  -o $AHRS_FILE \
48  -d $DEBUG --
49 
50  if (( $? == 0 )); then
51  echo "OK"
52  else
53  echo "no data"
54  fi
55  fi
56  done
57 done
then usage else fatal Wrong number of arguments fi JCookie sh eval JPrintDetector a $DETECTOR O IDENTIFIER source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE for RANGE in $RUNS[*]
exit
Definition: JPizza.sh:36
then JPizza f
Definition: JPizza.sh:46
then echo
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
Definition: JAcoustics.sh:20
then rm i $OUTPUT_FILE fi let RUN
do $DIR JTransitTime o
Definition: JTransitTime.sh:44
* usage
*set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2,-2] set_variable OUTPUT_FILE $argv[-1]
Definition: JDomino.sh:39
then JMuonMCEvt f $INPUT_FILE o $INTERMEDIATE_FILE d
Definition: JMuonPath.sh:45
alias put_queue eval echo n
Definition: qlib.csh:19
then usage $script< input_file >< detector_file > fi set_variable OUTPUT_DIR set_variable SELECTOR JDAQTimesliceL1 set_variable DEBUG case set_variable DEBUG
then display $WORKDIR
Definition: plot-Domino.sh:127
set_array RUNS
Definition: JDataQuality.sh:23
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable DEBUG set_variable WORKDIR tmp set_variable JDAQ_TIMESLICE JDAQTimeslice if do_usage *then usage $script< detector file >< inputfile > fi case set_variable WORKDIR
Definition: JLegolas.sh:23
do set_variable INPUT_FILE $WORKDIR KM3NeT_
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
Definition: JCanberra.sh:38
version
Definition: JCalibratePMT.sh:7
esac done
Definition: JAddHDE.sh:21
do if[[!-f $ACOUSTICS_WORKDIR/${KEY}.txt]]
Definition: JAcoustics.sh:38