Name
pw_extract - Approximate the background noise or envelope function by polynomials, and use constrained simplex method (in L1 sense) to extract image formation parameters (the coefficients of the polynomials) from 1D rotationally averaged power spectrum in logrithm scale. By adjusting the rank of polynomials, one can flexibly fit the background noise, and envelope function (non-Gaussian type).
Usage
- res = pw_extract(1dpw2, n1,iswi, Pixel_size)
Input
- 1dpw2
- 1D rotationally averaged power spectrum of particles or noise
- n1
n1=n+1, n is the rank of polynomial, which is used to approximate baseline noise, or envelope function.
- iswi
- an integer number, which can control the fitting objects - either envelope function or background noise.
- Pixel_size
Pixel size of the input image. Given it, one can output frequencies with unit of 1/`Å`.
Output
- res
- contains extracted background noise, or envelope function, frequencies, and associated fitting parameters.
Options
Description
- 1. The pw_extract c++ code calls the following functions to perform the parameters fitting:
- call_cl1, b. lsfit. c. CL1. These called functions are converted from Fortran 77 by f2c program. CL1 is the core code to perform constrained simplex optimization.
- 2. iswi is the control switch to perform either background or envelope fitting.
Method
- Simplex method
Reference
.1. Barrodale and F.D.K. Roberts L1 solution to linear equations subject to linear equality and inequality constraints ACM TOMS 6 (1980), 231-235.
.2. Z. Huang, P. R. Baldwin, S.Mullapudi, and P .A. Penczek, Automated determination of parameters describing power spectra of micrograph images in electron microscopy. J. Struct. Biol. 144 (2003), pp. 79–94.
Author / Maintainer
Zhong Huang
Keywords
- category 1
- UTILITIES
- category 2
- ADAPTIVE
Files
utilities.py
See also
Maturity
- stable
- works for most people, has been tested; test cases/examples available.
Bugs
None. It is perfect.