RMLImaging

Documentation for RMLImaging.

RMLImaging.AbstractRegularizerType
AbstractRegularizer

Mandatory fields

  • hyperparameter::Number: the hyper parameter of the regularization function. In default, it should be a number.
  • domain::RegularizerDomain: the domain of the image space where the regularization function will be computed.

Mandatory methods

  • evaluate(::AbstractRegularizerDomain, ::AbstractRegularizer, ::AbstractImageModel, ::AbstractArray): Evaluate the regularization function for the given input sky image.
  • evaluate(::AbstractRegularizer, ::AbstractImageModel, ::AbstractArray): Evaluate the regularization function for the given input sky image.
  • cost(::AbstractRegularizer, ::AbstractImageModel, ::AbstractArray): Evaluate the cost function for the given input sky image. The cost function is defined by the product of its hyperparameter and regularization function.
  • ``
source
RMLImaging.KLEntropyType
KLEntropy <: AbstractRegularizer

Regularizer using the Kullback-Leibler divergence (or a relative entropy).

fields

  • hyperparameter::Number: the hyperparameter of the regularizer
  • prior: the prior image.
  • domain::AbstractRegularizerDomain: the image domain where the regularization funciton will be computed. KLEntropy can be computed only in LinearDomain().
source
RMLImaging.L1NormType
L1Norm <: AbstractRegularizer

Regularizer using the l1-norm.

fields

  • hyperparameter::Number: the hyperparameter of the regularizer
  • weight: the weight of the regularizer, which could be a number or an array.
  • domain::AbstractRegularizerDomain: the image domain where the regularization funciton will be computed. L1Norm can be computed only in LinearDomain().
source
RMLImaging.SingleNFFT2DType
SingleNFFT2D(nfft_fwd, nfft_adj, vnorm) <: FourierTransform2D

A Fourier Transform Operator of a single 2D Image using NFFT.

Fields

  • nfft_fwd: NFFT operator for the forward transform
  • nfft_adj: NFFT operator for the adjoint transform
  • Vkernel: the factor (phase shift, pulse funciton, kernel, etc) to be multipled by the forward-transformed visibilities.
source
RMLImaging.SingleUVCoverageType
SingleUVCoverage(u, v, reverse_idx) <: AbstractUVCoverage

A basic type for single uv-coverage.

Arguemnts:

  • u::Vector
  • v::Vector
  • reverse_idx::Vector
source
RMLImaging.TSVType
TSV <: AbstractRegularizer

Regularizer using the Istropic Total Squared Variation

fields

  • hyperparameter::Number: the hyperparameter of the regularizer
  • weight: the weight of the regularizer, which may be used for multi-dimensional images.
  • domain::AbstractRegularizerDomain: the image domain where the regularization funciton will be computed.
source
RMLImaging.TVType
TV <: AbstractRegularizer

Regularizer using the Istropic Total Variation

fields

  • hyperparameter::Number: the hyperparameter of the regularizer
  • weight: the weight of the regularizer, which may be used for multi-dimensional images.
  • domain::AbstractRegularizerDomain: the image domain where the regularization funciton will be computed.
source
Base.map!Method
map!(image::EHTImages.AbstractEHTImage, imager::Imager2D, x::AbstractArray[, idx])
source
Base.mapMethod
map(image::EHTImages.AbstractEHTImage, imager::Imager2D, x::AbstractArray[, idx])
source
RMLImaging.ImagingProblemMethod
ImagingProblem(imager::Imager2D, x0::AbstractArray)

Initialize Optimization.OptimizationProblem for RML Imaging. Returns the initialized Optimization.OptimizationProblem object.

Arguments

  • imager::Imager2D: the imager
  • x0::AbstractArray: the initial image in the parameter domain.
source
RMLImaging.ImagingProblemMethod
ImagingProblem(imager::Imager2D, initialimage::AbstractEHTImage)

Initialize Optimization.OptimizationProblem for RML Imaging. Returns the initialized Optimization.OptimizationProblem object.

Arguments

  • imager::Imager2D: the imager
  • x0::AbstractArray: the initial image in the parameter domain.
source
RMLImaging.costMethod
cost(reg::AbstractRegularizer, skymodel::AbstractImageModel, x::AbstractArray)

Compute the cost function of the given regularization function for the given image parameters on the given image model. In default, this should return reg.hyperparameter .* evaluate(reg, skymodel, x).

Arguments

  • reg::AbstractRegularizer: the regularization function.
  • skymodel::AbstractImageModel: the model of the input image
  • x::AbstractArray: the parameters of the input image
source
RMLImaging.domainMethod
domain(reg::AbstractRegularizer) = reg.domain

Return the computing domain of the given regularizer.

source
RMLImaging.evaluateMethod
evaluate(imager::Imager2D, x::AbstractArray)

Evaluate chisquares and regularizers from the input image parameters

Arguments

  • imager::Imager2D: RML Imaging Setting
  • x::AbstractArray: the image parameters
source
RMLImaging.evaluateMethod
evaluate(imager::Imager2D, image::AbstractEHTImage)

Evaluate chisquares and regularizers from the input image

Arguments

  • imager::Imager2D: RML Imaging Setting
  • image::AbstractEHTImage: the image
source
RMLImaging.evaluateMethod
evaluate(reg::AbstractRegularizer, skymodel::AbstractImageModel, x::AbstractArray)

Compute the value of the given regularization function for the given image parameters on the given image model. In default, return evaluate(domain(reg), reg, skymodel, x).

Arguments

  • reg::AbstractRegularizer: the regularization function.
  • skymodel::AbstractImageModel: the model of the input image
  • x::AbstractArray: the parameters of the input image
source
RMLImaging.evaluateMethod
evaluate(domain::AbstractRegularizerDomain, reg::AbstractRegularizer, skymodel::AbstractImageModel, x::AbstractArray)

Compute the value of the given regularization function for the given image parameters on the given image model. In default, return 0.

Arguments

  • domain::AbstractRegularizerDomain: the domain of the image where the regularization function will be computed.
  • reg::AbstractRegularizer: the regularization function.
  • skymodel::AbstractImageModel: the model of the input image
  • x::AbstractArray: the parameters of the input image
source
RMLImaging.klentropy_baseMethod
klentropy_base(x::AbstractArray, p::AbstractArray)

Base function of the l1norm.

Arguments

  • I::AbstractArray: the image
source
RMLImaging.l1normMethod
l1norm(I::AbstractArray, w::Number)

Base function of the l1norm.

Arguments

  • I::AbstractArray: the image
  • w::Number: the regularization weight
source
RMLImaging.l1normMethod
l1norm(I::AbstractArray)

Base function of the l1norm.

Arguments

  • I::AbstractArray: the image
source
RMLImaging.lossfuncMethod
lossfunc(x, imager::Imager2D)

The Loss function for the basic 2-dimensional RML Imaging problem. Returns the cost function.

Arguments

  • x::AbstractArray: the image parameters
  • imager::Imager2D: RML Imaging Setting
source
RMLImaging.transform_linear_forwardMethod
transform_linear_forward(model::AbstractImageModel, x::AbstractArray)

Convert the input array of the image model parameters into the corresponding array of the linear-scale intensity map. This is supposed to be the inverse funciton of $transform_linear_inverse$.

Arguments

  • model::AbstractImageModel: the image model
  • x::AbstractArray: the array of the image model parameters
source
RMLImaging.transform_linear_inverseMethod
transform_linear_forward(model::AbstractImageModel, x::AbstractArray)

Convert the input array of the linear-scale intensity map into the array of the corresponding model parameters. This is supposed to be the inverse funciton of $transform_linear_forward$.

Arguments

  • model::AbstractImageModel: the image model
  • x::AbstractArray: the array of the linear-scale intensity map
source
RMLImaging.tsv_baseMethod
tsv_base(I::AbstractArray, w::Number; ex::Floop's Executor)

Base function of the istropic total squared Variation.

Arguments

  • I::AbstractArray: the input two dimensional real image
  • w::Number: the regularization weight
source
RMLImaging.tsv_baseMethod
tsv_base(I::AbstractArray; ex::FLoops's Executor)

Base function of the istropic total squared Variation.

Arguments

  • I::AbstractArray: the input two dimensional real image
source
RMLImaging.tv_baseMethod
tv_base(I::AbstractArray, w::Number; ex::FLoops's Executor)

Base function of the istropic total variation.

Arguments

  • I::AbstractArray: the input two dimensional real image
  • w::Number: the regularization weight
source
RMLImaging.tv_baseMethod
tv_base(I::AbstractArray; ex::FLoops's Executor)

Base function of the istropic total variation.

Arguments

  • I::AbstractArray: the input two dimensional real image
source
RMLImaging.tv_base_grad_pixelMethod
tv_base_pixel(I::AbstractArray, ix::Integer, iy::Integer)

Evaluate the gradient of the istropic variation term for the given pixel.

source
RMLImaging.tv_base_pixelMethod
tv_base_pixel(I::AbstractArray, ix::Integer, iy::Integer)

Evaluate the istropic variation term for the given pixel.

source