8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 44d14ab commit 6f34f5fCopy full SHA for 6f34f5f
numpy/core/tests/test_umath.py
@@ -710,7 +710,12 @@ def test_log_float32(self):
710
711
def test_sincos_float32(self):
712
np.random.seed(42)
713
- x_f32 = np.float32(np.random.uniform(low=-100.,high=100.,size=1000000))
+ N = 1000000
714
+ M = np.int(N/20)
715
+ index = np.random.randint(low=0, high=N, size=M)
716
+ x_f32 = np.float32(np.random.uniform(low=-100.,high=100.,size=N))
717
+ # test coverage for elements > 117435.992f for which glibc is used
718
+ x_f32[index] = np.float32(10E+10*np.random.rand(M))
719
x_f64 = np.float64(x_f32)
720
assert_array_max_ulp(np.sin(x_f32), np.float32(np.sin(x_f64)), maxulp=2)
721
assert_array_max_ulp(np.cos(x_f32), np.float32(np.cos(x_f64)), maxulp=2)
0 commit comments