Skip to content

Commit fba2d04

Browse files
committed
more on steps
1 parent f59c9cb commit fba2d04

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

skglm/experimental/pdcd_ws.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,8 @@ def _solve(self, X, y, datafit, penalty, w_init=None, Xw_init=None):
101101
# init steps
102102
# choose steps to verify condition: Assumption 2.1 e)
103103
scale = np.sqrt(2 * n_features)
104-
dual_steps = 1 / (norm(X, ord=2, axis=1) * scale)
105-
primal_steps = 1 / ((dual_steps[:, None] * (X ** 2)).sum(axis=0) * scale)
104+
dual_steps = 1 / (norm(X, ord=2) * scale)
105+
primal_steps = 1 / (norm(X, axis=0, ord=2) * scale)
106106

107107
# NOTE: primal and dual steps verify condition on steps when multiplied/divided
108108
# by an arbitrary positive constant

0 commit comments

Comments
 (0)