burn-nn 0.22.0

Neural network building blocks for the Burn deep learning framework
docs.rs failed to build burn-nn-0.22.0
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build: burn-nn-0.22.0-pre.4

Burn Neural Networks

Neural network layers, activations and losses for Burn

Current Crates.io Version Documentation license

Every layer is a module built from a config, and applications use them through burn::nn:

use burn::nn::{Linear, LinearConfig};

let linear: Linear = LinearConfig::new(784, 128).init(&device);
let output = linear.forward(input);
  • Layers: linear, convolution and transposed convolution (1D to 3D), pooling, normalization (batch, layer, group, instance, RMS), embeddings, dropout, recurrent layers (LSTM, GRU), attention and transformers, positional and rotary encodings, interpolation, and more.
  • activation: activation functions as modules.
  • loss: loss functions, from mean squared error and cross-entropy to CTC.
  • Initializer: weight initialization schemes.

See the module chapter of the Burn Book.

Feature Flags

  • std (default): standard library support. Without it the crate is no_std with alloc.
  • tracing: instrument operations with the tracing crate.

Part of the Burn deep learning framework. See the Burn Book and the API documentation.