Imager¶
-
ehtim.imaging.imager_utils.
imager_func
(Obsdata, InitIm, Prior, flux, d1='vis', d2=False, d3=False, alpha_d1=100, alpha_d2=100, alpha_d3=100, s1='simple', s2=False, s3=False, alpha_s1=1, alpha_s2=1, alpha_s3=1, alpha_flux=500, alpha_cm=500, **kwargs)[source]¶ Run a general interferometric imager. Only works directly on the image’s primary polarization.
- Parameters
Obsdata (Obsdata) – The Obsdata object with VLBI data
InitIm (Image) – The Image object with the initial image for the minimization
Prior (Image) – The Image object with the prior image
flux (float) – The total flux of the output image in Jy
d1 (str) – The first data term; options are ‘vis’, ‘bs’, ‘amp’, ‘cphase’, ‘cphase_diag’ ‘camp’, ‘logcamp’, ‘logcamp_diag’
d2 (str) – The second data term; options are ‘vis’, ‘bs’, ‘amp’, ‘cphase’, ‘cphase_diag’ ‘camp’, ‘logcamp’, ‘logcamp_diag’
d3 (str) – The third data term; options are ‘vis’, ‘bs’, ‘amp’, ‘cphase’, ‘cphase_diag’ ‘camp’, ‘logcamp’, ‘logcamp_diag’
s1 (str) – The first regularizer; options are ‘simple’, ‘gs’, ‘tv’, ‘tv2’, ‘l1’, ‘patch’,’compact’,’compact2’,’rgauss’
s2 (str) – The second regularizer; options are ‘simple’, ‘gs’, ‘tv’, ‘tv2’,’l1’, ‘patch’,’compact’,’compact2’,’rgauss’
s3 (str) – The third regularizer; options are ‘simple’, ‘gs’, ‘tv’, ‘tv2’,’l1’, ‘patch’,’compact’,’compact2’,’rgauss’
alpha_d1 (float) – The first data term weighting
alpha_d2 (float) – The second data term weighting
alpha_d2 – The third data term weighting
alpha_s1 (float) – The first regularizer term weighting
alpha_s2 (float) – The second regularizer term weighting
alpha_s3 (float) – The third regularizer term weighting
alpha_flux (float) – The weighting for the total flux constraint
alpha_cm (float) – The weighting for the center of mass constraint
maxit (int) – Maximum number of minimizer iterations
stop (float) – The convergence criterion
clipfloor (float) – The Jy/pixel level above which prior image pixels are varied
grads (bool) – If True, analytic gradients are used
logim (bool) – If True, uses I = exp(I’) change of variables
norm_reg (bool) – If True, normalizes regularizer terms
norm_init (bool) – If True, normalizes initial image to given total flux
show_updates (bool) – If True, displays the progress of the minimizer
weighting (str) – ‘natural’ or ‘uniform’
debias (bool) – if True then apply debiasing to amplitudes/closure amplitudes
systematic_noise (float) – a fractional systematic noise tolerance to add to thermal sigmas
snrcut (float) – a snr cutoff for including data in the chi^2 sum
beam_size (float) – beam size in radians for normalizing the regularizers
maxset (bool) – if True, use maximal set instead of minimal for closure quantities
systematic_cphase_noise (float) – a value in degrees to add to the closure phase sigmas
cp_uv_min (float) – flag baselines shorter than this before forming closure quantities
ttype (str) – The Fourier transform type; options are ‘fast’, ‘direct’, ‘nfft’
fft_pad_factor (float) – The FFT will pre-pad the image by this factor x the original size
order (int) – Interpolation order for sampling the FFT
conv_func (str) – The convolving function for gridding; options are ‘gaussian’, ‘pill’, and ‘cubic’
p_rad (int) – The pixel radius for the convolving function in gridding for FFTs
- Returns
Image object with result
- Return type
-
class
ehtim.imager.
Imager
(obs_in, init_im, prior_im=None, flux=None, data_term={'vis': 100}, reg_term={'simple': 1}, **kwargs)[source]¶ A general interferometric imager.
-
make_chisq_dict
(imcur)[source]¶ Make a dictionary of current chi^2 term values i indexes the observation number in self.obslist_next
-
make_chisqgrad_dict
(imcur, i=0)[source]¶ Make a dictionary of current chi^2 term gradient values i indexes the observation number in self.obslist_next
-
make_image
(pol=None, grads=True, mf=False, **kwargs)[source]¶ Make an image using current imager settings.
-
make_image_I
(grads=True, niter=1, blur_frac=1, **kwargs)[source]¶ Make Stokes I image using current imager settings.
-
make_image_IP
(grads=True, niter=1, blur_frac=1, **kwargs)[source]¶ Make Stokes I and P polarimetric image simultaneously using current imager settings.
-
make_image_IV
(grads=True, niter=1, blur_frac=1, **kwargs)[source]¶ Make Stokes I image using current imager settings.
-
make_image_I_stochastic_optics
(grads=True, **kwargs)[source]¶ Reconstructs an image of total flux density using the stochastic optics scattering mitigation technique.
Uses the scattering model in Imager.scattering_model. If none has been specified, defaults to standard model for Sgr A*. Returns the estimated unscattered image.
-
make_image_P
(grads=True, niter=1, blur_frac=1, **kwargs)[source]¶ Make Stokes P polarimetric image using current imager settings.
-
make_image_V
(grads=True, niter=1, blur_frac=1, **kwargs)[source]¶ Make Stokes I image using current imager settings.
-
property
obs_next
¶ the next Obsdata to be used in imaging
-