From 79b6a837f84d48ae47e1067f5f043270fb9160a6 Mon Sep 17 00:00:00 2001 From: augustin64 Date: Wed, 5 Jun 2024 13:40:40 +0200 Subject: [PATCH] Create `analyse_results.sh` --- cache_utils/2T/analyse.sh | 5 +++-- cache_utils/analyse_results.sh | 18 ++++++++++++++++++ 2 files changed, 21 insertions(+), 2 deletions(-) create mode 100755 cache_utils/analyse_results.sh diff --git a/cache_utils/2T/analyse.sh b/cache_utils/2T/analyse.sh index 1715eb9..1f58abc 100755 --- a/cache_utils/2T/analyse.sh +++ b/cache_utils/2T/analyse.sh @@ -1,7 +1,8 @@ #!/bin/sh -NAME=`basename "$1" .txt.bz2` -echo $NAME +# NAME=`basename "$1" .txt.bz2` +# echo $NAME +NAME=$1 #bzcat $1 | awk '/^Iteration [:digit:]*[.]*/ ' > "${NAME}-iterations.txt" #rm "${NAME}-results.csv.bz2" diff --git a/cache_utils/analyse_results.sh b/cache_utils/analyse_results.sh new file mode 100755 index 0000000..cbdb9c8 --- /dev/null +++ b/cache_utils/analyse_results.sh @@ -0,0 +1,18 @@ +#!/bin/bash +# Assumes the input file has no extension and isn't bzip compressed +# Automatically runs the different analysis scripts + +exit_echo () { + echo $@; + exit 1; +} + +[[ $1 ]] || exit_echo "Usage: $0 "; +[[ -f $1.slices.csv ]] || exit_echo "$1.slices.csv not found" +[[ -f $1.cores.csv ]] || exit_echo "$1.cores.csv not found" + +bash 2T/analyse.sh $1 + +. venv/bin/activate +python analyse_csv.py $1 +python analyse_medians.py $1