mlx.core.contiguous

目录

mlx.core.contiguous#

contiguous(a: array, /, allow_col_major: bool = False, *, stream: None | Stream | Device = None) array#

Force an array to be row contiguous. Copy if necessary.

参数:
  • a (array) -- The input to make contiguous

  • allow_col_major (bool) -- Consider column major as contiguous and don't copy

返回:

The row or col contiguous output.

返回类型:

array