summaryrefslogtreecommitdiff
path: root/numpy/array_api/_set_functions.py
diff options
context:
space:
mode:
authorDeveloper-Ecosystem-Engineering <65677710+Developer-Ecosystem-Engineering@users.noreply.github.com>2021-09-27 10:37:07 -0700
committerDeveloper-Ecosystem-Engineering <65677710+Developer-Ecosystem-Engineering@users.noreply.github.com>2021-09-27 10:37:07 -0700
commit9f91642c5ad8e5f9fc52df3f15cc9bba5722a5bf (patch)
treeb40d06b643a084b844aee22c001ff178df215942 /numpy/array_api/_set_functions.py
parenta136dba9d52d77691380d3b5385e090e5b7d7e6b (diff)
downloadnumpy-9f91642c5ad8e5f9fc52df3f15cc9bba5722a5bf.tar.gz
BUG: np.tan(np.inf) test failure
Numpy has a test failure where `np.tan(np.inf)` is not raising "invalid". The bug is due to an underlying bug in Apple's Libm. The bug is only present on arm64 and does not affect x86_64. The changes here apply to sin, cos, and tan. If the input is a non-finite value, then return `(x - x)`, which will raise "invalid" for `x=INFINITY` as well as return `NAN` for both `INFINITY` and `NAN` as input. Testing: (Note, the testing below is on top of another branch that fixes divide-by-zero failures in reciprocal) Before change: ``` FAILED numpy/core/tests/test_umath.py::TestSpecialFloats::test_tan - AssertionError: FloatingPointError not raised by tan 1 failed, 15589 passed, 302 skipped, 1268 deselected, 31 xfailed, 3 xpassed in 70.99s (0:01:10) ``` After change: ``` 15590 passed, 302 skipped, 1268 deselected, 31 xfailed, 3 xpassed in 71.38s (0:01:11) ```
Diffstat (limited to 'numpy/array_api/_set_functions.py')
0 files changed, 0 insertions, 0 deletions