nx_nn_train.nx
buildroot/runtime/nx_nn_train.nx
about
nx_nn_train.nx -- sovereign FIXED-POINT TRAINING (batch gradient descent), the final piece of the neural-audio
moonshot machinery. Together with nx_nn (the forward pass) this makes a net LEARNABLE entirely in integer arithmetic:
no FPU, no GPU, no third-party autograd -- so a learned PLC / RVQ-codebook predictor can be trained sovereignly on
affordable hardware. MSE loss, analytic gradient of a linear layer (dL/dW = (pred - target) . input), Q-scale step.
lr_shift sets the learning rate (bigger = smaller, more stable steps). Composes the same matmul as nx_nn. license_tier: ORIGINAL
dependencies 0 imports · 1 importers
imports: none
imported by: nx_nn_train_gate.nx
structs
| none |
consts
| none |
functions
| 12 | func nnt_step(X: *i64, Y: *i64, T: i64, W: *i64, I: i64, O: i64, Qshift: i64, update_shift: i64, grad: *i64, pred: *i64) -> i64 called by 1: main |
| 39 | func nnt_loss(X: *i64, Y: *i64, T: i64, W: *i64, I: i64, O: i64, Qshift: i64) -> i64 called by 1: main |