Brownian diffuser
Project description
brownian-diffuser
Forward integrate torch neural networks
Similar to torchsde.sdeint or torchdiffeq.odeint but for vanilla neural networks as implemented by TorchNets
Example usage
BrownianDiffuser
from brownian_diffuser import BrownianDiffuser
diffuser = BrownianDiffuser()
from torch_nets import TorchNet
import torch
net = TorchNet(50, 50, [400, 400])
X0 = torch.randn([200, 50])
t = torch.Tensor([2, 4, 6])
X_pred = diffuser(net, X0, t, n_steps=40, stdev=0.5, max_steps=None, return_all=False)
X_pred.shape
torch.Size([3, 200, 50])
BrownianMotion
from brownian_diffuser import BrownianMotion
X_state = torch.randn([400, 50])
BM = BrownianMotion(X_state, stdev=0.5, n_steps=40)
Z = BM()
Z.shape
torch.Size([40, 400, 50])
Installation
pip install brownian-diffuser
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 brownian-diffuser-0.0.2.tar.gz.
File metadata
- Download URL: brownian-diffuser-0.0.2.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f44716df58a6f5f1d2b26d99e17519b6fabae9e7d5b8b69ba719c100b22ac8f5
|
|
| MD5 |
970c883b92d46468666cba11cb81ace0
|
|
| BLAKE2b-256 |
59f59295a8c597293293047861223fb748da2b69c5f0b7d9268b497e3dbf04ac
|
File details
Details for the file brownian_diffuser-0.0.2-py3-none-any.whl.
File metadata
- Download URL: brownian_diffuser-0.0.2-py3-none-any.whl
- Upload date:
- Size: 7.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
db0b4b662a881ad67ff97b965daa92f3d6799064085679e10c126b97d8181de2
|
|
| MD5 |
f9ea0802b058e92a492b3830c9294b3b
|
|
| BLAKE2b-256 |
872defa47d6d663f718f002f730fbf5df12460ba453af1058b2f07a0bf705ef8
|