[1714] | 1 | #!/bin/bash |
---|
[1726] | 2 | yes | cp ../context_grid_dynamico.xml ./ |
---|
| 3 | yes | cp ../dynamico_grid.nc ./ |
---|
[1714] | 4 | |
---|
[1726] | 5 | yes | cp ../user_config.py sub_config1.py |
---|
| 6 | yes | cp ../config.py sub_config2.py |
---|
| 7 | yes | cp ../check.py sub_check.py |
---|
| 8 | yes | cp ../default_param.py default_param.py |
---|
[1714] | 9 | |
---|
| 10 | |
---|
[1721] | 11 | # Black 0;30 Dark Gray 1;30 |
---|
| 12 | # Red 0;31 Light Red 1;31 |
---|
| 13 | # Green 0;32 Light Green 1;32 |
---|
| 14 | # Brown/Orange 0;33 Yellow 1;33 |
---|
| 15 | # Blue 0;34 Light Blue 1;34 |
---|
| 16 | # Purple 0;35 Light Purple 1;35 |
---|
| 17 | # Cyan 0;36 Light Cyan 1;36 |
---|
| 18 | # Light Gray 0;37 White 1;37 |
---|
[1714] | 19 | |
---|
[1721] | 20 | |
---|
[1726] | 21 | |
---|
[1721] | 22 | Color='\033[0;36m' |
---|
| 23 | NC='\033[0m' # No Color |
---|
| 24 | |
---|
[1714] | 25 | touch report.txt |
---|
| 26 | > report.txt |
---|
[1716] | 27 | echo " " >> report.txt |
---|
| 28 | echo " " >> report.txt |
---|
[1727] | 29 | echo -e "testing ${Color}grid${NC} algorithms..." >> report.txt |
---|
[1716] | 30 | echo " " >> report.txt |
---|
[1714] | 31 | |
---|
[1723] | 32 | touch report.html |
---|
| 33 | > report.html |
---|
[1725] | 34 | echo "<br> " >> report.html |
---|
| 35 | echo "<br> " >> report.html |
---|
| 36 | echo "<br> " >> report.html |
---|
[1727] | 37 | echo "<p>testing <font color="blue">grid</font> algorithms...</p>" >> report.html |
---|
[1725] | 38 | echo "<br> " >> report.html |
---|
[1723] | 39 | |
---|
[1714] | 40 | nb_config=$(python sub_config1.py 2>&1) |
---|
| 41 | |
---|
| 42 | |
---|
| 43 | counter=0 |
---|
| 44 | while [ $counter -lt $nb_config ] |
---|
| 45 | do |
---|
| 46 | |
---|
| 47 | rm -f user_param.py |
---|
| 48 | |
---|
| 49 | cp user_param.py.$counter user_param.py |
---|
| 50 | |
---|
| 51 | ((counter++)) |
---|
| 52 | |
---|
| 53 | nb_proc=$(python sub_config2.py 2>&1) |
---|
| 54 | |
---|
[1725] | 55 | if [[ ($machine_name == irene) ]] |
---|
[1718] | 56 | then |
---|
| 57 | ccc_mprun -n $nb_proc ../../build_prod/bin/generic_testcase.exe |
---|
[1725] | 58 | elif [[($machine_name == ada)]] |
---|
| 59 | then |
---|
| 60 | echo "Testing on ADA" |
---|
| 61 | mpirun -np $nb_proc ../../build_prod/bin/generic_testcase.exe |
---|
| 62 | elif [[($machine_name == jeanzay)]] |
---|
| 63 | then |
---|
| 64 | echo "Testing on Jean-Zay" |
---|
| 65 | srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe |
---|
[1718] | 66 | else |
---|
[1725] | 67 | echo "other machine" |
---|
[1718] | 68 | fi |
---|
[1714] | 69 | |
---|
| 70 | python sub_check.py |
---|
| 71 | |
---|
| 72 | rm -f iodef.xml |
---|
| 73 | mv iodef.xml.bkp iodef.xml |
---|
| 74 | |
---|
| 75 | done |
---|
[1726] | 76 | rm -f default_param.py |
---|
| 77 | rm -f default_param.pyc |
---|
| 78 | rm -f user_param.pyc |
---|
| 79 | rm -f user_param.py.* |
---|
| 80 | rm -f sub_*.py |
---|