optim.ADMMBlock#
- class bartorch.optim.ADMMBlock#
Bases:
ModuleOne step of the alternating direction method of multipliers,
admm.c’sadmm.For
min 0.5 ||A x - y||^2 + sum_j f_j(G_j x - b_j): conjugate gradients onA^H A + cclambda + rho sum_j G_j^H G_jfrom the previousx, then each term’s split and dual. The state’sdoneis Boyd’s residual test, andinvokescounts inner iterations, the quantity BART’smaxiterbudgets. Each step takes its ownrhounlessdynamic_rhoorhogwildmoves it, in which case the state carries it. A sequence ofrhois a schedule, one per step and the last repeated beyond its end, with the scaled duals rescaled by the ratio of consecutive values so that the unscaled ones carry over: the increasing penalty of annealed plug-and-play,rho_k = lambda / sigma_k ** 2against a denoiser’s schedule ofsigma. With a term that introduces auxiliary variables the state vector is the image followed by those variables, andoutput()returns the image alone.- start()#
The run’s state: the start, zero splits and duals, and
A^H y.
- forward()#
Define the computation performed at every call.
Should be overridden by all subclasses.
Note
Although the recipe for forward pass needs to be defined within this function, one should call the
Moduleinstance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.
- output()#