From bd2378fad1578e7d7722ad846458ad7a2bb43442 Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Wed, 24 Apr 2019 13:30:24 +0200 Subject: [PATCH] updates --- train.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/train.py b/train.py index ea1a6034ed..f4477cf899 100644 --- a/train.py +++ b/train.py @@ -102,10 +102,10 @@ def train( # Scheduler https://github.com/ultralytics/yolov3/issues/238 # lf = lambda x: 1 - x / epochs # linear ramp to zero - # lf = lambda x: 10 ** (hyp['lrf'] * x / epochs) # exp ramp to lr0 * hyp['lrf'] - lf = lambda x: 1 - 10 ** (hyp['lrf'] * (1 - x / epochs)) # inv exp ramp to lr0 * hyp['lrf'] + # lf = lambda x: 10 ** (hyp['lrf'] * x / epochs) # exp ramp + lf = lambda x: 1 - 10 ** (hyp['lrf'] * (1 - x / epochs)) # inverse exp ramp scheduler = optim.lr_scheduler.LambdaLR(optimizer, lr_lambda=lf, last_epoch=start_epoch - 1) - # scheduler = optim.lr_scheduler.MultiStepLR(optimizer, milestones=[218, 245], gamma=0.1, last_epoch=start_epoch - 1) + # scheduler = optim.lr_scheduler.MultiStepLR(optimizer, milestones=[218, 245], gamma=0.1, last_epoch=start_epoch-1) # # Plot lr schedule # y = []