Skip to content

Commit

Permalink
Values extraction #53 report-path corection
Browse files Browse the repository at this point in the history
  • Loading branch information
tanguypierre committed Jun 27, 2024
1 parent b2eaa46 commit 353ba53
Showing 1 changed file with 16 additions and 8 deletions.
24 changes: 16 additions & 8 deletions launchProcess.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,19 @@ valid_machines=("discoverer" "gaya" "karolina" "meluxina" "local")
valid_toolboxes=("alemesh" "coefficientformpdes" "electric" "fluid" "fsi" "hdg" "heat" "heatfluid" "solid" "thermoelectric")



# +-------------------------------------------------+
# | ARGUMENTS CHECK |
# +-------------------------------------------------+


hostname=""
toolboxes=()
cases=()
directories=()
listing=false


if [ $# -lt 1 ] || [ "$*" == "-h" ] || [ "$*" == "--help" ]; then
usage
exit 0
Expand All @@ -43,11 +52,6 @@ if ! [[ " ${valid_machines[@]} " =~ " $hostname " ]]; then
exit 0
fi

toolboxes=()
cases=()
directories=()
listing=false

while [[ $# -gt 0 ]]; do
case "$1" in
-a|--all)
Expand Down Expand Up @@ -110,10 +114,13 @@ if { [ ${#cases[@]} -gt 0 ] || [ ${#directories[@]} -gt 0 ]; } && [ ${#toolboxes
exit 1
fi



# +-------------------------------------------------+
# | PROCESS START |
# +-------------------------------------------------+


rm -rf ~/feelppdb
rm -rf ./build/reframe/output/ ./build/reframe/stage/ ./build/reframe/perflogs

Expand All @@ -127,7 +134,7 @@ disk_path="/home"

export RFM_TEST_DIR=$(pwd)/src/feelpp/benchmarking/reframe/regression-tests
export FEELPP_TOOLBOXES_CASES=/usr/share/feelpp/data/testcases/toolboxes
export FEELPP_OUTPUT_PREFIX="${disk_path}/${USER}/feelppdbTANGUYYYY"
export FEELPP_OUTPUT_PREFIX="${disk_path}/${USER}/feelppdb"

columns=$(tput cols)
current_date=$(date +%Y%m%d)
Expand All @@ -144,7 +151,7 @@ for tb in "${toolboxes[@]}"; do

while read -r cfgPath; do
relative_path=${cfgPath#"$FEELPP_TOOLBOXES_CASES"}
relative_dir=$(dirname "$relative_path")
relative_dir=$(dirname "${relative_path#*/cases/}")
base_name=$(basename "${relative_path%.cfg}")

matched=true
Expand Down Expand Up @@ -172,14 +179,15 @@ for tb in "${toolboxes[@]}"; do
if $matched; then
counter=$((counter + 1))
toolboxCounter=$((toolboxCounter + 1))

if $listing; then
echo "$relative_path"
else
echo ""
yes '-' | head -n "$columns" | tr -d '\n'
echo "[Starting $relative_path]"
report_path=$(pwd)/docs/modules/${hostname}/pages/reports/${tb}/${relative_dir}/${current_date}-${base_name}.json
reframe -c "$RFM_TEST_DIR/heatTest.py" -S "case=$cfgPath" -r --system="$hostname" --report-file="$report_path"
#reframe -c "$RFM_TEST_DIR/heatTest.py" -S "case=$cfgPath" -r --system="$hostname" --report-file="$report_path"
fi
fi
done < <(find "$extended_path" -type f -name "*.cfg")
Expand Down

0 comments on commit 353ba53

Please sign in to comment.