ndarray-linalg

Library Featured

Linear algebra package for rust-ndarray using LAPACK

Checked · Sources

Downloads
184,034
Dependents
142
Stars
452
Forks
96
Contributors
32
Commits
1,421
Latest release
0.18.1 ·

About

From the project README ·

Linear algebra package for Rust with ndarray based on external LAPACK implementations.

Examples

See examples directory.

Note: To run examples, you must specify which backend will be used (as described below). For example, you can execute the solve example with the OpenBLAS backend like this:

cargo run --example solve --features=openblas

and run all tests of ndarray-linalg with OpenBLAS

cargo test --features=openblas

Backend Features

There are three LAPACK source crates:

ndarray_linalg must link just one of them for LAPACK FFI.

[dependencies]
ndarray = "0.14"
ndarray-linalg = { version = "0.13", features = ["openblas-static"] }

Supported features are following:

Read the full README
FeatureLink typeRequirementsDescription
openblas-staticstaticgcc, gfortran, makeBuild OpenBLAS in your project, and link it statically
openblas-systemdynamic/staticlibopenblas-devSeek OpenBLAS in system, and link it
netlib-staticstaticgfortran, makeSame as openblas-static except for using reference LAPACK
netlib-systemdynamic/staticliblapack-devSame as openblas-system except for using reference LAPACK
intel-mkl-staticstatic(pkg-config)Seek static library of Intel MKL from system, or download if not found, and link it statically
intel-mkl-systemdynamic(pkg-config)Seek shared library of Intel MKL from system, and link it dynamically
  • You must use just one feature of them.
  • dynamic/static means it depends on what is found in the system. When the system has /usr/lib/libopenblas.so, it will be linked dynamically, and /usr/lib/libopenblas.a will be linked statically. Dynamic linking is prior to static linking.
  • Requirements notices:
    • gcc and gfortran can be another compiler, e.g. icc and ifort.
    • libopenblas-dev is package name in Debian, Ubuntu, and other derived distributions. There are several binary packages of OpenBLAS, i.e. libopenblas-{openmp,pthread,serial}-dev. It can be other names in other distributions, e.g. Fedora, ArchLinux, and so on.
    • pkg-config is used for searching Intel MKL packages in system, and it is optional. See intel-mkl-src/README.md for detail.
For library developer

If you are creating a library depending on this crate, we encourage you not to link any backend:

[dependencies]
ndarray = "0.13"
ndarray-linalg = "0.12"

The cargo's feature is additive. If your library (saying lib1) set a feature openblas-static, the application using lib1 builds ndarray_linalg with openblas-static feature though they want to use intel-mkl-static backend.

See the cargo reference for detail

Tested Environments

Only x86_64 system is supported currently.

BackendLinuxWindowsmacOS
OpenBLAS✔️--
Netlib✔️--
Intel MKL✔️✔️✔️

License

CAUTION Be sure that if you use intel-mkl-src backend, you have to accept Intel Simplified Software License in addition to the MIT-License or Apache-2.0 License.

Dual-licensed to be compatible with the Rust project. Licensed under the Apache License, Version 2.0 http://www.apache.org/licenses/LICENSE-2.0 or the MIT license http://opensource.org/licenses/MIT, at your option.

Runs on
GPU support unknown
What shows it
  • no dependency or feature matches a backend row
Native code
Required
  • Binds native code: lapack-sys, intel-mkl-src (feature intel-mkl-dynamic-ilp64-iomp), netlib-src (feature netlib-static), openblas-src (feature openblas-static)
Python bindings
No Python binding crate found
License
Apache-2.0 OR MIT

Compare with similar projects

Order: strongest tier first, then most downloads, then name, with unmeasured values last. A library counts downloads over 30 days. An app counts binary downloads per release. An app with none counts its crate downloads over 30 days. ML Rust runs this catalogue, so its closest project always gets a row.

ndarray-linalg beside the projects that share a topic with it
ProjectDownloadsDependentsStarsLatest releaseRuns on (GPU)Native codeLicense
ndarray-linalg This page Featured

Linear algebra package for rust-ndarray using LAPACK

184,034 downloads over 30 days 142 452 0.18.1 GPU support unknown Binds native code: lapack-sys, intel-mkl-src (feature intel-mkl-dynamic-ilp64-iomp), netlib-src (feature netlib-static), openblas-src (feature openblas-static) Apache-2.0 OR MIT
linfa-linalg Listed Dormant

Pure-Rust implementation of linear algebra routines for ndarray

198,623 downloads over 30 days 20 39 0.2.1 GPU support unknown No native code found Apache-2.0 OR MIT

Interpolation package for ndarray

158,299 downloads over 30 days 4 12 0.6.0 GPU support unknown No native code found MIT
peroxide Listed

Rust comprehensive scientific computation library contains linear algebra, numerical analysis, statistics and machine learning tools with familiar syntax

Python bindings

56,548 downloads over 30 days 9 732 0.43.1 GPU support unknown Binds native code: openblas-src (feature O3-openblas-system), blas-sys (feature O3), hdf5-metno-sys (feature nc), lapack-sys (feature O3), libz-sys (feature nc) and 1 more Apache-2.0 OR MIT
basin Listed

Numerical optimization in pure Rust, with pluggable linear-algebra backends and WASM support.

22,519 downloads over 30 days 9 128 3.2.0 GPU support unknown Binds native code: blas-sys (feature nalgebra_latest-lapack), lapack-sys (feature nalgebra_latest-lapack) Apache-2.0 OR MIT
numr Listed

The base for numerical code in Rust, in the role NumPy has in Python: n-dimensional tensors, linear algebra, FFT, statistics and autograd on CPU, CUDA and WebGPU. The backends use native kernels, with no cuBLAS, MKL or other vendor math library.

1,673 downloads over 30 days 7 59 0.15.2 CUDA, WebGPU Binds native code: ring (feature distributed) Apache-2.0
Why FeaturedIt passes every Featured gate.

What it meets

  • It has 34 active dependents and 25 new dependents in 365 days. Featured needs 11 active dependents or 9 new dependents in 365 days.
  • Active dependents are at 82% of their peak. Featured needs at least 50%.
  • Docs are present. The release commit or a manifest ties the crate to the repository.
  • No vulnerability advisory stays unpatched past the grace window. At least one version is neither a prerelease nor 0.0.x.
  • The last activity is on 2 Jun 2026, 160 days ago. The rules expect an update within 1200 days. Dormancy rule

Exact rules: Featured library. The check on applied thresholds version 9.

Every rule outcome, as the check records it
  • expected-interval: version 0.18.1 base 300, doubled for 184034 downloads per month, doubled for 34 active users: E = 1200 days
  • dormancy: last activity 2026-06-02, 160 days ago, E = 1200: active
  • featured: featured: active_users 34, new_adopters 25, former_glory 0.82
Crates2 crates

Measurements and sources

Each signal row shows the raw value, its source and the fetch date. The Sources list gathers every distinct source on this page. Movement needs more history.

Sources6 sources
Adoption34 active dependents, 25 new dependents in 365 days1 not measured
Adoption measurements
SignalValueSourceFetchedCounts
Active dependents34crates.io database dumpYes
New dependents (365 days)25crates.io database dumpYes
Peak active dependents45crates.io database dumpYes
Active dependents as a share of the peak0.8182crates.io database dumpYes
Binary downloads per releaseNot measuredYes
MaintenanceLatest human commit: 5 months ago3 not measured
Maintenance measurements
SignalValueSourceFetchedCounts
Latest human commit2026-06-02GitHub repositoryYes
Latest release2026-06-02crates.io database dumpYes
First release2016-11-11crates.io database dumpYes
Latest version0.18.1crates.io database dumpYes
Days the oldest outside issue waits for a reply1776GitHub repositoryYes
Maintainer replies over 365 days3GitHub repositoryYes
Repository archivedfalseGitHub repositoryYes
Repository gonefalseGitHub repositoryYes
Release commit or manifest in the repotruecrates.io packageYes
Published docstruecrates.io database dumpYes
Latest release fails cargo checkNot measuredYes
Build check dateNot measuredYes
Build check toolchainNot measuredYes
SecurityUnpatched vulnerabilities: none
Security measurements
SignalValueSourceFetchedCounts
Unpatched vulnerabilities past the grace windownoneRustSec advisory databaseYes
RustSec unmaintained advisorynoneRustSec advisory databaseYes
Deprecation noticenonecrates.io database dumpYes
Deprecated requirementnonecrates.io database dumpYes
Distribution43 releases, 184,034 downloads over 30 days5 not measured
Distribution measurements
SignalValueSourceFetchedCounts
Releases43crates.io database dumpYes
Downloads over 30 days184034crates.io database dumpYes
Binary downloads over the last 3 releasesNot measuredYes
Homebrew installs on request over 365 daysNot measuredYes
Repology repository familiesNot measuredYes
Docker pull growth over 90 daysNot measuredYes
Docker pulls at the growth baselineNot measuredYes
Every version a prereleasefalsecrates.io database dumpYes
Every version 0.0.xfalsecrates.io database dumpYes
Every version yankedfalsecrates.io database dumpYes
Crate deleted from crates.iofalsecrates.io database dumpYes
Repository452 stars, 96 forks, 32 contributors, 1,421 commits. Stars alone never qualify a project.
Repository measurements
SignalValueSourceFetchedCounts
GitHub stars452GitHub repositoryYes — one part of the repository route
GitHub forks96GitHub repositoryYes — one part of the repository route
Contributors with a GitHub account32GitHub contributorsYes — one part of the repository route
Commits on the default branch1421GitHub repositoryNo
Repository's main crate left out of the entrynonecrates.io database dumpYes
Facts that never count
Facts that never count measurements
SignalValueSourceFetchedCounts
LicenseApache-2.0 OR MITcrates.io database dumpNo
Runs on, from listed crates and their direct dependenciesGPU support unknowncrates.io database dumpNo
What shows each backendno dependency or feature matches a backend rowcrates.io database dumpNo
Native code, from listed crates and their dependenciesBinds native code: lapack-sys, intel-mkl-src (feature intel-mkl-dynamic-ilp64-iomp), netlib-src (feature netlib-static), openblas-src (feature openblas-static)crates.io database dumpNo
Python bindings, from direct dependencies of listed cratesNo Python binding crate foundcrates.io database dumpNo
Crates that depend on a listed crate directly142crates.io database dumpNo

Corrections and review history

Report a correction

No correction applies to this entry.

Judgments

A judgment enters only through an approved issue and a merged pull request.

No judgment applies to this entry.