From 55856e9f80e40c884766e7fd9c9f27d2aad99ca2 Mon Sep 17 00:00:00 2001 From: James Nightingale Date: Fri, 22 Dec 2023 14:23:18 +0000 Subject: [PATCH] adapt images removed subfolder --- autolens/analysis/result.py | 7 ------- autolens/imaging/model/result.py | 1 - test_autolens/analysis/test_result.py | 8 ++++---- 3 files changed, 4 insertions(+), 12 deletions(-) diff --git a/autolens/analysis/result.py b/autolens/analysis/result.py index 2fbc8af65..78a713548 100644 --- a/autolens/analysis/result.py +++ b/autolens/analysis/result.py @@ -183,13 +183,6 @@ def positions_likelihood_from( return PositionsLHPenalty(positions=positions, threshold=threshold) return PositionsLHResample(positions=positions, threshold=threshold) - @property - def path_galaxy_tuples(self) -> [(str, ag.Galaxy)]: - """ - Tuples associating the names of galaxies with instances from the best fit - """ - return self.instance.path_instance_tuples_for_class(cls=ag.Galaxy) - class ResultDataset(Result): @property diff --git a/autolens/imaging/model/result.py b/autolens/imaging/model/result.py index f8621781d..07c7acb1d 100644 --- a/autolens/imaging/model/result.py +++ b/autolens/imaging/model/result.py @@ -59,7 +59,6 @@ def max_log_likelihood_tracer(self) -> Tracer: The `Tracer` is computed from the `max_log_likelihood_fit`, as this ensures that all linear light profiles are converted to normal light profiles with their `intensity` values updated. """ - return ( self.max_log_likelihood_fit.model_obj_linear_light_profiles_to_light_profiles ) diff --git a/test_autolens/analysis/test_result.py b/test_autolens/analysis/test_result.py index 3c3129749..be860d8dd 100644 --- a/test_autolens/analysis/test_result.py +++ b/test_autolens/analysis/test_result.py @@ -366,11 +366,11 @@ def test___image_dict(analysis_imaging_7x7): ) image_dict = result.image_galaxy_dict - assert isinstance(image_dict[("galaxies", "lens")], np.ndarray) - assert isinstance(image_dict[("galaxies", "source")], np.ndarray) + assert isinstance(image_dict[str(("galaxies", "lens"))], np.ndarray) + assert isinstance(image_dict[str(("galaxies", "source"))], np.ndarray) result.instance.galaxies.lens = al.Galaxy(redshift=0.5) image_dict = result.image_galaxy_dict - assert (image_dict[("galaxies", "lens")].native == np.zeros((7, 7))).all() - assert isinstance(image_dict[("galaxies", "source")], np.ndarray) + assert (image_dict[str(("galaxies", "lens"))].native == np.zeros((7, 7))).all() + assert isinstance(image_dict[str(("galaxies", "source"))], np.ndarray)