From 15c57cd4eff5a1034e56d604e8da55261ada3f39 Mon Sep 17 00:00:00 2001 From: markus holzer <markus.holzer@fau.de> Date: Thu, 11 Jun 2020 23:23:05 +0200 Subject: [PATCH] removed mrt3 from each test case --- apps/benchmarks/UniformGridGPU/UniformGridGPU.py | 12 ++++-------- apps/benchmarks/UniformGridGPU/UniformGridGPU_AA.py | 5 +++-- apps/benchmarks/UniformGridGenerated/CMakeLists.txt | 2 +- .../UniformGridGenerated/UniformGridGenerated.py | 12 ++++-------- tests/lbm/codegen/LbCodeGenerationExample.py | 2 +- 5 files changed, 13 insertions(+), 20 deletions(-) diff --git a/apps/benchmarks/UniformGridGPU/UniformGridGPU.py b/apps/benchmarks/UniformGridGPU/UniformGridGPU.py index 9ae07cd26..98eed9e8e 100644 --- a/apps/benchmarks/UniformGridGPU/UniformGridGPU.py +++ b/apps/benchmarks/UniformGridGPU/UniformGridGPU.py @@ -12,6 +12,7 @@ from pystencils.fast_approximation import insert_fast_sqrts, insert_fast_divisio from lbmpy.macroscopic_value_kernels import macroscopic_values_getter, macroscopic_values_setter omega = sp.symbols("omega") +omega_free = sp.Symbol("omega_free") omega_fill = sp.symbols("omega_:10") compile_time_block_size = False @@ -46,23 +47,18 @@ options_dict = { 'stencil': 'D3Q19', 'relaxation_rates': [omega_fill[0], omega, omega_fill[1], omega_fill[2], omega_fill[3], omega_fill[4], omega_fill[5]], }, - 'mrt3': { - 'method': 'mrt3', - 'stencil': 'D3Q19', - 'relaxation_rates': [omega, 1.1, 1.2], - }, 'entropic': { - 'method': 'mrt3', + 'method': 'mrt', 'stencil': 'D3Q19', 'compressible': True, - 'relaxation_rates': [omega, omega, sp.Symbol("omega_free")], + 'relaxation_rates': [omega, omega, omega_free, omega_free, omega_free, omega_free], 'entropic': True, }, 'entropic_kbc_n4': { 'method': 'trt-kbc-n4', 'stencil': 'D3Q27', 'compressible': True, - 'relaxation_rates': [omega, sp.Symbol("omega_free")], + 'relaxation_rates': [omega, omega_free], 'entropic': True, }, 'smagorinsky': { diff --git a/apps/benchmarks/UniformGridGPU/UniformGridGPU_AA.py b/apps/benchmarks/UniformGridGPU/UniformGridGPU_AA.py index 882de06f9..64ccfa6ac 100644 --- a/apps/benchmarks/UniformGridGPU/UniformGridGPU_AA.py +++ b/apps/benchmarks/UniformGridGPU/UniformGridGPU_AA.py @@ -10,6 +10,7 @@ from pystencils.fast_approximation import insert_fast_sqrts, insert_fast_divisio from lbmpy.macroscopic_value_kernels import macroscopic_values_getter, macroscopic_values_setter omega = sp.symbols("omega") +omega_free = sp.Symbol("omega_free") compile_time_block_size = False if compile_time_block_size: @@ -39,10 +40,10 @@ options_dict = { 'relaxation_rates': [omega, 1.3, 1.4, omega, 1.2, 1.1], }, 'entropic': { - 'method': 'mrt3', + 'method': 'mrt', 'stencil': 'D3Q19', 'compressible': True, - 'relaxation_rates': [omega, omega, sp.Symbol("omega_free")], + 'relaxation_rates': [omega, omega, omega_free, omega_free, omega_free], 'entropic': True, }, 'smagorinsky': { diff --git a/apps/benchmarks/UniformGridGenerated/CMakeLists.txt b/apps/benchmarks/UniformGridGenerated/CMakeLists.txt index 018a12cab..ee60a84f5 100644 --- a/apps/benchmarks/UniformGridGenerated/CMakeLists.txt +++ b/apps/benchmarks/UniformGridGenerated/CMakeLists.txt @@ -2,7 +2,7 @@ waLBerla_link_files_to_builddir( "*.prm" ) waLBerla_link_files_to_builddir( "*.py" ) -foreach(config trt smagorinsky mrt3 mrt entropic_kbc_n4 cumulant ) +foreach(config trt smagorinsky mrt entropic_kbc_n4 cumulant ) waLBerla_generate_target_from_python(NAME UniformGridGenerated_${config} CODEGEN_CFG ${config} FILE UniformGridGenerated.py diff --git a/apps/benchmarks/UniformGridGenerated/UniformGridGenerated.py b/apps/benchmarks/UniformGridGenerated/UniformGridGenerated.py index 4ea0ec31c..6a4d6c452 100644 --- a/apps/benchmarks/UniformGridGenerated/UniformGridGenerated.py +++ b/apps/benchmarks/UniformGridGenerated/UniformGridGenerated.py @@ -6,6 +6,7 @@ from lbmpy.macroscopic_value_kernels import macroscopic_values_getter, macroscop from lbmpy.fieldaccess import AAEvenTimeStepAccessor, AAOddTimeStepAccessor omega = sp.symbols("omega") +omega_free = sp.Symbol("omega_free") omega_fill = sp.symbols("omega_:10") options_dict = { @@ -31,23 +32,18 @@ options_dict = { 'stencil': 'D3Q19', 'relaxation_rates': [omega_fill[0], omega, omega_fill[1], omega_fill[2], omega_fill[3], omega_fill[4], omega_fill[5]], }, - 'mrt3': { - 'method': 'mrt3', - 'stencil': 'D3Q19', - 'relaxation_rates': [omega, 1.1, 1.2], - }, 'entropic': { - 'method': 'mrt3', + 'method': 'mrt', 'stencil': 'D3Q19', 'compressible': True, - 'relaxation_rates': [omega, omega, sp.Symbol("omega_free")], + 'relaxation_rates': [omega, omega, omega_free, omega_free, omega_free], 'entropic': True, }, 'entropic_kbc_n4': { 'method': 'trt-kbc-n4', 'stencil': 'D3Q27', 'compressible': True, - 'relaxation_rates': [omega, sp.Symbol("omega_free")], + 'relaxation_rates': [omega, omega_free], 'entropic': True, }, 'smagorinsky': { diff --git a/tests/lbm/codegen/LbCodeGenerationExample.py b/tests/lbm/codegen/LbCodeGenerationExample.py index 55c93853a..67aed714e 100644 --- a/tests/lbm/codegen/LbCodeGenerationExample.py +++ b/tests/lbm/codegen/LbCodeGenerationExample.py @@ -12,7 +12,7 @@ with CodeGeneration() as ctx: # the collision rule of the LB method where the some advanced features collision_rule = create_lb_collision_rule( stencil='D3Q19', compressible=True, - method='mrt3', relaxation_rates=[omega, omega, omega_free], + method='mrt', relaxation_rates=[omega, omega, omega_free, omega_free, omega_free, omega_free], entropic=True, # entropic method where second omega is chosen s.t. entropy condition omega_output_field=omega_out, # scalar field where automatically chosen omega of entropic or Smagorinsky method is written to force=force_field.center_vector, # read forces for each lattice cell from an external force field -- GitLab