From 85b8d871056ff2e22f3e2b5ce973feba43248247 Mon Sep 17 00:00:00 2001 From: Christoph Lehner Date: Sun, 22 Sep 2024 16:09:19 +0200 Subject: [PATCH] more economical resource management during hmc --- lib/gpt/qcd/pseudofermion/action/base.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/gpt/qcd/pseudofermion/action/base.py b/lib/gpt/qcd/pseudofermion/action/base.py index 6ed705c8..212eb794 100644 --- a/lib/gpt/qcd/pseudofermion/action/base.py +++ b/lib/gpt/qcd/pseudofermion/action/base.py @@ -31,7 +31,9 @@ def __init__(self, M, inverter, operator): def _updated(self, fields): U = fields[0:-1] psi = fields[-1] - return [m.updated(U) for m in self.M] + [U, psi] + for m in self.M: + m.update(U) + return self.M + [U, psi] def _allocate_force(self, U): frc = g.group.cartesian(U)