Skip to content

Commit

Permalink
Something is fishy.
Browse files Browse the repository at this point in the history
The error is the DaCe loading code.
Let's use only general names to see what is happening.
  • Loading branch information
philip-paul-mueller committed Sep 5, 2024
1 parent 7265ecc commit 5ab199d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import copy
import numpy as np
import pytest
import time

from dace.sdfg import nodes as dace_nodes

Expand Down Expand Up @@ -42,7 +43,7 @@ def _get_trivial_gpu_promotable(
Args:
tasklet_code: The body of the Tasklet inside the trivial map.
"""
sdfg = dace.SDFG("TrivailGPUPromotable")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state("state", is_start_block=True)
sdfg.add_symbol("N", dace.int32)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import copy
import numpy as np
import pytest
import time

from dace.sdfg import nodes as dace_nodes, propagation as dace_propagation

Expand All @@ -28,7 +29,7 @@ def _get_simple_sdfg() -> tuple[dace.SDFG, Callable[[np.ndarray, np.ndarray], np
can be taken out. This is because how it is constructed. However, applying
some simplistic transformations this can be done.
"""
sdfg = dace.SDFG("only_dependent")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state("state", is_start_block=True)
sdfg.add_symbol("N", dace.int32)
sdfg.add_symbol("M", dace.int32)
Expand All @@ -51,7 +52,7 @@ def _get_chained_sdfg() -> tuple[dace.SDFG, Callable[[np.ndarray, np.ndarray], n
The bottom Tasklet is the only dependent Tasklet.
"""
sdfg = dace.SDFG("only_dependent")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state("state", is_start_block=True)
sdfg.add_symbol("N", dace.int32)
sdfg.add_symbol("M", dace.int32)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import dace
import copy
import numpy as np
import time
from dace.sdfg import nodes as dace_nodes
from dace.transformation import dataflow as dace_dataflow

Expand All @@ -38,7 +39,7 @@ def _make_serial_sdfg_1(
N: The size of the arrays.
"""
shape = (N, N)
sdfg = dace.SDFG("serial_1_sdfg")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state(is_start_block=True)

for name in ["a", "b", "tmp"]:
Expand Down Expand Up @@ -93,7 +94,7 @@ def _make_serial_sdfg_2(
N: The size of the arrays.
"""
shape = (N, N)
sdfg = dace.SDFG("serial_2_sdfg")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state(is_start_block=True)

for name in ["a", "b", "c", "tmp_1", "tmp_2"]:
Expand Down Expand Up @@ -165,7 +166,7 @@ def _make_serial_sdfg_3(
input_shape = (N_input,)
output_shape = (N_output,)

sdfg = dace.SDFG("serial_3_sdfg")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state(is_start_block=True)

for name, shape in [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import copy
import numpy as np
import pytest
import time

from dace.sdfg import nodes as dace_nodes

Expand All @@ -28,7 +29,7 @@ def test_serial_map_promotion():
N = 10
shape_1d = (N,)
shape_2d = (N, N)
sdfg = dace.SDFG("serial_promotable")
sdfg = dace.SDFG(f"test_sdfg__{int(time.time() * 1000)}")
state = sdfg.add_state(is_start_block=True)

# 1D Arrays
Expand Down

0 comments on commit 5ab199d

Please sign in to comment.