From fed8b849da2532101a206c05987170fa4a7f4c6e Mon Sep 17 00:00:00 2001 From: caes Date: Thu, 4 Aug 2016 14:13:23 -0400 Subject: [PATCH] fixing some thor functionality --- scripts/analyze_lightcurves.sh | 46 ++++++++++++++++++---------------- 1 file changed, 25 insertions(+), 21 deletions(-) diff --git a/scripts/analyze_lightcurves.sh b/scripts/analyze_lightcurves.sh index 36e5ce3..2ef3061 100755 --- a/scripts/analyze_lightcurves.sh +++ b/scripts/analyze_lightcurves.sh @@ -114,28 +114,28 @@ do echo -n "1000 50 400 mcmc_${echo_band}.dat" >> tmp.psdlagargs # Run psdlag with inputs - if [[ -e $outputfile ]] + if [[ $1 == "thor" || $(hostname) == "thor.cs.wmich.edu"]] then - echo -n " Analysis already exists; skipping." - else - if [[ $1 == "thor" ]] + echo_band_noUTF=$(echo $echo_band| + #sed 's|𝛌||g'| + #sed 's|(|_|g'| + #sed 's|)|_|g'| + sed 's|=||g'| + sed 's|Å|A|g') + outputfile_noUTF=$(echo $outputfile| + #sed 's|𝛌||g'| + #sed 's|(|_|g'| + #sed 's|)|_|g'| + sed 's|=||g'| + sed 's|[{}]|_|g'| + sed 's|;|_|'| + sed 's|Å|A|g'| + sed 's|_≺_|_|g'| + sed 's|σ∊|err|') + if [[ -e $outputfile_noUTF ]] then - echo_band_noUTF=$(echo $echo_band| - #sed 's|𝛌||g'| - #sed 's|(|_|g'| - #sed 's|)|_|g'| - sed 's|=||g'| - sed 's|Å|A|g') - outputfile_noUTF=$(echo $outputfile| - #sed 's|𝛌||g'| - #sed 's|(|_|g'| - #sed 's|)|_|g'| - sed 's|=||g'| - sed 's|[{}]|_|g'| - sed 's|;|_|'| - sed 's|Å|A|g'| - sed 's|_≺_|_|g'| - sed 's|σ∊|err|') + echo -n " Analysis already exists; skipping." + else argsfile="thor/arguments/$echo_band_noUTF.args" submitscript="thor/${echo_band_noUTF}.pbs" cp tmp.psdlagargs $argsfile @@ -147,9 +147,13 @@ do cd thor qsub $(basename $submitscript) >> submissions cd .. + fi + else + if [[ -e $outputfile ]] + then + echo -n " Analysis already exists; skipping." else time bin/psdlag tmp.psdlagargs > $outputfile - fi fi echo "" done