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

test_alignment_sm100_conv2d

def test_alignment_sm100_conv2d[input_type: DType, output_type: DType](in_channels: Int, out_channels: Int) -> Bool

Checks whether the input and output channel counts meet SM100 conv2d alignment requirements.

Returns True when the input activation row is 64-byte aligned and the output row is 4-byte aligned, otherwise False.

Parameters:

  • ​input_type (DType): Element type of the input activation tensor, used to compute the per-row byte width for the 64-byte alignment check.
  • ​output_type (DType): Element type of the output tensor, used to compute the per-row byte width for the 4-byte alignment check.

Args:

  • ​in_channels (Int): Number of input channels per activation row.
  • ​out_channels (Int): Number of output channels per output row.

Returns:

Bool: True if both alignment constraints are satisfied, False otherwise.

Was this page helpful?