aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.pre-commit-config.yaml8
-rwxr-xr-xverif/frameworks/tosa_verif_framework_generator.py2
-rw-r--r--verif/generator/tosa_test_gen.py8
3 files changed, 9 insertions, 9 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 4a73a48..1658ca9 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -5,16 +5,16 @@
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/asottile/reorder_python_imports
- rev: v2.2.0
+ rev: v3.0.1
hooks:
- id: reorder-python-imports
- repo: https://github.com/psf/black
- rev: 20.8b1
+ rev: 22.3.0
hooks:
- id: black
-- repo: https://gitlab.com/pycqa/flake8
- rev: 3.7.9
+- repo: https://github.com/pycqa/flake8
+ rev: 4.0.1
hooks:
- id: flake8
diff --git a/verif/frameworks/tosa_verif_framework_generator.py b/verif/frameworks/tosa_verif_framework_generator.py
index 222376e..8457d92 100755
--- a/verif/frameworks/tosa_verif_framework_generator.py
+++ b/verif/frameworks/tosa_verif_framework_generator.py
@@ -23,7 +23,7 @@ from frameworks.write_test_json import write_test_json # noqa: E402
from frameworks.arg_gen import ArgGen # noqa: E402
from frameworks.tensor_gen import TGen # noqa: E402
from frameworks.test_builder import TBuilder # noqa: E402
-from frameworks.test_gen_utils import (
+from frameworks.test_gen_utils import ( # noqa: E402
QuantType,
get_tf_dtype,
get_shape_str,
diff --git a/verif/generator/tosa_test_gen.py b/verif/generator/tosa_test_gen.py
index b1f9938..64f0c5e 100644
--- a/verif/generator/tosa_test_gen.py
+++ b/verif/generator/tosa_test_gen.py
@@ -3702,7 +3702,7 @@ class TosaTestGen:
raise Exception("Unknown dtype, cannot convert to string: {}".format(t))
def typeWidth(self, t):
- """ Get the datatype width for integer types"""
+ """Get the datatype width for integer types"""
if t == DType.INT4:
return 4
elif t == DType.INT8:
@@ -5921,7 +5921,7 @@ class TosaTestGen:
if (divisor_arr == 0).any():
continue
- if (dividend_arr == -(2 ** 31)).any() and (divisor_arr == -1).any():
+ if (dividend_arr == -(2**31)).any() and (divisor_arr == -1).any():
continue
break
@@ -5980,8 +5980,8 @@ class TosaTestGen:
else:
result_arr = a_arr_64 * b_arr_64
- if (result_arr > -(2 ** 31)).all() and (
- result_arr <= ((2 ** 31) - 1)
+ if (result_arr > -(2**31)).all() and (
+ result_arr <= ((2**31) - 1)
).all():
break