holospy.reconstruct
#
- holospy.reconstruct.aperture_function(r, apradius, rsmooth)#
A smooth aperture function that decays from apradius-rsmooth to apradius+rsmooth.
- Parameters:
- Returns:
- holospy.reconstruct.estimate_sideband_position(data, sampling, central_band_mask_radius=None, sb='lower', high_cf=True)#
Finds the position of the sideband and returns its position.
- Parameters:
- data
numpy.ndarray
The data of the hologram.
- sampling
tuple
The sampling rate in both image directions.
- central_band_mask_radius
float
, optional The aperture radius used to mask out the centerband.
- sb
str
, optional Chooses which sideband is taken. ‘lower’, ‘upper’, ‘left’, or ‘right’.
- high_cfbool, optional
If False, the highest carrier frequency allowed for the sideband location is equal to half of the Nyquist frequency (Default: True).
- data
- Returns:
tuple
The sideband position (y, x), referred to the unshifted FFT.
- holospy.reconstruct.estimate_sideband_size(sb_position, shape, sb_size_ratio=0.5)#
Estimates the size of sideband filter
- Parameters:
- shapearray_like
Holographic data array
- sb_position
tuple
The sideband position (y, x), referred to the non-shifted FFT.
- sb_size_ratio
float
, optional Size of sideband as a fraction of the distance to central band
- Returns:
float
Size of sideband filter
- holospy.reconstruct.freq_array(shape, sampling)#
Makes up a frequency array.
- Parameters:
- Returns:
numpy.ndarray
Frequencies
- holospy.reconstruct.reconstruct(data, sampling, sb_size, sb_position, sb_smoothness, output_shape=None, plotting=False)#
Core function for holographic reconstruction.
- Parameters:
- dataarray_like
Holographic data array
- sampling
tuple
Sampling rate of the hologram in y and x direction.
- sb_size
float
Size of the sideband filter in pixel.
- sb_position
tuple
Sideband position in pixel.
- sb_smoothness
float
Smoothness of the aperture in pixel.
- output_shape
tuple
, optional New output shape.
- plottingbool
Plots the masked sideband used for reconstruction.
- Returns:
numpy.ndarray
Reconstructed electron wave