Skip to content
Snippets Groups Projects
Commit 8c0dc06d authored by Frederik Hennig's avatar Frederik Hennig
Browse files

fix gpu target detection again

parent 3058e2e0
No related branches found
No related tags found
1 merge request!172Changes for compatibility with pystencils 2.0
Pipeline #77946 passed with warnings
......@@ -47,10 +47,8 @@ class LatticeBoltzmannStep:
if config is not None:
if IS_PYSTENCILS_2:
target = config.get_target()
is_gpu = target.is_gpu()
else:
target = config.target
is_gpu = target == Target.GPU
else:
target = optimization.get('target', Target.CPU)
......@@ -93,7 +91,11 @@ class LatticeBoltzmannStep:
self.density_data_name = name + "_density" if density_data_name is None else density_data_name
self.density_data_index = density_data_index
self._gpu = is_gpu
if IS_PYSTENCILS_2:
self._gpu = target.is_gpu()
else:
self._gpu = target == Target.GPU
layout = lbm_optimisation.field_layout
alignment = False
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment