-
-
Notifications
You must be signed in to change notification settings - Fork 12.1k
Description
Describe the issue:
The cholesky function hangs on empty matrices when upper=True. The function does not hang when upper=False (the default). Note that upper=True is new in NumPy 2.0.
Reproduce the code example:
import numpy as np
a = np.empty((0, 0), dtype=np.float64)
np.linalg.cholesky(a, upper=True)
# <HANGS>Error message:
No response
Python and NumPy Versions:
2.0.0.dev0+git20240125.ac8b7ac
3.11.7 | packaged by conda-forge | (main, Dec 23 2023, 14:38:07) [Clang 16.0.6 ]
Runtime Environment:
[{'numpy_version': '2.0.0.dev0+git20240125.ac8b7ac',
'python': '3.11.7 | packaged by conda-forge | (main, Dec 23 2023, 14:38:07) '
'[Clang 16.0.6 ]',
'uname': uname_result(system='Darwin', node='Aarons-M3-MacBook-Pro.local', release='23.1.0', version='Darwin Kernel Version 23.1.0: Mon Oct 9 21:33:00 PDT 2023; root:xnu-10002.41.9~7/RELEASE_ARM64_T6031', machine='arm64')},
{'simd_extensions': {'baseline': ['NEON', 'NEON_FP16', 'NEON_VFPV4', 'ASIMD'],
'found': ['ASIMDHP'],
'not_found': ['ASIMDFHM']}}]
Context for the issue:
I'm not sure how important empty matrices really are for linalg functions like cholesky, but this is causing the array-api-tests to hang. data-apis/array-api-tests#101