Skip to content

Commit 5cc7e3e

Browse files
clean up imports
1 parent a73091e commit 5cc7e3e

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

tests/link/mlx/test_math.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
import mlx.core as mx
12
import numpy as np
23
import pytest
34

45
import pytensor
56
import pytensor.tensor as pt
67
from pytensor.tensor.math import Argmax, Max
7-
from tests.link.mlx.test_basic import compare_mlx_and_py, mx
8+
from tests.link.mlx.test_basic import compare_mlx_and_py
89

910

1011
def test_dot():
@@ -92,7 +93,6 @@ def test_elemwise_two_inputs(op) -> None:
9293

9394

9495
def test_int_div_specific() -> None:
95-
"""Test integer division with specific test cases"""
9696
x = pt.vector("x")
9797
y = pt.vector("y")
9898
out = pt.int_div(x, y)
@@ -105,18 +105,15 @@ def test_int_div_specific() -> None:
105105

106106

107107
def test_isnan() -> None:
108-
"""Test IsNan operation with various inputs including NaN values"""
109108
x = pt.vector("x")
110109
out = pt.isnan(x)
111110

112-
# Test with mix of normal values, NaN, and infinity
113111
x_test = mx.array([1.0, np.nan, 3.0, np.inf, -np.nan, 0.0, -np.inf])
114112

115113
compare_mlx_and_py([x], out, [x_test])
116114

117115

118116
def test_isnan_edge_cases() -> None:
119-
"""Test IsNan with edge cases"""
120117
x = pt.scalar("x")
121118
out = pt.isnan(x)
122119

0 commit comments

Comments
 (0)