diff --git a/autogalaxy/quantity/model/analysis.py b/autogalaxy/quantity/model/analysis.py index 11f0c377..f964190b 100644 --- a/autogalaxy/quantity/model/analysis.py +++ b/autogalaxy/quantity/model/analysis.py @@ -143,6 +143,19 @@ def fit_quantity_for_instance(self, instance: af.ModelInstance) -> FitQuantity: dataset=self.dataset, light_mass_obj=galaxies, func_str=self.func_str ) + def fit_from(self, instance: af.ModelInstance) -> FitQuantity: + """ + Standard-name alias for :meth:`fit_quantity_for_instance`. + + Exposing ``fit_from`` lets the autofit base ``Analysis.fit_for_visualization`` + helper dispatch through the same JIT-cached wrapper as imaging / + interferometer (it calls ``self.fit_from`` unconditionally). Without + this method, ``use_jax_for_visualization=True`` on ``AnalysisQuantity`` + would be a silent no-op — see the Phase 0c shipped notes in + ``PyAutoPrompt/complete.md``. + """ + return self.fit_quantity_for_instance(instance=instance) + def save_attributes(self, paths: af.DirectoryPaths): """ Before the non-linear search begins, this routine saves attributes of the `Analysis` object to the `files` diff --git a/autogalaxy/quantity/model/visualizer.py b/autogalaxy/quantity/model/visualizer.py index 37838bc3..6363cdab 100644 --- a/autogalaxy/quantity/model/visualizer.py +++ b/autogalaxy/quantity/model/visualizer.py @@ -69,7 +69,7 @@ def visualize( if skip_visualization(): return - fit = analysis.fit_quantity_for_instance(instance=instance) + fit = analysis.fit_for_visualization(instance=instance) plotter = PlotterQuantity( image_path=paths.image_path, title_prefix=analysis.title_prefix