Changeset 1726


Ignore:
Timestamp:
09/27/19 11:40:33 (5 years ago)
Author:
yushan
Message:

Generic_testcase : Cleanup and better organization

Location:
XIOS/dev/dev_trunk_omp
Files:
15 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/check.py

    r1725 r1726  
    6969                os.mkdir(configName+'/xios_output') 
    7070                 
    71                 os.system('cp param.def '+configName+'/setup/') 
    72                 os.system('cp all_param.def '+configName+'/setup/') 
    73                 os.system('cp iodef.xml '+configName+'/setup/') 
     71                os.system('mv param.def '+configName+'/setup/') 
     72                os.system('mv all_param.def '+configName+'/setup/') 
     73                os.system('mv user_param.py '+configName+'/setup/') 
     74                os.system('mv iodef.xml '+configName+'/setup/') 
    7475                os.system('cp context_atm.xml '+configName+'/setup/') 
    7576                os.system('cp context_grid_dynamico.xml '+configName+'/setup/') 
     
    8889                        line=line.rstrip() 
    8990                        if not line.startswith("#") and len(line) != 0: 
    90                                 cmd = 'cp -n '+line + ' '+configName+'/tmp_reference/' 
     91                                cmd = 'mv '+line + ' '+configName+'/tmp_reference/' 
    9192                                os.system(cmd) 
    9293 
     
    169170                h.close() 
    170171 
     172                if not os.path.exists('current_run'): 
     173                        os.mkdir('current_run') 
    171174 
     175                if not os.path.exists('current_run/'+configName): 
     176                        os.mkdir('current_run/'+configName) 
     177                os.system('mv -f param.def current_run/'+configName) 
     178                os.system('mv -f all_param.def current_run/'+configName) 
     179                os.system('mv -f user_param.py current_run/'+configName) 
     180                os.system('mv -f iodef.xml current_run/'+configName) 
     181                os.system('rm -f current_run/'+configName+'/context_atm.xml') 
     182                os.system('cp -n context_atm.xml current_run/'+configName) 
     183                os.system('cp -f context_grid_dynamico.xml current_run/'+configName) 
     184                os.system('cp -f dynamico_grid.nc current_run/'+configName) 
     185                os.system('mv -f xios_*.out current_run/'+configName) 
     186                os.system('mv -f xios_*.err current_run/'+configName) 
    172187 
    173188 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_axis_algo/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../context_grid_dynamico.xml ./ 
     3yes | cp ../dynamico_grid.nc ./ 
    24 
    3 rm -f sub_config1.py 
    4 rm -f sub_config2.py 
    5 rm -f sub_check.py 
    6 rm -f default_param.py 
    7  
    8 cp -n ../user_config.py sub_config1.py 
    9 cp -n ../config.py sub_config2.py 
    10 cp -n ../check.py sub_check.py 
    11 cp -n ../default_param.py default_param.py 
     5yes | cp ../user_config.py sub_config1.py 
     6yes | cp ../config.py sub_config2.py 
     7yes | cp ../check.py sub_check.py 
     8yes | cp ../default_param.py default_param.py 
    129 
    1310 
     
    5552 
    5653nb_proc=$(python sub_config2.py 2>&1)  
    57 nb_jz=$(($nb_proc-1)) 
    5854 
    5955if [[ ($machine_name == irene) ]] 
     
    6763then 
    6864    echo "Testing on Jean-Zay"  
    69     # touch srun.conf 
    70     # > srun.conf 
    71     # echo "0-"$nb_jz " ../../build_prod/bin/generic_testcase.exe">> srun.conf 
    72     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7365    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    7466else 
     
    8274 
    8375done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_axis_algo/user_params.def

    r1725 r1726  
    1111# e.g. NumberServers = 2, 4, 8   
    1212 
    13 NumberServers = 2 
     13NumberServers = 2, 4 
    1414ATMdomain='lmdz' 
    1515UsingServer2 = 'true' 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_domain_algo/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../context_grid_dynamico.xml ./ 
     3yes | cp ../dynamico_grid.nc ./ 
    24 
    3 rm -f sub_config1.py 
    4 rm -f sub_config2.py 
    5 rm -f sub_check.py 
    6 rm -f default_param.py 
     5yes | cp ../user_config.py sub_config1.py 
     6yes | cp ../config.py sub_config2.py 
     7yes | cp ../check.py sub_check.py 
     8yes | cp ../default_param.py default_param.py 
    79 
    8 cp -n ../user_config.py sub_config1.py 
    9 cp -n ../config.py sub_config2.py 
    10 cp -n ../check.py sub_check.py 
    11 cp -n ../default_param.py default_param.py 
    1210 
    1311# Black        0;30     Dark Gray     1;30 
     
    2927echo " " >> report.txt 
    3028echo " " >> report.txt 
    31 echo -e "testing ${Color}domain${NC} algorithms..." >> report.txt  
     29echo -e "testing ${Color}axis${NC} algorithms..." >> report.txt 
    3230echo " " >> report.txt 
    33  
    3431 
    3532touch report.html 
     
    3835echo "<br> " >> report.html 
    3936echo "<br> " >> report.html 
    40 echo "<p>testing  <font color="blue">domain</font> algorithms...</p>" >> report.html  
     37echo "<p>testing  <font color="blue">axis</font> algorithms...</p>" >> report.html  
    4138echo "<br> " >> report.html 
    4239 
     
    5552 
    5653nb_proc=$(python sub_config2.py 2>&1)  
    57 nb_jz=$(($nb_proc-1)) 
    5854 
    5955if [[ ($machine_name == irene) ]] 
     
    6763then 
    6864    echo "Testing on Jean-Zay"  
    69     # touch srun.conf 
    70     # > srun.conf 
    71     # echo "0-"$nb_jz " ../../build_prod/bin/generic_testcase.exe">> srun.conf 
    72     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7365    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    7466else 
    7567    echo "other machine" 
    7668fi 
    77  
    78  
    7969 
    8070python sub_check.py 
     
    8474 
    8575done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_average/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../../context_grid_dynamico.xml ./ 
     3yes | cp ../../dynamico_grid.nc ./ 
    24 
    3 cp -n  ../context_grid_dynamico.xml ./ 
    4 cp -n ../dynamico_grid.nc ./ 
     5yes | cp ../../user_config.py sub_config1.py 
     6yes | cp ../../config.py sub_config2.py 
     7yes | cp ../../check.py sub_check.py 
     8yes | cp ../../default_param.py default_param.py 
    59 
    6  
    7 rm -f sub_config1.py 
    8 rm -f sub_config2.py 
    9 rm -f sub_check.py 
    10 rm -f default_param.py 
    11  
    12 cp -n ../../user_config.py sub_config1.py 
    13 cp -n ../../config.py sub_config2.py 
    14 cp -n ../../check.py sub_check.py 
    15 cp -n ../../default_param.py default_param.py 
    1610 
    1711# Black        0;30     Dark Gray     1;30 
     
    2317# Cyan         0;36     Light Cyan    1;36 
    2418# Light Gray   0;37     White         1;37 
     19 
    2520 
    2621 
     
    3530echo " " >> report.txt 
    3631 
    37  
    3832touch report.html 
    3933> report.html 
     
    4337echo "<p>testing  <font color="blue">average</font> reduce...</p>" >> report.html  
    4438echo "<br> " >> report.html 
    45  
    4639 
    4740nb_config=$(python sub_config1.py 2>&1)                                                                                                                     
     
    5952 
    6053nb_proc=$(python sub_config2.py 2>&1)  
    61 nb_jz=$(($nb_proc-1)) 
    6254 
    6355if [[ ($machine_name == irene) ]] 
     
    7163then 
    7264    echo "Testing on Jean-Zay"  
    73     # touch srun.conf 
    74     # > srun.conf 
    75     # echo "0-"$nb_jz " ../../../build_prod/bin/generic_testcase.exe">> srun.conf 
    76     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7765    srun -n $nb_proc --mpi=pmi2 ../../../build_prod/bin/generic_testcase.exe 
    7866else 
     
    8674 
    8775done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_average/user_params.def

    r1715 r1726  
    1111# e.g. NumberServers = 2, 4, 8   
    1212 
    13 NumberServers = 2 
     13NumberServers = 2, 4 
    1414UsingServer2 = 'false' 
    1515ATMdomain = 'lmdz' 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_maximum/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../../context_grid_dynamico.xml ./ 
     3yes | cp ../../dynamico_grid.nc ./ 
    24 
    3 cp -n  ../context_grid_dynamico.xml ./ 
    4 cp -n ../dynamico_grid.nc ./ 
     5yes | cp ../../user_config.py sub_config1.py 
     6yes | cp ../../config.py sub_config2.py 
     7yes | cp ../../check.py sub_check.py 
     8yes | cp ../../default_param.py default_param.py 
    59 
    6  
    7 rm -f sub_config1.py 
    8 rm -f sub_config2.py 
    9 rm -f sub_check.py 
    10 rm -f default_param.py 
    11  
    12 cp -n ../../user_config.py sub_config1.py 
    13 cp -n ../../config.py sub_config2.py 
    14 cp -n ../../check.py sub_check.py 
    15 cp -n ../../default_param.py default_param.py 
    1610 
    1711# Black        0;30     Dark Gray     1;30 
     
    2519 
    2620 
     21 
    2722Color='\033[0;36m' 
    2823NC='\033[0m' # No Color 
    29  
    3024 
    3125touch report.txt 
     
    3327echo " " >> report.txt 
    3428echo " " >> report.txt 
    35 echo -e "testing ${Color}maximum${NC} reduce..." >> report.txt  
     29echo -e "testing ${Color}maximum${NC} reduce..." >> report.txt 
    3630echo " " >> report.txt 
    37  
    3831 
    3932touch report.html 
     
    5952 
    6053nb_proc=$(python sub_config2.py 2>&1)  
    61 nb_jz=$(($nb_proc-1)) 
    6254 
    6355if [[ ($machine_name == irene) ]] 
     
    7163then 
    7264    echo "Testing on Jean-Zay"  
    73     # touch srun.conf 
    74     # > srun.conf 
    75     # echo "0-"$nb_jz " ../../../build_prod/bin/generic_testcase.exe">> srun.conf 
    76     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7765    srun -n $nb_proc --mpi=pmi2 ../../../build_prod/bin/generic_testcase.exe 
    7866else 
     
    8674 
    8775done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_maximum/user_params.def

    r1715 r1726  
    1111# e.g. NumberServers = 2, 4, 8   
    1212 
    13 NumberServers = 2 
    14 UsingServer2 = 'false' 
     13NumberServers = 2, 4 
     14UsingServer2 = 'false', 'true' 
    1515ATMdomain = 'lmdz' 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_minimum/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../../context_grid_dynamico.xml ./ 
     3yes | cp ../../dynamico_grid.nc ./ 
    24 
    3 cp -n  ../context_grid_dynamico.xml ./ 
    4 cp -n ../dynamico_grid.nc ./ 
     5yes | cp ../../user_config.py sub_config1.py 
     6yes | cp ../../config.py sub_config2.py 
     7yes | cp ../../check.py sub_check.py 
     8yes | cp ../../default_param.py default_param.py 
    59 
    6  
    7 rm -f sub_config1.py 
    8 rm -f sub_config2.py 
    9 rm -f sub_check.py 
    10 rm -f default_param.py 
    11  
    12 cp -n ../../user_config.py sub_config1.py 
    13 cp -n ../../config.py sub_config2.py 
    14 cp -n ../../check.py sub_check.py 
    15 cp -n ../../default_param.py default_param.py 
    1610 
    1711# Black        0;30     Dark Gray     1;30 
     
    2519 
    2620 
     21 
    2722Color='\033[0;36m' 
    2823NC='\033[0m' # No Color 
     
    3227echo " " >> report.txt 
    3328echo " " >> report.txt 
    34 echo -e "testing ${Color}minimum${NC} reduce..." >> report.txt  
     29echo -e "testing ${Color}minimum${NC} reduce..." >> report.txt 
    3530echo " " >> report.txt 
    36  
    3731 
    3832touch report.html 
     
    5852 
    5953nb_proc=$(python sub_config2.py 2>&1)  
    60 nb_jz=$(($nb_proc-1)) 
    6154 
    6255if [[ ($machine_name == irene) ]] 
     
    7063then 
    7164    echo "Testing on Jean-Zay"  
    72     # touch srun.conf 
    73     # > srun.conf 
    74     # echo "0-"$nb_jz " ../../../build_prod/bin/generic_testcase.exe">> srun.conf 
    75     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7665    srun -n $nb_proc --mpi=pmi2 ../../../build_prod/bin/generic_testcase.exe 
    7766else 
     
    8574 
    8675done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_minimum/user_params.def

    r1715 r1726  
    1111# e.g. NumberServers = 2, 4, 8   
    1212 
    13 NumberServers = 2 
    14 UsingServer2 = 'false' 
     13NumberServers = 2, 4 
     14UsingServer2 = 'false', 'true' 
    1515ATMdomain = 'lmdz' 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/test_sum/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../../context_grid_dynamico.xml ./ 
     3yes | cp ../../dynamico_grid.nc ./ 
    24 
    3 cp -n  ../context_grid_dynamico.xml ./ 
    4 cp -n ../dynamico_grid.nc ./ 
     5yes | cp ../../user_config.py sub_config1.py 
     6yes | cp ../../config.py sub_config2.py 
     7yes | cp ../../check.py sub_check.py 
     8yes | cp ../../default_param.py default_param.py 
    59 
    6  
    7 rm -f sub_config1.py 
    8 rm -f sub_config2.py 
    9 rm -f sub_check.py 
    10 rm -f default_param.py 
    11  
    12 cp -n ../../user_config.py sub_config1.py 
    13 cp -n ../../config.py sub_config2.py 
    14 cp -n ../../check.py sub_check.py 
    15 cp -n ../../default_param.py default_param.py 
    1610 
    1711# Black        0;30     Dark Gray     1;30 
     
    2519 
    2620 
     21 
    2722Color='\033[0;36m' 
    2823NC='\033[0m' # No Color 
     
    3227echo " " >> report.txt 
    3328echo " " >> report.txt 
    34 echo -e "testing ${Color}accumulate${NC} reduce..." >> report.txt  
     29echo -e "testing ${Color}accumulate${NC} reduce..." >> report.txt 
    3530echo " " >> report.txt 
    36  
    3731 
    3832touch report.html 
     
    5852 
    5953nb_proc=$(python sub_config2.py 2>&1)  
    60 nb_jz=$(($nb_proc-1)) 
    6154 
    6255if [[ ($machine_name == irene) ]] 
     
    7063then 
    7164    echo "Testing on Jean-Zay"  
    72     # touch srun.conf 
    73     # > srun.conf 
    74     # echo "0-"$nb_jz " ../../../build_prod/bin/generic_testcase.exe">> srun.conf 
    75     #srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7665    srun -n $nb_proc --mpi=pmi2 ../../../build_prod/bin/generic_testcase.exe 
    7766else 
     
    8574 
    8675done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_grid_algo/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
     2yes | cp ../context_grid_dynamico.xml ./ 
     3yes | cp ../dynamico_grid.nc ./ 
    24 
    3 rm -f sub_config1.py 
    4 rm -f sub_config2.py 
    5 rm -f sub_check.py 
    6 rm -f default_param.py 
     5yes | cp ../user_config.py sub_config1.py 
     6yes | cp ../config.py sub_config2.py 
     7yes | cp ../check.py sub_check.py 
     8yes | cp ../default_param.py default_param.py 
    79 
    8 cp -n ../user_config.py sub_config1.py 
    9 cp -n ../config.py sub_config2.py 
    10 cp -n ../check.py sub_check.py 
    11 cp -n ../default_param.py default_param.py 
    1210 
    1311# Black        0;30     Dark Gray     1;30 
     
    2119 
    2220 
     21 
    2322Color='\033[0;36m' 
    2423NC='\033[0m' # No Color 
     
    2827echo " " >> report.txt 
    2928echo " " >> report.txt 
    30 echo -e "testing ${Color}grid${NC} algorithms..." >> report.txt  
     29echo -e "testing ${Color}axis${NC} algorithms..." >> report.txt 
    3130echo " " >> report.txt 
    32  
    33  
    3431 
    3532touch report.html 
     
    3835echo "<br> " >> report.html 
    3936echo "<br> " >> report.html 
    40 echo "<p>testing  <font color="blue">grid</font> algorithms...</p>" >> report.html  
     37echo "<p>testing  <font color="blue">axis</font> algorithms...</p>" >> report.html  
    4138echo "<br> " >> report.html 
    4239 
     
    5552 
    5653nb_proc=$(python sub_config2.py 2>&1)  
    57 nb_jz=$(($nb_proc-1)) 
    5854 
    5955if [[ ($machine_name == irene) ]] 
     
    6763then 
    6864    echo "Testing on Jean-Zay"  
    69     # touch srun.conf 
    70     # > srun.conf 
    71     # echo "0-"$nb_jz " ../../build_prod/bin/generic_testcase.exe">> srun.conf 
    72     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7365    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    7466else 
     
    8274 
    8375done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_grid_algo/user_params.def

    r1714 r1726  
    1111# e.g. NumberServers = 2, 4, 8   
    1212 
    13 NumberServers = 2 
     13NumberServers = 2, 4 
    1414UsingServer2 = 'false' 
    1515ATMdomain = 'lmdz' 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_scalar_algo/run_sub_test.sh

    r1725 r1726  
    11#!/bin/bash 
    2 rm -f sub_config1.py 
    3 rm -f sub_config2.py 
    4 rm -f sub_check.py 
    5 rm -f default_param.py 
     2yes | cp ../context_grid_dynamico.xml ./ 
     3yes | cp ../dynamico_grid.nc ./ 
    64 
    7 cp -n ../user_config.py sub_config1.py 
    8 cp -n ../config.py sub_config2.py 
    9 cp -n ../check.py sub_check.py 
    10 cp -n ../default_param.py default_param.py 
     5yes | cp ../user_config.py sub_config1.py 
     6yes | cp ../config.py sub_config2.py 
     7yes | cp ../check.py sub_check.py 
     8yes | cp ../default_param.py default_param.py 
     9 
    1110 
    1211# Black        0;30     Dark Gray     1;30 
     
    2019 
    2120 
     21 
    2222Color='\033[0;36m' 
    2323NC='\033[0m' # No Color 
     
    2727echo " " >> report.txt 
    2828echo " " >> report.txt 
    29 echo -e "testing ${Color}scalar${NC} algorithms..." >> report.txt  
     29echo -e "testing ${Color}axis${NC} algorithms..." >> report.txt 
    3030echo " " >> report.txt 
    3131 
     
    3535echo "<br> " >> report.html 
    3636echo "<br> " >> report.html 
    37 echo "<p>testing  <font color="blue">scalar</font> algorithms...</p>" >> report.html  
     37echo "<p>testing  <font color="blue">axis</font> algorithms...</p>" >> report.html  
    3838echo "<br> " >> report.html 
    3939 
     
    5252 
    5353nb_proc=$(python sub_config2.py 2>&1)  
    54 nb_jz=$(($nb_proc-1)) 
    5554 
    5655if [[ ($machine_name == irene) ]] 
     
    6463then 
    6564    echo "Testing on Jean-Zay"  
    66     # touch srun.conf 
    67     # > srun.conf 
    68     # echo "0-"$nb_jz " ../../build_prod/bin/generic_testcase.exe">> srun.conf 
    69     # srun --mpi=pmi2 -K1 --multi-prog -m cyclic ./srun.conf  
    7065    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    7166else 
    7267    echo "other machine" 
    7368fi 
     69 
    7470python sub_check.py 
    7571 
     
    7874 
    7975done 
     76rm -f default_param.py 
     77rm -f default_param.pyc 
     78rm -f user_param.pyc 
     79rm -f user_param.py.* 
     80rm -f sub_*.py 
  • XIOS/dev/dev_trunk_omp/src/test/generic_testcase.f90

    r1713 r1726  
    109109 
    110110  CALL MPI_FINALIZE(ierr) 
     111  print*, "generic_testcase.exe successful" 
    111112   
    112113CONTAINS 
Note: See TracChangeset for help on using the changeset viewer.