From 08a7757349aa67601ef1d4b845a0a9195cc4fdd4 Mon Sep 17 00:00:00 2001 From: jiang548 Date: Wed, 4 May 2022 11:26:51 -0400 Subject: [PATCH] add interactive progress bar --- script/network/bts1gensub.sh | 3 ++- script/network/bts2gensub.sh | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/script/network/bts1gensub.sh b/script/network/bts1gensub.sh index e649a81..d35835c 100755 --- a/script/network/bts1gensub.sh +++ b/script/network/bts1gensub.sh @@ -1,5 +1,4 @@ #!/bin/bash - #testing runtime and memeory echo -e "Begin testing on the first bootstrap data with the first 10 genes\n" @@ -76,6 +75,8 @@ perl -pe 's/XXX/'$CHUNK'/g' < $SIGNET_SCRIPT_ROOT/network/template.sub > sub$CHU echo "sbatch -W sub$CHUNK.sh &" >> qsub1.sh fi +walltime_s=$(echo $walltime | awk -F: '{ print (3600 * $1) + (60 * $2) + $3 }') +echo "progress_bar $walltime_s 100 40 params $NJOBS slurm" >> qsub1.sh echo "wait" >> qsub1.sh #tmpqueue=($(slist|grep $queue)) diff --git a/script/network/bts2gensub.sh b/script/network/bts2gensub.sh index 24db1fa..3d2f99a 100755 --- a/script/network/bts2gensub.sh +++ b/script/network/bts2gensub.sh @@ -79,6 +79,8 @@ perl -pe 's/XXX/'$CHUNK'/g' < $SIGNET_SCRIPT_ROOT/network/template.sub > sub$CHU echo "sbatch -W sub$CHUNK.sh &" >> qsub2.sh fi +walltime_s=$(echo $walltime | awk -F: '{ print (3600 * $1) + (60 * $2) + $3 }') +echo "progress_bar $walltime_s 100 40 params $NJOBS slurm" >> qsub2.sh echo "wait" >> qsub2.sh #tmpqueue=($(slist|grep $queue))