aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.pre-commit-config.yaml2
-rw-r--r--ethosu/vela/scheduler.py2
-rw-r--r--ethosu/vela/softmax.py4
-rw-r--r--ethosu/vela/tosa_reader.py2
4 files changed, 4 insertions, 6 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 17d38779..8e976b65 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -13,7 +13,7 @@ repos:
args: [--line-length=120]
- repo: https://gitlab.com/pycqa/flake8
- rev: 3.7.9
+ rev: 4.0.1
hooks:
- id: flake8
args: [--max-line-length=120, --extend-ignore=E203]
diff --git a/ethosu/vela/scheduler.py b/ethosu/vela/scheduler.py
index 6b084593..3ef0d7f2 100644
--- a/ethosu/vela/scheduler.py
+++ b/ethosu/vela/scheduler.py
@@ -1099,7 +1099,7 @@ class Scheduler:
)
print(f"\t\tSRAM Used: {mem_usage} bytes")
- print(f"\tCascades:")
+ print("\tCascades:")
for i, cascade in enumerate(schedule.cascades.values()):
print(f"\t\t{i}: {cascade.start} -> {cascade.end}, size: {cascade.mem_usage}")
diff --git a/ethosu/vela/softmax.py b/ethosu/vela/softmax.py
index 13ca319b..711c1e04 100644
--- a/ethosu/vela/softmax.py
+++ b/ethosu/vela/softmax.py
@@ -501,9 +501,7 @@ class SoftMax:
reciprocal_right_shift = add_op_get_ofm(create_sub(name, const_31, headroom_plus_one, no_scale_quant))
# PASS 7 - SHL
- one = create_const_tensor(
- f"one_const", [1, 1, 1, 1], DataType.int32, [1], np.int32, quantization=no_scale_quant
- )
+ one = create_const_tensor("one_const", [1, 1, 1, 1], DataType.int32, [1], np.int32, quantization=no_scale_quant)
constant_one = add_op_get_ofm(
create_shl(f"{self.op.name}_shl{pass_number}", one, reciprocal_right_shift, no_scale_quant)
)
diff --git a/ethosu/vela/tosa_reader.py b/ethosu/vela/tosa_reader.py
index aadcb0ad..2bec9cf1 100644
--- a/ethosu/vela/tosa_reader.py
+++ b/ethosu/vela/tosa_reader.py
@@ -253,7 +253,7 @@ class TosaSubgraph:
if tens.quantization.zero_point is None:
tens.quantization.zero_point = zp
elif tens.quantization.zero_point != zp:
- print(f"Error: Setting tensor zp not possible, tensor already has different zero point")
+ print("Error: Setting tensor zp not possible, tensor already has different zero point")
assert False