Best Python code snippet using avocado_python
parallel_regression.py
Source:parallel_regression.py  
1#!/usr/bin/env python2## \file parallel_regression.py3#  \brief Python script for automated regression testing of SU2 examples4#  \author A. Aranake, A. Campos, T. Economon, T. Lukaczyk, S. Padron5#  \version 7.0.6 "Blackbird"6#7# SU2 Project Website: https://su2code.github.io8#9# The SU2 Project is maintained by the SU2 Foundation10# (http://su2foundation.org)11#12# Copyright 2012-2020, SU2 Contributors (cf. AUTHORS.md)13#14# SU2 is free software; you can redistribute it and/or15# modify it under the terms of the GNU Lesser General Public16# License as published by the Free Software Foundation; either17# version 2.1 of the License, or (at your option) any later version.18#19# SU2 is distributed in the hope that it will be useful,20# but WITHOUT ANY WARRANTY; without even the implied warranty of21# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU22# Lesser General Public License for more details.23#24# You should have received a copy of the GNU Lesser General Public25# License along with SU2. If not, see <http://www.gnu.org/licenses/>.26# make print(*args) function available in PY2.6+, does'nt work on PY < 2.627from __future__ import print_function28import sys29from TestCase import TestCase30def main():31    '''This program runs SU2 and ensures that the output matches specified values.32       This will be used to do checks when code is pushed to github33       to make sure nothing is broken. '''34    test_list = []35    ##########################36    ### Compressible Euler ###37    ##########################38    # Channel39    channel           = TestCase('channel')40    channel.cfg_dir   = "euler/channel"41    channel.cfg_file  = "inv_channel_RK.cfg"42    channel.test_iter = 2043    channel.test_vals = [-2.651955, 2.814536, 0.031770, 0.002870] #last 4 columns44    channel.su2_exec  = "parallel_computation.py -f"45    channel.timeout   = 160046    channel.tol       = 0.0000147    test_list.append(channel)48    # NACA001249    naca0012           = TestCase('naca0012')50    naca0012.cfg_dir   = "euler/naca0012"51    naca0012.cfg_file  = "inv_NACA0012_Roe.cfg"52    naca0012.test_iter = 2053    naca0012.test_vals = [-4.055696, -3.564675, 0.336752, 0.021541] #last 4 columns54    naca0012.su2_exec  = "parallel_computation.py -f"55    naca0012.timeout   = 160056    naca0012.tol       = 0.0000157    test_list.append(naca0012)58    # Supersonic wedge59    wedge           = TestCase('wedge')60    wedge.cfg_dir   = "euler/wedge"61    wedge.cfg_file  = "inv_wedge_HLLC.cfg"62    wedge.test_iter = 2063    wedge.test_vals = [-0.941371, 4.787744, -0.208777, 0.036781] #last 4 columns64    wedge.su2_exec  = "parallel_computation.py -f"65    wedge.timeout   = 160066    wedge.tol       = 0.0000167    test_list.append(wedge)68    # ONERA M6 Wing69    oneram6           = TestCase('oneram6')70    oneram6.cfg_dir   = "euler/oneram6"71    oneram6.cfg_file  = "inv_ONERAM6.cfg"72    oneram6.test_iter = 1073    oneram6.test_vals = [-10.208444, -9.625586, 0.281704, 0.011821] #last 4 columns74    oneram6.su2_exec  = "parallel_computation.py -f"75    oneram6.timeout   = 320076    oneram6.tol       = 0.0000177    test_list.append(oneram6)78    # Fixed CL NACA001279    fixedCL_naca0012           = TestCase('fixedcl_naca0012')80    fixedCL_naca0012.cfg_dir   = "fixed_cl/naca0012"81    fixedCL_naca0012.cfg_file  = "inv_NACA0012.cfg"82    fixedCL_naca0012.test_iter = 1083    fixedCL_naca0012.test_vals = [-12.137437, -6.705109, 0.300000, 0.019470] #last 4 columns84    fixedCL_naca0012.su2_exec  = "parallel_computation.py -f"85    fixedCL_naca0012.timeout   = 160086    fixedCL_naca0012.tol       = 0.0000187    test_list.append(fixedCL_naca0012)88    # Polar sweep of the inviscid NACA001289    polar_naca0012           = TestCase('polar_naca0012')90    polar_naca0012.cfg_dir   = "polar/naca0012"91    polar_naca0012.cfg_file  = "inv_NACA0012.cfg"92    polar_naca0012.polar     = True93    polar_naca0012.test_iter = 1094    polar_naca0012.test_vals = [-1.216242, 4.253547, 0.001423, 0.015977] #last 4 columns95    polar_naca0012.su2_exec  = "compute_polar.py -i 11"96    polar_naca0012.timeout   = 160097    polar_naca0012.tol       = 0.0000198    test_list.append(polar_naca0012)99    # HYPERSONIC FLOW PAST BLUNT BODY100    bluntbody           = TestCase('bluntbody')101    bluntbody.cfg_dir   = "euler/bluntbody"102    bluntbody.cfg_file  = "blunt.cfg"103    bluntbody.test_iter = 20104    bluntbody.test_vals = [0.540009, 6.916653, 0.000000, 1.868976] #last 4 columns105    bluntbody.su2_exec  = "parallel_computation.py -f"106    bluntbody.timeout   = 1600107    bluntbody.tol       = 0.00001108    test_list.append(bluntbody)109    ##########################110    ###  Compressible N-S  ###111    ##########################112    # Laminar flat plate113    flatplate           = TestCase('flatplate')114    flatplate.cfg_dir   = "navierstokes/flatplate"115    flatplate.cfg_file  = "lam_flatplate.cfg"116    flatplate.test_iter = 20117    flatplate.test_vals = [-4.648252, 0.813253, -0.130643, 0.024357] #last 4 columns118    flatplate.su2_exec  = "parallel_computation.py -f"119    flatplate.timeout   = 1600120    flatplate.tol       = 0.00001121    test_list.append(flatplate)122    # Laminar cylinder (steady)123    cylinder           = TestCase('cylinder')124    cylinder.cfg_dir   = "navierstokes/cylinder"125    cylinder.cfg_file  = "lam_cylinder.cfg"126    cylinder.test_iter = 25127    cylinder.test_vals = [-6.759136, -1.291221, 0.107150, 0.853257] #last 4 columns128    cylinder.su2_exec  = "parallel_computation.py -f"129    cylinder.timeout   = 1600130    cylinder.tol       = 0.00001131    test_list.append(cylinder)132    # Laminar cylinder (low Mach correction)133    cylinder_lowmach           = TestCase('cylinder_lowmach')134    cylinder_lowmach.cfg_dir   = "navierstokes/cylinder"135    cylinder_lowmach.cfg_file  = "cylinder_lowmach.cfg"136    cylinder_lowmach.test_iter = 25137    cylinder_lowmach.test_vals = [-6.870761, -1.408778, -0.228736, 112.418622] #last 4 columns138    cylinder_lowmach.su2_exec  = "parallel_computation.py -f"139    cylinder_lowmach.timeout   = 1600140    cylinder_lowmach.tol       = 0.00001141    test_list.append(cylinder_lowmach)142    # 2D Poiseuille flow (body force driven with periodic inlet / outlet)143    poiseuille           = TestCase('poiseuille')144    poiseuille.cfg_dir   = "navierstokes/poiseuille"145    poiseuille.cfg_file  = "lam_poiseuille.cfg"146    poiseuille.test_iter = 10147    poiseuille.test_vals = [-5.050864, 0.648220, 0.000349, 13.639525] #last 4 columns148    poiseuille.su2_exec  = "parallel_computation.py -f"149    poiseuille.timeout   = 1600150    poiseuille.tol       = 0.001151    test_list.append(poiseuille)152    # 2D Poiseuille flow (inlet profile file)153    poiseuille_profile           = TestCase('poiseuille_profile')154    poiseuille_profile.cfg_dir   = "navierstokes/poiseuille"155    poiseuille_profile.cfg_file  = "profile_poiseuille.cfg"156    poiseuille_profile.test_iter = 10157    poiseuille_profile.test_vals = [-12.493492, -7.671588, -0.000000, 2.085796] #last 4 columns158    poiseuille_profile.su2_exec  = "parallel_computation.py -f"159    poiseuille_profile.timeout   = 1600160    poiseuille_profile.tol       = 0.00001161    test_list.append(poiseuille_profile)162    ##########################163    ### Compressible RANS  ###164    ##########################165    # RAE2822 SA166    rae2822_sa           = TestCase('rae2822_sa')167    rae2822_sa.cfg_dir   = "rans/rae2822"168    rae2822_sa.cfg_file  = "turb_SA_RAE2822.cfg"169    rae2822_sa.test_iter = 20170    rae2822_sa.test_vals = [-2.013881, -5.271311, 0.814981, 0.061858] #last 4 columns171    rae2822_sa.su2_exec  = "parallel_computation.py -f"172    rae2822_sa.timeout   = 1600173    rae2822_sa.tol       = 0.00001174    test_list.append(rae2822_sa)175    # RAE2822 SST176    rae2822_sst           = TestCase('rae2822_sst')177    rae2822_sst.cfg_dir   = "rans/rae2822"178    rae2822_sst.cfg_file  = "turb_SST_RAE2822.cfg"179    rae2822_sst.test_iter = 20180    rae2822_sst.test_vals = [-0.510623, 4.877370, 0.817050, 0.062058] #last 4 columns181    rae2822_sst.su2_exec  = "parallel_computation.py -f"182    rae2822_sst.timeout   = 1600183    rae2822_sst.tol       = 0.00001184    test_list.append(rae2822_sst)185    # RAE2822 SST_SUST186    rae2822_sst_sust           = TestCase('rae2822_sst_sust')187    rae2822_sst_sust.cfg_dir   = "rans/rae2822"188    rae2822_sst_sust.cfg_file  = "turb_SST_SUST_RAE2822.cfg"189    rae2822_sst_sust.test_iter = 20190    rae2822_sst_sust.test_vals = [-2.430819, 4.877370, 0.817050, 0.062058] #last 4 columns191    rae2822_sst_sust.su2_exec  = "parallel_computation.py -f"192    rae2822_sst_sust.timeout   = 1600193    rae2822_sst_sust.tol       = 0.00001194    test_list.append(rae2822_sst_sust)195    # Flat plate196    turb_flatplate           = TestCase('turb_flatplate')197    turb_flatplate.cfg_dir   = "rans/flatplate"198    turb_flatplate.cfg_file  = "turb_SA_flatplate.cfg"199    turb_flatplate.test_iter = 20200    turb_flatplate.test_vals = [-4.145487, -6.734014, -0.176490, 0.057451] #last 4 columns201    turb_flatplate.su2_exec  = "parallel_computation.py -f"202    turb_flatplate.timeout   = 1600203    turb_flatplate.tol       = 0.00001204    test_list.append(turb_flatplate)205    # ONERA M6 Wing206    turb_oneram6           = TestCase('turb_oneram6')207    turb_oneram6.cfg_dir   = "rans/oneram6"208    turb_oneram6.cfg_file  = "turb_ONERAM6.cfg"209    turb_oneram6.test_iter = 10210    turb_oneram6.test_vals = [-2.412448, -6.702975, 0.229867, 0.147637] #last 4 columns211    turb_oneram6.su2_exec  = "parallel_computation.py -f"212    turb_oneram6.timeout   = 3200213    turb_oneram6.tol       = 0.00001214    test_list.append(turb_oneram6)215    # NACA0012 (SA, FUN3D finest grid results: CL=1.0983, CD=0.01242)216    turb_naca0012_sa           = TestCase('turb_naca0012_sa')217    turb_naca0012_sa.cfg_dir   = "rans/naca0012"218    turb_naca0012_sa.cfg_file  = "turb_NACA0012_sa.cfg"219    turb_naca0012_sa.test_iter = 10220    turb_naca0012_sa.test_vals = [-12.078401, -16.147829, 1.064326, 0.019770] #last 4 columns221    turb_naca0012_sa.su2_exec  = "parallel_computation.py -f"222    turb_naca0012_sa.timeout   = 3200223    turb_naca0012_sa.tol       = 0.00001224    test_list.append(turb_naca0012_sa)225    # NACA0012 (SST, FUN3D finest grid results: CL=1.0840, CD=0.01253)226    turb_naca0012_sst           = TestCase('turb_naca0012_sst')227    turb_naca0012_sst.cfg_dir   = "rans/naca0012"228    turb_naca0012_sst.cfg_file  = "turb_NACA0012_sst.cfg"229    turb_naca0012_sst.test_iter = 10230    turb_naca0012_sst.test_vals = [-15.273461, -6.243802, 1.049988, 0.019165] #last 4 columns231    turb_naca0012_sst.su2_exec  = "parallel_computation.py -f"232    turb_naca0012_sst.timeout   = 3200233    turb_naca0012_sst.tol       = 0.00001234    test_list.append(turb_naca0012_sst)235    # NACA0012 (SST_SUST, FUN3D finest grid results: CL=1.0840, CD=0.01253)236    turb_naca0012_sst_sust           = TestCase('turb_naca0012_sst_sust')237    turb_naca0012_sst_sust.cfg_dir   = "rans/naca0012"238    turb_naca0012_sst_sust.cfg_file  = "turb_NACA0012_sst_sust.cfg"239    turb_naca0012_sst_sust.test_iter = 10240    turb_naca0012_sst_sust.test_vals = [-14.851212, -6.062226, 1.005233, 0.019014] #last 4 columns241    turb_naca0012_sst_sust.su2_exec  = "parallel_computation.py -f"242    turb_naca0012_sst_sust.timeout   = 3200243    turb_naca0012_sst_sust.tol       = 0.00001244    test_list.append(turb_naca0012_sst_sust)245    # PROPELLER246    propeller           = TestCase('propeller')247    propeller.cfg_dir   = "rans/propeller"248    propeller.cfg_file  = "propeller.cfg"249    propeller.test_iter = 10250    propeller.test_vals = [-3.389575, -8.409529, 0.000048, 0.056329] #last 4 columns251    propeller.su2_exec  = "parallel_computation.py -f"252    propeller.timeout   = 3200253    propeller.tol       = 0.00001254    test_list.append(propeller)255    #################################256    ## Compressible RANS Restart  ###257    #################################258    # NACA0012 SST Multigrid restart259    turb_naca0012_sst_restart_mg           = TestCase('turb_naca0012_sst_restart_mg')260    turb_naca0012_sst_restart_mg.cfg_dir   = "rans/naca0012"261    turb_naca0012_sst_restart_mg.cfg_file  = "turb_NACA0012_sst_multigrid_restart.cfg"262    turb_naca0012_sst_restart_mg.test_iter = 20263    turb_naca0012_sst_restart_mg.ntest_vals = 5264    turb_naca0012_sst_restart_mg.test_vals = [-7.627853, -7.729525, -1.981053, -0.000016, 0.079062] #last 5 columns265    turb_naca0012_sst_restart_mg.su2_exec  = "parallel_computation.py -f"266    turb_naca0012_sst_restart_mg.timeout   = 3200267    turb_naca0012_sst_restart_mg.tol       = 0.000001268    test_list.append(turb_naca0012_sst_restart_mg)269    #############################270    ### Incompressible Euler  ###271    #############################272    # NACA0012 Hydrofoil273    inc_euler_naca0012           = TestCase('inc_euler_naca0012')274    inc_euler_naca0012.cfg_dir   = "incomp_euler/naca0012"275    inc_euler_naca0012.cfg_file  = "incomp_NACA0012.cfg"276    inc_euler_naca0012.test_iter = 20277    inc_euler_naca0012.test_vals = [-4.802192, -3.799720, 0.497093, 0.007515] #last 4 columns278    inc_euler_naca0012.su2_exec  = "parallel_computation.py -f"279    inc_euler_naca0012.timeout   = 1600280    inc_euler_naca0012.tol       = 0.00001281    test_list.append(inc_euler_naca0012)282    # C-D nozzle with pressure inlet and mass flow outlet283    inc_nozzle           = TestCase('inc_nozzle')284    inc_nozzle.cfg_dir   = "incomp_euler/nozzle"285    inc_nozzle.cfg_file  = "inv_nozzle.cfg"286    inc_nozzle.test_iter = 20287    inc_nozzle.test_vals = [-5.959953, -4.932037, -0.000109, 0.121192] #last 4 columns288    inc_nozzle.su2_exec  = "parallel_computation.py -f"289    inc_nozzle.timeout   = 1600290    inc_nozzle.tol       = 0.00001291    test_list.append(inc_nozzle)292    #############################293    ### Incompressible N-S    ###294    #############################295    # Laminar cylinder296    inc_lam_cylinder          = TestCase('inc_lam_cylinder')297    inc_lam_cylinder.cfg_dir   = "incomp_navierstokes/cylinder"298    inc_lam_cylinder.cfg_file  = "incomp_cylinder.cfg"299    inc_lam_cylinder.test_iter = 10300    inc_lam_cylinder.test_vals = [-3.987107, -3.176477, -0.057813, 7.691336] #last 4 columns301    inc_lam_cylinder.su2_exec  = "parallel_computation.py -f"302    inc_lam_cylinder.timeout   = 1600303    inc_lam_cylinder.tol       = 0.00001304    test_list.append(inc_lam_cylinder)305    # Buoyancy-driven cavity306    inc_buoyancy          = TestCase('inc_buoyancy')307    inc_buoyancy.cfg_dir   = "incomp_navierstokes/buoyancy_cavity"308    inc_buoyancy.cfg_file  = "lam_buoyancy_cavity.cfg"309    inc_buoyancy.test_iter = 20310    inc_buoyancy.test_vals = [-4.436564, 0.508012, 0.000000, 0.000000] #last 4 columns311    inc_buoyancy.su2_exec  = "parallel_computation.py -f"312    inc_buoyancy.timeout   = 1600313    inc_buoyancy.tol       = 0.00001314    test_list.append(inc_buoyancy)315    # Laminar heated cylinder with polynomial fluid model316    inc_poly_cylinder          = TestCase('inc_poly_cylinder')317    inc_poly_cylinder.cfg_dir   = "incomp_navierstokes/cylinder"318    inc_poly_cylinder.cfg_file  = "poly_cylinder.cfg"319    inc_poly_cylinder.test_iter = 20320    inc_poly_cylinder.test_vals = [-7.812686, -2.080649, 0.016033, 1.912088] #last 4 columns321    inc_poly_cylinder.su2_exec  = "parallel_computation.py -f"322    inc_poly_cylinder.timeout   = 1600323    inc_poly_cylinder.tol       = 0.00001324    test_list.append(inc_poly_cylinder)325    # X-coarse laminar bend as a mixed element CGNS test326    inc_lam_bend          = TestCase('inc_lam_bend')327    inc_lam_bend.cfg_dir   = "incomp_navierstokes/bend"328    inc_lam_bend.cfg_file  = "lam_bend.cfg"329    inc_lam_bend.test_iter = 10330    inc_lam_bend.test_vals = [-3.437567, -3.088005, -0.022291, -0.172738] #last 4 columns331    inc_lam_bend.su2_exec  = "mpirun -n 2 SU2_CFD"332    inc_lam_bend.timeout   = 1600333    inc_lam_bend.tol       = 0.00001334    test_list.append(inc_lam_bend)335    ############################336    ### Incompressible RANS  ###337    ############################338    # NACA0012339    inc_turb_naca0012           = TestCase('inc_turb_naca0012')340    inc_turb_naca0012.cfg_dir   = "incomp_rans/naca0012"341    inc_turb_naca0012.cfg_file  = "naca0012.cfg"342    inc_turb_naca0012.test_iter = 20343    inc_turb_naca0012.test_vals = [-4.788584, -11.040550, -0.000000, 0.309515] #last 4 columns344    inc_turb_naca0012.su2_exec  = "parallel_computation.py -f"345    inc_turb_naca0012.timeout   = 1600346    inc_turb_naca0012.tol       = 0.00001347    test_list.append(inc_turb_naca0012)348    # NACA0012, SST_SUST349    inc_turb_naca0012_sst_sust           = TestCase('inc_turb_naca0012_sst_sust')350    inc_turb_naca0012_sst_sust.cfg_dir   = "incomp_rans/naca0012"351    inc_turb_naca0012_sst_sust.cfg_file  = "naca0012_SST_SUST.cfg"352    inc_turb_naca0012_sst_sust.test_iter = 20353    inc_turb_naca0012_sst_sust.test_vals = [-7.276480, 0.146181, -0.000000, 0.312017] #last 4 columns354    inc_turb_naca0012_sst_sust.su2_exec  = "parallel_computation.py -f"355    inc_turb_naca0012_sst_sust.timeout   = 1600356    inc_turb_naca0012_sst_sust.tol       = 0.00001357    test_list.append(inc_turb_naca0012_sst_sust)358    ####################359    ### DG-FEM Euler ###360    ####################361    # NACA0012362    fem_euler_naca0012           = TestCase('fem_euler_naca0012')363    fem_euler_naca0012.cfg_dir   = "hom_euler/NACA0012_5thOrder"364    fem_euler_naca0012.cfg_file  = "fem_NACA0012_reg.cfg"365    fem_euler_naca0012.test_iter = 10366    fem_euler_naca0012.test_vals = [-6.519946,-5.976944,0.255551,0.000028] #last 4 columns367    fem_euler_naca0012.su2_exec  = "mpirun -n 2 SU2_CFD"368    fem_euler_naca0012.timeout   = 1600369    fem_euler_naca0012.tol       = 0.00001370    test_list.append(fem_euler_naca0012)371    ############################372    ### DG-FEM Navier-Stokes ###373    ############################374    # Flat plate375    fem_ns_flatplate           = TestCase('fem_ns_flatplate')376    fem_ns_flatplate.cfg_dir   = "hom_navierstokes/FlatPlate/nPoly4"377    fem_ns_flatplate.cfg_file  = "lam_flatplate_reg.cfg"378    fem_ns_flatplate.test_iter = 25379    fem_ns_flatplate.test_vals = [1.383727,3.175247,0.058387,0.257951] #last 4 columns380    fem_ns_flatplate.su2_exec  = "mpirun -n 2 SU2_CFD"381    fem_ns_flatplate.timeout   = 1600382    fem_ns_flatplate.tol       = 0.00001383    test_list.append(fem_ns_flatplate)384    # Steady cylinder385    fem_ns_cylinder           = TestCase('fem_ns_cylinder')386    fem_ns_cylinder.cfg_dir   = "hom_navierstokes/CylinderViscous/nPoly3"387    fem_ns_cylinder.cfg_file  = "fem_Cylinder_reg.cfg"388    fem_ns_cylinder.test_iter = 10389    fem_ns_cylinder.test_vals = [0.454960,0.979123,-0.000028,79.984799] #last 4 columns390    fem_ns_cylinder.su2_exec  = "mpirun -n 2 SU2_CFD"391    fem_ns_cylinder.timeout   = 1600392    fem_ns_cylinder.tol       = 0.00001393    test_list.append(fem_ns_cylinder)394    # Steady sphere395    fem_ns_sphere           = TestCase('fem_ns_sphere')396    fem_ns_sphere.cfg_dir   = "hom_navierstokes/SphereViscous/nPoly3_QuadDominant"397    fem_ns_sphere.cfg_file  = "fem_Sphere_reg.cfg"398    fem_ns_sphere.test_iter = 10399    fem_ns_sphere.test_vals = [-0.288121,0.240324,0.000258,21.797363] #last 4 columns400    fem_ns_sphere.su2_exec  = "SU2_CFD"401    fem_ns_sphere.timeout   = 1600402    fem_ns_sphere.tol       = 0.00001403    test_list.append(fem_ns_sphere)404    # Unsteady sphere ADER405    fem_ns_sphere_ader           = TestCase('fem_ns_sphere_ader')406    fem_ns_sphere_ader.cfg_dir   = "hom_navierstokes/SphereViscous/nPoly3_QuadDominant"407    fem_ns_sphere_ader.cfg_file  = "fem_Sphere_reg_ADER.cfg"408    fem_ns_sphere_ader.test_iter = 10409    fem_ns_sphere_ader.test_vals = [-35.000000,-35.000000,0.000047,31.110911] #last 4 columns410    fem_ns_sphere_ader.su2_exec  = "SU2_CFD"411    fem_ns_sphere_ader.timeout   = 1600412    fem_ns_sphere_ader.tol       = 0.00001413    test_list.append(fem_ns_sphere_ader)414    # Unsteady cylinder415    fem_ns_unsteady_cylinder           = TestCase('fem_ns_unsteady_cylinder')416    fem_ns_unsteady_cylinder.cfg_dir   = "hom_navierstokes/UnsteadyCylinder/nPoly4"417    fem_ns_unsteady_cylinder.cfg_file  = "fem_unst_cylinder.cfg"418    fem_ns_unsteady_cylinder.test_iter = 11419    fem_ns_unsteady_cylinder.test_vals = [-3.558582,-3.014464,-0.038927,1.383983] #last 4 columns420    fem_ns_unsteady_cylinder.su2_exec  = "SU2_CFD"421    fem_ns_unsteady_cylinder.timeout   = 1600422    fem_ns_unsteady_cylinder.unsteady  = True423    fem_ns_unsteady_cylinder.tol       = 0.00001424    test_list.append(fem_ns_unsteady_cylinder)425    # Unsteady cylinder ADER426    fem_ns_unsteady_cylinder_ader           = TestCase('fem_ns_unsteady_cylinder_ader')427    fem_ns_unsteady_cylinder_ader.cfg_dir   = "hom_navierstokes/UnsteadyCylinder/nPoly4"428    fem_ns_unsteady_cylinder_ader.cfg_file  = "fem_unst_cylinder_ADER.cfg"429    fem_ns_unsteady_cylinder_ader.test_iter = 11430    fem_ns_unsteady_cylinder_ader.test_vals = [-35.000000,-35.000000,-0.041003,1.391339] #last 4 columns431    fem_ns_unsteady_cylinder_ader.su2_exec  = "SU2_CFD"432    fem_ns_unsteady_cylinder_ader.timeout   = 1600433    fem_ns_unsteady_cylinder_ader.unsteady  = True434    fem_ns_unsteady_cylinder_ader.tol       = 0.00001435    test_list.append(fem_ns_unsteady_cylinder_ader)436    ############################437    ###      Transition      ###438    ############################439    # Schubauer-Klebanoff Natural Transition Case440    schubauer_klebanoff_transition              = TestCase('Schubauer_Klebanoff')441    schubauer_klebanoff_transition.cfg_dir      = "transition/Schubauer_Klebanoff"442    schubauer_klebanoff_transition.cfg_file     = "transitional_BC_model_ConfigFile.cfg"443    schubauer_klebanoff_transition.test_iter    = 10444    schubauer_klebanoff_transition.test_vals    = [-7.994738, -14.268367, 0.000046, 0.007987] #last 4 columns445    schubauer_klebanoff_transition.su2_exec     = "parallel_computation.py -f"446    schubauer_klebanoff_transition.timeout      = 1600447    schubauer_klebanoff_transition.tol          = 0.00001448    test_list.append(schubauer_klebanoff_transition)449    #####################################450    ### Cont. adj. compressible Euler ###451    #####################################452    # Inviscid NACA0012453    contadj_naca0012           = TestCase('contadj_naca0012')454    contadj_naca0012.cfg_dir   = "cont_adj_euler/naca0012"455    contadj_naca0012.cfg_file  = "inv_NACA0012.cfg"456    contadj_naca0012.test_iter = 5457    contadj_naca0012.test_vals = [-9.300829, -14.583240, 0.300920, 0.019552] #last 4 columns458    contadj_naca0012.su2_exec  = "parallel_computation.py -f"459    contadj_naca0012.timeout   = 1600460    contadj_naca0012.tol       = 0.00001461    test_list.append(contadj_naca0012)462    # Inviscid ONERA M6463    contadj_oneram6           = TestCase('contadj_oneram6')464    contadj_oneram6.cfg_dir   = "cont_adj_euler/oneram6"465    contadj_oneram6.cfg_file  = "inv_ONERAM6.cfg"466    contadj_oneram6.test_iter = 10467    contadj_oneram6.test_vals = [-12.132202, -12.702416, 0.685900, 0.007594] #last 4 columns468    contadj_oneram6.su2_exec  = "parallel_computation.py -f"469    contadj_oneram6.timeout   = 1600470    contadj_oneram6.tol       = 0.00001471    test_list.append(contadj_oneram6)472    # Inviscid WEDGE: tests averaged outflow total pressure adjoint473    contadj_wedge             = TestCase('contadj_wedge')474    contadj_wedge.cfg_dir   = "cont_adj_euler/wedge"475    contadj_wedge.cfg_file  = "inv_wedge_ROE.cfg"476    contadj_wedge.test_iter = 10477    contadj_wedge.test_vals = [2.872691, -2.755572, 853010.000000, 0.000000] #last 4 columns478    contadj_wedge.su2_exec  = "parallel_computation.py -f"479    contadj_wedge.timeout   = 1600480    contadj_wedge.tol       = 0.00001481    test_list.append(contadj_wedge)482    # Inviscid fixed CL NACA0012483    contadj_fixed_CL_naca0012           = TestCase('contadj_fixedcl_naca0012')484    contadj_fixed_CL_naca0012.cfg_dir   = "fixed_cl/naca0012"485    contadj_fixed_CL_naca0012.cfg_file  = "inv_NACA0012_ContAdj.cfg"486    contadj_fixed_CL_naca0012.test_iter = 100487    contadj_fixed_CL_naca0012.test_vals = [0.317289, -5.193066, 0.360470, 0.000069] #last 4 columns488    contadj_fixed_CL_naca0012.su2_exec  = "parallel_computation.py -f"489    contadj_fixed_CL_naca0012.timeout   = 1600490    contadj_fixed_CL_naca0012.tol       = 0.00001491    test_list.append(contadj_fixed_CL_naca0012)492    ###################################493    ### Cont. adj. compressible N-S ###494    ###################################495    # Adjoint laminar cylinder496    contadj_ns_cylinder           = TestCase('contadj_ns_cylinder')497    contadj_ns_cylinder.cfg_dir   = "cont_adj_navierstokes/cylinder"498    contadj_ns_cylinder.cfg_file  = "lam_cylinder.cfg"499    contadj_ns_cylinder.test_iter = 20500    contadj_ns_cylinder.test_vals = [-3.644966, -9.102024, 2.056700, -0.000000] #last 4 columns501    contadj_ns_cylinder.su2_exec  = "parallel_computation.py -f"502    contadj_ns_cylinder.timeout   = 1600503    contadj_ns_cylinder.tol       = 0.00001504    test_list.append(contadj_ns_cylinder)505    # Adjoint laminar naca0012 subsonic506    contadj_ns_naca0012_sub           = TestCase('contadj_ns_naca0012_sub')507    contadj_ns_naca0012_sub.cfg_dir   = "cont_adj_navierstokes/naca0012_sub"508    contadj_ns_naca0012_sub.cfg_file  = "lam_NACA0012.cfg"509    contadj_ns_naca0012_sub.test_iter = 20510    contadj_ns_naca0012_sub.test_vals = [-2.743268, -8.215193, 0.518810, 0.001210] #last 4 columns511    contadj_ns_naca0012_sub.su2_exec  = "parallel_computation.py -f"512    contadj_ns_naca0012_sub.timeout   = 1600513    contadj_ns_naca0012_sub.tol       = 0.00001514    test_list.append(contadj_ns_naca0012_sub)515    # Adjoint laminar naca0012 transonic516    contadj_ns_naca0012_trans           = TestCase('contadj_ns_naca0012_trans')517    contadj_ns_naca0012_trans.cfg_dir   = "cont_adj_navierstokes/naca0012_trans"518    contadj_ns_naca0012_trans.cfg_file  = "lam_NACA0012.cfg"519    contadj_ns_naca0012_trans.test_iter = 20520    contadj_ns_naca0012_trans.test_vals = [ -1.039664, -6.575019, 1.772300, 0.012495] #last 4 columns521    contadj_ns_naca0012_trans.su2_exec  = "parallel_computation.py -f"522    contadj_ns_naca0012_trans.timeout   = 1600523    contadj_ns_naca0012_trans.tol       = 0.00001524    test_list.append(contadj_ns_naca0012_trans)525    #######################################################526    ### Cont. adj. compressible RANS (frozen viscosity) ###527    #######################################################528    # Adjoint turbulent NACA0012529    contadj_rans_naca0012           = TestCase('contadj_rans_naca0012')530    contadj_rans_naca0012.cfg_dir   = "cont_adj_rans/naca0012"531    contadj_rans_naca0012.cfg_file  = "turb_nasa.cfg"532    contadj_rans_naca0012.test_iter = 20533    contadj_rans_naca0012.test_vals = [-0.794162, -5.761722, 19.214000, -0.000000] #last 4 columns534    contadj_rans_naca0012.su2_exec  = "parallel_computation.py -f"535    contadj_rans_naca0012.timeout   = 1600536    contadj_rans_naca0012.tol       = 0.00001537    test_list.append(contadj_rans_naca0012)538    # Adjoint turbulent NACA0012 with binary restarts539    contadj_rans_naca0012_bin           = TestCase('contadj_rans_naca0012_bin')540    contadj_rans_naca0012_bin.cfg_dir   = "cont_adj_rans/naca0012"541    contadj_rans_naca0012_bin.cfg_file  = "turb_nasa_binary.cfg"542    contadj_rans_naca0012_bin.test_iter = 18543    contadj_rans_naca0012_bin.test_vals = [-0.794169, -5.761671, 19.214000, -0.000000] #last 4 columns544    contadj_rans_naca0012_bin.su2_exec  = "parallel_computation.py -f"545    contadj_rans_naca0012_bin.timeout   = 1600546    contadj_rans_naca0012_bin.tol       = 0.00001547    test_list.append(contadj_rans_naca0012_bin)548    # Adjoint turbulent RAE2822549    contadj_rans_rae2822           = TestCase('contadj_rans_rae822')550    contadj_rans_rae2822.cfg_dir   = "cont_adj_rans/rae2822"551    contadj_rans_rae2822.cfg_file  = "turb_SA_RAE2822.cfg"552    contadj_rans_rae2822.test_iter = 20553    contadj_rans_rae2822.test_vals = [-5.381383, -10.883812, -0.212470, 0.005448] #last 4 columns554    contadj_rans_rae2822.su2_exec  = "parallel_computation.py -f"555    contadj_rans_rae2822.timeout   = 1600556    contadj_rans_rae2822.tol       = 0.00001557    test_list.append(contadj_rans_rae2822)558    #############################559    ### Compressibele RANS UQ ###560    #############################561    # NACA0012 1c562    turb_naca0012_1c           = TestCase('turb_naca0012_1c')563    turb_naca0012_1c.cfg_dir   = "rans_uq/naca0012"564    turb_naca0012_1c.cfg_file  = "turb_NACA0012_uq_1c.cfg"565    turb_naca0012_1c.test_iter = 10566    turb_naca0012_1c.test_vals = [-4.973604, 1.141377, 0.870252, 0.041511] #last 4 columns567    turb_naca0012_1c.su2_exec  = "parallel_computation.py -f"568    turb_naca0012_1c.timeout   = 1600569    turb_naca0012_1c.tol       = 0.00001570    test_list.append(turb_naca0012_1c)571    # NACA0012 2c572    turb_naca0012_2c           = TestCase('turb_naca0012_2c')573    turb_naca0012_2c.cfg_dir   = "rans_uq/naca0012"574    turb_naca0012_2c.cfg_file  = "turb_NACA0012_uq_2c.cfg"575    turb_naca0012_2c.test_iter = 10576    turb_naca0012_2c.test_vals = [-5.484222, 0.967203, 0.909852, 0.056844] #last 4 columns577    turb_naca0012_2c.su2_exec  = "parallel_computation.py -f"578    turb_naca0012_2c.timeout   = 1600579    turb_naca0012_2c.tol       = 0.00001580    test_list.append(turb_naca0012_2c)581    # NACA0012 3c582    turb_naca0012_3c           = TestCase('turb_naca0012_3c')583    turb_naca0012_3c.cfg_dir   = "rans_uq/naca0012"584    turb_naca0012_3c.cfg_file  = "turb_NACA0012_uq_3c.cfg"585    turb_naca0012_3c.test_iter = 10586    turb_naca0012_3c.test_vals = [-5.587082, 0.929251, 1.008548, 0.094463] #last 4 columns587    turb_naca0012_3c.su2_exec  = "parallel_computation.py -f"588    turb_naca0012_3c.timeout   = 1600589    turb_naca0012_3c.tol       = 0.00001590    test_list.append(turb_naca0012_3c)591    # NACA0012 p1c1592    turb_naca0012_p1c1           = TestCase('turb_naca0012_p1c1')593    turb_naca0012_p1c1.cfg_dir   = "rans_uq/naca0012"594    turb_naca0012_p1c1.cfg_file  = "turb_NACA0012_uq_p1c1.cfg"595    turb_naca0012_p1c1.test_iter = 10596    turb_naca0012_p1c1.test_vals = [-5.128243, 1.076374, 0.959431, 0.067416] #last 4 columns597    turb_naca0012_p1c1.su2_exec  = "parallel_computation.py -f"598    turb_naca0012_p1c1.timeout   = 1600599    turb_naca0012_p1c1.tol       = 0.00001600    test_list.append(turb_naca0012_p1c1)601    # NACA0012 p1c2602    turb_naca0012_p1c2           = TestCase('turb_naca0012_p1c2')603    turb_naca0012_p1c2.cfg_dir   = "rans_uq/naca0012"604    turb_naca0012_p1c2.cfg_file  = "turb_NACA0012_uq_p1c2.cfg"605    turb_naca0012_p1c2.test_iter = 10606    turb_naca0012_p1c2.test_vals = [-5.556656, 0.941889, 0.956330, 0.069297] #last 4 columns607    turb_naca0012_p1c2.su2_exec  = "parallel_computation.py -f"608    turb_naca0012_p1c2.timeout   = 1600609    turb_naca0012_p1c2.tol       = 0.00001610    test_list.append(turb_naca0012_p1c2)611    ######################################612    ### Harmonic Balance               ###613    ######################################614    # Description of the regression test615    harmonic_balance           = TestCase('harmonic_balance')616    harmonic_balance.cfg_dir   = "harmonic_balance"617    harmonic_balance.cfg_file  = "HB.cfg"618    harmonic_balance.test_iter = 25619    harmonic_balance.test_vals = [-1.589755, 3.922208, 0.006724, 0.099454] #last 4 columns620    harmonic_balance.su2_exec  = "parallel_computation.py -f"621    harmonic_balance.timeout   = 1600622    harmonic_balance.tol       = 0.00001623    harmonic_balance.new_output = False624    test_list.append(harmonic_balance)625    # Turbulent pitching NACA 64a010 airfoil626    hb_rans_preconditioning           = TestCase('hb_rans_preconditioning')627    hb_rans_preconditioning.cfg_dir   = "harmonic_balance/hb_rans_preconditioning"628    hb_rans_preconditioning.cfg_file  = "davis.cfg"629    hb_rans_preconditioning.test_iter = 25630    hb_rans_preconditioning.test_vals = [-1.909596, -5.954720, 0.007773, 0.131219] #last 4 columns631    hb_rans_preconditioning.su2_exec  = "parallel_computation.py -f"632    hb_rans_preconditioning.timeout   = 1600633    hb_rans_preconditioning.tol       = 0.00001634    hb_rans_preconditioning.new_output = False635    test_list.append(hb_rans_preconditioning)636    ######################################637    ### Moving Wall                    ###638    ######################################639    # Rotating NACA 0012640    rot_naca0012           = TestCase('rot_naca0012')641    rot_naca0012.cfg_dir   = "rotating/naca0012"642    rot_naca0012.cfg_file  = "rot_NACA0012.cfg"643    rot_naca0012.test_iter = 25644    rot_naca0012.test_vals = [-2.676869, 2.865489, -0.079572, 0.002267] #last 4 columns645    rot_naca0012.su2_exec  = "parallel_computation.py -f"646    rot_naca0012.timeout   = 1600647    rot_naca0012.tol       = 0.00001648    test_list.append(rot_naca0012)649    # Lid-driven cavity650    cavity           = TestCase('cavity')651    cavity.cfg_dir   = "moving_wall/cavity"652    cavity.cfg_file  = "lam_cavity.cfg"653    cavity.test_iter = 25654    cavity.test_vals = [-5.588455, -0.124966, 0.308126, 0.940895] #last 4 columns655    cavity.su2_exec  = "parallel_computation.py -f"656    cavity.timeout   = 1600657    cavity.tol       = 0.00001658    test_list.append(cavity)659    # Spinning cylinder660    spinning_cylinder           = TestCase('spinning_cylinder')661    spinning_cylinder.cfg_dir   = "moving_wall/spinning_cylinder"662    spinning_cylinder.cfg_file  = "spinning_cylinder.cfg"663    spinning_cylinder.test_iter = 25664    spinning_cylinder.test_vals = [-7.857785, -2.425289, 1.554359, 1.531183] #last 4 columns665    spinning_cylinder.su2_exec  = "parallel_computation.py -f"666    spinning_cylinder.timeout   = 1600667    spinning_cylinder.tol       = 0.00001668    test_list.append(spinning_cylinder)669    ######################################670    ### Unsteady                       ###671    ######################################672    # Square cylinder673    square_cylinder           = TestCase('square_cylinder')674    square_cylinder.cfg_dir   = "unsteady/square_cylinder"675    square_cylinder.cfg_file  = "turb_square.cfg"676    square_cylinder.test_iter = 3677    square_cylinder.test_vals = [-1.162660, 0.066413, 1.399789, 2.220408] #last 4 columns678    square_cylinder.su2_exec  = "parallel_computation.py -f"679    square_cylinder.timeout   = 1600680    square_cylinder.tol       = 0.00001681    square_cylinder.unsteady  = True682    test_list.append(square_cylinder)683    # Gust684    sine_gust           = TestCase('sine_gust')685    sine_gust.cfg_dir   = "gust"686    sine_gust.cfg_file  = "inv_gust_NACA0012.cfg"687    sine_gust.test_iter = 5688    sine_gust.test_vals = [-1.977520, 3.481804, -0.012343, -0.007390] #last 4 columns689    sine_gust.su2_exec  = "parallel_computation.py -f"690    sine_gust.timeout   = 1600691    sine_gust.tol       = 0.00001692    sine_gust.unsteady  = True693    test_list.append(sine_gust)694    # Aeroelastic695    aeroelastic           = TestCase('aeroelastic')696    aeroelastic.cfg_dir   = "aeroelastic"697    aeroelastic.cfg_file  = "aeroelastic_NACA64A010.cfg"698    aeroelastic.test_iter = 2699    aeroelastic.test_vals = [0.076842, 0.033154, -0.001650, -0.000127] #last 4 columns700    aeroelastic.su2_exec  = "parallel_computation.py -f"701    aeroelastic.timeout   = 1600702    aeroelastic.tol       = 0.00001703    aeroelastic.unsteady  = True704    test_list.append(aeroelastic)705    # Delayed Detached Eddy Simulation706    ddes_flatplate        = TestCase('ddes_flatplate')707    ddes_flatplate.cfg_dir   = "ddes/flatplate"708    ddes_flatplate.cfg_file  = "ddes_flatplate.cfg"709    ddes_flatplate.test_iter = 10710    ddes_flatplate.test_vals = [-2.714758, -5.883004, -0.215005, 0.023783] #last 4 columns711    ddes_flatplate.su2_exec  = "parallel_computation.py -f"712    ddes_flatplate.timeout   = 1600713    ddes_flatplate.tol       = 0.00001714    ddes_flatplate.unsteady  = True715    test_list.append(ddes_flatplate)716    # unsteady pitching NACA0015, SA717    unst_inc_turb_naca0015_sa           = TestCase('unst_inc_turb_naca0015_sa')718    unst_inc_turb_naca0015_sa.cfg_dir   = "unsteady/pitching_naca0015_rans_inc"719    unst_inc_turb_naca0015_sa.cfg_file  = "config_incomp_turb_sa.cfg"720    unst_inc_turb_naca0015_sa.test_iter = 1721    unst_inc_turb_naca0015_sa.test_vals = [-2.990703, -6.865923, 1.475736, 0.419770] #last 4 columns722    unst_inc_turb_naca0015_sa.su2_exec  = "parallel_computation.py -f"723    unst_inc_turb_naca0015_sa.timeout   = 1600724    unst_inc_turb_naca0015_sa.tol       = 0.00001725    unst_inc_turb_naca0015_sa.unsteady  = True726    test_list.append(unst_inc_turb_naca0015_sa)727    ######################################728    ### NICFD                          ###729    ######################################730    # Rarefaction shock wave edge_VW731    edge_VW           = TestCase('edge_VW')732    edge_VW.cfg_dir   = "nicf/edge"733    edge_VW.cfg_file  = "edge_VW.cfg"734    edge_VW.test_iter = 100735    edge_VW.test_vals = [-5.203154, 0.933157, -0.000009, 0.000000] #last 4 columns736    edge_VW.su2_exec  = "parallel_computation.py -f"737    edge_VW.timeout   = 1600738    edge_VW.tol       = 0.00001739    test_list.append(edge_VW)740    # Rarefaction shock wave edge_PPR741    edge_PPR           = TestCase('edge_PPR')742    edge_PPR.cfg_dir   = "nicf/edge"743    edge_PPR.cfg_file  = "edge_PPR.cfg"744    edge_PPR.test_iter = 100745    edge_PPR.test_vals = [-5.385223, 0.755862, -0.000035, 0.000000] #last 4 columns746    edge_PPR.su2_exec  = "parallel_computation.py -f"747    edge_PPR.timeout   = 1600748    edge_PPR.tol       = 0.00001749    test_list.append(edge_PPR)750    ######################################751    ### Turbomachinery                 ###752    ######################################753    # Jones APU Turbocharger754    Jones_tc           = TestCase('jones_turbocharger')755    Jones_tc.cfg_dir   = "turbomachinery/APU_turbocharger"756    Jones_tc.cfg_file  = "Jones.cfg"757    Jones_tc.test_iter = 5758    Jones_tc.test_vals = [-5.280323, 0.379654, 44.725390, 2.271597] #last 4 columns759    Jones_tc.su2_exec  = "parallel_computation.py -f"760    Jones_tc.timeout   = 1600761    Jones_tc.new_output = False762    Jones_tc.tol       = 0.00001763    test_list.append(Jones_tc)764	# Jones APU Turbocharger restart765    Jones_tc_rst           = TestCase('jones_turbocharger_restart')766    Jones_tc_rst.cfg_dir   = "turbomachinery/APU_turbocharger"767    Jones_tc_rst.cfg_file  = "Jones_rst.cfg"768    Jones_tc_rst.test_iter = 5769    Jones_tc_rst.test_vals = [-4.626538, -1.570728, 34.013520, 10.190740] #last 4 columns770    Jones_tc_rst.su2_exec  = "parallel_computation.py -f"771    Jones_tc_rst.timeout   = 1600772    Jones_tc_rst.new_output = False773    Jones_tc_rst.tol       = 0.00001774    test_list.append(Jones_tc_rst)775    # 2D axial stage776    axial_stage2D           = TestCase('axial_stage2D')777    axial_stage2D.cfg_dir   = "turbomachinery/axial_stage_2D"778    axial_stage2D.cfg_file  = "Axial_stage2D.cfg"779    axial_stage2D.test_iter = 20780    axial_stage2D.test_vals = [-1.933205, 5.381311, 73.357930, 1.780467] #last 4 columns781    axial_stage2D.su2_exec  = "parallel_computation.py -f"782    axial_stage2D.timeout   = 1600783    axial_stage2D.new_output = False784    axial_stage2D.tol       = 0.00001785    test_list.append(axial_stage2D)786    # 2D transonic stator787    transonic_stator           = TestCase('transonic_stator')788    transonic_stator.cfg_dir   = "turbomachinery/transonic_stator_2D"789    transonic_stator.cfg_file  = "transonic_stator.cfg"790    transonic_stator.test_iter = 20791    transonic_stator.test_vals = [-0.576128, 5.820136, 96.994800, 0.062868] #last 4 columns792    transonic_stator.su2_exec  = "parallel_computation.py -f"793    transonic_stator.timeout   = 1600794    transonic_stator.new_output = False795    transonic_stator.tol       = 0.00001796    test_list.append(transonic_stator)797    # 2D transonic stator restart798    transonic_stator_rst           = TestCase('transonic_stator_restart')799    transonic_stator_rst.cfg_dir   = "turbomachinery/transonic_stator_2D"800    transonic_stator_rst.cfg_file  = "transonic_stator_rst.cfg"801    transonic_stator_rst.test_iter = 20802    transonic_stator_rst.test_vals = [-6.618297, -0.617100, 5.002986, 0.002951] #last 4 columns803    transonic_stator_rst.su2_exec  = "parallel_computation.py -f"804    transonic_stator_rst.timeout   = 1600805    transonic_stator_rst.new_output = False806    transonic_stator_rst.tol       = 0.00001807    test_list.append(transonic_stator_rst)808    ######################################809    ### Sliding Mesh                   ###810    ######################################811    # Uniform flow812    uniform_flow         = TestCase('uniform_flow')813    uniform_flow.cfg_dir   = "sliding_interface/uniform_flow"814    uniform_flow.cfg_file  = "uniform_NN.cfg"815    uniform_flow.test_iter = 5816    uniform_flow.test_vals = [5.000000, 0.000000, -0.188747, -10.631534] #last 4 columns817    uniform_flow.su2_exec  = "parallel_computation.py -f"818    uniform_flow.timeout   = 1600819    uniform_flow.tol       = 0.000001820    uniform_flow.unsteady  = True821    uniform_flow.multizone = True822    test_list.append(uniform_flow)823    # Channel_2D824    channel_2D           = TestCase('channel_2D')825    channel_2D.cfg_dir   = "sliding_interface/channel_2D"826    channel_2D.cfg_file  = "channel_2D_WA.cfg"827    channel_2D.test_iter = 2828    channel_2D.test_vals = [2.000000, 0.000000, 0.397891, 0.352785, 0.405448] #last 4 columns829    channel_2D.su2_exec  = "parallel_computation.py -f"830    channel_2D.timeout   = 100831    channel_2D.tol       = 0.00001832    channel_2D.unsteady  = True833    channel_2D.multizone = True834    test_list.append(channel_2D)835    # Channel_3D836    channel_3D           = TestCase('channel_3D')837    channel_3D.cfg_dir   = "sliding_interface/channel_3D"838    channel_3D.cfg_file  = "channel_3D_WA.cfg"839    channel_3D.test_iter = 2840    channel_3D.test_vals = [2.000000, 0.000000, 0.620166, 0.505156, 0.415129] #last 4 columns841    channel_3D.su2_exec  = "parallel_computation.py -f"842    channel_3D.timeout   = 1600843    channel_3D.tol       = 0.00001844    channel_3D.unsteady  = True845    channel_3D.multizone = True846    test_list.append(channel_3D)847    # Pipe848    pipe           = TestCase('pipe')849    pipe.cfg_dir   = "sliding_interface/pipe"850    pipe.cfg_file  = "pipe_NN.cfg"851    pipe.test_iter = 2852    pipe.test_vals = [0.150025, 0.491954, 0.677756, 0.963980, 1.006936] #last 4 columns853    pipe.su2_exec  = "parallel_computation.py -f"854    pipe.timeout   = 1600855    pipe.tol       = 0.00001856    pipe.unsteady  = True857    pipe.multizone = True858    test_list.append(pipe)859    # Rotating cylinders860    rotating_cylinders           = TestCase('rotating_cylinders')861    rotating_cylinders.cfg_dir   = "sliding_interface/rotating_cylinders"862    rotating_cylinders.cfg_file  = "rot_cylinders_WA.cfg"863    rotating_cylinders.test_iter = 3864    rotating_cylinders.test_vals = [3.000000, 0.000000, 0.777575, 1.134804, 1.224136] #last 4 columns865    rotating_cylinders.su2_exec  = "parallel_computation.py -f"866    rotating_cylinders.timeout   = 1600867    rotating_cylinders.tol       = 0.00001868    rotating_cylinders.unsteady  = True869    rotating_cylinders.multizone  = True870    test_list.append(rotating_cylinders)871    # Supersonic vortex shedding872    supersonic_vortex_shedding           = TestCase('supersonic_vortex_shedding')873    supersonic_vortex_shedding.cfg_dir   = "sliding_interface/supersonic_vortex_shedding"874    supersonic_vortex_shedding.cfg_file  = "sup_vor_shed_WA.cfg"875    supersonic_vortex_shedding.test_iter = 5876    supersonic_vortex_shedding.test_vals = [5.000000, 0.000000, 1.227386, 1.638722] #last 4 columns877    supersonic_vortex_shedding.su2_exec  = "parallel_computation.py -f"878    supersonic_vortex_shedding.timeout   = 1600879    supersonic_vortex_shedding.tol       = 0.00001880    supersonic_vortex_shedding.unsteady  = True881    supersonic_vortex_shedding.multizone  = True882    test_list.append(supersonic_vortex_shedding)883    # Bars_SST_2D884    bars_SST_2D           = TestCase('bars_SST_2D')885    bars_SST_2D.cfg_dir   = "sliding_interface/bars_SST_2D"886    bars_SST_2D.cfg_file  = "bars.cfg"887    bars_SST_2D.test_iter = 13888    bars_SST_2D.test_vals = [13.000000, -0.619179, -1.564701] #last 4 columns889    bars_SST_2D.su2_exec  = "SU2_CFD"890    bars_SST_2D.timeout   = 1600891    bars_SST_2D.tol       = 0.00001892    bars_SST_2D.multizone = True893    test_list.append(bars_SST_2D)894    # Sliding mesh with incompressible flows (steady)895    slinc_steady           = TestCase('slinc_steady')896    slinc_steady.cfg_dir   = "sliding_interface/incompressible_steady"897    slinc_steady.cfg_file  = "config.cfg"898    slinc_steady.test_iter = 19899    slinc_steady.test_vals = [19.000000,  -1.766116, -2.206522] #last 4 columns900    slinc_steady.su2_exec  = "SU2_CFD"901    slinc_steady.timeout   = 100902    slinc_steady.tol       = 0.00002903    slinc_steady.multizone = True904    test_list.append(slinc_steady)905    # Sliding mesh with incompressible flows (unsteady)906    # slinc_unsteady           = TestCase('slinc_unsteady')907    # slinc_unsteady.cfg_dir   = "sliding_interface/incompressible_unsteady"908    # slinc_unsteady.cfg_file  = "config.cfg"909    # slinc_unsteady.test_iter = 19910    # slinc_unsteady.test_vals = [-3.513701,1.931626,0.000000,0.000000] #last 4 columns911    # slinc_unsteady.su2_exec  = "SU2_CFD"912    # slinc_unsteady.timeout   = 100913    # slinc_unsteady.tol       = 0.00001914    # slinc_unsteady.unsteady  = True915    # test_list.append(slinc_unsteady)916    ##########################917    ### FEA - FSI          ###918    ##########################919    # Static beam, 3d920    statbeam3d           = TestCase('statbeam3d')921    statbeam3d.cfg_dir   = "fea_fsi/StatBeam_3d"922    statbeam3d.cfg_file  = "configBeam_3d.cfg"923    statbeam3d.test_iter = 0924    statbeam3d.test_vals = [-8.396797, -8.162206, -8.156102, 64095.0] #last 4 columns925    statbeam3d.su2_exec  = "parallel_computation_fsi.py -f"926    statbeam3d.timeout   = 1600927    statbeam3d.tol       = 0.00001928    test_list.append(statbeam3d)929    # Dynamic beam, 2d930    dynbeam2d           = TestCase('dynbeam2d')931    dynbeam2d.cfg_dir   = "fea_fsi/DynBeam_2d"932    dynbeam2d.cfg_file  = "configBeam_2d.cfg"933    dynbeam2d.test_iter = 6934    dynbeam2d.test_vals = [-3.240015, 2.895057, -0.353146, 6.6127e+04] #last 4 columns935    dynbeam2d.su2_exec  = "parallel_computation.py -f"936    dynbeam2d.timeout   = 1600937    dynbeam2d.unsteady  = True938    dynbeam2d.tol       = 0.00001939    test_list.append(dynbeam2d)940    # FSI, 2d941    fsi2d           = TestCase('fsi2d')942    fsi2d.cfg_dir   = "fea_fsi/WallChannel_2d"943    fsi2d.cfg_file  = "configFSI.cfg"944    fsi2d.test_iter = 4945    fsi2d.test_vals = [4, 0, -3.764076, -4.081142] #last 4 columns946    fsi2d.su2_exec  = "parallel_computation_fsi.py -f"947    fsi2d.timeout   = 1600948    fsi2d.multizone= True949    fsi2d.unsteady = True950    fsi2d.tol       = 0.00001951    test_list.append(fsi2d)952    # FSI, Static, 2D, new mesh solver953    stat_fsi           = TestCase('stat_fsi')954    stat_fsi.cfg_dir   = "fea_fsi/stat_fsi"955    stat_fsi.cfg_file  = "config.cfg"956    stat_fsi.test_iter = 7957    stat_fsi.test_vals = [-3.313612, -4.957573, 0.000000, 7.000000] #last 4 columns958    stat_fsi.su2_exec  = "mpirun -n 2 SU2_CFD"959    stat_fsi.multizone = True960    stat_fsi.timeout   = 1600961    stat_fsi.tol       = 0.00001962    test_list.append(stat_fsi)963    # FSI, Dynamic, 2D, new mesh solver964    dyn_fsi           = TestCase('dyn_fsi')965    dyn_fsi.cfg_dir   = "fea_fsi/dyn_fsi"966    dyn_fsi.cfg_file  = "config.cfg"967    dyn_fsi.test_iter = 4968    dyn_fsi.test_vals = [-4.379832, -4.005999, 0.000000, 0.000000] #last 4 columns969    dyn_fsi.multizone = True970    dyn_fsi.unsteady  = True971    dyn_fsi.su2_exec  = "mpirun -n 2 SU2_CFD"972    dyn_fsi.timeout   = 1600973    dyn_fsi.tol       = 0.00001974    test_list.append(dyn_fsi)975    # FSI, Static, 2D, new mesh solver, restart976    stat_fsi_restart           = TestCase('stat_fsi_restart')977    stat_fsi_restart.cfg_dir   = "fea_fsi/stat_fsi"978    stat_fsi_restart.cfg_file  = "config_restart.cfg"979    stat_fsi_restart.test_iter = 1980    stat_fsi_restart.test_vals = [-3.422425, -4.289201, 0.000000, 27.000000] #last 4 columns981    stat_fsi_restart.su2_exec  = "mpirun -n 2 SU2_CFD"982    stat_fsi_restart.multizone = True983    stat_fsi_restart.timeout   = 1600984    stat_fsi_restart.tol       = 0.00001985    test_list.append(stat_fsi_restart)986    # ###############################987    # ### Radiative Heat Transfer ###988    # ###############################989    # Radiative heat transfer990    p1rad           = TestCase('p1rad')991    p1rad.cfg_dir   = "radiation/p1model"992    p1rad.cfg_file  = "configp1.cfg"993    p1rad.new_output= True994    p1rad.test_iter = 100995    p1rad.test_vals = [-7.743540, -7.919958, -2.112177, 0.096091] #last 4 columns996    p1rad.su2_exec  = "mpirun -n 2 SU2_CFD"997    p1rad.timeout   = 1600998    p1rad.tol       = 0.00001999    test_list.append(p1rad)1000    # ###############################1001    # ### Conjugate heat transfer ###1002    # ###############################1003    # CHT incompressible1004    cht_incompressible           = TestCase('cht_incompressible')1005    cht_incompressible.cfg_dir   = "coupled_cht/incomp_2d"1006    cht_incompressible.cfg_file  = "cht_2d_3cylinders.cfg"1007    cht_incompressible.test_iter = 101008    cht_incompressible.test_vals = [-2.132187, -0.579649, -0.579649, -0.579649] #last 4 columns1009    cht_incompressible.su2_exec  = "SU2_CFD"1010    cht_incompressible.timeout   = 16001011    cht_incompressible.multizone = True1012    cht_incompressible.tol       = 0.000011013    test_list.append(cht_incompressible)1014    # CHT incompressible unsteady1015    cht_incompressible_unsteady           = TestCase('cht_incompressible_unsteady')1016    cht_incompressible_unsteady.cfg_dir   = "coupled_cht/incomp_2d_unsteady"1017    cht_incompressible_unsteady.cfg_file  = "cht_2d_3cylinders.cfg"1018    cht_incompressible_unsteady.test_iter = 21019    cht_incompressible_unsteady.test_vals = [-1.356091, -0.080383, -0.080387, -0.080384] #last 4 columns1020    cht_incompressible_unsteady.su2_exec  = "SU2_CFD"1021    cht_incompressible_unsteady.timeout   = 16001022    cht_incompressible_unsteady.multizone = True1023    cht_incompressible_unsteady.unsteady  = True1024    cht_incompressible_unsteady.tol       = 0.000011025    test_list.append(cht_incompressible_unsteady)1026    # CHT compressible1027    cht_compressible           = TestCase('cht_compressible')1028    cht_compressible.cfg_dir   = "coupled_cht/comp_2d"1029    cht_compressible.cfg_file  = "cht_2d_3cylinders.cfg"1030    cht_compressible.test_iter = 101031    cht_compressible.test_vals = [-4.257607, -0.526125, -0.526125, -0.526125] #last 4 columns1032    cht_compressible.su2_exec  = "SU2_CFD"1033    cht_compressible.timeout   = 16001034    cht_compressible.multizone = True1035    cht_compressible.tol       = 0.000011036    test_list.append(cht_compressible)1037    ##########################1038    ###   Python wrapper   ###1039    ##########################1040    # NACA00121041    pywrapper_naca0012           = TestCase('pywrapper_naca0012')1042    pywrapper_naca0012.cfg_dir   = "euler/naca0012"1043    pywrapper_naca0012.cfg_file  = "inv_NACA0012_Roe.cfg"1044    pywrapper_naca0012.test_iter = 1001045    pywrapper_naca0012.test_vals = [-7.298733, -6.733533, 0.333456, 0.021233] #last 4 columns1046    pywrapper_naca0012.su2_exec  = "mpirun -np 2 SU2_CFD.py --parallel -f"1047    pywrapper_naca0012.timeout   = 16001048    pywrapper_naca0012.tol       = 0.000011049    test_list.append(pywrapper_naca0012)1050    # NACA0012 (SST, FUN3D results for finest grid: CL=1.0840, CD=0.01253)1051    pywrapper_turb_naca0012_sst           = TestCase('pywrapper_turb_naca0012_sst')1052    pywrapper_turb_naca0012_sst.cfg_dir   = "rans/naca0012"1053    pywrapper_turb_naca0012_sst.cfg_file  = "turb_NACA0012_sst.cfg"1054    pywrapper_turb_naca0012_sst.test_iter = 101055    pywrapper_turb_naca0012_sst.test_vals = [-15.273461, -6.243802, 1.049988, 0.019165] #last 4 columns1056    pywrapper_turb_naca0012_sst.su2_exec  = "mpirun -np 2 SU2_CFD.py --parallel -f"1057    pywrapper_turb_naca0012_sst.timeout   = 32001058    pywrapper_turb_naca0012_sst.tol       = 0.000011059    test_list.append(pywrapper_turb_naca0012_sst)1060    # Square cylinder1061    pywrapper_square_cylinder           = TestCase('pywrapper_square_cylinder')1062    pywrapper_square_cylinder.cfg_dir   = "unsteady/square_cylinder"1063    pywrapper_square_cylinder.cfg_file  = "turb_square.cfg"1064    pywrapper_square_cylinder.test_iter = 31065    pywrapper_square_cylinder.test_vals = [-1.162660, 0.066413, 1.399789, 2.220408] #last 4 columns1066    pywrapper_square_cylinder.su2_exec  = "mpirun -np 2 SU2_CFD.py --parallel -f"1067    pywrapper_square_cylinder.timeout   = 16001068    pywrapper_square_cylinder.tol       = 0.000011069    pywrapper_square_cylinder.unsteady  = True1070    test_list.append(pywrapper_square_cylinder)1071    # Aeroelastic1072    pywrapper_aeroelastic         = TestCase('pywrapper_aeroelastic')1073    pywrapper_aeroelastic.cfg_dir   = "aeroelastic"1074    pywrapper_aeroelastic.cfg_file  = "aeroelastic_NACA64A010.cfg"1075    pywrapper_aeroelastic.test_iter = 21076    pywrapper_aeroelastic.test_vals = [0.076842, 0.033154, -0.001650, -0.000127] #last 4 columns1077    pywrapper_aeroelastic.su2_exec  = "mpirun -np 2 SU2_CFD.py --parallel -f"1078    pywrapper_aeroelastic.timeout   = 16001079    pywrapper_aeroelastic.tol       = 0.000011080    pywrapper_aeroelastic.unsteady  = True1081    test_list.append(pywrapper_aeroelastic)1082    # FSI, 2d1083    pywrapper_fsi2d           = TestCase('pywrapper_fsi2d')1084    pywrapper_fsi2d.cfg_dir   = "fea_fsi/WallChannel_2d"1085    pywrapper_fsi2d.cfg_file  = "configFSI.cfg"1086    pywrapper_fsi2d.test_iter = 41087    pywrapper_fsi2d.test_vals = [4, 0, -3.764076, -4.081142] #last 4 columns1088    pywrapper_fsi2d.su2_exec  = "mpirun -np 2 SU2_CFD.py --nZone 2 --fsi True --parallel -f"1089    pywrapper_fsi2d.timeout   = 16001090    pywrapper_fsi2d.unsteady  = True1091    pywrapper_fsi2d.multizone = True1092    pywrapper_fsi2d.tol       = 0.000011093    test_list.append(pywrapper_fsi2d)1094    # Unsteady CHT1095    pywrapper_unsteadyCHT               = TestCase('pywrapper_unsteadyCHT')1096    pywrapper_unsteadyCHT.cfg_dir       = "py_wrapper/flatPlate_unsteady_CHT"1097    pywrapper_unsteadyCHT.cfg_file      = "unsteady_CHT_FlatPlate_Conf.cfg"1098    pywrapper_unsteadyCHT.test_iter     = 51099    pywrapper_unsteadyCHT.test_vals     = [-1.614167, 2.245730, -0.000767, 0.175598] #last 4 columns1100    pywrapper_unsteadyCHT.su2_exec      = "mpirun -np 2 python launch_unsteady_CHT_FlatPlate.py --parallel -f"1101    pywrapper_unsteadyCHT.timeout       = 16001102    pywrapper_unsteadyCHT.tol           = 0.000011103    pywrapper_unsteadyCHT.unsteady      = True1104    pywrapper_unsteadyCHT.new_output    = True1105    test_list.append(pywrapper_unsteadyCHT)1106    # Rigid motion1107    pywrapper_rigidMotion               = TestCase('pywrapper_rigidMotion')1108    pywrapper_rigidMotion.cfg_dir       = "py_wrapper/flatPlate_rigidMotion"1109    pywrapper_rigidMotion.cfg_file      = "flatPlate_rigidMotion_Conf.cfg"1110    pywrapper_rigidMotion.test_iter     = 51111    pywrapper_rigidMotion.test_vals     = [-1.614165, 2.242648, -0.037218, 0.173751] #last 4 columns1112    pywrapper_rigidMotion.su2_exec      = "mpirun -np 2 python launch_flatPlate_rigidMotion.py --parallel -f"1113    pywrapper_rigidMotion.timeout       = 16001114    pywrapper_rigidMotion.tol           = 0.000011115    pywrapper_rigidMotion.unsteady      = True1116    test_list.append(pywrapper_rigidMotion)1117    ##############################################1118    ### Method of Manufactured Solutions (MMS) ###1119    ##############################################1120    # FVM, compressible, laminar N-S1121    mms_fvm_ns           = TestCase('mms_fvm_ns')1122    mms_fvm_ns.cfg_dir   = "mms/fvm_navierstokes"1123    mms_fvm_ns.cfg_file  = "lam_mms_roe.cfg"1124    mms_fvm_ns.test_iter = 201125    mms_fvm_ns.test_vals = [-2.851428, 2.192348, 0.000000, 0.000000] #last 4 columns1126    mms_fvm_ns.su2_exec  = "mpirun -n 2 SU2_CFD"1127    mms_fvm_ns.timeout   = 16001128    mms_fvm_ns.tol       = 0.00011129    test_list.append(mms_fvm_ns)1130    # FVM, incompressible, euler1131    mms_fvm_inc_euler           = TestCase('mms_fvm_inc_euler')1132    mms_fvm_inc_euler.cfg_dir   = "mms/fvm_incomp_euler"1133    mms_fvm_inc_euler.cfg_file  = "inv_mms_jst.cfg"1134    mms_fvm_inc_euler.test_iter = 201135    mms_fvm_inc_euler.test_vals = [-9.128515, -9.441740, 0.000000, 0.000000] #last 4 columns1136    mms_fvm_inc_euler.su2_exec  = "mpirun -np 2 SU2_CFD"1137    mms_fvm_inc_euler.timeout   = 16001138    mms_fvm_inc_euler.tol       = 0.00011139    test_list.append(mms_fvm_inc_euler)1140    # FVM, incompressible, laminar N-S1141    mms_fvm_inc_ns           = TestCase('mms_fvm_inc_ns')1142    mms_fvm_inc_ns.cfg_dir   = "mms/fvm_incomp_navierstokes"1143    mms_fvm_inc_ns.cfg_file  = "lam_mms_fds.cfg"1144    mms_fvm_inc_ns.test_iter = 201145    mms_fvm_inc_ns.test_vals = [-7.414944, -7.631546, 0.000000, 0.000000] #last 4 columns1146    mms_fvm_inc_ns.su2_exec  = "mpirun -np 2 SU2_CFD"1147    mms_fvm_inc_ns.timeout   = 16001148    mms_fvm_inc_ns.tol       = 0.00011149    test_list.append(mms_fvm_inc_ns)1150    # DG, compressible, euler1151    ringleb_dg_euler           = TestCase('ringleb_dg_euler')1152    ringleb_dg_euler.cfg_dir   = "mms/dg_ringleb"1153    ringleb_dg_euler.cfg_file  = "ringleb_dg.cfg"1154    ringleb_dg_euler.test_iter = 1001155    ringleb_dg_euler.test_vals = [-5.136652, -4.724941, 0.000000, 0.000000] #last 4 columns1156    ringleb_dg_euler.su2_exec  = "SU2_CFD"1157    ringleb_dg_euler.timeout   = 16001158    ringleb_dg_euler.tol       = 0.00011159    test_list.append(ringleb_dg_euler)1160    # DG, compressible, laminar N-S1161    mms_dg_ns           = TestCase('mms_dg_ns')1162    mms_dg_ns.cfg_dir   = "mms/dg_navierstokes"1163    mms_dg_ns.cfg_file  = "lam_mms_dg.cfg"1164    mms_dg_ns.test_iter = 1001165    mms_dg_ns.test_vals = [-1.845393, 3.520699, 0.000000, 0.000000] #last 4 columns1166    mms_dg_ns.su2_exec  = "SU2_CFD"1167    mms_dg_ns.timeout   = 16001168    mms_dg_ns.tol       = 0.00011169    test_list.append(mms_dg_ns)1170    # DG, compressible, laminar N-S 3D1171    mms_dg_ns_3d           = TestCase('mms_dg_ns_3d')1172    mms_dg_ns_3d.cfg_dir   = "mms/dg_navierstokes_3d"1173    mms_dg_ns_3d.cfg_file  = "lam_mms_dg_3d.cfg"1174    mms_dg_ns_3d.test_iter = 1001175    mms_dg_ns_3d.test_vals = [-0.146826, 5.356413, 0.000000, 0.000000] #last 4 columns1176    mms_dg_ns_3d.su2_exec  = "SU2_CFD"1177    mms_dg_ns_3d.timeout   = 16001178    mms_dg_ns_3d.tol       = 0.00011179    test_list.append(mms_dg_ns_3d)1180    ######################################1181    ### RUN TESTS                      ###1182    ######################################1183    pass_list = [ test.run_test() for test in test_list ]1184    ######################################1185    ### RUN SU2_SOL TESTS              ###1186    ######################################1187    # parallel STL output using1188    stl_writer_test                = TestCase('stl_writer_test')1189    stl_writer_test.cfg_dir        = "rans/oneram6"1190    stl_writer_test.cfg_file       = "turb_ONERAM6.cfg"1191    stl_writer_test.test_iter      = 11192    stl_writer_test.su2_exec       = "mpirun -n 2 SU2_SOL"1193    stl_writer_test.timeout        = 16001194    stl_writer_test.reference_file = "surface_flow.stl.ref"1195    stl_writer_test.test_file      = "surface_flow.stl"1196    pass_list.append(stl_writer_test.run_filediff())1197    test_list.append(stl_writer_test)1198    ######################################1199    ### RUN SU2_DEF TESTS              ###1200    ######################################1201    # Inviscid NACA0012 (triangles)1202    naca0012_def            = TestCase('naca0012_def')1203    naca0012_def.cfg_dir   = "deformation/naca0012"1204    naca0012_def.cfg_file  = "def_NACA0012.cfg"1205    naca0012_def.test_iter = 101206    naca0012_def.test_vals = [0.00354532] #residual1207    naca0012_def.su2_exec  = "mpirun -n 2 SU2_DEF"1208    naca0012_def.timeout   = 16001209    naca0012_def.tol       = 1e-81210    pass_list.append(naca0012_def.run_def())1211    test_list.append(naca0012_def)1212    # Inviscid NACA0012 based on SURFACE_FILE input (surface_bump.dat)1213    naca0012_def_file            = TestCase('naca0012_def_file')1214    naca0012_def_file.cfg_dir   = "deformation/naca0012"1215    naca0012_def_file.cfg_file  = "surface_file_NACA0012.cfg"1216    naca0012_def_file.test_iter = 101217    naca0012_def_file.test_vals = [0.00354532] #residual1218    naca0012_def_file.su2_exec  = "mpirun -n 2 SU2_DEF"1219    naca0012_def_file.timeout   = 16001220    naca0012_def_file.tol       = 1e-81221    pass_list.append(naca0012_def_file.run_def())1222    test_list.append(naca0012_def_file)1223    # RAE2822 (mixed tris + quads)1224    rae2822_def            = TestCase('rae2822_def')1225    rae2822_def.cfg_dir   = "deformation/rae2822"1226    rae2822_def.cfg_file  = "def_RAE2822.cfg"1227    rae2822_def.test_iter = 101228    rae2822_def.test_vals = [8.2438e-09] #residual1229    rae2822_def.su2_exec  = "mpirun -n 2 SU2_DEF"1230    rae2822_def.timeout   = 16001231    rae2822_def.tol       = 1e-131232    pass_list.append(rae2822_def.run_def())1233    test_list.append(rae2822_def)1234    # Turb NACA4412 (quads, wall distance)1235    naca4412_def            = TestCase('naca4412_def')1236    naca4412_def.cfg_dir   = "deformation/naca4412"1237    naca4412_def.cfg_file  = "def_NACA4412.cfg"1238    naca4412_def.test_iter = 101239    naca4412_def.test_vals = [2.210380e-12] #residual1240    naca4412_def.su2_exec  = "mpirun -n 2 SU2_DEF"1241    naca4412_def.timeout   = 16001242    naca4412_def.tol       = 1e-121243    pass_list.append(naca4412_def.run_def())1244    test_list.append(naca4412_def)1245    # Brick of tets (inverse volume)1246    brick_tets_def            = TestCase('brick_tets_def')1247    brick_tets_def.cfg_dir   = "deformation/brick_tets"1248    brick_tets_def.cfg_file  = "def_brick_tets.cfg"1249    brick_tets_def.test_iter = 101250    brick_tets_def.test_vals = [0.000954604] #residual1251    brick_tets_def.su2_exec  = "mpirun -n 2 SU2_DEF"1252    brick_tets_def.timeout   = 16001253    brick_tets_def.tol       = 1e-91254    pass_list.append(brick_tets_def.run_def())1255    test_list.append(brick_tets_def)1256    # Brick of isotropic hexas (inverse volume)1257    brick_hex_def           = TestCase('brick_hex_def')1258    brick_hex_def.cfg_dir   = "deformation/brick_hex"1259    brick_hex_def.cfg_file  = "def_brick_hex.cfg"1260    brick_hex_def.test_iter = 101261    brick_hex_def.test_vals = [0.000199532] #residual1262    brick_hex_def.su2_exec  = "mpirun -n 2 SU2_DEF"1263    brick_hex_def.timeout   = 16001264    brick_hex_def.tol       = 1e-91265    pass_list.append(brick_hex_def.run_def())1266    test_list.append(brick_hex_def)1267    # Brick with a pyramid layer (inverse volume)1268    brick_pyra_def           = TestCase('brick_pyra_def')1269    brick_pyra_def.cfg_dir   = "deformation/brick_pyra"1270    brick_pyra_def.cfg_file  = "def_brick_pyra.cfg"1271    brick_pyra_def.test_iter = 101272    brick_pyra_def.test_vals = [0.00160022] #residual1273    brick_pyra_def.su2_exec  = "mpirun -n 2 SU2_DEF"1274    brick_pyra_def.timeout   = 16001275    brick_pyra_def.tol       = 1e-81276    pass_list.append(brick_pyra_def.run_def())1277    test_list.append(brick_pyra_def)1278    # Brick of isotropic prisms (inverse volume)1279    brick_prism_def           = TestCase('brick_prism_def')1280    brick_prism_def.cfg_dir   = "deformation/brick_prism"1281    brick_prism_def.cfg_file  = "def_brick_prism.cfg"1282    brick_prism_def.test_iter = 101283    brick_prism_def.test_vals = [0.00260853] #residual1284    brick_prism_def.su2_exec  = "mpirun -n 2 SU2_DEF"1285    brick_prism_def.timeout   = 16001286    brick_prism_def.tol       = 1e-81287    pass_list.append(brick_prism_def.run_def())1288    test_list.append(brick_prism_def)1289    # Brick of prisms with high aspect ratio cells near the wall (wall distance)1290    brick_prism_rans_def           = TestCase('brick_prism_rans_def')1291    brick_prism_rans_def.cfg_dir   = "deformation/brick_prism_rans"1292    brick_prism_rans_def.cfg_file  = "def_brick_prism_rans.cfg"1293    brick_prism_rans_def.test_iter = 101294    brick_prism_rans_def.test_vals = [3.10348e-07] #residual1295    brick_prism_rans_def.su2_exec  = "mpirun -n 2 SU2_DEF"1296    brick_prism_rans_def.timeout   = 16001297    brick_prism_rans_def.tol       = 1e-121298    pass_list.append(brick_prism_rans_def.run_def())1299    test_list.append(brick_prism_rans_def)1300    # Brick of hexas with high aspect ratio cells near the wall (inverse volume)1301    brick_hex_rans_def           = TestCase('brick_hex_rans_def')1302    brick_hex_rans_def.cfg_dir   = "deformation/brick_hex_rans"1303    brick_hex_rans_def.cfg_file  = "def_brick_hex_rans.cfg"1304    brick_hex_rans_def.test_iter = 101305    brick_hex_rans_def.test_vals = [3.55635e-06] #residual1306    brick_hex_rans_def.su2_exec  = "mpirun -n 2 SU2_DEF"1307    brick_hex_rans_def.timeout   = 16001308    brick_hex_rans_def.tol       = 1e-111309    pass_list.append(brick_hex_rans_def.run_def())1310    test_list.append(brick_hex_rans_def)1311    # Cylindrical FFD test1312    cylinder_ffd_def           = TestCase('cylinder_ffd_def')1313    cylinder_ffd_def.cfg_dir   = "deformation/cylindrical_ffd"1314    cylinder_ffd_def.cfg_file  = "def_cylindrical.cfg"1315    cylinder_ffd_def.test_iter = 101316    cylinder_ffd_def.test_vals = [0.00054847] #residual1317    cylinder_ffd_def.su2_exec  = "mpirun -n 2 SU2_DEF"1318    cylinder_ffd_def.timeout   = 16001319    cylinder_ffd_def.tol       = 1e-91320    pass_list.append(cylinder_ffd_def.run_def())1321    test_list.append(cylinder_ffd_def)1322    # Spherical FFD test1323    sphere_ffd_def           = TestCase('sphere_ffd_def')1324    sphere_ffd_def.cfg_dir   = "deformation/spherical_ffd"1325    sphere_ffd_def.cfg_file  = "def_spherical.cfg"1326    sphere_ffd_def.test_iter = 101327    sphere_ffd_def.test_vals = [0.00359947] #residual1328    sphere_ffd_def.su2_exec  = "mpirun -n 2 SU2_DEF"1329    sphere_ffd_def.timeout   = 16001330    sphere_ffd_def.tol       = 1e-81331    pass_list.append(sphere_ffd_def.run_def())1332    test_list.append(sphere_ffd_def)1333    # Spherical FFD test using BSplines1334    sphere_ffd_def_bspline           = TestCase('sphere_ffd_def_bspline')1335    sphere_ffd_def_bspline.cfg_dir   = "deformation/spherical_ffd"1336    sphere_ffd_def_bspline.cfg_file  = "def_spherical_bspline.cfg"1337    sphere_ffd_def_bspline.test_iter = 101338    sphere_ffd_def_bspline.test_vals = [0.00208206] #residual1339    sphere_ffd_def_bspline.su2_exec  = "mpirun -n 2 SU2_DEF"1340    sphere_ffd_def_bspline.timeout   = 16001341    sphere_ffd_def_bspline.tol       = 1e-81342    pass_list.append(sphere_ffd_def_bspline.run_def())1343    test_list.append(sphere_ffd_def_bspline)1344    # Tests summary1345    print('==================================================================')1346    print('Summary of the parallel tests')1347    print('python version:', sys.version)1348    for i, test in enumerate(test_list):1349        if (pass_list[i]):1350            print('  passed - %s'%test.tag)1351        else:1352            print('* FAILED - %s'%test.tag)1353    if all(pass_list):1354        sys.exit(0)1355    else:1356        sys.exit(1)1357    # done1358if __name__ == '__main__':...hybrid_regression.py
Source:hybrid_regression.py  
1#!/usr/bin/env python2## \file parallel_regression.py3#  \brief Python script for automated regression testing of SU2 examples4#  \author A. Aranake, A. Campos, T. Economon, T. Lukaczyk, S. Padron5#  \version 7.0.6 "Blackbird"6#7# SU2 Project Website: https://su2code.github.io8#9# The SU2 Project is maintained by the SU2 Foundation10# (http://su2foundation.org)11#12# Copyright 2012-2020, SU2 Contributors (cf. AUTHORS.md)13#14# SU2 is free software; you can redistribute it and/or15# modify it under the terms of the GNU Lesser General Public16# License as published by the Free Software Foundation; either17# version 2.1 of the License, or (at your option) any later version.18#19# SU2 is distributed in the hope that it will be useful,20# but WITHOUT ANY WARRANTY; without even the implied warranty of21# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU22# Lesser General Public License for more details.23#24# You should have received a copy of the GNU Lesser General Public25# License along with SU2. If not, see <http://www.gnu.org/licenses/>.26# make print(*args) function available in PY2.6+, does'nt work on PY < 2.627from __future__ import print_function28import sys29from TestCase import TestCase30def main():31    '''This program runs SU2 and ensures that the output matches specified values.32       This will be used to do checks when code is pushed to github33       to make sure nothing is broken. '''34    test_list = []35    ##########################36    ### Compressible Euler ###37    ##########################38    # Channel39    channel           = TestCase('channel')40    channel.cfg_dir   = "euler/channel"41    channel.cfg_file  = "inv_channel_RK.cfg"42    channel.test_iter = 2043    channel.test_vals = [-2.667326, 2.797439, 0.018717, 0.006906]44    test_list.append(channel)45    # NACA001246    naca0012           = TestCase('naca0012')47    naca0012.cfg_dir   = "euler/naca0012"48    naca0012.cfg_file  = "inv_NACA0012_Roe.cfg"49    naca0012.test_iter = 2050    naca0012.test_vals = [-4.023999, -3.515034, 0.339426, 0.022217]51    test_list.append(naca0012)52    # Supersonic wedge53    wedge           = TestCase('wedge')54    wedge.cfg_dir   = "euler/wedge"55    wedge.cfg_file  = "inv_wedge_HLLC.cfg"56    wedge.test_iter = 2057    wedge.test_vals = [-0.942862, 4.784581, -0.208106, 0.036665]58    test_list.append(wedge)59    # ONERA M6 Wing60    oneram6           = TestCase('oneram6')61    oneram6.cfg_dir   = "euler/oneram6"62    oneram6.cfg_file  = "inv_ONERAM6.cfg"63    oneram6.test_iter = 1064    oneram6.test_vals = [0.281704, 0.011821]65    test_list.append(oneram6)66    # Fixed CL NACA001267    fixedCL_naca0012           = TestCase('fixedcl_naca0012')68    fixedCL_naca0012.cfg_dir   = "fixed_cl/naca0012"69    fixedCL_naca0012.cfg_file  = "inv_NACA0012.cfg"70    fixedCL_naca0012.test_iter = 1071    fixedCL_naca0012.test_vals = [-12.130189, -6.702728, 0.300000, 0.019470]72    test_list.append(fixedCL_naca0012)73    # HYPERSONIC FLOW PAST BLUNT BODY74    bluntbody           = TestCase('bluntbody')75    bluntbody.cfg_dir   = "euler/bluntbody"76    bluntbody.cfg_file  = "blunt.cfg"77    bluntbody.test_iter = 2078    bluntbody.test_vals = [0.540010, 6.916656, 0.000027, 1.869004]79    test_list.append(bluntbody)80    ##########################81    ###  Compressible N-S  ###82    ##########################83    # Laminar flat plate84    flatplate           = TestCase('flatplate')85    flatplate.cfg_dir   = "navierstokes/flatplate"86    flatplate.cfg_file  = "lam_flatplate.cfg"87    flatplate.test_iter = 2088    flatplate.test_vals = [-4.680775, 0.781235, -0.135957, 0.022978]89    test_list.append(flatplate)90    # Laminar cylinder (steady)91    cylinder           = TestCase('cylinder')92    cylinder.cfg_dir   = "navierstokes/cylinder"93    cylinder.cfg_file  = "lam_cylinder.cfg"94    cylinder.test_iter = 2595    cylinder.test_vals = [-6.765432, -1.297428, 0.019596, 0.310240]96    test_list.append(cylinder)97    # Laminar cylinder (low Mach correction)98    cylinder_lowmach           = TestCase('cylinder_lowmach')99    cylinder_lowmach.cfg_dir   = "navierstokes/cylinder"100    cylinder_lowmach.cfg_file  = "cylinder_lowmach.cfg"101    cylinder_lowmach.test_iter = 25102    cylinder_lowmach.test_vals = [-6.850130, -1.388096, -0.056203, 108.140819]103    test_list.append(cylinder_lowmach)104    # 2D Poiseuille flow (body force driven with periodic inlet / outlet)105    poiseuille           = TestCase('poiseuille')106    poiseuille.cfg_dir   = "navierstokes/poiseuille"107    poiseuille.cfg_file  = "lam_poiseuille.cfg"108    poiseuille.test_iter = 10109    poiseuille.test_vals = [-5.048282, 0.650814, 0.008714, 13.677678]110    test_list.append(poiseuille)111    # 2D Poiseuille flow (inlet profile file)112    poiseuille_profile           = TestCase('poiseuille_profile')113    poiseuille_profile.cfg_dir   = "navierstokes/poiseuille"114    poiseuille_profile.cfg_file  = "profile_poiseuille.cfg"115    poiseuille_profile.test_iter = 10116    poiseuille_profile.test_vals = [-12.494721, -7.712408, -0.000000, 2.085796]117    test_list.append(poiseuille_profile)118    ##########################119    ### Compressible RANS  ###120    ##########################121    # RAE2822 SA122    rae2822_sa           = TestCase('rae2822_sa')123    rae2822_sa.cfg_dir   = "rans/rae2822"124    rae2822_sa.cfg_file  = "turb_SA_RAE2822.cfg"125    rae2822_sa.test_iter = 20126    rae2822_sa.test_vals = [-2.021218, -5.268447, 0.807465, 0.060897]127    test_list.append(rae2822_sa)128    # RAE2822 SST129    rae2822_sst           = TestCase('rae2822_sst')130    rae2822_sst.cfg_dir   = "rans/rae2822"131    rae2822_sst.cfg_file  = "turb_SST_RAE2822.cfg"132    rae2822_sst.test_iter = 20133    rae2822_sst.test_vals = [-0.510637, 4.876603, 0.812485, 0.061969]134    test_list.append(rae2822_sst)135    # RAE2822 SST_SUST136    rae2822_sst_sust           = TestCase('rae2822_sst_sust')137    rae2822_sst_sust.cfg_dir   = "rans/rae2822"138    rae2822_sst_sust.cfg_file  = "turb_SST_SUST_RAE2822.cfg"139    rae2822_sst_sust.test_iter = 20140    rae2822_sst_sust.test_vals = [-2.429813, 4.876602, 0.812485, 0.061969]141    test_list.append(rae2822_sst_sust)142    # Flat plate143    turb_flatplate           = TestCase('turb_flatplate')144    turb_flatplate.cfg_dir   = "rans/flatplate"145    turb_flatplate.cfg_file  = "turb_SA_flatplate.cfg"146    turb_flatplate.test_iter = 20147    turb_flatplate.test_vals = [-4.157169, -6.737133, -0.176253, 0.057446]148    test_list.append(turb_flatplate)149    # ONERA M6 Wing150    turb_oneram6           = TestCase('turb_oneram6')151    turb_oneram6.cfg_dir   = "rans/oneram6"152    turb_oneram6.cfg_file  = "turb_ONERAM6.cfg"153    turb_oneram6.test_iter = 10154    turb_oneram6.test_vals = [-2.412446, -6.702976, 0.229866, 0.147638]155    test_list.append(turb_oneram6)156    # NACA0012 (SA, FUN3D finest grid results: CL=1.0983, CD=0.01242)157    turb_naca0012_sa           = TestCase('turb_naca0012_sa')158    turb_naca0012_sa.cfg_dir   = "rans/naca0012"159    turb_naca0012_sa.cfg_file  = "turb_NACA0012_sa.cfg"160    turb_naca0012_sa.test_iter = 10161    turb_naca0012_sa.test_vals = [-12.076819, -16.049252, 1.064326, 0.019770]162    test_list.append(turb_naca0012_sa)163    # NACA0012 (SST, FUN3D finest grid results: CL=1.0840, CD=0.01253)164    turb_naca0012_sst           = TestCase('turb_naca0012_sst')165    turb_naca0012_sst.cfg_dir   = "rans/naca0012"166    turb_naca0012_sst.cfg_file  = "turb_NACA0012_sst.cfg"167    turb_naca0012_sst.test_iter = 10168    turb_naca0012_sst.test_vals = [-15.273728, -6.243783, 1.049988, 0.019165]169    test_list.append(turb_naca0012_sst)170    # NACA0012 (SST_SUST, FUN3D finest grid results: CL=1.0840, CD=0.01253)171    turb_naca0012_sst_sust           = TestCase('turb_naca0012_sst_sust')172    turb_naca0012_sst_sust.cfg_dir   = "rans/naca0012"173    turb_naca0012_sst_sust.cfg_file  = "turb_NACA0012_sst_sust.cfg"174    turb_naca0012_sst_sust.test_iter = 10175    turb_naca0012_sst_sust.test_vals = [-14.851214, -6.062566, 1.005233, 0.019014]176    test_list.append(turb_naca0012_sst_sust)177    # PROPELLER178    propeller           = TestCase('propeller')179    propeller.cfg_dir   = "rans/propeller"180    propeller.cfg_file  = "propeller.cfg"181    propeller.test_iter = 10182    propeller.test_vals = [-3.389576, -8.409529, 0.000048, 0.056329]183    test_list.append(propeller)184    #################################185    ## Compressible RANS Restart  ###186    #################################187    # NACA0012 SST Multigrid restart188    turb_naca0012_sst_restart_mg           = TestCase('turb_naca0012_sst_restart_mg')189    turb_naca0012_sst_restart_mg.cfg_dir   = "rans/naca0012"190    turb_naca0012_sst_restart_mg.cfg_file  = "turb_NACA0012_sst_multigrid_restart.cfg"191    turb_naca0012_sst_restart_mg.test_iter = 20192    turb_naca0012_sst_restart_mg.ntest_vals = 5193    turb_naca0012_sst_restart_mg.test_vals = [-7.653296, -7.729472, -1.981061, -0.000016, 0.079062]194    test_list.append(turb_naca0012_sst_restart_mg)195    #############################196    ### Compressibele RANS UQ ###197    #############################198    # NACA0012 1c199    turb_naca0012_1c           = TestCase('turb_naca0012_1c')200    turb_naca0012_1c.cfg_dir   = "rans_uq/naca0012"201    turb_naca0012_1c.cfg_file  = "turb_NACA0012_uq_1c.cfg"202    turb_naca0012_1c.test_iter = 10203    turb_naca0012_1c.test_vals = [-4.979339, 1.140084, 1.217182, 0.220079]204    test_list.append(turb_naca0012_1c)205    # NACA0012 2c206    turb_naca0012_2c           = TestCase('turb_naca0012_2c')207    turb_naca0012_2c.cfg_dir   = "rans_uq/naca0012"208    turb_naca0012_2c.cfg_file  = "turb_NACA0012_uq_2c.cfg"209    turb_naca0012_2c.test_iter = 10210    turb_naca0012_2c.test_vals = [-5.484195, 0.969780, 1.315926, 0.258346]211    test_list.append(turb_naca0012_2c)212    # NACA0012 3c213    turb_naca0012_3c           = TestCase('turb_naca0012_3c')214    turb_naca0012_3c.cfg_dir   = "rans_uq/naca0012"215    turb_naca0012_3c.cfg_file  = "turb_NACA0012_uq_3c.cfg"216    turb_naca0012_3c.test_iter = 10217    turb_naca0012_3c.test_vals = [-5.586959, 0.932347, 1.540973, 0.345562]218    test_list.append(turb_naca0012_3c)219    # NACA0012 p1c1220    turb_naca0012_p1c1           = TestCase('turb_naca0012_p1c1')221    turb_naca0012_p1c1.cfg_dir   = "rans_uq/naca0012"222    turb_naca0012_p1c1.cfg_file  = "turb_NACA0012_uq_p1c1.cfg"223    turb_naca0012_p1c1.test_iter = 10224    turb_naca0012_p1c1.test_vals = [-5.132080, 1.076459, 1.183320, 0.207012]225    test_list.append(turb_naca0012_p1c1)226    # NACA0012 p1c2227    turb_naca0012_p1c2           = TestCase('turb_naca0012_p1c2')228    turb_naca0012_p1c2.cfg_dir   = "rans_uq/naca0012"229    turb_naca0012_p1c2.cfg_file  = "turb_NACA0012_uq_p1c2.cfg"230    turb_naca0012_p1c2.test_iter = 10231    turb_naca0012_p1c2.test_vals = [-5.556645, 0.945121, 1.246337, 0.231311]232    test_list.append(turb_naca0012_p1c2)233    ######################################234    ### Harmonic Balance               ###235    ######################################236    # Description of the regression test237    harmonic_balance           = TestCase('harmonic_balance')238    harmonic_balance.cfg_dir   = "harmonic_balance"239    harmonic_balance.cfg_file  = "HB.cfg"240    harmonic_balance.test_iter = 25241    harmonic_balance.test_vals = [-1.589755, 3.922207, 0.006725, 0.099455]242    harmonic_balance.new_output = False243    test_list.append(harmonic_balance)244    # Turbulent pitching NACA 64a010 airfoil245    hb_rans_preconditioning           = TestCase('hb_rans_preconditioning')246    hb_rans_preconditioning.cfg_dir   = "harmonic_balance/hb_rans_preconditioning"247    hb_rans_preconditioning.cfg_file  = "davis.cfg"248    hb_rans_preconditioning.test_iter = 25249    hb_rans_preconditioning.test_vals = [-1.909633, -5.954752, 0.007773, 0.131217]250    hb_rans_preconditioning.new_output = False251    test_list.append(hb_rans_preconditioning)252    ######################################253    ### Moving Wall                    ###254    ######################################255    # Lid-driven cavity256    cavity           = TestCase('cavity')257    cavity.cfg_dir   = "moving_wall/cavity"258    cavity.cfg_file  = "lam_cavity.cfg"259    cavity.test_iter = 25260    cavity.test_vals = [-5.627934, -0.164469, 0.051998, 2.547065]261    test_list.append(cavity)262    # Spinning cylinder263    spinning_cylinder           = TestCase('spinning_cylinder')264    spinning_cylinder.cfg_dir   = "moving_wall/spinning_cylinder"265    spinning_cylinder.cfg_file  = "spinning_cylinder.cfg"266    spinning_cylinder.test_iter = 25267    spinning_cylinder.test_vals = [-7.996313, -2.601764, 1.510692, 1.493876]268    test_list.append(spinning_cylinder)269    ######################################270    ### Unsteady                       ###271    ######################################272    # Square cylinder273    square_cylinder           = TestCase('square_cylinder')274    square_cylinder.cfg_dir   = "unsteady/square_cylinder"275    square_cylinder.cfg_file  = "turb_square.cfg"276    square_cylinder.test_iter = 3277    square_cylinder.test_vals = [-1.162572, 0.066371, 1.399790, 2.220393]278    square_cylinder.unsteady  = True279    test_list.append(square_cylinder)280    # Gust281    sine_gust           = TestCase('sine_gust')282    sine_gust.cfg_dir   = "gust"283    sine_gust.cfg_file  = "inv_gust_NACA0012.cfg"284    sine_gust.test_iter = 5285    sine_gust.test_vals = [-1.977520, 3.481804, -0.012404, -0.007452]286    sine_gust.unsteady  = True287    test_list.append(sine_gust)288    # Aeroelastic289    aeroelastic           = TestCase('aeroelastic')290    aeroelastic.cfg_dir   = "aeroelastic"291    aeroelastic.cfg_file  = "aeroelastic_NACA64A010.cfg"292    aeroelastic.test_iter = 2293    aeroelastic.test_vals = [0.074525, 0.033127, -0.001650, -0.000127]294    aeroelastic.unsteady  = True295    test_list.append(aeroelastic)296    # Delayed Detached Eddy Simulation297    ddes_flatplate        = TestCase('ddes_flatplate')298    ddes_flatplate.cfg_dir   = "ddes/flatplate"299    ddes_flatplate.cfg_file  = "ddes_flatplate.cfg"300    ddes_flatplate.test_iter = 10301    ddes_flatplate.test_vals = [-2.714758, -5.883004, -0.215005, 0.023783]302    ddes_flatplate.unsteady  = True303    test_list.append(ddes_flatplate)304    ######################################305    ### NICFD                          ###306    ######################################307    # Rarefaction shock wave edge_VW308    edge_VW           = TestCase('edge_VW')309    edge_VW.cfg_dir   = "nicf/edge"310    edge_VW.cfg_file  = "edge_VW.cfg"311    edge_VW.test_iter = 100312    edge_VW.test_vals = [-5.040283, 1.124491, -0.000009, 0.000000]313    test_list.append(edge_VW)314    # Rarefaction shock wave edge_PPR315    edge_PPR           = TestCase('edge_PPR')316    edge_PPR.cfg_dir   = "nicf/edge"317    edge_PPR.cfg_file  = "edge_PPR.cfg"318    edge_PPR.test_iter = 100319    edge_PPR.test_vals = [-5.401640, 0.738165, -0.000035, 0.000000]320    test_list.append(edge_PPR)321    ######################################322    ### Turbomachinery                 ###323    ######################################324    # Jones APU Turbocharger325    Jones_tc           = TestCase('jones_turbocharger')326    Jones_tc.cfg_dir   = "turbomachinery/APU_turbocharger"327    Jones_tc.cfg_file  = "Jones.cfg"328    Jones_tc.test_iter = 5329    Jones_tc.test_vals = [-5.280316, 0.379651, 44.725470, 2.271540]330    Jones_tc.new_output = False331    test_list.append(Jones_tc)332	# Jones APU Turbocharger restart333    Jones_tc_rst           = TestCase('jones_turbocharger_restart')334    Jones_tc_rst.cfg_dir   = "turbomachinery/APU_turbocharger"335    Jones_tc_rst.cfg_file  = "Jones_rst.cfg"336    Jones_tc_rst.test_iter = 5337    Jones_tc_rst.test_vals = [-4.626647, -1.570858, 34.014100, 10.190720]338    Jones_tc_rst.new_output = False339    test_list.append(Jones_tc_rst)340    # 2D axial stage341    axial_stage2D           = TestCase('axial_stage2D')342    axial_stage2D.cfg_dir   = "turbomachinery/axial_stage_2D"343    axial_stage2D.cfg_file  = "Axial_stage2D.cfg"344    axial_stage2D.test_iter = 20345    axial_stage2D.test_vals = [-1.933199, 5.381560, 73.357900, 1.780500]346    axial_stage2D.new_output = False347    test_list.append(axial_stage2D)348    # 2D transonic stator349    transonic_stator           = TestCase('transonic_stator')350    transonic_stator.cfg_dir   = "turbomachinery/transonic_stator_2D"351    transonic_stator.cfg_file  = "transonic_stator.cfg"352    transonic_stator.test_iter = 20353    transonic_stator.test_vals = [-0.563540, 5.823232, 96.736080, 0.062426]354    transonic_stator.new_output = False355    test_list.append(transonic_stator)356    # 2D transonic stator restart357    transonic_stator_rst           = TestCase('transonic_stator_restart')358    transonic_stator_rst.cfg_dir   = "turbomachinery/transonic_stator_2D"359    transonic_stator_rst.cfg_file  = "transonic_stator_rst.cfg"360    transonic_stator_rst.test_iter = 20361    transonic_stator_rst.test_vals = [-6.621626, -0.614379, 5.002986, 0.002951]362    transonic_stator_rst.new_output = False363    test_list.append(transonic_stator_rst)364    ######################################365    ### Sliding Mesh                   ###366    ######################################367    # Uniform flow368    uniform_flow         = TestCase('uniform_flow')369    uniform_flow.cfg_dir   = "sliding_interface/uniform_flow"370    uniform_flow.cfg_file  = "uniform_NN.cfg"371    uniform_flow.test_iter = 5372    uniform_flow.test_vals = [5.000000, 0.000000, -0.188748, -10.631530]373    uniform_flow.unsteady  = True374    uniform_flow.multizone = True375    test_list.append(uniform_flow)376    # Channel_2D377    channel_2D           = TestCase('channel_2D')378    channel_2D.cfg_dir   = "sliding_interface/channel_2D"379    channel_2D.cfg_file  = "channel_2D_WA.cfg"380    channel_2D.test_iter = 2381    channel_2D.test_vals = [2.000000, 0.000000, 0.398089, 0.352762, 0.405397]382    channel_2D.unsteady  = True383    channel_2D.multizone = True384    test_list.append(channel_2D)385    # Channel_3D386    channel_3D           = TestCase('channel_3D')387    channel_3D.cfg_dir   = "sliding_interface/channel_3D"388    channel_3D.cfg_file  = "channel_3D_WA.cfg"389    channel_3D.test_iter = 2390    channel_3D.test_vals = [2.000000, 0.000000, 0.620151, 0.505157, 0.415249]391    channel_3D.unsteady  = True392    channel_3D.multizone = True393    test_list.append(channel_3D)394    # Pipe395    pipe           = TestCase('pipe')396    pipe.cfg_dir   = "sliding_interface/pipe"397    pipe.cfg_file  = "pipe_NN.cfg"398    pipe.test_iter = 2399    pipe.test_vals = [0.150024, 0.491949, 0.677757, 0.963990, 1.006944]400    pipe.unsteady  = True401    pipe.multizone = True402    test_list.append(pipe)403    # Rotating cylinders404    rotating_cylinders           = TestCase('rotating_cylinders')405    rotating_cylinders.cfg_dir   = "sliding_interface/rotating_cylinders"406    rotating_cylinders.cfg_file  = "rot_cylinders_WA.cfg"407    rotating_cylinders.test_iter = 3408    rotating_cylinders.test_vals = [3.000000, 0.000000, 0.777567, 1.134807, 1.224136]409    rotating_cylinders.unsteady  = True410    rotating_cylinders.multizone  = True411    test_list.append(rotating_cylinders)412    # Supersonic vortex shedding413    supersonic_vortex_shedding           = TestCase('supersonic_vortex_shedding')414    supersonic_vortex_shedding.cfg_dir   = "sliding_interface/supersonic_vortex_shedding"415    supersonic_vortex_shedding.cfg_file  = "sup_vor_shed_WA.cfg"416    supersonic_vortex_shedding.test_iter = 5417    supersonic_vortex_shedding.test_vals = [5.000000, 0.000000, 1.216554, 1.639121]418    supersonic_vortex_shedding.unsteady  = True419    supersonic_vortex_shedding.multizone  = True420    test_list.append(supersonic_vortex_shedding)421    # Bars_SST_2D422    bars_SST_2D           = TestCase('bars_SST_2D')423    bars_SST_2D.cfg_dir   = "sliding_interface/bars_SST_2D"424    bars_SST_2D.cfg_file  = "bars.cfg"425    bars_SST_2D.test_iter = 13426    bars_SST_2D.test_vals = [13.000000, -0.619179, -1.564701]427    bars_SST_2D.multizone = True428    test_list.append(bars_SST_2D)429    ##########################430    ### FEA - FSI          ###431    ##########################432    # Static beam, 3d433    statbeam3d           = TestCase('statbeam3d')434    statbeam3d.cfg_dir   = "fea_fsi/StatBeam_3d"435    statbeam3d.cfg_file  = "configBeam_3d.cfg"436    statbeam3d.test_iter = 0437    statbeam3d.test_vals = [-2.378370, -1.585252, -2.028505, 6.4359e+04]438    test_list.append(statbeam3d)439    # Dynamic beam, 2d440    dynbeam2d           = TestCase('dynbeam2d')441    dynbeam2d.cfg_dir   = "fea_fsi/DynBeam_2d"442    dynbeam2d.cfg_file  = "configBeam_2d.cfg"443    dynbeam2d.test_iter = 6444    dynbeam2d.test_vals = [-3.240015, 2.895057, -0.353146, 66127.000000]445    dynbeam2d.unsteady  = True446    test_list.append(dynbeam2d)447    # FSI, 2d448    fsi2d           = TestCase('fsi2d')449    fsi2d.cfg_dir   = "fea_fsi/WallChannel_2d"450    fsi2d.cfg_file  = "configFSI.cfg"451    fsi2d.test_iter = 4452    fsi2d.test_vals = [4.000000, 0.000000, -3.764089, -4.081119]453    fsi2d.multizone= True454    fsi2d.unsteady = True455    test_list.append(fsi2d)456    # FSI, Static, 2D, new mesh solver457    stat_fsi           = TestCase('stat_fsi')458    stat_fsi.cfg_dir   = "fea_fsi/stat_fsi"459    stat_fsi.cfg_file  = "config.cfg"460    stat_fsi.test_iter = 7461    stat_fsi.test_vals = [-3.242834, -4.866608, 0.000000, 11.000000]462    stat_fsi.multizone = True463    test_list.append(stat_fsi)464    # FSI, Dynamic, 2D, new mesh solver465    dyn_fsi           = TestCase('dyn_fsi')466    dyn_fsi.cfg_dir   = "fea_fsi/dyn_fsi"467    dyn_fsi.cfg_file  = "config.cfg"468    dyn_fsi.test_iter = 4469    dyn_fsi.test_vals = [-4.379823, -4.005990, 0.000000, 74.000000]470    dyn_fsi.multizone = True471    dyn_fsi.unsteady  = True472    test_list.append(dyn_fsi)473    # FSI, Static, 2D, new mesh solver, restart474    stat_fsi_restart           = TestCase('stat_fsi_restart')475    stat_fsi_restart.cfg_dir   = "fea_fsi/stat_fsi"476    stat_fsi_restart.cfg_file  = "config_restart.cfg"477    stat_fsi_restart.test_iter = 1478    stat_fsi_restart.test_vals = [-3.474239, -4.250710, 0.000000, 36.000000]479    stat_fsi_restart.multizone = True480    test_list.append(stat_fsi_restart)481    ##############################################482    ### Method of Manufactured Solutions (MMS) ###483    ##############################################484    # FVM, compressible, laminar N-S485    mms_fvm_ns           = TestCase('mms_fvm_ns')486    mms_fvm_ns.cfg_dir   = "mms/fvm_navierstokes"487    mms_fvm_ns.cfg_file  = "lam_mms_roe.cfg"488    mms_fvm_ns.test_iter = 20489    mms_fvm_ns.test_vals = [-2.851428, 2.192348, 0.000000, 0.000000]490    test_list.append(mms_fvm_ns)491    ######################################492    ### RUN TESTS                      ###493    ######################################494    for test in test_list:495        test.su2_exec = "SU2_CFD -t 2"496        test.timeout = 600497        test.tol = 1e-4498    #end499    pass_list = [ test.run_test() for test in test_list ]500    # Tests summary501    print('==================================================================')502    print('Summary of the parallel tests')503    print('python version:', sys.version)504    for i, test in enumerate(test_list):505        if (pass_list[i]):506            print('  passed - %s'%test.tag)507        else:508            print('* FAILED - %s'%test.tag)509    if all(pass_list):510        sys.exit(0)511    else:512        sys.exit(1)513    # done514if __name__ == '__main__':...parselog.py
Source:parselog.py  
1import os2import pylab3import sys4log_file = sys.argv[1]5train_iter = []6train_loss = []7test_iter = []8test_acc = []9test_loss = []10class CaffeVersion:11    OLD, NEW = range(0, 2)12CAFFE_VERSION = CaffeVersion.NEW13# prefix_loss = (CAFFE_VERSION is CaffeVersion.OLD) and 'loss = ' or 'loss = '14prefix_loss = (CAFFE_VERSION is CaffeVersion.OLD) and 'flow_loss0 = ' or 'flow_loss0 = '15prefix_acc  = 'accuracy_texture = '16prefix_iter = 'Iteration '17# prefix_scr0 = 'Test score #0: '18# prefix_scr1 = 'Test score #1: '19prefix_train_scr0 = 'Train net output #0: flow_loss0 = '20prefix_scr0 = 'Test net output #0: flow_loss0 = '21prefix_scr1 = 'Test net output #1: '22plateau = 423with open(log_file) as f:24    for line in f:25        if line.find(prefix_iter) >= 0:26            st = line.find(prefix_iter) + len(prefix_iter)27            ed = line.find(',')28            iter_num = int(line[st:ed])29            if line.find('Testing net') >= 0:30                test_iter.append(iter_num)31            else:32                if line.find('lr = ') < 0:33                    train_iter.append(iter_num)34        if CAFFE_VERSION is CaffeVersion.OLD:35            if line.find(prefix_train_scr0) >= 0:36                # st = line.find(prefix_loss) + len(prefix_loss)37                st = line.find(prefix_train_scr0) + len(prefix_train_scr0)38                train_loss.append(float(line[st:]))39                continue40            if line.find(prefix_scr0) >= 0:41                st = line.find(prefix_scr0) + len(prefix_scr0)42                test_acc.append(float(line[st:]))43                continue44            if line.find(prefix_scr1) >= 0:45                st = line.find(prefix_scr1) + len(prefix_scr1)46                test_loss.append(float(line[st:]))47                continue48        else:49            if line.find(prefix_train_scr0) >= 0:50                st = line.find(prefix_train_scr0) + len(prefix_train_scr0)51                ed = line.find('(*')52                loss = float(line[st:ed])53                if loss > plateau:54                    loss = plateau55                if line.find('flow_loss0 =') >= 0:56                    train_loss.append(loss)57                if line.find('Test net') >= 0:58                    test_loss.append(loss)59                continue60            if line.find(prefix_scr0) >= 0:61                st = line.find(prefix_scr0) + len(prefix_scr0)62                ed = line.find('(*')63                loss = float(line[st:ed])64                if line.find('flow_loss0 =') >= 0:65                    test_loss.append(loss)66                continue67            if line.find(prefix_acc) >= 0 and line.find('Test net') >= 0:68                st = line.find(prefix_acc) + len(prefix_acc)69                test_acc.append(float(line[st:]))70                continue71if len(train_iter) - len(train_loss) == 1:72    train_iter = train_iter[:-1]73if len(train_iter) - len(train_loss) == 2:74    train_iter = train_iter[:-2]75if len(test_iter) - len(test_loss) == 1:76    test_iter = test_iter[:-1]77print len(train_iter), len(train_loss)78print len(test_iter), len(test_loss)79if len(train_iter) > 100:80    pylab.plot(train_iter[4:len(train_iter)], train_loss[4:len(train_loss)])81    pylab.plot(test_iter[1:len(test_iter)], test_loss[1:len(test_iter)], 'r')82else:83    pylab.plot(train_iter[4:len(train_iter)], train_loss[4:len(train_loss)],'*-')84    pylab.plot(test_iter[1:len(test_iter)], test_loss[1:len(test_iter)], 'rs-')85pylab.plot(train_iter, train_loss, 'b')86pylab.plot(test_iter, test_loss, 'r')87pylab.legend(['training', 'testing'])88pylab.xlabel('iter'), pylab.ylabel('loss')89# pylab.figure()90# pylab.plot(test_iter, test_acc)91# pylab.xlabel('iter'), pylab.ylabel('test accuracy')...test1.py
Source:test1.py  
1# coding=utf-82# test_list = [1, 2, 3, 4]3#4# test_iter = iter(test_list)5#6# print(next(test_iter))7# print(next(test_iter))8# print(test_iter.__next__())9# print(test_iter.__next__())10# print(test_iter.__next__())11# When we reach the end and there is no more data to be returned,12# it will raise StopIteration.13# raise StopIteration14# next(test_iter)15# # æå¨å®ç°for loop16# test_list_two = ["123", "456", "789"]17# for item in test_list_two:18#     print(item)19# # for loop ç大è´åç20# # a for loop takes an iterator and iterates over it using next()21# test_iter = iter(test_list_two)22# while True:23#     try:24#         print(next(test_iter))25#     except StopIteration:26#         break27# nextåiterä¹åªä¸è¿æ¯è°ç¨çå®ä¾çself.__next__,åself.__iter__èå·²28# # è³äºfor loopçå
é¨åçæ¯ä¸æ¯è¿æ ·å¢ï¼æä»¬å¯ä»¥åä¸ä¸ªå®éª29# class TestIterator:30#     def __init__(self, max):31#         self.max = max32#33#     def __iter__(self):34#         self.n = 035#         return self36#37#     def __next__(self):38#         if self.n < self.max:39#             result = 3 ** self.n40#             self.n += 141#             return result42#         else:43#             raise StopIteration44#45#46# a = TestIterator(4)47#48# for item in a:49#     print(item)50# ä¸è¿è¦å°å¿ï¼å ä¸ºå¾ªç¯ä½¿ç¨çæ éç»å¾ªç¯ï¼è¿ä»£å¯¹è±¡å¾æå¯è½æ°¸è¿äºæ æ³èå°½51# å¦ä¸é¢çä¾åï¼int()æ¯å¯è¿ä»£çï¼ç¶åiter()æ¹æ³éé¢ç¬¬äºä¸ªåæ°æ¯å¨å
µ52# ææå°±æ¯å¦ænextå¼ä¸æ¯ç¬¬äºä¸ªåæ°ï¼å°±ç»§ç»è¿ä»£53# test_iter = iter(int, 1)54# print(test_iter.__next__())55# print(test_iter.__next__())56# print(test_iter.__next__())57# print(test_iter.__next__())58# print(test_iter.__next__())59# print(test_iter.__next__())60# print(test_iter.__next__())61# print(test_iter.__next__())62# print(test_iter.__next__())63#64# æä»¬ä¹å¯ä»¥æå¨è®©forå¾ªç¯æ çº¿å¾ªç¯ï¼åªè¦raise StopIterationå°±è¡äº65class TestIteratorTwo:66    def __iter__(self):67        self.num = 168        return self69    def __next__(self):70        num = self.num71        print(num)72        self.num += 273        return num74# è¿æ ·å°±æ é循ç¯äºï¼çå§ï¼å³ä½¿æ¯for循ç¯éé¢passäºï¼ä¹æ¯æè¾åºç75for item in TestIteratorTwo():...Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!
