2727
2828# ## ---------------------------------------------------------------------------
2929
30- if [ " 0 $1 " != " 0dd " ] && [ " 0 $1 " != " 0rr " ] && [ " 0 $1 " != " 0tf " ]; then
30+ if [[ $1 != " dd " && $1 != " rr " && $1 != " tf " ] ]; then
3131 echo Please indicate whether to start with raw-reader [rr] or with DataDistribution [dd] or TfReader [tf] 1>&2
3232 exit 1
3333fi
3434
3535if [[ -f local_env.sh ]]; then source ./local_env.sh; fi
3636
37- export ALICE_O2_FST=1
37+ if [[ -z $ALICE_O2_FST ]] ; then export ALICE_O2_FST=1; fi
3838
3939if [[ -z " ${WORKFLOW_PARAMETERS+x} " ]]; then
4040 export WORKFLOW_PARAMETERS=" CALIB,QC,EVENT_DISPLAY,CALIB_LOCAL_AGGREGATOR"
41- if [[ " 0 $FST_TMUX_INTEGRATED_AGGREGATOR " == " 01 " ]]; then
41+ if [[ $FST_TMUX_INTEGRATED_AGGREGATOR == 1 ]]; then
4242 export WORKFLOW_PARAMETERS=" ${WORKFLOW_PARAMETERS} ,CALIB_LOCAL_INTEGRATED_AGGREGATOR"
4343 else
4444 export WORKFLOW_PARAMETERS=" ${WORKFLOW_PARAMETERS} ,CALIB_PROXIES"
@@ -51,9 +51,9 @@ if [[ -z "${WORKFLOW_PARAMETERS+x}" ]]; then
5151fi
5252[[ -z " ${SEVERITY} " ]] && export SEVERITY=" important"
5353
54- if [[ " 0 $FST_TMUX_NO_EPN " != " 01 " ]]; then
54+ if [[ $FST_TMUX_NO_EPN != 1 ]]; then
5555 # This sets up the hardcoded configuration to run the full system workflow on the EPN
56- if [[ " 0 $EPN_NODE_MI100 " == " 01 " && -z $EPN_GLOBAL_SCALING ]]; then
56+ if [[ $EPN_NODE_MI100 == 1 && -z $EPN_GLOBAL_SCALING ]]; then
5757 export EPN_GLOBAL_SCALING=" 3 / 2"
5858 fi
5959 [[ -z $NGPUS ]] && export NGPUS=4
@@ -69,7 +69,7 @@ if [[ "0$FST_TMUX_NO_EPN" != "01" ]]; then
6969 export ALL_EXTRA_CONFIG=" $ALL_EXTRA_CONFIG ;NameConf.mCCDBServer=${DPL_CONDITION_BACKEND} ;"
7070 export GEN_TOPO_QC_OVERRIDE_CCDB_SERVER=" ${DPL_CONDITION_BACKEND} "
7171 [[ -z $NUM_DPL_WORKFLOWS ]] && NUM_DPL_WORKFLOWS=2
72- if [[ ` lspci | grep " Vega 20\|Arcturus GL-XL" | wc -l` != " 8" ]]; then
72+ if [[ $GPUTYPE == " HIP " && $NGPUS == 4 && ` lspci | grep " Vega 20\|Arcturus GL-XL" | wc -l` != " 8" ]]; then
7373 echo " Could not detect 8 EPN GPUs, aborting" 1>&2
7474 exit 1
7575 fi
@@ -96,31 +96,31 @@ if [[ -z ${DPL_RAWPROXY_OVERRIDE_ORBITRESET+x} && $1 == "dd" ]]; then
9696 fi
9797fi
9898
99- if [ " 0 $FST_TMUX_MEM_OVERRIDE " != " 0 " ]; then
99+ if [[ -n $FST_TMUX_MEM_OVERRIDE ] ]; then
100100 export SHMSIZE=$(( $FST_TMUX_MEM_OVERRIDE << 30 ))
101101 export DDSHMSIZE=$(( $FST_TMUX_MEM_OVERRIDE << 10 ))
102102fi
103103
104- if [ $1 == " dd" ]; then
104+ if [[ $1 == " dd" ] ]; then
105105 export CMD=datadistribution.sh
106106 export GPU_NUM_MEM_REG_CALLBACKS=$(( $NUM_DPL_WORKFLOWS + 3 ))
107- elif [ $1 == " tf" ]; then
107+ elif [[ $1 == " tf" ] ]; then
108108 export CMD=tf-reader.sh
109109 export GPU_NUM_MEM_REG_CALLBACKS=$(( NUM_DPL_WORKFLOWS + ${NUMAGPUIDS:- 0} ))
110- elif [ $1 == " rr" ]; then
110+ elif [[ $1 == " rr" ] ]; then
111111 export CMD=raw-reader.sh
112112 export GPU_NUM_MEM_REG_CALLBACKS=$(( $NUM_DPL_WORKFLOWS + ${NUMAGPUIDS:- 0} ))
113113fi
114114
115- if [ " 0 $FST_TMUX_NOWAIT " != " 01 " ]; then
115+ if [[ $FST_TMUX_NOWAIT != 1 ] ]; then
116116 ENDCMD=" echo END; sleep 1000"
117117fi
118118
119- if [ " 0 $FST_TMUX_KILLCHAINS " == " 01 " ]; then
119+ if [[ $FST_TMUX_KILLCHAINS == 1 ] ]; then
120120 KILLCMD=" sleep 60; ps aux | grep 'o2-dpl-run --session' | grep -v grep | awk '{print \$ 2}' | xargs kill -s INT --;"
121121fi
122122
123- if [ " 0 $FST_TMUX_LOGPREFIX " != " 0 " ]; then
123+ if [[ -n $FST_TMUX_LOGPREFIX ] ]; then
124124 LOGCMD=" &> ${FST_TMUX_LOGPREFIX} _[REPLACE].log"
125125fi
126126
147147 : ${CALIB_TASKS:= " " }
148148fi
149149
150- if [ " 0 $FST_TMUX_BATCH_MODE " == " 01 " ]; then
150+ if [[ $FST_TMUX_BATCH_MODE == 1 ] ]; then
151151 { sleep $FST_SLEEP0 ; eval " NUMAID=0 $GEN_TOPO_MYDIR /dpl-workflow.sh ${LOGCMD/ \[ REPLACE]/ 0} " ; eval " $ENDCMD " ; } &
152152 { sleep $FST_SLEEP1 ; eval " NUMAID=1 $GEN_TOPO_MYDIR /dpl-workflow.sh ${LOGCMD/ \[ REPLACE]/ 1} " ; eval " $ENDCMD " ; } &
153153 { sleep $FST_SLEEP2 ; eval " SEVERITY=debug numactl --interleave=all $GEN_TOPO_MYDIR /$CMD ${LOGCMD/ \[ REPLACE]/ 2} " ; eval " $KILLCMD $ENDCMD " ; } &
0 commit comments