From 1a2a05c59f77ea7dab4a88630d77a388d0a6ffdb Mon Sep 17 00:00:00 2001 From: Sebastian Kehl Date: Mon, 12 Feb 2024 10:48:32 +0100 Subject: [PATCH] Fix use of deprecated scipy.minimize api. For scipy>=1.11 x0 must be passed as ndim=1 array. Implicit raveling of the array was deprecated with 1.11. --- src/trimem/mc/util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/trimem/mc/util.py b/src/trimem/mc/util.py index ac21993..43655b6 100644 --- a/src/trimem/mc/util.py +++ b/src/trimem/mc/util.py @@ -289,7 +289,7 @@ def _cb(x): } res = minimize( funcs.fun, - mesh.x, + mesh.x.ravel(), jac=funcs.grad, callback=_cb, method="L-BFGS-B",