contiguous op / prim (#1612)

This commit is contained in:
Awni Hannun
2024-11-21 19:51:49 -08:00
committed by GitHub
parent 0d5e7716ad
commit dcca0d7477
11 changed files with 104 additions and 25 deletions

View File

@@ -1486,6 +1486,12 @@ array real(const array& a, StreamOrDevice s = {});
/* The imaginary part of a complex array. */
array imag(const array& a, StreamOrDevice s = {});
/* Ensure the array's underlying memory is contiguous. */
array contiguous(
const array& a,
bool allow_col_major = false,
StreamOrDevice s = {});
/** @} */
} // namespace mlx::core