Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
- fit.inversion.mapper.grid.scaled_minima[0]
)
)
if sub_plotter.figure.aspect in "square":
aspect_inv = ratio
elif sub_plotter.figure.aspect in "auto":
aspect_inv = 1.0 / ratio
elif sub_plotter.figure.aspect in "equal":
aspect_inv = 1.0
sub_plotter.setup_subplot(
number_subplots=number_subplots, subplot_index=4, aspect=float(aspect_inv)
)
inversion_plots.reconstruction(
inversion=fit.inversion,
source_positions=include.positions_of_plane_from_fit_and_plane_index(
fit=fit, plane_index=plane_index
),
caustics=include.caustics_from_obj(obj=fit.tracer),
include=include,
plotter=sub_plotter,
)
sub_plotter.output.subplot_to_figure()
sub_plotter.figure.close()
plane_plots.plane_image(
plane=fit.tracer.planes[plane_index],
grid=include.traced_grid_of_plane_from_fit_and_plane_index(
fit=fit, plane_index=plane_index
),
positions=include.positions_of_plane_from_fit_and_plane_index(
fit=fit, plane_index=plane_index
),
caustics=include.caustics_from_obj(obj=fit.tracer),
include=include,
plotter=plotter,
)
elif fit.tracer.planes[plane_index].has_pixelization:
inversion_plots.reconstruction(
inversion=fit.inversion,
source_positions=include.positions_of_plane_from_fit_and_plane_index(
fit=fit, plane_index=plane_index
),
caustics=include.caustics_from_obj(obj=fit.tracer),
include=include,
plotter=plotter,
)