Skip to content
Snippets Groups Projects
Commit 5fc850cc authored by jourdain's avatar jourdain
Browse files

Abinit: standardize validate.sh

parent a1822381
No related branches found
No related tags found
No related merge requests found
#!/bin/bash
#set -x
mkdir results-abinit-au31_small
cp -a abinit_test_au31.out* abinit_test_au31.log* abinit_test_au31.files abinit_test_au31.in au.hpc.paw results-abinit-au31_small/
file=abinit_test_au31.out
max_allowed_diff=00000.1
Tot_energy_good=-28668.51038046899999933714
Tot_energy=$(printf -- "%.25g" `grep 'Total energy in eV' $file | awk '{print $6}'`)
echo $Tot_energy_good $Tot_energy $max_allowed_diff| awk '{if (sqrt(($1 - $2)^2) > $3) print "ERROR Total energy differs more than "$3; else print "OK accurate Total energy"}'
grep -i "individual time" abinit_test_au31.out | awk -Fwall= '{print "time="$2}'
if [ -z "$Tot_energy" ]
then
echo "bench is not validated"
else
echo "bench is validated"
echo $Tot_energy_good $Tot_energy $max_allowed_diff| awk '{if (sqrt(($1 - $2)^2) > $3) print "ERROR Total energy differs more than "$3; else print "OK accurate Total energy"}'
grep -i "individual time" abinit_test_au31.out | awk -Fwall= '{print "time="$2}'
fi
#!/bin/bash
#set -x
mkdir results-abinit-ti255_big
cp -a abinit_test_ti255.out* abinit_test_ti255.log* abinit_test_ti255.files abinit_test_ti255.in ti.hpc.paw results-abinit-ti255_big/
......@@ -9,7 +8,11 @@ max_allowed_diff=000000.01
Tot_energy_good=-405774.5462722299999995812
Tot_energy=$(printf -- "%.25g" `grep 'Total energy in eV' $file | awk '{print $6}'`)
echo $Tot_energy_good $Tot_energy $max_allowed_diff| awk '{if (sqrt(($1 - $2)^2) > $3) print "ERROR Total energy differs more than "$3; else print "OK accurate Total energy"}'
grep -i "individual time" abinit_test_ti255.out | awk -Fwall= '{print "time="$2}'
if [ -z "$Tot_energy" ]
then
echo "bench is not validated"
else
echo "bench is validated"
echo $Tot_energy_good $Tot_energy $max_allowed_diff| awk '{if (sqrt(($1 - $2)^2) > $3) print "ERROR Total energy differs more than "$3; else print "OK accurate Total energy"}'
grep -i "individual time" abinit_test_ti255.out | awk -Fwall= '{print "time="$2}'
fi
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment