From 58b1dd463e384abb7cb5868a72d3381b5eabd125 Mon Sep 17 00:00:00 2001 From: Paul Gustafson Date: Sun, 26 Nov 2023 13:04:10 -0800 Subject: [PATCH] Add error code to type: ignore (#2451) Co-authored-by: Paul Gustafson --- tinygrad/tensor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tinygrad/tensor.py b/tinygrad/tensor.py index 749240cfa6..40ad59765b 100644 --- a/tinygrad/tensor.py +++ b/tinygrad/tensor.py @@ -750,8 +750,8 @@ class Tensor: def __gt__(self, x) -> Tensor: return mlops.Less.apply(*self._broadcasted(x, True)) def __ge__(self, x) -> Tensor: return 1.0-(self Tensor: return 1.0-(self>x) - def __ne__(self, x) -> Tensor: return (selfx) # type: ignore - def __eq__(self, x) -> Tensor: return 1.0-(self != x) # type: ignore + def __ne__(self, x) -> Tensor: return (selfx) # type: ignore[override] + def __eq__(self, x) -> Tensor: return 1.0-(self != x) # type: ignore[override] # ***** functional nn ops *****