Skip to content

Commit ae0132f

Browse files
committed
Int32 is too small for geomspace test
1 parent 6cd90ee commit ae0132f

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/tensor/test_extra_ops.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1301,7 +1301,9 @@ def test_broadcast_arrays():
13011301
["linspace", "logspace", "geomspace"],
13021302
ids=["linspace", "logspace", "geomspace"],
13031303
)
1304-
@pytest.mark.parametrize("dtype", [None, "int", "float"], ids=[None, "int", "float"])
1304+
@pytest.mark.parametrize(
1305+
"dtype", [None, "int64", "floatX"], ids=[None, "int64", "floatX"]
1306+
)
13051307
@pytest.mark.parametrize(
13061308
"start, stop, num_samples, endpoint, axis",
13071309
[
@@ -1317,7 +1319,7 @@ def test_broadcast_arrays():
13171319
def test_space_ops(op, dtype, start, stop, num_samples, endpoint, axis):
13181320
pt_func = getattr(pt, op)
13191321
np_func = getattr(np, op)
1320-
dtype = dtype + config.floatX[-2:] if dtype is not None else dtype
1322+
dtype = dtype if dtype != "floatX" else config.floatX
13211323
z = pt_func(start, stop, num_samples, endpoint=endpoint, axis=axis, dtype=dtype)
13221324

13231325
numpy_res = np_func(

0 commit comments

Comments
 (0)