mlx-macros-burn

Crates.iomlx-macros-burn
lib.rsmlx-macros-burn
version0.25.5
created_at2025-12-31 08:26:52.712176+00
updated_at2025-12-31 09:05:37.844726+00
descriptionProcedural macros for mlx-rs-burn
homepage
repositoryhttps://github.com/TuringWorks/mlx-rs
max_upload_size
id2014241
size17,275
ravituringworks (ravituringworks)

documentation

https://docs.rs/mlx-rs-burn

README

mlx-macros-burn

Crates.io Documentation License

Procedural macros for mlx-rs-burn.

Overview

This crate provides public procedural macros for mlx-rs-burn, including:

  • #[derive(ModuleParameters)] - Derive macro for neural network module parameters
  • Helper macros for defining MLX operations

Installation

This crate is automatically included as a dependency of mlx-rs-burn. You typically don't need to add it directly.

[dependencies]
# Just use mlx-rs-burn instead:
mlx-rs-burn = "0.25.4"

Available Macros

#[derive(ModuleParameters)]

Automatically implements parameter collection for neural network modules:

use mlx_macros::ModuleParameters;

#[derive(ModuleParameters)]
struct MyLayer {
    #[param]
    weights: Array,
    #[param]
    bias: Array,
}

Related Crates

Crate Description
mlx-rs-burn Safe Rust bindings for MLX
mlx-sys-burn Low-level FFI bindings
mlx-internal-macros-burn Internal macros
burn-mlx MLX backend for Burn

Upstream

Fork of mlx-macros from oxideai/mlx-rs.

License

MIT OR Apache-2.0

Commit count: 0

cargo fmt