Skip to content

Class: HarmonixModel

Bases: SourceModel

Wrapper for external models with harmonix-like visibility methods.

source is an ordinary field, so a pytree source (such as a harmonix Harmonix) has parameters that zodiax paths reach and fits can vary, e.g. "source.radius" (mas) or "source.data" (map coefficients for l

= 1, with Y00 = 1); a source that is not a pytree needs eqx.filter_jit, not jax.jit. A wrapped source has weight 1 inside a System, where only harmonix stars can be drawn.

Parameters:

Name Type Description Default
source object

External model. getattr(source, visibility_method) is called with the baselines (and observation_time if given) and must return complex visibilities normalized to 1 at zero baseline.

required
visibility_method str

Names of the visibility method (default "model") and of a render(npix, fov_mas) method for render (default "render"); sources with a surface and a radius in mas (harmonix stars) are drawn from the surface's intensity, East left and North up, when there is none.

'model'
render_method str

Names of the visibility method (default "model") and of a render(npix, fov_mas) method for render (default "render"); sources with a surface and a radius in mas (harmonix stars) are drawn from the surface's intensity, East left and North up, when there is none.

'model'
expects_wavelength_units bool

If True (default), pass spatial frequencies u / wavel, v / wavel; otherwise u, v in metres.

True
observation_time optional

Extra argument passed after the baselines, e.g. a time for rotating stars; static (hashable), so array-valued times are not supported under jax.jit.

None

__init__(source, visibility_method='model', render_method='render', expects_wavelength_units=True, observation_time=None)

model(u, v, wavel)

render(npix=256, fov_mas=200.0)