API Reference

Data Structures

Mask1D(shape[, dtype, buffer, offset, …])
Mask2D(shape[, dtype, buffer, offset, …])
Array1D(shape[, dtype, buffer, offset, …])
Array2D(shape[, dtype, buffer, offset, …])
ValuesIrregular(shape[, dtype, buffer, …])
Grid1D(shape[, dtype, buffer, offset, …])
Grid2D(shape[, dtype, buffer, offset, …])
Grid2DIterate(shape[, dtype, buffer, …])
Grid2DInterpolate
Grid2DIrregular(shape[, dtype, buffer, …])
Kernel2D(shape[, dtype, buffer, offset, …])
Convolver(mask, kernel)
Visibilities(shape[, dtype, buffer, offset, …])
TransformerDFT(uv_wavelengths, real_space_mask)
TransformerNUFFT(uv_wavelengths, real_space_mask)

Datasets

Imaging(image, noise_map, psf[, settings, …])
SettingsImaging([grid_class, …])
SimulatorImaging(exposure_time, …)
SettingsInterferometer([grid_class, …])
Interferometer(visibilities, noise_map, …)
SimulatorInterferometer(uv_wavelengths, …)

Fitting

FitImaging(imaging, tracer[, …])
FitInterferometer(interferometer, tracer[, …])

Point Source Modeling

PointDataset(name, positions, List[List[T]], …)
PointDict()
FitPositionsImage(name, positions, …)
FitFluxes(name, fluxes, noise_map, …)
PointSolver(grid[, use_upscaling, …])

Light Profiles

EllGaussian(centre, float] = (0.0, 0.0), …)
SphGaussian(centre, float] = (0.0, 0.0), …)
EllSersic(centre, float] = (0.0, 0.0), …)
SphSersic(centre, float] = (0.0, 0.0), …)
EllExponential(centre, float] = (0.0, 0.0), …)
SphExponential(centre, float] = (0.0, 0.0), …)
EllDevVaucouleurs(centre, float] = (0.0, …)
SphDevVaucouleurs(centre, float] = (0.0, …)
EllSersicCore(centre, float] = (0.0, 0.0), …)
SphSersicCore(centre, float] = (0.0, 0.0), …)
EllChameleon(centre, float] = (0.0, 0.0), …)
SphChameleon(centre, float] = (0.0, 0.0), …)

Mass Profiles

Total Mass Profiles:

PointMass(centre, float] = (0.0, 0.0), …)
EllPowerLawCored(centre, float] = (0.0, …)
SphPowerLawCored(centre, float] = (0.0, …)
EllPowerLawBroken(centre, float] = (0.0, …)
SphPowerLawBroken(centre, float] = (0.0, …)
EllIsothermalCored(centre, float] = (0.0, …)
SphIsothermalCored(centre, float] = (0.0, …)
EllPowerLaw(centre, float] = (0.0, 0.0), …)
SphPowerLaw(centre, float] = (0.0, 0.0), …)
EllIsothermal(centre, float] = (0.0, 0.0), …)
SphIsothermal(centre, float] = (0.0, 0.0), …)

Dark Mass Profiles:

EllNFWGeneralized(centre, float] = (0.0, …)
SphNFWGeneralized(centre, float] = (0.0, …)
SphNFWTruncated(centre, float] = (0.0, 0.0), …)
SphNFWTruncatedMCRLudlow(centre, …)
SphNFWTruncatedMCRDuffy(centre, …) This function only applies for the lens configuration as follows: Cosmology: FlatLamdaCDM H0 = 70.0 km/sec/Mpc Omega_Lambda = 0.7 Omega_m = 0.3 Redshfit of Main Lens: 0.6 Redshift of Source: 2.5 A truncated NFW halo at z = 0.6 with tau = 2.0
EllNFW(centre, float] = (0.0, 0.0), …)
SphNFW(centre, float] = (0.0, 0.0), kappa_s, …)
SphNFWMCRDuffy(centre, float] = (0.0, 0.0), …)
SphNFWMCRLudlow(centre, float] = (0.0, 0.0), …)
EllNFWMCRLudlow(centre, float] = (0.0, 0.0), …)

Stellar Mass Profiles:

EllGaussian(centre, float] = (0.0, 0.0), …)
EllSersic(centre, float] = (0.0, 0.0), …)
SphSersic(centre, float] = (0.0, 0.0), …)
EllExponential(centre, float] = (0.0, 0.0), …)
SphExponential(centre, float] = (0.0, 0.0), …)
EllDevVaucouleurs(centre, float] = (0.0, …)
SphDevVaucouleurs(centre, float] = (0.0, …)
EllSersicRadialGradient(centre, …)
SphSersicRadialGradient(centre, …)
EllChameleon(centre, float] = (0.0, 0.0), …)
SphChameleon(centre, float] = (0.0, 0.0), …)

Mass-sheets:

ExternalShear(elliptical_comps, …)
MassSheet(centre, float] = (0.0, 0.0), kappa)

Lensing

Galaxy(redshift, pixelization, …) @DynamicAttrs
Plane(galaxies, redshift, profiling_dict, …)
Tracer(planes, cosmology, profiling_dict, …)
SettingsLens([positions_threshold, …])

LinearEqns

Pixelizations:

Rectangular([shape])
VoronoiMagnification([shape])
VoronoiBrightnessImage([pixels, …])

Regularizations:

Constant([coefficient])
AdaptiveBrightness([inner_coefficient, …])

LinearEqns:

Mapper(source_grid_slim, …[, …])
LinearEqn

Settings:

SettingsPixelization(use_border, …)
SettingsInversion(use_w_tilde, …)

Plots

Plotters:

Array2DPlotter(array, mat_plot_2d, …)
Grid2DPlotter(grid, mat_plot_2d, visuals_2d, …)
MapperPlotter(mapper, …)
YX1DPlotter(y, List[T], …)
InversionPlotter(inversion, mat_plot_2d, …)
ImagingPlotter(imaging, mat_plot_2d, …)
InterferometerPlotter(interferometer, …)
LightProfilePlotter(light_profile, grid, …)
MassProfilePlotter(mass_profile, grid, …)
GalaxyPlotter(galaxy, grid, mat_plot_1d, …)
FitImagingPlotter(fit, mat_plot_2d, …)
FitInterferometerPlotter(fit, mat_plot_1d, …)
PlanePlotter(plane, grid, mat_plot_1d, …)
HyperPlotter(mat_plot_2d, visuals_2d, include_2d)
FitImagingPlotter(fit, mat_plot_2d, …)
FitInterferometerPlotter(fit, mat_plot_1d, …)
TracerPlotter(tracer, grid, …)
MultiFigurePlotter(plotter_list)
MultiYX1DPlotter(plotter_list[, color_list, …])

Search Plotters:

DynestyPlotter(samples, mat_plot_1d, …)
UltraNestPlotter(samples, mat_plot_1d, …)
EmceePlotter(samples, mat_plot_1d, …)
ZeusPlotter(samples, mat_plot_1d, …)
PySwarmsPlotter(samples, mat_plot_1d, …)

Plot Customization Objects

MatPlot1D(units, figure, axis, cmap, …)
MatPlot2D(units, figure, axis, cmap, …)
Include1D([half_light_radius, einstein_radius])
Include2D([origin, mask, border, grid, …])
Visuals1D(half_light_radius, …)
Visuals2D(origin, border, mask, positions, …)

Matplotlib Wrapper Base Objects:

Units(use_scaled, conversion_factor, in_kpc)
Figure(**kwargs) Sets up the Matplotlib figure before plotting (this is used when plotting individual figures and subplots).
Axis(symmetric_source_centre, **kwargs)
Cmap(**kwargs) Customizes the Matplotlib colormap and its normalization.
Colorbar(manual_tick_labels, …)
ColorbarTickParams(**kwargs) Customizes the ticks of the colorbar of the plotted figure.
TickParams(**kwargs) The settings used to customize a figure’s y and x ticks parameters.
YTicks(manual_values, **kwargs)
XTicks(manual_values, **kwargs)
Title(**kwargs)
YLabel(**kwargs)
XLabel(**kwargs)
Legend([include]) The settings used to include and customize a legend on a figure.
Output(path, filename, format, …)

Matplotlib Wrapper 1D Objects:

YXPlot([plot_axis_type, label])

Matplotlib Wrapper 2D Objects:

ArrayOverlay(**kwargs) Overlays an Array2D data structure over a figure.
GridScatter(**kwargs) Scatters an input set of grid points, for example (y,x) coordinates or data structures representing 2D (y,x) coordinates like a Grid2D or Grid2DIrregular.
GridPlot(**kwargs) Plots Grid2D data structure that are better visualized as solid lines, for example rectangular lines that are plotted over an image and grids of (y,x) coordinates as lines (as opposed to a scatter of points using the GridScatter object).
VectorFieldQuiver(**kwargs) Plots a VectorField data structure.
PatchOverlay(**kwargs) Adds patches to a plotted figure using matplotlib patches objects.
VoronoiDrawer(**kwargs) Draws Voronoi pixels from a MapperVoronoi object (see inversions.mapper).
OriginScatter(**kwargs) Plots the (y,x) coordinates of the origin of a data structure (e.g.
MaskScatter(**kwargs) Plots a mask over an image, using the Mask2d object’s (y,x) edge_grid_sub_1 property.
BorderScatter(**kwargs) Plots a border over an image, using the Mask2d object’s (y,x) border_grid_sub_1 property.
PositionsScatter(**kwargs) Plots the (y,x) coordinates that are input in a plotter via the positions input.
IndexScatter(**kwargs) Plots specific (y,x) coordinates of a grid (or grids) via their 1d or 2d indexes.
PixelizationGridScatter(**kwargs) Plots the grid of a Pixelization object (see autoarray.inversion).
ParallelOverscanPlot(**kwargs)
SerialPrescanPlot(**kwargs)
SerialOverscanPlot(**kwargs)

Lens Modeling

Setup:

AnalysisImaging(dataset, positions[, …])
AnalysisInterferometer(dataset, positions[, …])
AnalysisPoint(point_dict, solver[, imaging, …])
SetupHyper(hyper_galaxies_lens, …)
Preloads(w_tilde, use_w_tilde, …[, failed])

Searches:

DynestyStatic(name, path_prefix, unique_tag)
DynestyDynamic(name, path_prefix, unique_tag)
Emcee(name, path_prefix, unique_tag, …[, …])
PySwarmsLocal(name, path_prefix, unique_tag)
PySwarmsGlobal(name, path_prefix, …)
MultiNest(name, path_prefix, unique_tag, …)