mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Revert "Enable ruff rule E721 (#165162)"
This reverts commit 9e7c19f72b6d0690915c307409c0c0a76b5a3bf0. Reverted https://github.com/pytorch/pytorch/pull/165162 on behalf of https://github.com/pytorch-auto-revert due to Reverted automatically by pytorch's autorevert, to avoid this behaviour add the tag autorevert: disable ([comment](https://github.com/pytorch/pytorch/pull/165162#issuecomment-3393328271))
This commit is contained in:
@ -3327,7 +3327,7 @@ class TestReductions(TestCase):
|
||||
"""
|
||||
def _test_histogramdd_numpy(self, t, bins, bin_range, weights, density):
|
||||
def to_np(t):
|
||||
if type(t) is list:
|
||||
if type(t) == list:
|
||||
return list(map(to_np, t))
|
||||
if not torch.is_tensor(t):
|
||||
return t
|
||||
|
Reference in New Issue
Block a user