google / automl

Google Brain AutoML
Apache License 2.0
6.25k stars 1.45k forks source link

How to set up cosine learning rate to decrease to 0 at the end of training. #1122

Open lejekjr opened 2 years ago

lejekjr commented 2 years ago

Version automl/efficientdet/keras/ tag: 1.2

I have two trainings one after another. First training: image

config.yaml contains: image

Second training starts from first training pretrained_ckpt. image

config.yaml contains: image

epoch_learning_rate tensorboard plot: image

I didn't specify lr_decay_method in both trainigns so it was 'cosine' by default.

Question:

How to setup 'cosine' learning rate schedule so that training would start with the learning_rate value at the top of cosine wave and deacrease to 0 at the end of training? In the same way as learning_rate: { cosine_decay_learning_rate { learning_rate_base: 0.005 total_steps: 115200 warmup_learning_rate: 0.0 warmup_steps: 5000 } }

from TensorFlow Object Detection API does. image