diff --git a/python/dune/perftool/blockstructured/__init__.py b/python/dune/perftool/blockstructured/__init__.py index bb573c50bf35dd86f202a0514a815188fda91710..6fba7aa41ee13c2e3076243d52f859b2971e2ff5 100644 --- a/python/dune/perftool/blockstructured/__init__.py +++ b/python/dune/perftool/blockstructured/__init__.py @@ -20,11 +20,6 @@ from dune.perftool.pdelab import PDELabInterface class BlockStructuredInterface(PDELabInterface): def __init__(self): PDELabInterface.__init__(self) - # register transformation - from dune.perftool.generation import transform - from dune.perftool. blockstructured.transformations import blockstructured_iname_duplication - transform(blockstructured_iname_duplication) - def generate_accumulation_instruction(self, expr, visitor): if get_option('vectorization_blockstructured'): diff --git a/python/dune/perftool/blockstructured/spaces.py b/python/dune/perftool/blockstructured/spaces.py index e667e691efcfa4d9eb6491d3fdb86b779dea97ea..1f39a9d2ee51c228f9dc4acb96c7530ad9dea3ce 100644 --- a/python/dune/perftool/blockstructured/spaces.py +++ b/python/dune/perftool/blockstructured/spaces.py @@ -14,6 +14,12 @@ def lfs_inames(element, restriction, count=None, context=''): lfs = name_leaf_lfs(element, restriction) + # register transformation + # warning: this will register the transformation a couple of times + from dune.perftool.generation import transform + from dune.perftool. blockstructured.transformations import blockstructured_iname_duplication + transform(blockstructured_iname_duplication) + dim_names = ["x", "y", "z"] + [str(i) for i in range(4, world_dimension() + 1)] name = "micro_{}_{}_index_".format(lfs, context) inames = tuple()