Skip to main content

BackPACK: Packing more into backprop

Project description

BackPACK BackPACK: Packing more into backprop

Travis Coveralls Python 3.6+

BackPACK is built on top of PyTorch. It efficiently computes quantities other than the gradient.

Provided quantities include:

  • Individual gradients from a mini-batch
  • Estimates of the gradient variance or second moment
  • Approximate second-order information (diagonal and Kronecker approximations)

Motivation: Computation of most quantities is not necessarily expensive (often just a small modification of the existing backward pass where backpropagated information can be reused). But it is difficult to do in the current software environment.

Installation

pip install backpack-for-pytorch

Examples

Contributing

BackPACK is actively being developed. We are appreciating any help. If you are considering to contribute, do not hesitate to contact us. An overview of the development procedure is provided in the developer README.

How to cite

If you are using BackPACK, consider citing the paper

@inproceedings{dangel2020backpack,
    title     = {Back{PACK}: Packing more into Backprop},
    author    = {Felix Dangel and Frederik Kunstner and Philipp Hennig},
    booktitle = {International Conference on Learning Representations},
    year      = {2020},
    url       = {https://openreview.net/forum?id=BJlrF24twB}
}
BackPACK is not endorsed by or affiliated with Facebook, Inc. PyTorch, the PyTorch logo and any related marks are trademarks of Facebook, Inc.

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

backpack-for-pytorch-1.3.0.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

backpack_for_pytorch-1.3.0-py3-none-any.whl (119.8 kB view details)

Uploaded Python 3

File details

Details for the file backpack-for-pytorch-1.3.0.tar.gz.

File metadata

  • Download URL: backpack-for-pytorch-1.3.0.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.23.0 requests-toolbelt/0.9.1 tqdm/4.57.0 CPython/3.7.6

File hashes

Hashes for backpack-for-pytorch-1.3.0.tar.gz
Algorithm Hash digest
SHA256 dca0542c4f2ae6d7e791b3b694812dbb833b4b5df4e1ee373a6374d147055080
MD5 5479b81d2676624b41f0580df34ef69d
BLAKE2b-256 02cea2a1c6cc9577551d3298d4d8972573eae3f4c46ade28360b804a4e4f943b

See more details on using hashes here.

File details

Details for the file backpack_for_pytorch-1.3.0-py3-none-any.whl.

File metadata

  • Download URL: backpack_for_pytorch-1.3.0-py3-none-any.whl
  • Upload date:
  • Size: 119.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.23.0 requests-toolbelt/0.9.1 tqdm/4.57.0 CPython/3.7.6

File hashes

Hashes for backpack_for_pytorch-1.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 22c7d6e55ee0ee5923e6cee727275f994c0db6827a5b4766046d730920ae7b95
MD5 b6c18d3932a34492c3a00b419d5520eb
BLAKE2b-256 9ca88287f09570a4829f506962dcb18962d3df4b2770c827ea12e912f139ecf8

See more details on using hashes here.

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