scivex-nn
Neural networks for Scivex. Autograd engine, layers, optimizers, and loss functions for building and training deep learning models.
Highlights
- Autograd — Automatic differentiation with dynamic computation graph
- Layers — Linear, Conv1d/2d/3d, RNN, LSTM, GRU, BatchNorm, LayerNorm, Dropout
- Attention — MultiHeadAttention, MultiQuery, GroupedQuery, Flash, Rotary/Sinusoidal positional encoding
- Transformer — TransformerEncoderLayer, TransformerDecoderLayer
- Pooling — MaxPool1d/2d, AvgPool1d/2d, AdaptiveAvgPool, GlobalAvgPool
- Activations — ReLU, GELU, SiLU, Sigmoid, Tanh, Softmax, LeakyReLU, ELU
- Optimizers — SGD (with momentum), Adam, AdamW, RMSprop, Adagrad
- Losses — MSE, CrossEntropy, BinaryCrossEntropy, Huber, L1
- Schedulers — StepLR, CosineAnnealing, ReduceOnPlateau, WarmupCosine
- Mixed precision — FP16/BF16 support via scivex-core half types
- GPU support — Optional GPU acceleration via scivex-gpu
Usage
use *;
let mut model = new;
let mut optimizer = new;
let loss = cross_entropy_loss;
loss.backward;
optimizer.step;
License
MIT