Skip to content

Support ndarray 0.15 #180

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Jun 7, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,19 +87,20 @@ jobs:
run: pip install maturin poetry toml
- name: Create an isolated example directory
run: cp -r examples/simple-extension/ ../simple-extension-msrv
- name: Edit Cargo.toml
- name: Edit Cargo.toml and change the path of rust-numpy
run: |
import toml
cargo_toml = toml.load("Cargo.toml")
cargo_toml["dependencies"]["numpy"]["path"] = "../rust-numpy"
cargo_toml["dependencies"]["ndarray"] = "0.13.1"
cargo_toml["dependencies"]["num-complex"] = "0.2.4"
cargo_toml["dependencies"]["numpy"]["path"] = "../rust-numpy"
with open("Cargo.toml", "w") as f:
toml.dump(cargo_toml, f)
working-directory: ../simple-extension-msrv
shell: python
- name: Remove ndarray 0.14.0
run: cargo update -p ndarray:0.14.0 --precise 0.13.1
- name: Use ndarray 0.13.1 and num-complex 0.2.0
run: |
cargo update -p ndarray:0.15.2 --precise 0.13.1
working-directory: ../simple-extension-msrv
- name: Test Example
run: |
Expand Down
5 changes: 2 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ cfg-if = "0.1"
libc = "0.2"
num-complex = ">= 0.2, <= 0.4"
num-traits = "0.2"
ndarray = ">= 0.13, < 0.15"
ndarray = ">= 0.13, < 0.16"
pyo3 = { version = "0.13", default-features = false }

[dev-dependencies]
Expand All @@ -29,6 +29,5 @@ pyo3 = "0.13"
default = []
rayon = ["ndarray/rayon"]


[workspace]
members = ["examples/*"]
members = ["examples/*"]
5 changes: 3 additions & 2 deletions examples/linalg/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ crate-type = ["cdylib"]

[dependencies]
numpy = { path = "../.." }
ndarray = "0.14"
ndarray-linalg = { version = "0.13", features = ["openblas-static"] }
ndarray = "0.15"
# ndarray-linalg = { version = "0.13", features = ["openblas-static"] }
ndarray-linalg = { git = "https://github.com/rust-ndarray/ndarray-linalg", features = ["openblas-static"] }

[dependencies.pyo3]
version = "0.13"
Expand Down
4 changes: 2 additions & 2 deletions examples/simple-extension/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ crate-type = ["cdylib"]

[dependencies]
numpy = { path = "../.." }
ndarray = "0.14"
num-complex = "0.3"
ndarray = "0.15.2"
num-complex = "0.4.0"

[dependencies.pyo3]
version = "0.13"
Expand Down