From 6bab15ceeebc03bf9e858632b7823ac52d881bc2 Mon Sep 17 00:00:00 2001 From: Zaccharie Ramzi Date: Wed, 20 Mar 2019 14:32:17 +0100 Subject: [PATCH] changed from dot to vdot in fista restarting criterion --- modopt/opt/algorithms.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/modopt/opt/algorithms.py b/modopt/opt/algorithms.py index 9b768b3c..7e301d60 100644 --- a/modopt/opt/algorithms.py +++ b/modopt/opt/algorithms.py @@ -393,10 +393,7 @@ def is_restart(self, z_old, x_new, x_old): """ if self.restart_strategy is None: return False - criterion = np.dot( - (z_old - x_new).flatten(), - (x_new - x_old).flatten(), - ) >= 0 + criterion = np.vdot(z_old - x_new, x_new - x_old) >= 0 if criterion: if 'adaptive' in self.restart_strategy: self.r_lazy *= self.xi_restart