A physics-inspired optimizer adding decaying oscillations to gradient descent
Project description
Bouncing Decayer Optimizer
A physics-inspired optimizer for PyTorch — adding decaying oscillations like a bouncing ball.
Gradient descent is great — but it can get stuck or converge too fast.
This optimizer adds a decaying sinusoidal perturbation:
- Early → big "bounces" help explore.
- Later → oscillations fade, optimizer settles.
🧰 Usage SOON (Pypi verification pending)
from bouncing_decayer_optimizer import BouncingDecayerOptimizer
import torch
model = torch.nn.Linear(10, 1)
optimizer = BouncingDecayerOptimizer(model.parameters(), lr=0.01)
for epoch in range(100):
optimizer.zero_grad()
inputs = torch.randn(32, 10)
targets = torch.randn(32, 1)
outputs = model(inputs)
loss = torch.nn.functional.mse_loss(outputs, targets)
loss.backward()
optimizer.step()
print(f"Epoch {epoch}, Loss: {loss.item()}")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file bouncing_decayer_optimizer-0.1.0.tar.gz.
File metadata
- Download URL: bouncing_decayer_optimizer-0.1.0.tar.gz
- Upload date:
- Size: 3.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a521287236cc19a7f8d2cffabbbcbf8333c071c59e07cba3bad7d4138596eb60
|
|
| MD5 |
41c6195709a322c3de00af3cea9ac35d
|
|
| BLAKE2b-256 |
5500271b48b61853c3562d38b628eb058b161b29cc2bf95ba0260bea7cf71213
|
Provenance
The following attestation bundles were made for bouncing_decayer_optimizer-0.1.0.tar.gz:
Publisher:
publish-to-pypi.yml on sandy1279/bouncing_decayer_optimizer
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
bouncing_decayer_optimizer-0.1.0.tar.gz -
Subject digest:
a521287236cc19a7f8d2cffabbbcbf8333c071c59e07cba3bad7d4138596eb60 - Sigstore transparency entry: 329603978
- Sigstore integration time:
-
Permalink:
sandy1279/bouncing_decayer_optimizer@1f14ffed9d28225bfb0769d1c42095e762aec269 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/sandy1279
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@1f14ffed9d28225bfb0769d1c42095e762aec269 -
Trigger Event:
push
-
Statement type:
File details
Details for the file bouncing_decayer_optimizer-0.1.0-py3-none-any.whl.
File metadata
- Download URL: bouncing_decayer_optimizer-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
15c9eeeb748da5b229a6379c9f27c3d7b2aef7fcb5893bc18d8b01dfbba0fadd
|
|
| MD5 |
b46d8dbcfa9a9bc53729d2dadf43f24c
|
|
| BLAKE2b-256 |
98feddddc17d9b34c1bcf080ef5c4deacccfdea8f7af6b2a69f4199ecd08bba2
|
Provenance
The following attestation bundles were made for bouncing_decayer_optimizer-0.1.0-py3-none-any.whl:
Publisher:
publish-to-pypi.yml on sandy1279/bouncing_decayer_optimizer
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
bouncing_decayer_optimizer-0.1.0-py3-none-any.whl -
Subject digest:
15c9eeeb748da5b229a6379c9f27c3d7b2aef7fcb5893bc18d8b01dfbba0fadd - Sigstore transparency entry: 329603997
- Sigstore integration time:
-
Permalink:
sandy1279/bouncing_decayer_optimizer@1f14ffed9d28225bfb0769d1c42095e762aec269 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/sandy1279
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@1f14ffed9d28225bfb0769d1c42095e762aec269 -
Trigger Event:
push
-
Statement type: