ndarray

ndarray: an N-dimensional array with array views, multidimensional slicing, and efficient operations

Github星跟蹤圖

ndarray

The ndarray crate provides an n-dimensional container for general elements
and for numerics.

Please read the API documentation on docs.rs__

__ https://docs.rs/ndarray/, build_status, _, crates, _

.., build_status, image:: https://api.travis-ci.org/rust-ndarray/ndarray.svg?branch=master
.. _build_status: https://travis-ci.org/rust-ndarray/ndarray

.., crates, image:: http://meritbadge.herokuapp.com/ndarray
.. _crates: https://crates.io/crates/ndarray

Highlights

  • Generic 1, 2, ..., n-dimensional arrays
  • Owned arrays and array views
  • Slicing, also with arbitrary step size, and negative indices to mean
    elements from the end of the axis.
  • Views and subviews of arrays; iterators that yield subviews.

Status and Lookout

  • Still iterating on and evolving the crate

    • The crate is continuously developing, and breaking changes are expected
      during evolution from version to version. We adopt the newest stable
      rust features if we need them.
  • Performance:

    • Prefer higher order methods and arithmetic operations on arrays first,
      then iteration, and as a last priority using indexed algorithms.
    • Efficient floating point matrix multiplication even for very large
      matrices; can optionally use BLAS to improve it further.

Crate Feature Flags

The following crate feature flags are available. They are configured in
your Cargo.toml.

  • serde

    • Optional, compatible with Rust stable
    • Enables serialization support for serde 1.x
  • rayon

    • Optional, compatible with Rust stable
    • Enables parallel iterators, parallelized methods and par_azip!.
  • blas

    • Optional and experimental, compatible with Rust stable
    • Enable transparent BLAS support for matrix multiplication.
      Uses blas-src for pluggable backend, which needs to be configured
      separately.

How to use with cargo

::

[dependencies]
ndarray = "0.13.0"

How to enable blas integration. Depend on blas-src directly to pick a blas
provider. Depend on the same blas-src version as ndarray does, for the
selection to work. A proposed configuration using system openblas is shown
below. Note that only end-user projects (not libraries) should select
provider::

[dependencies]
ndarray = { version = "0.13.0", features = ["blas"] }
blas-src = { version = "0.4.0", default-features = false, features = ["openblas"] }
openblas-src = { version = "0.7.0", default-features = false, features = ["cblas", "system"] }

Recent Changes

See RELEASES.md <./RELEASES.md>_.

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. This file may not be copied, modified, or distributed
except according to those terms.

主要指標

概覽
名稱與所有者rust-ndarray/ndarray
主編程語言Rust
編程語言Rust (語言數: 3)
平台
許可證Apache License 2.0
所有者活动
創建於2014-08-04 09:27:53
推送於2025-05-26 18:30:30
最后一次提交2025-05-26 14:30:30
發布數70
最新版本名稱0.16.1 (發布於 2024-08-14 19:38:41)
第一版名稱ndarray-rand-0.3.0 (發布於 2016-11-21 19:35:17)
用户参与
星數3.9k
關注者數47
派生數333
提交數3.3k
已啟用問題?
問題數676
打開的問題數173
拉請求數617
打開的拉請求數29
關閉的拉請求數98
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?