mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-08-29 10:16:07 +00:00
add test for Tensor silu and swish (#8381)
was only tested in onnx, added to test_ops for completeness
This commit is contained in:
@@ -765,6 +765,12 @@ class TestOps(unittest.TestCase):
|
||||
def test_selu(self):
|
||||
helper_test_op([(45,65)], torch.nn.functional.selu, Tensor.selu)
|
||||
helper_test_op([()], torch.nn.functional.selu, Tensor.selu)
|
||||
def test_silu(self):
|
||||
helper_test_op([(45,65)], torch.nn.functional.silu, Tensor.silu)
|
||||
helper_test_op([()], torch.nn.functional.silu, Tensor.silu)
|
||||
def test_swish(self):
|
||||
helper_test_op([(45,65)], torch.nn.functional.silu, Tensor.swish)
|
||||
helper_test_op([()], torch.nn.functional.silu, Tensor.swish)
|
||||
|
||||
def test_abs(self):
|
||||
helper_test_op([(45,65)], torch.abs, Tensor.abs)
|
||||
|
||||
Reference in New Issue
Block a user