burn/burn-wgpu
Zsombor c0859dde59
Implement fusing for recip() (#959)
2023-11-15 17:15:01 -05:00
..
benches WGPU: Support elemwise operation fusion (#948) 2023-11-15 15:13:37 -05:00
src Implement fusing for recip() (#959) 2023-11-15 17:15:01 -05:00
Cargo.toml WGPU: Support elemwise operation fusion (#948) 2023-11-15 15:13:37 -05:00
LICENSE-APACHE Feat/wgpu backend setup (#376) 2023-06-02 11:52:47 -04:00
LICENSE-MIT Feat/wgpu backend setup (#376) 2023-06-02 11:52:47 -04:00
README.md [Breaking] Refactor Backend Names (#904) 2023-10-29 18:27:49 -04:00

README.md

Burn WGPU Backend

Burn WGPU backend

Current Crates.io Version license

This crate provides a WGPU backend for Burn using the wgpu.

The backend supports Vulkan, Metal, DirectX11/12, OpenGL, WebGPU.

Usage Example

#[cfg(feature = "wgpu")]
mod wgpu {
    use burn_autodiff::Autodiff;
    use burn_wgpu::{AutoGraphicsApi, Wgpu, WgpuDevice};
    use mnist::training;

    pub fn run() {
        let device = WgpuDevice::default();
        training::run::<Autodiff<Wgpu<AutoGraphicsApi, f32, i32>>>(device);
    }
}

Configuration

You can set BURN_WGPU_MAX_TASKS to a positive integer that determines how many computing tasks are submitted in batches to the graphics API.