IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /max/get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).

Mojo function

conv_transposed_cpu

def conv_transposed_cpu[filter_packed: Bool, filter_is_cfrs: Bool, has_epilogue_fusion: Bool, elementwise_lambda: def[dtype: DType, rank: Int, width: SIMDLength, alignment: Int = Int(1)](IndexList[rank], SIMD[dtype, width]) capturing thin -> None](output: TileTensor[Storage=output.Storage, linear_idx_type=output.linear_idx_type], input: TileTensor[Storage=input.Storage, linear_idx_type=input.linear_idx_type], filter: TileTensor[Storage=filter.Storage, linear_idx_type=filter.linear_idx_type], stride: IndexList[(input.LayoutType.rank - Int(2))], dilation: IndexList[(input.LayoutType.rank - Int(2))], pad_d: IndexList[Int(2)], pad_h: IndexList[Int(2)], pad_w: IndexList[Int(2)], ctx: Optional[DeviceContext] = None)

Runs a transposed convolution on the CPU using the direct register-tiled kernel.

Packs the filter when needed, builds the convolution shape, and dispatches the tiled computation across the available CPU parallelism, optionally fusing an elementwise epilogue.

Parameters:

  • ​filter_packed (Bool): Whether the filter is already in packed FRSCf layout.
  • ​filter_is_cfrs (Bool): Whether the filter is in CFRS layout, which is unsupported.
  • ​has_epilogue_fusion (Bool): Whether to fuse an elementwise epilogue into the kernel.
  • ​elementwise_lambda (def[dtype: DType, rank: Int, width: SIMDLength, alignment: Int = Int(1)](IndexList[rank], SIMD[dtype, width]) capturing thin -> None): Elementwise epilogue closure applied to each output row segment.

Args:

Was this page helpful?