Skip to content

Commit

Permalink
Update deepmd/utils/learning_rate.py
Browse files Browse the repository at this point in the history
Signed-off-by: Jinzhe Zeng <[email protected]>
  • Loading branch information
njzjz authored Oct 15, 2024
1 parent 367d33e commit 90c6f9a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion deepmd/utils/learning_rate.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(
self.decay_rate = decay_rate
self.min_lr = stop_lr

def value(self, step) -> np.ndarray:
def value(self, step) -> np.float64:
"""Get the learning rate at the given step."""
step_lr = self.start_lr * np.power(self.decay_rate, step // self.decay_steps)
if step_lr < self.min_lr:
Expand Down

0 comments on commit 90c6f9a

Please sign in to comment.