Module prelude

Source
Expand description

Structs and macros used by most projects. Add use burn::prelude::* to your code to quickly get started with Burn.

Re-exports§

pub use crate::nn;

Macros§

s
Slice argument constructor for tensor indexing.

Structs§

Bool
A type-level representation of the kind of a bool tensor.
Float
A type-level representation of the kind of a float tensor
Int
A type-level representation of the kind of a int tensor.
Shape
Shape of a tensor.
Tensor
A tensor with a given backend, shape and data type.
TensorData
Data structure for tensors.

Traits§

Backend
This trait defines all types and functions needed for a backend to be used with burn.
Config
Configuration trait.
DeviceOps
Device trait for all cubecl devices.
ElementConversion
Element conversion trait for tensor.
Module
Trait for all neural network modules.
SliceArg
Trait for slice arguments that can be converted into an array of slices. This allows the slice method to accept both single slices (from s![..]) and arrays of slices (from s![.., ..] or [0..5, 1..3]).
ToElement
A generic trait for converting a value to a number. Adapted from num_traits::ToPrimitive to support bool.

Type Aliases§

Device
Device type used by the backend.

Derive Macros§

Config
Derive macro for the config.
Module
Derive macro for the module.