Accept .txt.bz2 files

This commit is contained in:
augustin64 2024-06-05 15:57:29 +02:00
parent f7dfbe5ead
commit e0180e9b52
2 changed files with 9 additions and 9 deletions

View File

@ -1,8 +1,7 @@
#!/bin/sh #!/bin/sh
# NAME=`basename "$1" .txt.bz2` NAME="${1%%.*}"
# echo $NAME echo $NAME
NAME=$1
#bzcat $1 | awk '/^Iteration [:digit:]*[.]*/ ' > "${NAME}-iterations.txt" #bzcat $1 | awk '/^Iteration [:digit:]*[.]*/ ' > "${NAME}-iterations.txt"
#rm "${NAME}-results.csv.bz2" #rm "${NAME}-results.csv.bz2"

View File

@ -1,18 +1,19 @@
#!/bin/bash #!/bin/bash
# Assumes the input file has no extension and isn't bzip compressed # Automatically run the different analysis scripts
# Automatically runs the different analysis scripts
exit_echo () { exit_echo () {
echo $@; echo $@;
exit 1; exit 1;
} }
NAME="${1%%.*}"
[[ $1 ]] || exit_echo "Usage: $0 <file>"; [[ $1 ]] || exit_echo "Usage: $0 <file>";
[[ -f $1.slices.csv ]] || exit_echo "$1.slices.csv not found" [[ -f $NAME.slices.csv ]] || exit_echo "$NAME.slices.csv not found"
[[ -f $1.cores.csv ]] || exit_echo "$1.cores.csv not found" [[ -f $NAME.cores.csv ]] || exit_echo "$NAME.cores.csv not found"
bash 2T/analyse.sh $1 bash 2T/analyse.sh $1
. venv/bin/activate . venv/bin/activate
python analyse_csv.py $1 python analyse_csv.py $NAME
python analyse_medians.py $1 python analyse_medians.py $NAME