From 60a6a3c6f4aa68b5d99f35b5e2395257fa6677e4 Mon Sep 17 00:00:00 2001 From: mattiasakesson Date: Tue, 5 Dec 2023 11:04:59 +0100 Subject: [PATCH] fix increment average --- fedn/fedn/utils/plugins/androidhelper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fedn/fedn/utils/plugins/androidhelper.py b/fedn/fedn/utils/plugins/androidhelper.py index 0213e977d..21256f442 100644 --- a/fedn/fedn/utils/plugins/androidhelper.py +++ b/fedn/fedn/utils/plugins/androidhelper.py @@ -37,7 +37,7 @@ def increment_average( weights = {} for i in model.keys(): weights[i] = list( - w * np.array(model[i]) + (1 - w) * np.array(model_next[i]) + (1-w) * np.array(model[i]) + w * np.array(model_next[i]) ) return weights