From edff2462118641ba9862ca747e097d61eca2e1f9 Mon Sep 17 00:00:00 2001 From: Dirreke Date: Wed, 29 Oct 2025 23:31:07 +0800 Subject: [PATCH] Bump ndarray to 0.17 --- ndarray-linalg/Cargo.toml | 2 +- ndarray-linalg/src/lobpcg/eig.rs | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ndarray-linalg/Cargo.toml b/ndarray-linalg/Cargo.toml index 8c5c83a8..70cb1141 100644 --- a/ndarray-linalg/Cargo.toml +++ b/ndarray-linalg/Cargo.toml @@ -38,7 +38,7 @@ rand = "0.8.3" thiserror = "2.0.0" [dependencies.ndarray] -version = "0.16.0" +version = "0.17.1" features = ["approx", "std"] default-features = false diff --git a/ndarray-linalg/src/lobpcg/eig.rs b/ndarray-linalg/src/lobpcg/eig.rs index e60adb04..7349c36d 100644 --- a/ndarray-linalg/src/lobpcg/eig.rs +++ b/ndarray-linalg/src/lobpcg/eig.rs @@ -69,7 +69,10 @@ impl Truncate lobpcg( |y| self.problem.dot(&y), x, - |mut y| y.assign(&preconditioner.dot(&y)), + |mut y| { + let p = preconditioner.dot(&y); + y.assign(&p); + }, self.constraints.clone(), self.precision, self.maxiter,