In [ ]:
%matplotlib inline
import numpy as np
import matplotlib.pyplot as plt
from pyunlocbox import functions, solvers
plt.rcParams['figure.figsize'] = (17, 5)
In [ ]:
f1 = functions.norm_l2(y=[4, 5, 6, 7])
f2 = functions.dummy()
solver = solvers.forward_backward()
ret = solvers.solve([f1, f2], [0., 0, 0, 0], solver, atol=1e-5)
ret['sol']
In [ ]:
plt.semilogy(np.array(ret['objective'])[:, 0], '.-');
Try to follow one of our tutorials.
In [ ]:
# Your code here.
Or try anything that goes through your mind! Look at the reference guide to know more about the API.
In [ ]:
# Your code here.
If you miss a package, you can install it with:
In [ ]:
! pip install pyunlocbox