Skip to content

Commit

Permalink
Upgrade ndarray-linalg 0.16, argmin 0.9.0 (#331)
Browse files Browse the repository at this point in the history
  • Loading branch information
relf authored Jan 31, 2024
1 parent 86ad712 commit 4e40ce6
Show file tree
Hide file tree
Showing 10 changed files with 76 additions and 40 deletions.
23 changes: 14 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ authors = [
"Luca Palmieri <[email protected]>",
"Lorenz Schmidt <[email protected]>",
"Paul Körbitz <[email protected]>",
"Yuhan Lin <[email protected]>"
"Yuhan Lin <[email protected]>",
]
description = "A Machine Learning framework for Rust"
edition = "2018"
Expand Down Expand Up @@ -41,12 +41,12 @@ rand = { version = "0.8", features = ["small_rng"] }
approx = "0.4"

ndarray = { version = "0.15", features = ["approx"] }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
sprs = { version = "0.11", default-features = false }

thiserror = "1.0"

criterion = { version = "0.4.0", optional = true}
criterion = { version = "0.4.0", optional = true }

[dependencies.serde_crate]
package = "serde"
Expand All @@ -57,17 +57,22 @@ features = ["std", "derive"]

[dev-dependencies]
ndarray-rand = "0.14"
linfa-datasets = { path = "datasets", features = ["winequality", "iris", "diabetes", "generate"] }
linfa-datasets = { path = "datasets", features = [
"winequality",
"iris",
"diabetes",
"generate",
] }
statrs = "0.16.0"

[target.'cfg(not(windows))'.dependencies]
pprof = { version = "0.11.0", features = ["flamegraph", "criterion"], optional = true}
pprof = { version = "0.11.0", features = [
"flamegraph",
"criterion",
], optional = true }

[workspace]
members = [
"algorithms/*",
"datasets",
]
members = ["algorithms/*", "datasets"]

[profile.release]
opt-level = 3
18 changes: 13 additions & 5 deletions algorithms/linfa-clustering/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,21 @@ edition = "2018"
authors = [
"Luca Palmieri <[email protected]>",
"xd009642 <[email protected]>",
"Rémi Lafage <[email protected]>"
"Rémi Lafage <[email protected]>",
]
description = "A collection of clustering algorithms"
license = "MIT OR Apache-2.0"

repository = "https://github.com/rust-ml/linfa/"
readme = "README.md"

keywords = ["clustering", "machine-learning", "linfa", "k-means", "unsupervised"]
keywords = [
"clustering",
"machine-learning",
"linfa",
"k-means",
"unsupervised",
]
categories = ["algorithms", "mathematics", "science"]

[features]
Expand All @@ -28,9 +34,9 @@ default-features = false
features = ["std", "derive"]

[dependencies]
ndarray = { version = "0.15", features = ["rayon", "approx"]}
ndarray = { version = "0.15", features = ["rayon", "approx"] }
linfa-linalg = { version = "0.1", default-features = false }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
ndarray-rand = "0.14"
ndarray-stats = "0.5"
num-traits = "0.2"
Expand All @@ -44,7 +50,9 @@ noisy_float = "0.2.0"

[dev-dependencies]
ndarray-npy = { version = "0.8", default-features = false }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["generate"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"generate",
] }
criterion = "0.4.0"
serde_json = "1"
approx = "0.4"
Expand Down
11 changes: 7 additions & 4 deletions algorithms/linfa-elasticnet/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "linfa-elasticnet"
version = "0.7.0"
authors = [
"Paul Körbitz / Google <[email protected]>",
"Lorenz Schmidt <[email protected]>"
"Lorenz Schmidt <[email protected]>",
]

description = "A Machine Learning framework for Rust"
Expand All @@ -29,9 +29,9 @@ default-features = false
features = ["std", "derive"]

[dependencies]
ndarray = { version = "0.15", features = ["approx"]}
ndarray = { version = "0.15", features = ["approx"] }
linfa-linalg = { version = "0.1", default-features = false }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }

num-traits = "0.2"
approx = "0.4"
Expand All @@ -40,6 +40,9 @@ thiserror = "1.0"
linfa = { version = "0.7.0", path = "../.." }

[dev-dependencies]
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["diabetes", "linnerud"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"diabetes",
"linnerud",
] }
ndarray-rand = "0.14"
rand_xoshiro = "0.6"
10 changes: 6 additions & 4 deletions algorithms/linfa-ftrl/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,22 @@ version = "1.0"
features = ["derive"]

[dependencies]
ndarray = { version = "0.15.4", features = ["serde"]}
ndarray = { version = "0.15.4", features = ["serde"] }
ndarray-rand = "0.14.0"
argmin = { version = "0.8.1", default-features = false }
argmin = { version = "0.9.0", default-features = false }
argmin-math = { version = "0.3", features = ["ndarray_v0_15-nolinalg"] }
thiserror = "1.0"
rand = "0.8.5"
rand_xoshiro = "0.6.0"

linfa = { version = "0.7.0", path = "../.."}
linfa = { version = "0.7.0", path = "../.." }

[dev-dependencies]
criterion = "0.4.0"
approx = "0.4"
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["winequality"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"winequality",
] }
linfa = { version = "0.7.0", path = "../..", features = ["benchmarks"] }

[[bench]]
Expand Down
2 changes: 1 addition & 1 deletion algorithms/linfa-ica/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ features = ["std", "derive"]
[dependencies]
ndarray = { version = "0.15" }
linfa-linalg = { version = "0.1", default-features = false }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
ndarray-rand = "0.14"
ndarray-stats = "0.5"
num-traits = "0.2"
Expand Down
12 changes: 7 additions & 5 deletions algorithms/linfa-linear/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "linfa-linear"
version = "0.7.0"
authors = [
"Paul Körbitz / Google <[email protected]>",
"VasanthakumarV <[email protected]>"
"VasanthakumarV <[email protected]>",
]

description = "A Machine Learning framework for Rust"
Expand Down Expand Up @@ -31,18 +31,20 @@ features = ["std", "derive"]
[dependencies]
ndarray = { version = "0.15", features = ["approx"] }
linfa-linalg = { version = "0.1", default-features = false }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
num-traits = "0.2"
argmin = { version = "0.8.1", default-features = false }
argmin = { version = "0.9.0", default-features = false }
argmin-math = { version = "0.3", features = ["ndarray_v0_15-nolinalg"] }
thiserror = "1.0"

linfa = { version = "0.7.0", path = "../.." }

[dev-dependencies]
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["diabetes"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"diabetes",
] }
approx = "0.4"
criterion = "0.4.0"
criterion = "0.4.0"
statrs = "0.16.0"
linfa = { version = "0.7.0", path = "../..", features = ["benchmarks"] }

Expand Down
6 changes: 4 additions & 2 deletions algorithms/linfa-logistic/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ version = "1.0"
ndarray = { version = "0.15", features = ["approx"] }
ndarray-stats = "0.5.0"
num-traits = "0.2"
argmin = { version = "0.8.1", default-features = false }
argmin = { version = "0.9.0", default-features = false }
argmin-math = { version = "0.3", features = ["ndarray_v0_15-nolinalg"] }
thiserror = "1.0"

Expand All @@ -35,5 +35,7 @@ linfa = { version = "0.7.0", path = "../.." }

[dev-dependencies]
approx = "0.4"
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["winequality"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"winequality",
] }
rmp-serde = "1"
6 changes: 4 additions & 2 deletions algorithms/linfa-pls/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ features = ["std", "derive"]
[dependencies]
ndarray = { version = "0.15" }
linfa-linalg = { version = "0.1", default-features = false }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
ndarray-stats = "0.5"
ndarray-rand = "0.14"
num-traits = "0.2"
Expand All @@ -37,7 +37,9 @@ linfa = { version = "0.7.0", path = "../.." }

[dev-dependencies]
linfa = { version = "0.7.0", path = "../..", features = ["benchmarks"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["linnerud"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"linnerud",
] }
approx = "0.4"
rand_xoshiro = "0.6"
criterion = "0.4.0"
Expand Down
13 changes: 8 additions & 5 deletions algorithms/linfa-preprocessing/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ serde = ["serde_crate", "ndarray/serde", "serde_regex"]
[dependencies]
linfa = { version = "0.7.0", path = "../.." }
ndarray = { version = "0.15", features = ["approx"] }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
linfa-linalg = { version = "0.1", default-features = false }
ndarray-stats = "0.5"
thiserror = "1.0"
Expand All @@ -29,7 +29,7 @@ ndarray-rand = { version = "0.14" }
unicode-normalization = "0.1.8"
regex = "1.4.5"
encoding = "0.2"
sprs = { version="0.11.0", default-features = false }
sprs = { version = "0.11.0", default-features = false }

serde_regex = { version = "1.1", optional = true }

Expand All @@ -41,9 +41,12 @@ default-features = false
features = ["std", "derive"]

[dev-dependencies]
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["diabetes", "winequality"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"diabetes",
"winequality",
] }
linfa-bayes = { version = "0.7.0", path = "../linfa-bayes" }
iai = "0.1"
iai = "0.1"
curl = "0.4.35"
flate2 = "1.0.20"
tar = "0.4.33"
Expand All @@ -65,4 +68,4 @@ harness = false

[[bench]]
name = "norm_scaler_bench"
harness = false
harness = false
15 changes: 12 additions & 3 deletions algorithms/linfa-reduction/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@ license = "MIT OR Apache-2.0"
repository = "https://github.com/rust-ml/linfa"
readme = "README.md"

keywords = ["reduction", "machine-learning", "linfa", "spectral", "unsupervised"]
keywords = [
"reduction",
"machine-learning",
"linfa",
"spectral",
"unsupervised",
]
categories = ["algorithms", "mathematics", "science"]

[features]
Expand All @@ -27,7 +33,7 @@ features = ["std", "derive"]
[dependencies]
ndarray = { version = "0.15", features = ["approx"] }
linfa-linalg = { version = "0.1" }
ndarray-linalg = { version = "0.15", optional = true }
ndarray-linalg = { version = "0.16", optional = true }
ndarray-rand = "0.14"
num-traits = "0.2"
thiserror = "1.0"
Expand All @@ -38,5 +44,8 @@ linfa-kernel = { version = "0.7.0", path = "../linfa-kernel" }

[dev-dependencies]
ndarray-npy = { version = "0.8", default-features = false }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = ["iris", "generate"] }
linfa-datasets = { version = "0.7.0", path = "../../datasets", features = [
"iris",
"generate",
] }
approx = { version = "0.4" }

0 comments on commit 4e40ce6

Please sign in to comment.