Jpp  18.3.0-rc.1
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JReconstructDetector.sh
Go to the documentation of this file.
1 #!/bin/zsh
2 script=${0##*/}
3 
4 # ------------------------------------------------------------------------------------------
5 #
6 # Auxiliary script to test destruction and construction of detector.
7 #
8 # ------------------------------------------------------------------------------------------
9 
10 
11 if [ -z $JPP_DIR ]; then
12  echo "Variable JPP_DIR undefined."
13  exit
14 fi
15 
16 source $JPP_DIR/setenv.sh $JPP_DIR >& /dev/null
17 
19 set_variable PRECISION 5.0e-3
21 
22 if do_usage $*; then
23  usage "$script <detector file> [working directory]"
24 fi
25 
26 case $# in
27  2) set_variable WORKDIR $2;&
29  *) fatal "Wrong number of arguments."
30 esac
31 
32 set_variable CALIBRATION $WORKDIR/calibration.txt
33 
34 function clean()
35 {
36  rm -f $CALIBRATION
37  rm -f $WORKDIR/skeleton.dat
38  rm -f $WORKDIR/detector.dat
39 }
40 
41 clean
42 
43 
44 JDestructDetector \
45  -a $DETECTOR \
46  -o $CALIBRATION \
47  -p $PRECISION \
48  -d $DEBUG
49 
50 JEditDetector \
51  -a $DETECTOR \
52  -o $WORKDIR/skeleton.dat \
53  -M "-1 reset" \
54  -d $DEBUG
55 
56 JConstructDetector \
57  -a $WORKDIR/skeleton.dat \
58  -f $CALIBRATION \
59  -o $WORKDIR/detector.dat \
60  -d $DEBUG
61 
63 
64 JCompareDetector \
65  -a $DETECTOR \
66  -b $WORKDIR/detector.dat \
67  -p "tcal = $PRECISION" \
68  -p "pcal = $PRECISION" \
69  -p "rcal = $PRECISION" \
70  -p "ccal = $PRECISION" \
71  -d $DEBUG
72 
73 
74 CHECK_EXIT_CODE
75 
76 #clean
77 
o $QUALITY_ROOT d $DEBUG!CHECK_EXIT_CODE JPlot1D f
Definition: JDataQuality.sh:76
usr share Modules init zsh export TMPDIR
exit
Definition: JPizza.sh:36
then
Definition: datalogs.sh:31
then fatal Wrong number of arguments fi JConvertDetectorFormat a o
then rm
Definition: sftpput.zsh:30
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
Definition: JAcoustics.sh:21
then JCalibrateToT a
Definition: JTuneHV.sh:113
case $OPTION in clean clean
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable DEBUG set_variable WORKDIR
Definition: JLegolas.sh:20
* usage
fi set_variable FILENAME $WORKDIR
Definition: datalogs.sh:34
then JMuonMCEvt f $INPUT_FILE o $INTERMEDIATE_FILE d
Definition: JMuonPath.sh:47
then set_variable MODULE getModule a $DETECTOR L $STRING $FLOOR JEditDetector a $DETECTOR M $MODULE add $X o $DETECTOR else echo No update of detector $DETECTOR
set_variable DETECTOR
do set_variable DETECTOR_TXT $WORKDIR detector
then echo
Definition: JQAQC.sh:90
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 JAcoustics sh $DETECTOR_ID source JAcousticsToolkit sh CHECK_EXIT_CODE typeset A EMITTERS get_tripods $WORKDIR tripod txt EMITTERS get_transmitters $WORKDIR transmitter txt EMITTERS for EMITTER in
Definition: JCanberra.sh:48
script
Definition: JAcoustics.sh:2
esac $JPP_BIN JLogger sh $LOGGER until pgrep JGetMessage</dev/null > dev null
#define DEBUG(A)
Message macros.
Definition: JMessage.hh:62