raft
RAFT is an NVIDIA-sponsored C++ library providing GPU-accelerated primitives for machine learning—linear algebra, clustering, nearest-neighbor search, and statistics. It offers optional Python bindings (pylibraft) and Dask integration for multi-GPU workflows, designed as building blocks rather than a direct data-science tool.
Key facts
Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.
| Field | Value |
|---|---|
| Repository | NVIDIA/raft |
| Owner | NVIDIA |
| Primary language | Cuda |
| License | Apache-2.0 — OSI-approved |
| Stars | 1k |
| Forks | 238 |
| Open issues | 447 |
| Latest release | v26.06.00 (2026-06-03) |
| Last updated | 2026-07-08 |
| Source | https://github.com/NVIDIA/raft |
What raft is
Header-only C++ template library with optional shared library, exposing dense/sparse linear algebra, solvers, statistics, and vector-search kernels via mdspan multi-dimensional arrays and raft::device_resources for stream/handle management. Python bindings support __cuda_array_interface__ for zero-copy interop with CuPy, PyTorch, and JAX.
Get the raft source
Clone the repository and explore it locally.
git clone https://github.com/NVIDIA/raft.gitcd raft# follow the project's README for install & configurationNeed it deployed, integrated, or customized instead? DEV.co ships production installs.
Best use cases
Implementation considerations
- Mandatory dependency on RAPIDS RMM for memory allocation; understand RMM pooling and allocation strategies to optimize performance.
- mdspan and mdarray API requires modern C++ (C++17+); template compilation can be slow without using the optional shared library prebuilt types.
- Handle and stream management via raft::device_resources; synchronization and kernel launch patterns differ from standard CUDA—review examples carefully.
- Python bindings (pylibraft) are lightweight wrappers; inspect source for which algorithms are exposed; coverage growing but not exhaustive.
- Multi-GPU code via raft-dask requires Dask cluster setup and NCCL communication; verify interop with target distributed frameworks (Ray, MPI).
When to avoid it — and what to weigh
- CPU-only inference or training at scale — RAFT is GPU-first; CPU fallback is not a focus. Pure CPU workloads incur overhead and miss the core value proposition.
- Data scientists needing high-level ML APIs — RAFT is intentionally low-level and primitives-focused; RAPIDS libraries (cuML, cuDF) are the intended abstraction layer for data science workflows.
- Projects without CUDA expertise or GPU infrastructure — Requires CUDA compiler, cuBLAS, cuSOLVER, and modern NVIDIA GPUs; integration complexity is high for teams new to GPU development.
- Scenarios requiring cross-vendor GPU support — CUDA-only; no AMD ROCm, Intel oneAPI, or other accelerator support.
License & commercial use
Licensed under Apache-2.0 (Apache License 2.0), a permissive OSI-approved license allowing commercial use, modification, and distribution with standard attribution and liability disclaimers.
Apache-2.0 is a permissive license that permits commercial use, including in proprietary applications, without requiring disclosure of source code modifications. No additional license fees or restrictions apply. However, as with all open-source dependencies, ensure your legal team reviews compliance obligations (e.g., attribution, liability limitation) before deployment.
DEV.co evaluation signals
Editorial assessment — not user reviews. Directional, with an explicit confidence level.
| Signal | Assessment |
|---|---|
| Maintenance | Active |
| Documentation | Adequate |
| License clarity | Clear |
| Deployment complexity | High |
| DEV.co fit | Good |
| Assessment confidence | High |
No critical vulnerabilities or exploit details found in provided data. Standard considerations: CUDA kernel execution is not memory-safe by default—bounds checking and input validation are developer responsibility. RMM and cuBLAS dependencies should be monitored for CVEs. No formal security audit details provided; review CVE databases and NVIDIA advisories before using in high-security environments.
Alternatives to consider
FAISS (Meta) + CuPy / Rapids cuML
Pure vector-search focus with simpler Python API; cuML provides higher-level ML algos. Less general-purpose than RAFT's primitives approach.
Thrust (NVIDIA standard library)
Lower-level CUDA primitives; more manual but directly integrated into NVIDIA toolkit. Lacks ML-specific algorithms and RMM convenience.
oneAPI / Intel GPU libraries
Cross-vendor GPU acceleration; less mature for ML workflows but no NVIDIA lock-in. Smaller ecosystem compared to CUDA/RAPIDS.
Build on raft with DEV.co software developers
Evaluate RAFT's GPU primitives for your use case. Start with the getting-started guide and assess GPU infrastructure requirements. Devco can help architect and integrate RAFT into your production pipeline.
Talk to DEV.coRelated open-source tools
Surfaced by semantic similarity across the DEV.co open-source index.
Related on DEV.co
Explore the category and the services that help you build with it.
raft FAQ
Is RAFT a complete ML framework?
Can I use RAFT without CUDA?
How do I avoid slow template compilation?
Is RAFT production-ready?
Software developers & web developers for hire
From first prototype to production, DEV.co delivers software development services around tools like raft. Our software development agency staffs experienced software developers and web developers for custom software development, web development, integrations, and ongoing support across vector databases and beyond.
Ready to accelerate your ML workload?
Evaluate RAFT's GPU primitives for your use case. Start with the getting-started guide and assess GPU infrastructure requirements. Devco can help architect and integrate RAFT into your production pipeline.