diff --git a/kwave/utils/matlab.py b/kwave/utils/matlab.py index 2e040157..c23d4e67 100644 --- a/kwave/utils/matlab.py +++ b/kwave/utils/matlab.py @@ -47,7 +47,7 @@ def matlab_assign(matrix: np.ndarray, indices: Union[int, np.ndarray], """ original_shape = matrix.shape - matrix = matrix.flatten(order='F') + matrix = np.ravel(matrix, order='F') matrix[indices] = values return matrix.reshape(original_shape, order='F')