Skip to content

Commit cacdbdf

Browse files
committed
MAINT: improve comments, xfail messages
1 parent 4429b2f commit cacdbdf

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

torch_np/_dtypes_impl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ def nep50_to_tensors(x1, x2):
8787
"""If either of inputs is a python scalar, type-promote with NEP 50.
8888
8989
NB: NEP 50 mandates RuntimeWarnings on some overflows. We do not emit them:
90-
we either raise OverflowError or just do the computation.
90+
we either raise an OverflowError or silently do the computation.
9191
"""
9292

9393
x1_type, x2_type = type(x1), type(x2)

torch_np/tests/numpy_tests/core/test_scalarmath.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -495,7 +495,7 @@ def test_numpy_scalar_relational_operators(self):
495495
assert_(np.array(-1, dtype=dt1)[()] == np.array(-1, dtype=dt2)[()],
496496
"type %s and %s failed" % (dt1, dt2))
497497

498-
@pytest.mark.xfail(reason="pytorch unsigned wraps around")
498+
@pytest.mark.xfail(reason="NEP50")
499499
def test_numpy_scalar_relational_operators_2(self):
500500
#Unsigned integers
501501
for dt1 in 'B':

0 commit comments

Comments
 (0)