Build with this node

Start with a prompt in Studio, or copy it into your own coding agent.

Ask Studio

@maruaudio/dsp/neural/nam-a2 runs a standard Neural Amp Modeler A2 model: the causal WaveNet of 23 dilated convolution layers, residual matrices and a 16-tap head, in Lite (3 channels) or Full (8 channels) width. It consumes the model's original float32 weight stream in NeuralAmpModelerCore's order, including the learned trailing head scale, and computes one mono sample per namA2Tick with scalar float32 storage and LeakyReLU (slope 0.01). It bundles no trained weights; model parsing, selection and packing live in @maruaudio/nam-runtime. It re-exports @maru/processors-nam-a2-spec.

Lifecycle

initNamA2(channels, weights) allocates, throws on a wrong channel count, weight count or a non-finite weight, prewarms with zeros to reject non-finite output when any weight is nonzero, and returns cold histories. Before activation, prewarmNamA2 (throws) or tryPrewarmNamA2 (boolean) feeds the 6,347-sample receptive field; tryPrepareNamA2FreshZero reaches the same state for a fresh candidate with bounded transients and 25 ordinary ticks. namA2Tick processes; resetNamA2 clears histories without reallocating or prewarming; copyNamA2History restores an admitted history into matching preallocated state without touching weights.

When to use it

Playing a captured amp or pedal model whose file uses the standard A2 topology, inside a Processor that prepares and validates the model off the audio thread and swaps it in only after it passes.

Limits

  • Mono, one sample per tick, at the model's sample rate: no resampling. Input should be finite audio; the prewarm check does not bound every input.
  • Weight counts are 1,871 (Lite) and 12,146 (Full); other widths are refused.
  • Fresh-zero admission uses absolute bounds that discard cancellation, so it may refuse usable models; a refused candidate must not replace the active one. The tests establish no browser playback or realtime deadline.

Algorithm properties and proofs

No Lean 4 proof is mapped to this node.

Explore proofs alongside performance

Ports

  • In ininput · audio · mono
  • Out outoutput · audio · mono

One sample per namA2Tick call.

Dependencies

Dependents

No other node imports this one.

Used by