Skip to content

Commit 2f95492

Browse files
authored
Update test_rand_deform_grid.py
1 parent f4b6da4 commit 2f95492

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

tests/test_rand_deform_grid.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,8 @@ def test_rand_deform_grid(self, input_param, input_data, expected_val):
129129
g = RandDeformGrid(**input_param)
130130
g.set_random_state(123)
131131
result = g(**input_data)
132-
self.assertEqual(isinstance(result, torch.Tensor), isinstance(expected_val, torch.Tensor))
133132
if isinstance(result, torch.Tensor):
134-
np.testing.assert_allclose(result.cpu().numpy(), expected_val.cpu().numpy(), rtol=1e-4, atol=1e-4)
133+
np.testing.assert_allclose(result.cpu().numpy(), expected_val, rtol=1e-4, atol=1e-4)
135134
else:
136135
np.testing.assert_allclose(result, expected_val, rtol=1e-4, atol=1e-4)
137136

0 commit comments

Comments
 (0)