example-flow.sh 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #!/bin/bash
  2. INFILE=$1
  3. OUTFILE=$2
  4. RES_FIT_FILE=$3
  5. DCAFILE=$4
  6. #SBATCH --time=0:15:00
  7. #SBATCH -D /tmp
  8. PROJECT_DIR=/lustre/nyx/hades/user/parfenov/mpd_summer2019/real-flow
  9. TMPDIR=$PROJECT_DIR/TMPFLOW/TMP_${SLURM_JOB_ID}
  10. mkdir -p $TMPDIR
  11. OUTDIR=${OUTFILE%/*}
  12. AFTERSLASHNAME=${INFILE##*/}
  13. BASENAME=${AFTERSLASHNAME%.*}
  14. LOG=${OUTDIR}/${BASENAME}_flow.OUT
  15. ERR=${OUTDIR}/${BASENAME}_flow.ERR
  16. #. /lustre/nyx/hades/user/parfenov/Soft/MPDRoot/build/config.sh
  17. #source /cvmfs/hades.gsi.de/install/5.34.34/hydra2-4.9n/defall.sh
  18. cp $PROJECT_DIR/utility.C $TMPDIR
  19. cp $PROJECT_DIR/utility.h $TMPDIR
  20. cp $PROJECT_DIR/MpdCalculator.C $TMPDIR
  21. cp $PROJECT_DIR/MpdCalculator.h $TMPDIR
  22. cp $PROJECT_DIR/main_flow.C $TMPDIR
  23. cp $PROJECT_DIR/compile.sh $TMPDIR
  24. cp $PROJECT_DIR/SpecFuncMathMore.h $TMPDIR
  25. cp $PROJECT_DIR/example-resolutions.sh $TMPDIR
  26. cd $TMPDIR
  27. ls 1>$LOG 2>$ERR
  28. . compile.sh 1>> $LOG 2>> $ERR
  29. ls >> $LOG
  30. root -l -b -q 'main_flow.C+("'${INFILE}'","'${OUTFILE}'","'$RES_FIT_FILE'","'${DCAFILE}'")' 1>> $LOG 2>> $ERR
  31. cd $PROJECT_DIR
  32. rm -rf $TMPDIR