Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Installation

From crates.io

Add to your Cargo.toml:

[dependencies]
omeinsum = "0.1"

From Git

For the latest development version:

[dependencies]
omeinsum = { git = "https://github.com/TensorBFS/omeinsum-rs" }

Features

FeatureDefaultDescription
parallelYesEnable parallel execution with rayon
tropical-kernelsYesUse optimized tropical-gemm kernels
cudaNoEnable CUDA GPU support

Minimal Build

For a minimal build without optional dependencies:

[dependencies]
omeinsum = { version = "0.1", default-features = false }

With CUDA

[dependencies]
omeinsum = { version = "0.1", features = ["cuda"] }

Verification

Verify the installation:

use omeinsum::{Tensor, Cpu};

fn main() {
    let t = Tensor::<f32, Cpu>::from_data(&[1.0, 2.0, 3.0], &[3]);
    println!("omeinsum installed successfully!");
    println!("Tensor shape: {:?}", t.shape());
}