Skip to main content
Log in

Mojo function

ndbuffer_view_from_tensor

ndbuffer_view_from_tensor[type: DType, rank: Int](tensor: Tensor[type, rank]) -> NDBuffer[type, rank]

ndbuffer_view_from_tensor[type: DType, in_rank: Int, out_rank: Int](tensor: Tensor[type, in_rank], offset: Int, out_shape: IndexList[out_rank]) -> NDBuffer[type, out_rank]