Expand description
A companion to the torch-sys crate that provides bindings for
CUDA-specific functionality from libtorch. This crate is separated out to
make it easier for clients who want to avoid compiling CUDA code.
The same safety logic described in the torch-sys crate applies here.
When the cuda feature is enabled, the cuda and nccl modules provide
full CUDA/NCCL bindings. When disabled, cuda provides Python-based CUDA
stream/event wrappers (which panic if no GPU is available at runtime), and
nccl provides stub types for compilation without NCCL headers.
Bindings for torch’s wrappers around CUDA-related functionality.
Structs§
Enums§
- Cuda
Error - Corresponds to the CUDA error codes.