Skip to main content

Atiny is a gradient based PyTorch optimizer. Atiny uses half of Adam's memory to achieve results that are not inferior to Adam.

Project description

Atiny Optimizer

Atiny is a gradient based PyTorch optimizer. Atiny uses half of Adam's memory to achieve results that are not inferior to Adam.

image image

思路说明

不使用二阶动量,而是使用一阶动量与当前梯度计算每个参数的更新补偿. 内置了一个学习率衰减器,自动为每组参数个性化的学习率衰减.(需要参数:ldr) 使用ArcSinh函数影响向量模长实现权重衰减

Demo程序

demo程序在test.py文件中,直接运行即可得到此页面中Atiny与Adam的对比图.(依赖visdom) demo中构建了一个神经网络用简陋的方式对一个包含动态随机参数的公式生成的周期性曲线进行预测.

Install

pip install Atiny

Use

from Atiny import Atiny
...
optimizer=Atiny(moduel.parameters(),lr=lr,ldr=ldr,weight_decay=weight_decay)

HomePage

https://github.com/PsycheHalo/Atiny/

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

atiny-0.0.3.tar.gz (10.4 kB view details)

Uploaded Source

Built Distribution

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

atiny-0.0.3-py3-none-any.whl (10.8 kB view details)

Uploaded Python 3

File details

Details for the file atiny-0.0.3.tar.gz.

File metadata

  • Download URL: atiny-0.0.3.tar.gz
  • Upload date:
  • Size: 10.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for atiny-0.0.3.tar.gz
Algorithm Hash digest
SHA256 758379cae33d90ea22286756e3e78461d4080ddf6028fb47b46cf2245311f172
MD5 e20f42eaca1511cbf561dc6121af7a66
BLAKE2b-256 260402e711c5570a5eb851018cf03b78bff774062a6bff3cbce35e3551e41341

See more details on using hashes here.

Provenance

The following attestation bundles were made for atiny-0.0.3.tar.gz:

Publisher: python-publish.yml on PsycheHalo/Atiny

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file atiny-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: atiny-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 10.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for atiny-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 5278bb1f947367699db4d6e3427c631aef41bed2ce932fd5941ef074f57542d5
MD5 3e20d260a6640539ef226ecd5693e3bb
BLAKE2b-256 3e39732fcb4169c314c136e57c2363071625433fb1beca90862ae82cfcbbd2b1

See more details on using hashes here.

Provenance

The following attestation bundles were made for atiny-0.0.3-py3-none-any.whl:

Publisher: python-publish.yml on PsycheHalo/Atiny

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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