Skip to content

Commit

Permalink
[Lint] run pre-commit on PR #124
Browse files Browse the repository at this point in the history
  • Loading branch information
maltanar committed Dec 16, 2024
1 parent 157d808 commit ab67851
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/qonnx/transformation/general.py
Original file line number Diff line number Diff line change
Expand Up @@ -342,11 +342,11 @@ def apply(self, model):
# set specified defaults
default_values = []
for key, value in model_config["Defaults"].items():
assert (len(value) % 2 == 0)
assert len(value) % 2 == 0
if key not in model_config:
for val, op in zip(value[::2], value[1::2]):
default_values.append((key, val, op))
assert (not (op == "all" and len(value) > 2))
default_values.append((key, val, op))
assert not (op == "all" and len(value) > 2)
default_configs = {key: val for key, val, op in default_values if op == "all" or node.op_type in op}
for attr, value in default_configs.items():
inst.set_nodeattr(attr, value)
Expand Down

0 comments on commit ab67851

Please sign in to comment.