@proxify<EOL>def lbfgs(x, rho, f_df, maxiter=<NUM_LIT:20>):
def f_df_augmented(theta):<EOL><INDENT>f, df = f_df(theta)<EOL>obj = f + (rho / <NUM_LIT>) * np.linalg.norm(theta - x) ** <NUM_LIT:2><EOL>grad = df + rho * (theta - x)<EOL>return obj, grad<EOL><DEDENT>res = scipy_minimize(f_df_augmented, x, jac=True, method='<STR_LIT>',<EOL>options={'<STR_LIT>': maxiter, '<STR_LIT>': False})<EOL>return res.x<EOL>
Minimize the proximal operator of a given objective using L-BFGS

Parameters
----------
f_df : function
    Returns the objective and gradient of the function to minimize

maxiter : int
    Maximum number of L-BFGS iterations