magni.cs.reconstruction.amp.threshold_operator module¶

Module providing threshold functions for the Approximate Message Passing (AMP) algorithm.

Routine listings¶

ValidatedThresholdOperator(magni.utils.validation.types.ThresholdOperator)
A base class for validated magni.cs.reconstruction.amp threshold operator
SoftThreshold(ValidatedThresholdOperator)
A soft threshold operator.
class magni.cs.reconstruction.amp.threshold_operator.ValidatedThresholdOperator(var)[source]

A base class for validated magni.cs.reconstruction.amp threshold operator

Parameters: var (dict) – The threshold operator state variables.
compute_deriv_threshold(var)[source]

Compute the entrywise derivative threshold.

Parameters: var (dict) – The variables used in computing the derivative threshold. eta_deriv (ndarray) – The computed entrywise derivative threshold.

Notes

This method honors magni.utils.validation.enable_allow_validate_once.

compute_threshold(var)[source]

Compute the entrywise threshold.

Parameters: var (dict) – The variables used in computing the threshold. eta (ndarray) – The computed entrywise threshold.

Notes

This method honors magni.utils.validation.enable_allow_validate_once.

update_threshold_level(var)[source]

Update the threshold level state.

Parameters: var (dict) – The variables used in computing the threshold level update.

Notes

This method honors magni.utils.validation.enable_allow_validate_once.

class magni.cs.reconstruction.amp.threshold_operator.SoftThreshold(var)[source]

A soft threshold operator.

This soft threshold operator is based on the description of it and its use in AMP as given in [1] with corrections from [2].

Parameters: threshold_level_update_method ({‘residual’, ‘median’}) – The method to use for updating the threshold level. theta (float) – The tunable regularisation parameter in the threshold level. tau_hat_sq (float) – The mean squared error of the (approximated) un-thresholded estimate used to determine the threshold level.

Notes

The above Parameters are the threshold parameters that must be passed in a var dict to the threshold constructor.

References

 [1] A. Montanari, “Graphical models concepts in compressed sensing” in Compressed Sensing: Theory and Applications, Y. C. Eldar and G. Kutyniok (Ed.), Cambridge University Press, ch. 9, pp. 394-438, 2012.
 [2] J. T. Parker, “Approximate Message Passing Algorithms for Generalized Bilinear Inference”, PhD Thesis, Graduate School of The Ohio State University, 2014
compute_deriv_threshold(var)[source]

Compute the entrywise derivative soft threshold.

Parameters: var (dict) – The variables used in computing the derivative threshold. eta_deriv (ndarray) – The computed entrywise derivative threshold.
compute_threshold(var)[source]

Compute the entrywise soft threshold.

Parameters: var (dict) – The variables used in computing the threshold. eta (ndarray) – The computed entrywise threshold.
update_threshold_level(var)[source]

Update the threshold level state.

Parameters: var (dict) – The variables used in computing the threshold level update.