Skip to content

Commit

Permalink
Python format
Browse files Browse the repository at this point in the history
  • Loading branch information
pvasireddy-amd committed Oct 23, 2024
1 parent 6302047 commit 30b4f9c
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions python/dialects/aie.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,12 @@ def __call__(self, *call_args):
def bd_dim_layout(size, stride):
return Attribute.parse(f"#aie.bd_dim_layout<{size=}, {stride=}>")


def bd_pad_layout(const_pad_before, const_pad_after):
return Attribute.parse(f"#aie.bd_pad_layout<{const_pad_before=}, {const_pad_after=}>")
return Attribute.parse(
f"#aie.bd_pad_layout<{const_pad_before=}, {const_pad_after=}>"
)


@register_attribute_builder("BDDimLayoutArrayAttr")
def bd_dim_layout_array_attr_builder(tups: List[Attribute | Tuple[int]], context=None):
Expand All @@ -125,7 +129,8 @@ def bd_dim_layout_array_array_attr_builder(tup_arrs: List[List[tuple]], context=
f'#aie<bd_dim_layout_array_array[{", ".join(map(str, tup_arrs))}]>',
context=context,
)



@register_attribute_builder("BDPadLayoutArrayAttr")
def bd_pad_layout_array_attr_builder(
tups: List[Union[Attribute, Tuple[int]]], context=None
Expand Down

0 comments on commit 30b4f9c

Please sign in to comment.