Skip to content

Commit 39a38f3

Browse files
committed
style: fix D401
1 parent b7ddc4a commit 39a38f3

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

pytorch_optimizer/optimizer/utils.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,14 @@
1313

1414

1515
def debias_beta(beta: float, step: int) -> float:
16-
r"""Applies the Adam-style debias correction into beta.
16+
r"""Apply the Adam-style debias correction into beta.
1717
1818
Simplified version of `\^{beta} = beta * (1.0 - beta ** (step - 1)) / (1.0 - beta ** step)`
19+
20+
:param beta: float. beta.
21+
:param step: int. number of step.
1922
"""
20-
return (beta**step - beta) / (beta**step - 1.0)
23+
return (beta ** step - beta) / (beta ** step - 1.0) # fmt: skip
2124

2225

2326
def is_valid_parameters(parameters: PARAMETERS) -> bool:

0 commit comments

Comments
 (0)