Skip to content

Commit

Permalink
fix pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
edopao committed Nov 27, 2024
1 parent bfd3e9b commit 8088d42
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ def test_sdfgConvertible_laplap(cartesian_case):
# TODO(ricoh): enable test after adding GTIR support
pytest.skip("DaCe SDFGConvertible interface does not support GTIR program.")

if gtx_allocators.is_field_allocator_factory_for(cartesian_case.allocator, gtx_allocators.CUPY_DEVICE):
allocator, backend = unstructured_case.allocator, unstructured_case.backend

if gtx_allocators.is_field_allocator_factory_for(allocator, gtx_allocators.CUPY_DEVICE):
import cupy as xp
else:
import numpy as xp
Expand All @@ -57,12 +59,12 @@ def test_sdfgConvertible_laplap(cartesian_case):
def sdfg():
tmp_field = xp.empty_like(out_field)
lap_program.with_grid_type(cartesian_case.grid_type).with_backend(
cartesian_case.backend
backend
).with_connectivities(gtx_common.offset_provider_to_type(cartesian_case.offset_provider))(
in_field, tmp_field
)
lap_program.with_grid_type(cartesian_case.grid_type).with_backend(
cartesian_case.backend
backend
).with_connectivities(gtx_common.offset_provider_to_type(cartesian_case.offset_provider))(
tmp_field, out_field
)
Expand Down

0 comments on commit 8088d42

Please sign in to comment.