Skip to main content

An adaptation of pytorch OneCycleLR that doesn't crash when max steps is reached

Project description

OneLongCycleLR

This is a simple adaptation from the OneCycleLR of pytorch.optim package. The default behaviour is to raise a ValueError when the maximum number of steps is reached. This one instead just keeps on returning the last value.

To install it, just use:

pip install onelongcyclelr

And to use it you need to import it like

from onelongcyclelr import OneLongCycleLR

The arguments and keywords needed are exactly the same as the official implementation.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

onelongcyclelr-0.1.2.tar.gz (2.3 kB view hashes)

Uploaded Source

Built Distribution

onelongcyclelr-0.1.2-py3-none-any.whl (3.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page