Enable ruff E741 rule (#11370)

* Enable ruff E741 rule

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Maxim Smolskiy
2024-04-19 22:30:22 +03:00
committed by GitHub
parent 0a9a860eb1
commit a42eb35702
14 changed files with 102 additions and 92 deletions

View File

@ -309,9 +309,9 @@ class SmoSVM:
# calculate L and H which bound the new alpha2
s = y1 * y2
if s == -1:
l, h = max(0.0, a2 - a1), min(self._c, self._c + a2 - a1)
l, h = max(0.0, a2 - a1), min(self._c, self._c + a2 - a1) # noqa: E741
else:
l, h = max(0.0, a2 + a1 - self._c), min(self._c, a2 + a1)
l, h = max(0.0, a2 + a1 - self._c), min(self._c, a2 + a1) # noqa: E741
if l == h:
return None, None