Skip to content

Commit ffcf6bd

Browse files
authored
Merge pull request #94 from mrava87/main
doc: cleaned docstring of ProximalGradient
2 parents 7bf160f + dfcbb89 commit ffcf6bd

File tree

2 files changed

+15
-14
lines changed

2 files changed

+15
-14
lines changed

docs/source/api/index.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,10 @@ Primal
138138
AcceleratedProximalGradient
139139
ADMM
140140
ADMML2
141+
GeneralizedProximalGradient
141142
HQS
142143
LinearizedADMM
143144
ProximalGradient
144-
AcceleratedProximalGradient
145-
GeneralizedProximalGradient
146145
ProximalPoint
147146
TwIST
148147

pyproximal/optimization/primal.py

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def ProximalGradient(proxf, proxg, x0, tau=None, beta=0.5,
104104
epsg=1., niter=10, niterback=100,
105105
acceleration=None,
106106
callback=None, show=False):
107-
r"""Proximal gradient (optionnally accelerated)
107+
r"""Proximal gradient (optionally accelerated)
108108
109109
Solves the following minimization problem using (Accelerated) Proximal
110110
gradient algorithm:
@@ -140,7 +140,7 @@ def ProximalGradient(proxf, proxg, x0, tau=None, beta=0.5,
140140
Number of iterations of iterative scheme
141141
niterback : :obj:`int`, optional
142142
Max number of iterations of backtracking
143-
acceleration: :obj:`str`, optional
143+
acceleration : :obj:`str`, optional
144144
Acceleration (``None``, ``vandenberghe`` or ``fista``)
145145
callback : :obj:`callable`, optional
146146
Function with signature (``callback(x)``) to call after each iteration
@@ -155,15 +155,15 @@ def ProximalGradient(proxf, proxg, x0, tau=None, beta=0.5,
155155
156156
Notes
157157
-----
158-
The (Accelerated) Proximal point algorithm can be expressed by the
159-
following recursion:
158+
The Proximal point algorithm can be expressed by the following recursion:
160159
161160
.. math::
162161
163-
\mathbf{y}^{k+1} = \mathbf{x}^k + \omega^k
164-
(\mathbf{x}^k - \mathbf{x}^{k-1})
162+
165163
\mathbf{x}^{k+1} = \prox_{\tau^k \epsilon g}(\mathbf{y}^{k+1} -
166164
\tau^k \nabla f(\mathbf{y}^{k+1})) \\
165+
\mathbf{y}^{k+1} = \mathbf{x}^k + \omega^k
166+
(\mathbf{x}^k - \mathbf{x}^{k-1})
167167
168168
where at each iteration :math:`\tau^k` can be estimated by back-tracking
169169
as follows:
@@ -180,12 +180,14 @@ def ProximalGradient(proxf, proxg, x0, tau=None, beta=0.5,
180180
181181
where :math:`\tilde{f}_\tau(\mathbf{x}, \mathbf{y}) = f(\mathbf{y}) +
182182
\nabla f(\mathbf{y})^T (\mathbf{x} - \mathbf{y}) +
183-
1/(2\tau)||\mathbf{x} - \mathbf{y}||_2^2`,
184-
and
185-
:math:`\omega^k = 0` for ``acceleration=None``,
186-
:math:`\omega^k = k / (k + 3)` for ``acceleration=vandenberghe`` [1]_
187-
or :math:`\omega^k = (t_{k-1}-1)/t_k` for ``acceleration=fista`` where
188-
:math:`t_k = (1 + \sqrt{1+4t_{k-1}^{2}}) / 2` [2]_
183+
1/(2\tau)||\mathbf{x} - \mathbf{y}||_2^2`.
184+
185+
Different accellerations are provided:
186+
187+
- ``acceleration=None``: :math:`\omega^k = 0`;
188+
- `acceleration=vandenberghe`` [1]_: :math:`\omega^k = k / (k + 3)` for `
189+
- ``acceleration=fista``: :math:`\omega^k = (t_{k-1}-1)/t_k` for where
190+
:math:`t_k = (1 + \sqrt{1+4t_{k-1}^{2}}) / 2` [2]_
189191
190192
.. [1] Vandenberghe, L., "Fast proximal gradient methods", 2010.
191193
.. [2] Beck, A., and Teboulle, M. "A Fast Iterative Shrinkage-Thresholding

0 commit comments

Comments
 (0)