Changeset 1729


Ignore:
Timestamp:
10/03/19 16:28:14 (5 years ago)
Author:
yushan
Message:

GENERIC_TESTCASE : Each configuration is considered now as an independent test

Location:
XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE
Files:
12 added
4 deleted
24 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/CMakeLists.txt

    r1723 r1729  
     1############################## 
     2# file generated by setup.py # 
     3#      DO NOT modify         # 
     4############################## 
     5 
    16cmake_minimum_required(VERSION 2.8.12.2) 
    27 
    38project(generic_testcase) 
    49 
    5  
    610enable_testing() 
    711 
     12add_subdirectory(test_config) 
     13add_subdirectory(test_domain_algo) 
     14add_subdirectory(test_scalar_algo) 
    815add_subdirectory(test_function) 
    916add_subdirectory(test_axis_algo) 
    10 add_subdirectory(test_domain_algo) 
    1117add_subdirectory(test_grid_algo) 
    12 add_subdirectory(test_scalar_algo) 
    13  
    1418 
    1519add_custom_target("report") 
     20 
    1621add_custom_command(TARGET "report"  
    17         POST_BUILD  
    18         COMMAND rm -f report.txt 
    19         COMMAND cat */*/report.txt > report.txt 
    20         COMMAND cat */report.txt >> report.txt 
    21         COMMAND rm -f report.html 
    22         COMMAND cat */*/report.html > report.html 
    23         COMMAND cat */report.html >> report.html) 
     22                   POST_BUILD 
     23                   COMMAND rm -f report.txt 
     24                   COMMAND rm -f report.html 
     25                   COMMAND cat test_config/report.txt >> report.txt 
     26                   COMMAND cat test_config/report.html >> report.html 
     27                   COMMAND cat test_domain_algo/report.txt >> report.txt 
     28                   COMMAND cat test_domain_algo/report.html >> report.html 
     29                   COMMAND cat test_scalar_algo/report.txt >> report.txt 
     30                   COMMAND cat test_scalar_algo/report.html >> report.html 
     31                   COMMAND cat test_function/report.txt >> report.txt 
     32                   COMMAND cat test_function/report.html >> report.html 
     33                   COMMAND cat test_axis_algo/report.txt >> report.txt 
     34                   COMMAND cat test_axis_algo/report.html >> report.html 
     35                   COMMAND cat test_grid_algo/report.txt >> report.txt 
     36                   COMMAND cat test_grid_algo/report.html >> report.html 
     37                   ) 
     38 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/config.py

    r1716 r1729  
    3434        nb_proc = NumberClients+NumberServers 
    3535 
    36         os.rename("iodef.xml", "iodef.xml.bkp") 
     36        # os.rename("iodef.xml", "iodef.xml.bkp") 
    3737 
    3838        filein = open("iodef.xml.bkp", "r") 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/job_irene.sh

    r1718 r1729  
    5050 
    5151export machine_name=irene 
    52  
     52python user_config.py 
    5353cmake . 
    5454make test 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_axis_algo/CMakeLists.txt

    r1714 r1729  
     1############################## 
     2# file generated by setup.py # 
     3#      DO NOT modify         # 
     4############################## 
     5 
    16cmake_minimum_required(VERSION 2.8.12.2) 
    27 
    38project(generic_testcase) 
    49 
     10find_package(PythonInterp REQUIRED) 
    511 
    612enable_testing() 
    713 
     14add_test( NAME test_axis_algo_config0 
     15          COMMAND ${PYTHON_EXECUTABLE} 
     16          ${CMAKE_CURRENT_BINARY_DIR}/run_test_0.py 
     17          test_axis_algo_config0) 
    818 
    9 add_test( axis_algo ./run_sub_test.sh) 
     19add_test( NAME test_axis_algo_config1 
     20          COMMAND ${PYTHON_EXECUTABLE} 
     21          ${CMAKE_CURRENT_BINARY_DIR}/run_test_1.py 
     22          test_axis_algo_config1) 
     23 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_axis_algo/iodef.xml

    r1728 r1729  
    77 
    88      <variable id="timestep"> 1h </variable> 
    9       <variable id="domain"> lmdz </variable> 
     9      <variable id="domain"> atm::domain </variable> 
    1010      <variable id="domain_mask"> true </variable> 
    1111      <variable id="axis_mask"> true </variable> 
     
    5555        <variable id="info_level" type="int">100</variable> 
    5656        <variable id="print_file" type="bool">true</variable> 
    57         <variable id="using_server2" type="bool">true</variable> 
    58         <variable id="ratio_server2" type="int">50</variable> 
    59         <variable id="number_pools_server2" type="int">1</variable> 
     57        <variable id="using_server2" type="bool">xios::usingSrv2</variable> 
     58        <variable id="ratio_server2" type="int">xios::ratioSrv2</variable> 
     59        <variable id="number_pools_server2" type="int">xios::nbplSrv2</variable> 
    6060        <variable id="pure_one_sided" type="bool">false</variable> 
    6161        <variable id="check_event_sync" type="bool">true</variable> 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_axis_algo/job_irene.sh

    r1718 r1729  
    4949#ccc_mprun tau_exec -io ../../bin/test_send.exe 
    5050#ddt -start -n 8 ../buile_intelmpi/bin/test_omp.exe 
     51python setup.py 
    5152 
    5253cmake . 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_axis_algo/run_sub_test.sh

    r1728 r1729  
    11#!/bin/bash 
    2 yes | cp ../context_grid_dynamico.xml ./ 
    3 yes | cp ../dynamico_grid.nc ./ 
    42 
    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 
    93 
    10 yes | cp ../iodef.xml iodef.xml 
     4 
     5cp ../context_grid_dynamico.xml ./ 
     6cp ../dynamico_grid.nc ./ 
     7 
     8cp ../config.py sub_config.py 
     9cp ../check.py sub_check.py 
     10 
     11cp ../default_param.py default_param.py 
     12 
     13cp ../iodef.xml iodef.xml 
    1114 
    1215# Black        0;30     Dark Gray     1;30 
     
    2023 
    2124 
     25mv iodef.xml iodef.xml.bkp 
    2226 
    23 Color='\033[0;36m' 
    24 NC='\033[0m' # No Color 
     27nb_proc=$(python sub_config.py 2>&1)  
    2528 
    26 touch report.txt 
    27 > report.txt 
    28 echo " " >> report.txt 
    29 echo " " >> report.txt 
    30 echo -e "testing ${Color}axis${NC} algorithms..." >> report.txt 
    31 echo " " >> report.txt 
     29machine_name=jeanzay 
    3230 
    33 touch report.html 
    34 > report.html 
    35 echo "<br> " >> report.html 
    36 echo "<br> " >> report.html 
    37 echo "<br> " >> report.html 
    38 echo "<p>testing  <font color="blue">axis</font> algorithms...</p>" >> report.html  
    39 echo "<br> " >> report.html 
    40  
    41 nb_config=$(python sub_config1.py 2>&1)                                                                                                                     
    42  
    43  
    44 counter=0 
    45 while [ $counter -lt $nb_config ] 
    46 do 
    47  
    48 rm -f user_param.py 
    49  
    50 cp user_param.py.$counter user_param.py 
    51  
    52 ((counter++)) 
    53  
    54 nb_proc=$(python sub_config2.py 2>&1)  
    55  
     31echo $nb_proc 
    5632if [[ ($machine_name == irene) ]] 
    5733then 
     
    6743    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    6844    if [ $? -ne 0 ] 
    69         then 
    70                 echo "execution failed" 
     45        then 
     46            echo "execution failed" 
    7147            rm -f iodef.xml 
    7248            mv iodef.xml.bkp iodef.xml 
     49            rm -f user_param.py 
    7350            rm -f default_param.py 
    74             rm -f default_param.pyc 
    75             rm -f user_param.pyc 
    76             rm -f user_param.py.* 
    77             rm -f sub_*.py 
    78                 exit 1234 
     51            rm -f sub_config.py 
     52            exit 1234 
    7953    fi 
    8054else 
     
    8761rm -f iodef.xml 
    8862mv iodef.xml.bkp iodef.xml 
    89  
    90 done 
     63rm -f user_param.py 
    9164rm -f default_param.py 
    92 rm -f default_param.pyc 
    93 rm -f user_param.pyc 
    94 rm -f user_param.py.* 
    95 rm -f sub_*.py 
     65rm -f sub_config.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_domain_algo/CMakeLists.txt

    r1721 r1729  
     1############################## 
     2# file generated by setup.py # 
     3#      DO NOT modify         # 
     4############################## 
     5 
    16cmake_minimum_required(VERSION 2.8.12.2) 
    27 
    38project(generic_testcase) 
    49 
     10find_package(PythonInterp REQUIRED) 
    511 
    612enable_testing() 
    713 
     14add_test( NAME test_domain_algo_config0 
     15          COMMAND ${PYTHON_EXECUTABLE} 
     16          ${CMAKE_CURRENT_BINARY_DIR}/run_test_0.py 
     17          test_domain_algo_config0) 
    818 
    9 add_test( domain_algo ./run_sub_test.sh) 
     19add_test( NAME test_domain_algo_config1 
     20          COMMAND ${PYTHON_EXECUTABLE} 
     21          ${CMAKE_CURRENT_BINARY_DIR}/run_test_1.py 
     22          test_domain_algo_config1) 
     23 
     24add_test( NAME test_domain_algo_config2 
     25          COMMAND ${PYTHON_EXECUTABLE} 
     26          ${CMAKE_CURRENT_BINARY_DIR}/run_test_2.py 
     27          test_domain_algo_config2) 
     28 
     29add_test( NAME test_domain_algo_config3 
     30          COMMAND ${PYTHON_EXECUTABLE} 
     31          ${CMAKE_CURRENT_BINARY_DIR}/run_test_3.py 
     32          test_domain_algo_config3) 
     33 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_domain_algo/iodef.xml

    r1728 r1729  
    77 
    88      <variable id="timestep"> 1h </variable> 
    9       <variable id="domain"> lmdz </variable> 
     9      <variable id="domain"> atm::domain </variable> 
    1010      <variable id="domain_mask"> true </variable> 
    1111      <variable id="axis_mask"> true </variable> 
     
    5555        <variable id="info_level" type="int">100</variable> 
    5656        <variable id="print_file" type="bool">true</variable> 
    57         <variable id="using_server2" type="bool">true</variable> 
    58         <variable id="ratio_server2" type="int">50</variable> 
    59         <variable id="number_pools_server2" type="int">1</variable> 
     57        <variable id="using_server2" type="bool">xios::usingSrv2</variable> 
     58        <variable id="ratio_server2" type="int">xios::ratioSrv2</variable> 
     59        <variable id="number_pools_server2" type="int">xios::nbplSrv2</variable> 
    6060        <variable id="pure_one_sided" type="bool">false</variable> 
    6161        <variable id="check_event_sync" type="bool">true</variable> 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_domain_algo/job_irene.sh

    r1718 r1729  
    4949#ccc_mprun tau_exec -io ../../bin/test_send.exe 
    5050#ddt -start -n 8 ../buile_intelmpi/bin/test_omp.exe 
    51  
     51python setup.py 
    5252cmake . 
    5353make test 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_domain_algo/run_sub_test.sh

    r1728 r1729  
    11#!/bin/bash 
    2 yes | cp ../context_grid_dynamico.xml ./ 
    3 yes | cp ../dynamico_grid.nc ./ 
    42 
    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 
    93 
    10 yes | cp ../iodef.xml iodef.xml 
     4 
     5cp ../context_grid_dynamico.xml ./ 
     6cp ../dynamico_grid.nc ./ 
     7 
     8cp ../config.py sub_config.py 
     9cp ../check.py sub_check.py 
     10 
     11cp ../default_param.py default_param.py 
     12 
     13 
     14cp ../iodef.xml iodef.xml 
    1115 
    1216# Black        0;30     Dark Gray     1;30 
     
    2024 
    2125 
     26mv iodef.xml iodef.xml.bkp 
    2227 
    23 Color='\033[0;36m' 
    24 NC='\033[0m' # No Color 
     28nb_proc=$(python sub_config.py 2>&1)  
    2529 
    26 touch report.txt 
    27 > report.txt 
    28 echo " " >> report.txt 
    29 echo " " >> report.txt 
    30 echo -e "testing ${Color}domain${NC} algorithms..." >> report.txt 
    31 echo " " >> report.txt 
     30machine_name=jeanzay 
    3231 
    33 touch report.html 
    34 > report.html 
    35 echo "<br> " >> report.html 
    36 echo "<br> " >> report.html 
    37 echo "<br> " >> report.html 
    38 echo "<p>testing  <font color="blue">domain</font> algorithms...</p>" >> report.html  
    39 echo "<br> " >> report.html 
    40  
    41 nb_config=$(python sub_config1.py 2>&1)                                                                                                                     
    42  
    43  
    44 counter=0 
    45 while [ $counter -lt $nb_config ] 
    46 do 
    47  
    48 rm -f user_param.py 
    49  
    50 cp user_param.py.$counter user_param.py 
    51  
    52 ((counter++)) 
    53  
    54 nb_proc=$(python sub_config2.py 2>&1)  
    55  
     32echo $nb_proc 
    5633if [[ ($machine_name == irene) ]] 
    5734then 
     
    6744    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    6845    if [ $? -ne 0 ] 
    69       then 
    70         echo "execution failed" 
    71         rm -f iodef.xml 
    72         mv iodef.xml.bkp iodef.xml 
    73         rm -f default_param.py 
    74         rm -f default_param.pyc 
    75         rm -f user_param.pyc 
    76         rm -f user_param.py.* 
    77         rm -f sub_*.py 
    78         exit 1234 
     46        then 
     47            echo "execution failed" 
     48            rm -f iodef.xml 
     49            mv iodef.xml.bkp iodef.xml 
     50            rm -f user_param.py 
     51            rm -f default_param.py 
     52            rm -f sub_config.py 
     53            exit 1234 
    7954    fi 
    8055else 
     
    8762rm -f iodef.xml 
    8863mv iodef.xml.bkp iodef.xml 
    89  
    90 done 
     64rm -f user_param.py 
    9165rm -f default_param.py 
    92 rm -f default_param.pyc 
    93 rm -f user_param.pyc 
    94 rm -f user_param.py.* 
    95 rm -f sub_*.py 
     66rm -f sub_config.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/CMakeLists.txt

    r1723 r1729  
     1############################## 
     2# file generated by setup.py # 
     3#      DO NOT modify         # 
     4############################## 
     5 
    16cmake_minimum_required(VERSION 2.8.12.2) 
    27 
    38project(generic_testcase) 
    49 
     10find_package(PythonInterp REQUIRED) 
    511 
    612enable_testing() 
    713 
    8 add_subdirectory(test_average) 
    9 add_subdirectory(test_maximum) 
    10 add_subdirectory(test_minimum) 
    11 add_subdirectory(test_sum) 
     14add_test( NAME test_function_config0 
     15          COMMAND ${PYTHON_EXECUTABLE} 
     16          ${CMAKE_CURRENT_BINARY_DIR}/run_test_0.py 
     17          test_function_config0) 
    1218 
    13 add_custom_target("subreport") 
    14 add_custom_command(TARGET "subreport"  
    15         POST_BUILD  
    16         COMMAND rm -f subreport.txt 
    17         COMMAND rm -f subreport.html 
    18         COMMAND cat */report.txt > subreport.txt 
    19         COMMAND cat */report.html > subreport.html) 
     19add_test( NAME test_function_config1 
     20          COMMAND ${PYTHON_EXECUTABLE} 
     21          ${CMAKE_CURRENT_BINARY_DIR}/run_test_1.py 
     22          test_function_config1) 
     23 
     24add_test( NAME test_function_config2 
     25          COMMAND ${PYTHON_EXECUTABLE} 
     26          ${CMAKE_CURRENT_BINARY_DIR}/run_test_2.py 
     27          test_function_config2) 
     28 
     29add_test( NAME test_function_config3 
     30          COMMAND ${PYTHON_EXECUTABLE} 
     31          ${CMAKE_CURRENT_BINARY_DIR}/run_test_3.py 
     32          test_function_config3) 
     33 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/context_atm.xml

    r1714 r1729  
    364364  <file_definition  type="one_file" > 
    365365     
    366     <file id="atm_output1" output_freq="1ts" type="one_file" enabled="true"> 
    367        <field id="id_field2D" field_ref="field2D" enabled="true"/> 
    368        <field id="id_field3D" field_ref="field3D" enabled="true"/> 
     366 
     367     <file id="atm_output" output_freq="4ts" enabled="true" > 
     368        
     369       <field field_ref="field2D" operation="average" enabled="true"/> 
     370       <field field_ref="field3D" operation="average" enabled="false"/> 
     371       <field field_ref="pressure" operation="average" enabled="false"/> 
     372       <field field_ref="field3D_recv" operation="average" enabled="false"/> 
     373       <field field_ref="field3D_resend" operation="average" enabled="false"/> 
     374        
     375       <!-- <field field_ref="field_X" operation="average" enabled="true"/> 
     376       <field field_ref="field_Y" operation="average" enabled="true"/> 
     377       <field field_ref="field_Z" operation="average" enabled="true"/> 
     378       <field field_ref="field_XY" operation="average" enabled="true"/> 
     379       <field field_ref="field_XYZ" operation="average" enabled="true"/> 
     380       <field field_ref="field_XZ" operation="average" enabled="true"/> 
     381       <field field_ref="field_YZ" operation="average" enabled="true"/> 
     382        
     383       <field field_ref="field_zoom_vert" operation="average" enabled="true"/> 
     384       <field field_ref="field_zoom_vert_sum" operation="average" enabled="true"/> --> 
     385        
    369386    </file> 
    370387 
    371      <file id="atm_output" output_freq="4ts" enabled="true"> 
    372        <field id="field2D_ave" field_ref="field2D" operation="average" enabled="true"/> 
    373        <field id="field2D_max" field_ref="field2D" operation="maximum" enabled="true"/> 
    374        <field id="field2D_min" field_ref="field2D" operation="minimum" enabled="true"/> 
    375        <field id="field2D_sum" field_ref="field2D" operation="accumulate" enabled="true"/> 
    376  
    377        <field id="field3D_ave" field_ref="field3D" operation="average" enabled="true"/> 
    378        <field id="field3D_max" field_ref="field3D" operation="maximum" enabled="true"/> 
    379        <field id="field3D_min" field_ref="field3D" operation="minimum" enabled="true"/> 
    380        <field id="field3D_sum" field_ref="field3D" operation="accumulate" enabled="true"/> 
     388 
     389    <file id="atm_output_ensemble" output_freq="4ts" enabled="false"> 
     390       <field field_ref="field2D_W" operation="average" /> 
     391       <field field_ref="field3D_W" operation="average" /> 
     392       <field field_ref="pressure_W" operation="average" /> 
     393       <field field_ref="field3D_recv_W" operation="average" /> 
     394       <field field_ref="field3D_resend_W" operation="average" /> 
     395 
     396       <field field_ref="field_XW" operation="average" enabled="false" /> 
     397       <field field_ref="field_YW" operation="average" enabled="false" /> 
     398       <field field_ref="field_XYW" operation="average" enabled="false" /> 
     399       <field field_ref="field_ZW" operation="average" enabled="false" /> 
     400       <field field_ref="field_XYZW" operation="average" enabled="false" /> 
     401       <field field_ref="field_XZW" operation="average" enabled="false" /> 
     402       <field field_ref="field_YZW" operation="average" enabled="false" /> 
    381403    </file> 
    382404 
     
    393415       <field field_ref="other_field_YZ" enabled="false"/> 
    394416    </file> 
    395  
    396     <file id="atm_output_W" output_freq="1ts" enabled="false"> 
    397        <field field_ref="field3D_W" enabled="true"/> 
    398        <field field_ref="field2D_W" enabled="true"/>  
    399        <field field_ref="field_XW" enabled="true"/> 
    400        <field field_ref="field_YW" enabled="true"/> 
    401        <field field_ref="field_XYW" enabled="true"/> 
    402        <field field_ref="field_ZW" enabled="true"/> 
    403        <field field_ref="field_XYZW" enabled="true"/> 
    404        <field field_ref="field_XZW" enabled="true"/> 
    405        <field field_ref="field_YZW" enabled="true"/> 
    406     </file> 
    407417     
    408418 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/iodef.xml

    r1712 r1729  
    4646    <variable_definition> 
    4747      <variable_group id="buffer"> 
    48         <variable id="min_buffer_size" type="int">10000000</variable> 
    49         <variable id="optimal_buffer_size" type="string">performance</variable> 
    50         <variable id="buffer_factor_size" type="double">0.8</variable>  
     48  <variable id="min_buffer_size" type="int">10000000</variable> 
     49  <variable id="optimal_buffer_size" type="string">performance</variable> 
     50  <variable id="buffer_factor_size" type="double">0.8</variable>  
    5151      </variable_group> 
    5252 
    5353      <variable_group id="parameters" > 
    54         <variable id="using_server" type="bool">xios::usingSrv2</variable> 
     54        <variable id="using_server" type="bool">true</variable> 
    5555        <variable id="info_level" type="int">100</variable> 
    5656        <variable id="print_file" type="bool">true</variable> 
    57         <variable id="using_server2" type="bool">false</variable> 
     57        <variable id="using_server2" type="bool">xios::usingSrv2</variable> 
    5858        <variable id="ratio_server2" type="int">xios::ratioSrv2</variable> 
    5959        <variable id="number_pools_server2" type="int">xios::nbplSrv2</variable> 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_function/job_irene.sh

    r1718 r1729  
    4848#ccc_mprun tau_exec -io ../../bin/test_send.exe 
    4949#ddt -start -n 8 ../buile_intelmpi/bin/test_omp.exe 
    50  
     50python setup.py 
    5151cmake . 
    5252make test 
    53 make subreport 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_grid_algo/CMakeLists.txt

    r1721 r1729  
     1############################## 
     2# file generated by setup.py # 
     3#      DO NOT modify         # 
     4############################## 
     5 
    16cmake_minimum_required(VERSION 2.8.12.2) 
    27 
    38project(generic_testcase) 
    49 
     10find_package(PythonInterp REQUIRED) 
    511 
    612enable_testing() 
    713 
     14add_test( NAME test_grid_algo_config0 
     15          COMMAND ${PYTHON_EXECUTABLE} 
     16          ${CMAKE_CURRENT_BINARY_DIR}/run_test_0.py 
     17          test_grid_algo_config0) 
    818 
    9 add_test( grid_algo ./run_sub_test.sh) 
     19add_test( NAME test_grid_algo_config1 
     20          COMMAND ${PYTHON_EXECUTABLE} 
     21          ${CMAKE_CURRENT_BINARY_DIR}/run_test_1.py 
     22          test_grid_algo_config1) 
     23 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_grid_algo/iodef.xml

    r1728 r1729  
    77 
    88      <variable id="timestep"> 1h </variable> 
    9       <variable id="domain"> lmdz </variable> 
     9      <variable id="domain"> atm::domain </variable> 
    1010      <variable id="domain_mask"> true </variable> 
    1111      <variable id="axis_mask"> true </variable> 
     
    5555        <variable id="info_level" type="int">100</variable> 
    5656        <variable id="print_file" type="bool">true</variable> 
    57         <variable id="using_server2" type="bool">false</variable> 
    58         <variable id="ratio_server2" type="int">50</variable> 
    59         <variable id="number_pools_server2" type="int">1</variable> 
     57        <variable id="using_server2" type="bool">xios::usingSrv2</variable> 
     58        <variable id="ratio_server2" type="int">xios::ratioSrv2</variable> 
     59        <variable id="number_pools_server2" type="int">xios::nbplSrv2</variable> 
    6060        <variable id="pure_one_sided" type="bool">false</variable> 
    6161        <variable id="check_event_sync" type="bool">true</variable> 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_grid_algo/job_irene.sh

    r1718 r1729  
    4949#ccc_mprun tau_exec -io ../../bin/test_send.exe 
    5050#ddt -start -n 8 ../buile_intelmpi/bin/test_omp.exe 
    51  
     51python setup.py 
    5252cmake . 
    5353make test 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_grid_algo/run_sub_test.sh

    r1728 r1729  
    11#!/bin/bash 
    2 yes | cp ../context_grid_dynamico.xml ./ 
    3 yes | cp ../dynamico_grid.nc ./ 
    42 
    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 
    93 
    10 yes | cp ../iodef.xml iodef.xml 
     4 
     5cp ../context_grid_dynamico.xml ./ 
     6cp ../dynamico_grid.nc ./ 
     7 
     8cp ../config.py sub_config.py 
     9cp ../check.py sub_check.py 
     10 
     11cp ../default_param.py default_param.py 
     12 
     13 
     14cp ../iodef.xml iodef.xml 
    1115 
    1216# Black        0;30     Dark Gray     1;30 
     
    2024 
    2125 
     26mv iodef.xml iodef.xml.bkp 
    2227 
    23 Color='\033[0;36m' 
    24 NC='\033[0m' # No Color 
     28nb_proc=$(python sub_config.py 2>&1)  
    2529 
    26 touch report.txt 
    27 > report.txt 
    28 echo " " >> report.txt 
    29 echo " " >> report.txt 
    30 echo -e "testing ${Color}grid${NC} algorithms..." >> report.txt 
    31 echo " " >> report.txt 
     30machine_name=jeanzay 
    3231 
    33 touch report.html 
    34 > report.html 
    35 echo "<br> " >> report.html 
    36 echo "<br> " >> report.html 
    37 echo "<br> " >> report.html 
    38 echo "<p>testing  <font color="blue">grid</font> algorithms...</p>" >> report.html  
    39 echo "<br> " >> report.html 
    40  
    41 nb_config=$(python sub_config1.py 2>&1)                                                                                                                     
    42  
    43  
    44 counter=0 
    45 while [ $counter -lt $nb_config ] 
    46 do 
    47  
    48 rm -f user_param.py 
    49  
    50 cp user_param.py.$counter user_param.py 
    51  
    52 ((counter++)) 
    53  
    54 nb_proc=$(python sub_config2.py 2>&1)  
    55  
     32echo $nb_proc 
    5633if [[ ($machine_name == irene) ]] 
    5734then 
    58           echo "Testing on Irene" 
     35    echo "Testing on Irene" 
    5936    ccc_mprun -n $nb_proc ../../build_prod/bin/generic_testcase.exe 
    6037elif [[($machine_name == ada)]] 
     
    6744    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    6845    if [ $? -ne 0 ] 
    69         then 
    70                 echo "execution failed" 
     46        then 
     47            echo "execution failed" 
    7148            rm -f iodef.xml 
    7249            mv iodef.xml.bkp iodef.xml 
     50            rm -f user_param.py 
    7351            rm -f default_param.py 
    74             rm -f default_param.pyc 
    75             rm -f user_param.pyc 
    76             rm -f user_param.py.* 
    77             rm -f sub_*.py 
    78                 exit 1234 
     52            rm -f sub_config.py 
     53            exit 1234 
    7954    fi 
    8055else 
     
    8762rm -f iodef.xml 
    8863mv iodef.xml.bkp iodef.xml 
    89  
    90 done 
     64rm -f user_param.py 
    9165rm -f default_param.py 
    92 rm -f default_param.pyc 
    93 rm -f user_param.pyc 
    94 rm -f user_param.py.* 
    95 rm -f sub_*.py 
     66rm -f sub_config.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_scalar_algo/CMakeLists.txt

    r1721 r1729  
     1############################## 
     2# file generated by setup.py # 
     3#      DO NOT modify         # 
     4############################## 
     5 
    16cmake_minimum_required(VERSION 2.8.12.2) 
    27 
    38project(generic_testcase) 
    49 
     10find_package(PythonInterp REQUIRED) 
    511 
    612enable_testing() 
    713 
     14add_test( NAME test_scalar_algo_config0 
     15          COMMAND ${PYTHON_EXECUTABLE} 
     16          ${CMAKE_CURRENT_BINARY_DIR}/run_test_0.py 
     17          test_scalar_algo_config0) 
    818 
    9 add_test( scalar_algo ./run_sub_test.sh) 
     19add_test( NAME test_scalar_algo_config1 
     20          COMMAND ${PYTHON_EXECUTABLE} 
     21          ${CMAKE_CURRENT_BINARY_DIR}/run_test_1.py 
     22          test_scalar_algo_config1) 
     23 
     24add_test( NAME test_scalar_algo_config2 
     25          COMMAND ${PYTHON_EXECUTABLE} 
     26          ${CMAKE_CURRENT_BINARY_DIR}/run_test_2.py 
     27          test_scalar_algo_config2) 
     28 
     29add_test( NAME test_scalar_algo_config3 
     30          COMMAND ${PYTHON_EXECUTABLE} 
     31          ${CMAKE_CURRENT_BINARY_DIR}/run_test_3.py 
     32          test_scalar_algo_config3) 
     33 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_scalar_algo/iodef.xml

    r1728 r1729  
    77 
    88      <variable id="timestep"> 1h </variable> 
    9       <variable id="domain"> lmdz </variable> 
     9      <variable id="domain"> atm::domain </variable> 
    1010      <variable id="domain_mask"> true </variable> 
    1111      <variable id="axis_mask"> true </variable> 
     
    5555        <variable id="info_level" type="int">100</variable> 
    5656        <variable id="print_file" type="bool">true</variable> 
    57         <variable id="using_server2" type="bool">false</variable> 
    58         <variable id="ratio_server2" type="int">50</variable> 
    59         <variable id="number_pools_server2" type="int">1</variable> 
     57        <variable id="using_server2" type="bool">xios::usingSrv2</variable> 
     58        <variable id="ratio_server2" type="int">xios::ratioSrv2</variable> 
     59        <variable id="number_pools_server2" type="int">xios::nbplSrv2</variable> 
    6060        <variable id="pure_one_sided" type="bool">false</variable> 
    6161        <variable id="check_event_sync" type="bool">true</variable> 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_scalar_algo/job_irene.sh

    r1718 r1729  
    4949#ccc_mprun tau_exec -io ../../bin/test_send.exe 
    5050#ddt -start -n 8 ../buile_intelmpi/bin/test_omp.exe 
    51  
     51python setup.py 
    5252cmake . 
    5353make test 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/test_scalar_algo/run_sub_test.sh

    r1728 r1729  
    11#!/bin/bash 
    2 yes | cp ../context_grid_dynamico.xml ./ 
    3 yes | cp ../dynamico_grid.nc ./ 
    42 
    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 
    93 
    10 yes | cp ../iodef.xml iodef.xml 
     4 
     5cp ../context_grid_dynamico.xml ./ 
     6cp ../dynamico_grid.nc ./ 
     7 
     8cp ../config.py sub_config.py 
     9cp ../check.py sub_check.py 
     10 
     11cp ../default_param.py default_param.py 
     12 
     13 
     14cp ../iodef.xml iodef.xml 
    1115 
    1216# Black        0;30     Dark Gray     1;30 
     
    2024 
    2125 
     26mv iodef.xml iodef.xml.bkp 
    2227 
    23 Color='\033[0;36m' 
    24 NC='\033[0m' # No Color 
     28nb_proc=$(python sub_config.py 2>&1)  
    2529 
    26 touch report.txt 
    27 > report.txt 
    28 echo " " >> report.txt 
    29 echo " " >> report.txt 
    30 echo -e "testing ${Color}scalar${NC} algorithms..." >> report.txt 
    31 echo " " >> report.txt 
     30machine_name=jeanzay 
    3231 
    33 touch report.html 
    34 > report.html 
    35 echo "<br> " >> report.html 
    36 echo "<br> " >> report.html 
    37 echo "<br> " >> report.html 
    38 echo "<p>testing  <font color="blue">scalar</font> algorithms...</p>" >> report.html  
    39 echo "<br> " >> report.html 
    40  
    41 nb_config=$(python sub_config1.py 2>&1)                                                                                                                     
    42  
    43  
    44 counter=0 
    45 while [ $counter -lt $nb_config ] 
    46 do 
    47  
    48 rm -f user_param.py 
    49  
    50 cp user_param.py.$counter user_param.py 
    51  
    52 ((counter++)) 
    53  
    54 nb_proc=$(python sub_config2.py 2>&1)  
    55  
     32echo $nb_proc 
    5633if [[ ($machine_name == irene) ]] 
    5734then 
    58           echo "Testing on Irene" 
     35    echo "Testing on Irene" 
    5936    ccc_mprun -n $nb_proc ../../build_prod/bin/generic_testcase.exe 
    6037elif [[($machine_name == ada)]] 
     
    6744    srun -n $nb_proc --mpi=pmi2 ../../build_prod/bin/generic_testcase.exe 
    6845    if [ $? -ne 0 ] 
    69         then 
    70                 echo "execution failed" 
     46        then 
     47            echo "execution failed" 
    7148            rm -f iodef.xml 
    7249            mv iodef.xml.bkp iodef.xml 
     50            rm -f user_param.py 
    7351            rm -f default_param.py 
    74             rm -f default_param.pyc 
    75             rm -f user_param.pyc 
    76             rm -f user_param.py.* 
    77             rm -f sub_*.py 
    78                 exit 1234 
     52            rm -f sub_config.py 
     53            exit 1234 
    7954    fi 
    8055else 
     
    8762rm -f iodef.xml 
    8863mv iodef.xml.bkp iodef.xml 
    89  
    90 done 
     64rm -f user_param.py 
    9165rm -f default_param.py 
    92 rm -f default_param.pyc 
    93 rm -f user_param.pyc 
    94 rm -f user_param.py.* 
    95 rm -f sub_*.py 
     66rm -f sub_config.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/user_config.py

    r1712 r1729  
    22import sys 
    33 
    4 from default_param import * 
    5  
    64def main(): 
    75 
    8         default_nb_config = 7 
    96 
    10         nb_config = 1; 
    11         configs = [0]*default_nb_config 
    12           
    13         configs_arg = [[], [], [], [], [], [], []]  
     7        dirpath = os.getcwd() 
     8        my_list = os.listdir(dirpath) 
    149 
    15         f=open("user_params.def", "r") 
    16         for line in f: 
    17                 line = line.strip() 
    18                 if len(line) != 0: 
    19                         if not line.startswith("#"): 
    20                                 nb_config = nb_config * (line.count(",")+1) 
    21                                 line = line.replace(",", "") 
    22                                 line = line.replace("=", "") 
    23                                 if line.startswith("UsingServer2"): 
    24                                         line = line.replace("UsingServer2", "") 
    25                                         for word in line.split(): 
    26                                                 configs[0] += 1 
    27                                                 configs_arg[0].append('UsingServer2 = '+word) 
    28                                 elif line.startswith("RatioServer2"): 
    29                                         line = line.replace("RatioServer2", "") 
    30                                         for word in line.split(): 
    31                                                 configs[1] += 1 
    32                                                 configs_arg[1].append('RatioServer2 = '+word) 
    33                                 elif line.startswith("NumberPoolsServer2"): 
    34                                         line = line.replace("NumberPoolsServer2", "") 
    35                                         for word in line.split(): 
    36                                                 configs[2] += 1 
    37                                                 configs_arg[2].append('NumberPoolsServer2 = '+word) 
    38                                 elif line.startswith("NumberClients"): 
    39                                         line = line.replace("NumberClients", "") 
    40                                         for word in line.split(): 
    41                                                 configs[3] += 1 
    42                                                 configs_arg[3].append('NumberClients = '+word) 
    43                                 elif line.startswith("NumberServers"): 
    44                                         line = line.replace("NumberServers", "") 
    45                                         for word in line.split(): 
    46                                                 configs[4] += 1 
    47                                                 configs_arg[4].append('NumberServers = '+word) 
    48                                 elif line.startswith("Duration"): 
    49                                         line = line.replace("Duration", "") 
    50                                         for word in line.split(): 
    51                                                 configs[5] += 1 
    52                                                 configs_arg[5].append('Duration = '+word) 
    53                                 elif line.startswith("ATMdomain"): 
    54                                         line = line.replace("ATMdomain", "") 
    55                                         for word in line.split(): 
    56                                                 configs[6] += 1 
    57                                                 configs_arg[6].append('ATMdomain = '+word) 
     10        test_list=[] 
     11        for folder in my_list: 
     12                if folder.startswith("test_"): 
     13                        test_list.append(folder) 
     14                        os.system('cd '+folder+' && python setup.py') 
     15         
    5816 
    59                                  
    60         for x in range(default_nb_config): 
    61                 if configs[x]==0: 
    62                         configs[x] =1 
     17        f=open("CMakeLists.txt", "w") 
    6318 
    64         config_id=0 
    65         for i0 in range(configs[0]): 
    66                 hasContent0 = len(configs_arg[0])>0 
    67                 for i1 in range(configs[1]): 
    68                         hasContent1 = len(configs_arg[1])>0 
    69                         for i2 in range(configs[2]): 
    70                                 hasContent2 = len(configs_arg[2])>0 
    71                                 for i3 in range(configs[3]): 
    72                                         hasContent3 = len(configs_arg[3])>0 
    73                                         for i4 in range(configs[4]): 
    74                                                 hasContent4 = len(configs_arg[4])>0 
    75                                                 for i5 in range(configs[5]): 
    76                                                         hasContent5 = len(configs_arg[5])>0 
    77                                                         for i6 in range(configs[6]): 
    78                                                                 hasContent6 = len(configs_arg[6])>0 
     19        f.write("##############################\n") 
     20        f.write("# file generated by setup.py #\n") 
     21        f.write("#      DO NOT modify         #\n") 
     22        f.write("##############################\n\n") 
     23         
     24        f.write("cmake_minimum_required(VERSION 2.8.12.2)\n\n") 
     25        f.write("project(generic_testcase)\n\n") 
     26        f.write("enable_testing()\n\n") 
    7927 
    80                                                                 filename = "user_param.py."+repr(config_id) 
    81                                                                 g = open(filename, "w") 
     28        for x in range(len(test_list)): 
     29                f.write("add_subdirectory(" + test_list[x]+ ")\n") 
    8230 
    83                                                                 if hasContent0: g.write(configs_arg[0][i0]+'\n') 
    84                                                                 if hasContent1: g.write(configs_arg[1][i1]+'\n') 
    85                                                                 if hasContent2: g.write(configs_arg[2][i2]+'\n') 
    86                                                                 if hasContent3: g.write(configs_arg[3][i3]+'\n') 
    87                                                                 if hasContent4: g.write(configs_arg[4][i4]+'\n') 
    88                                                                 if hasContent5: g.write(configs_arg[5][i5]+'\n') 
    89                                                                 if hasContent6: g.write(configs_arg[6][i6]+'\n') 
    90                                                          
    91                                                                 config_id +=1 
    92                                                                 g.close 
     31        f.write("\n") 
     32        f.write("add_custom_target(\"report\")\n\n") 
     33        f.write("add_custom_command(TARGET \"report\" \n") 
     34        f.write("                   POST_BUILD\n") 
     35        f.write("                   COMMAND rm -f report.txt\n") 
     36        f.write("                   COMMAND rm -f report.html\n") 
    9337 
    94  
    95         print >>sys.stderr, nb_config 
    96  
     38        for folder in test_list: 
     39                f.write("                   COMMAND cat "+folder+"/report.txt >> report.txt\n") 
     40                f.write("                   COMMAND cat "+folder+"/report.html >> report.html\n") 
     41        f.write("                   )\n\n") 
     42        f.close 
     43         
    9744 
    9845if __name__== "__main__": 
Note: See TracChangeset for help on using the changeset viewer.