Mojo struct
ImageShape
@register_passable(trivial)
struct ImageShape
A data-layout agnostic representation of tensor shapes used in conv2d.
Fields
- N (
Int): - C (
Int): - H (
Int): - W (
Int):
Implemented traits
AnyType,
Copyable,
ImplicitlyCopyable,
Movable,
UnknownDestructibility
Aliases
__copyinit__is_trivial
alias __copyinit__is_trivial = True
__del__is_trivial
alias __del__is_trivial = True
__moveinit__is_trivial
alias __moveinit__is_trivial = True
Methods
__init__
__init__[layout: Layout, dtype: DType, image_layout: Image2DLayout](image_data: ImageData[layout, dtype, image_layout, origin]) -> Self
Constructor of an ImageShape instance from an ImageData.
Args:
- image_data (
ImageData): The image data instance to extract shape info from.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!