File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 1
1
import math
2
2
import dpnp
3
3
import numpy
4
+ from .helper import skip_or_change_if_dtype_not_supported
5
+
6
+
7
+ dtype = skip_or_change_if_dtype_not_supported (numpy .float64 , change_dtype = True )
4
8
5
9
6
10
def test_erf ():
7
- a = numpy .linspace (2.0 , 3.0 , num = 10 )
8
- ia = dpnp .linspace (2.0 , 3.0 , num = 10 )
11
+ a = numpy .linspace (2.0 , 3.0 , num = 10 , dtype = dtype )
12
+ ia = dpnp .linspace (2.0 , 3.0 , num = 10 , dtype = dtype )
9
13
10
14
numpy .testing .assert_array_equal (a , ia )
11
15
@@ -19,8 +23,8 @@ def test_erf():
19
23
20
24
21
25
def test_erf_fallback ():
22
- a = numpy .linspace (2.0 , 3.0 , num = 10 )
23
- dpa = dpnp .linspace (2.0 , 3.0 , num = 10 )
26
+ a = numpy .linspace (2.0 , 3.0 , num = 10 , dtype = dtype )
27
+ dpa = dpnp .linspace (2.0 , 3.0 , num = 10 , dtype = dtype )
24
28
25
29
expected = numpy .empty_like (a )
26
30
for idx , val in enumerate (a ):
You can’t perform that action at this time.
0 commit comments