Skip to main content

Implementation of stabilized Barzilai-Borwein Method for gradient descent problems

Project description

Stabilized Barzilai-Borwein method

Implements gradient descent using Stabilized Barzilai-Borwein method.

It's based on the following paper: Burdakov, Oleg & Dai, Yu-Hong & Huang, Na. (2019). Stabilized Barzilai-Borwein.

The Barzilai-Borwein (BB) method is a popular and efficient tool for solving large-scale unconstrained optimization problems. Its search direction is the same as for the steepest descent (Cauchy) method, but its stepsize rule is different. Owing to this, it converges much faster than the Cauchy method. A feature of the BB method is that it may generate too long steps, which throw the iterates too far away from the solution. Moreover, it may not converge, even when the objective function is strongly convex.

In this library, the stabilization technique proposed in the paper is implemented. It consists in bounding the distance between each pair of successive iterates, which often allows for decreasing the number of BB iterations. When the BB method does not converge, this method makes it convergent. Under suitable assumptions, the method converges globally, despite the fact that no line search is involved, and only gradient values are used. Since the number of stabilization steps is finite, the stabilized version inherits the fast local convergence of the BB method. This technique often allows the BB method to solve problems in a fewer iterations, or even to solve problems where the latter fails.

Usage

This simple examples shows its most basic use.

>> from scipy.optimize import rosen, rosen_der
>> from stabbb import stab_BB
>> x0 = [1.3, 0.7, 0.8, 1.9, 1.2]
>> bestX, _ = stab_BB(x0, rosen, rosen_der)
>> bestX
array([ 1.,  1.,  1.,  1.,  1.])

Please refer to the docstring for a longer explanation.

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

stabbb-0.0.0.1.tar.gz (13.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

stabbb-0.0.0.1-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file stabbb-0.0.0.1.tar.gz.

File metadata

  • Download URL: stabbb-0.0.0.1.tar.gz
  • Upload date:
  • Size: 13.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.4

File hashes

Hashes for stabbb-0.0.0.1.tar.gz
Algorithm Hash digest
SHA256 8a5ccfb952a46fefb94fd6bff8370cafb53fb168a8aadb9033102a93170458d3
MD5 4e00092f82909ea60983058be6106861
BLAKE2b-256 65a03949dc1029d6e3bee9e5493ad5beec54b4b009ef62ab8f72fce24ea73dd7

See more details on using hashes here.

File details

Details for the file stabbb-0.0.0.1-py3-none-any.whl.

File metadata

  • Download URL: stabbb-0.0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 6.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.4

File hashes

Hashes for stabbb-0.0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f62e90f17d2fd6d6df1e0c99b51319216219def776484d8c1c699479f9340260
MD5 d33f66668bda752fa5717de4b05db23b
BLAKE2b-256 fe3a9882c74c2373fcd6016ba56dd26504bdfec3e77c365ed7484d86539e253d

See more details on using hashes here.

Supported by

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