Skip to main content

nammy

A proof-of-concept trainer for Neural Amp Modeler's classic A1 WaveNet architecture, implemented with tinygrad instead of PyTorch.

What's implemented

  • The standard A1 WaveNet: two layer arrays (16 and 8 channels), dilations 1–512, kernel size 3, Tanh, residual 1x1s, per-array head rechannel, head_scale = 0.02, receptive field 4093 — a faithful port of nam.models.wavenet.
  • NAM-style data pipeline: WAV loading (PCM 16/24/32 and IEEE float), latency compensation, and (nx+ny-1, ny) window slicing matching nam.data.Dataset.
  • Training matching NAM's standard learning config: Adam(lr=0.004), per-epoch exponential LR decay (gamma 0.993), MSE loss, ESR validation with best-checkpoint restore, JIT-compiled train step.
  • Export to .nam (classic v0.5.4 schema) loadable by the NAM plugin.

Not implemented (yet): A2/packed training, gated/FiLM variants, MRSTFT loss, pre-emphasis, output loudness normalization, the standardized input-file splits/checks.

Usage

Train from an input/output pair:

$ uv run python -m nammy train input.wav output.wav --epochs 100 --out model.nam

input.wav is the DI/reamp source, output.wav the processed capture; both must share a sample rate and be time-aligned (use --latency <samples> to compensate reamp latency).

Run audio through a trained model (reamp):

$ uv run python -m nammy process model.nam input.wav output.wav

This also loads classic-schema (non-gated Tanh WaveNet) .nam files trained elsewhere.

Notes

  • Runs on tinygrad's default device. Without a GPU and without clang installed, it falls back to the libLLVM CPU renderer automatically.
  • Validation: uv run tests/test_poc.py checks receptive field, forward parity against an independent numpy implementation, .nam export round-trip, dataset alignment, and a training smoke test.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nammy-0.1.0.tar.gz (13.4 kB view details)

Uploaded Source

Built Distribution

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

nammy-0.1.0-py3-none-any.whl (10.4 kB view details)

Uploaded Python 3

File details

Details for the file nammy-0.1.0.tar.gz.

File metadata

  • Download URL: nammy-0.1.0.tar.gz
  • Upload date:
  • Size: 13.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.18 {"installer":{"name":"uv","version":"0.11.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":null,"id":"forky","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for nammy-0.1.0.tar.gz
Algorithm Hash digest
SHA256 4c195b43125ca4ce443625ee6af75511181db329dfc04c93021a17caa2ef808b
MD5 5b5c639f984a3b0b73aec4d9db78d37b
BLAKE2b-256 1c7d46ca8748399b24050bdeae9e23bd6ccabd3833879da87524c3a15f57e0c1

See more details on using hashes here.

File details

Details for the file nammy-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: nammy-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 10.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.18 {"installer":{"name":"uv","version":"0.11.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":null,"id":"forky","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for nammy-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3a9a71bdf164ad510929f1313bcc16a9525ded4b83370f2035a82a0bd0e1040c
MD5 3df7907618348510009c91bb4b5fcd9c
BLAKE2b-256 89ece58803580015c2e6abb0b9d18a86ee8bc1440ac5ab367c72fd58aa74fcbd

See more details on using hashes here.

Release history Release notifications | RSS feed

0.3.0

2 files

This release

0.1.0 This release

2 files

Supported by

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