Skip to content

Commit 030f1be

Browse files
committed
ruff
1 parent 6ad12ec commit 030f1be

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

TPTBox/registration/deepali/_hooks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ def fn(_: "DeepaliPairwiseImageTrainer", num_steps: int, num_eval: int, result:
8888
if isinstance(weight, (list, tuple)):
8989
weight = weight[level]
9090
if not isinstance(weight, str):
91-
value *= weight
91+
value *= weight # type: ignore # noqa: PLW2901
9292
elif "+" in weight:
9393
weight = f"({weight})"
9494
message += f", {value:>12.05f} [{weight} * {name}]"
@@ -120,7 +120,7 @@ def fn(_: "DeepaliPairwiseImageTrainer", num_steps: int, num_eval: int, result:
120120
weight = weight[level]
121121

122122
if not isinstance(weight, str):
123-
value *= weight
123+
value *= weight # type: ignore # noqa: PLW2901
124124
elif "+" in weight:
125125
weight = f"({weight})"
126126
message += f", {value:>5.05f}[{weight}*{name}]"

0 commit comments

Comments
 (0)