Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main'
Browse files Browse the repository at this point in the history
# Conflicts:
#	lenstronomy/Data/psf.py
  • Loading branch information
sibirrer committed Sep 13, 2024
2 parents e0679ad + 3e0d4e5 commit 616b00d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
10 changes: 4 additions & 6 deletions lenstronomy/Data/psf.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,9 @@ def __init__(
)
# store the initial input PSF and supersampling factor
self._kernel_point_source_init = kernel_point_source
self._point_source_supersampling_factor_init = point_source_supersampling_factor
self._point_source_supersampling_factor_init = (
point_source_supersampling_factor
)
kernel_point_source_ = copy.deepcopy(kernel_point_source)
if kernel_point_source_normalisation is True:
kernel_point_source_ /= np.sum(kernel_point_source)
Expand Down Expand Up @@ -195,7 +197,6 @@ def kernel_point_source_supersampled(self, supersampling_factor, updata_cache=Tr

elif self.psf_type == "PIXEL":


kernel = kernel_util.subgrid_kernel(
self.kernel_point_source, supersampling_factor, odd=True, num_iter=5
)
Expand All @@ -222,9 +223,7 @@ def kernel_point_source_supersampled(self, supersampling_factor, updata_cache=Tr
else:
raise ValueError("psf_type %s not valid!" % self.psf_type)
if updata_cache is True:
self._kernel_point_source_supersampled = (
kernel_point_source_supersampled
)
self._kernel_point_source_supersampled = kernel_point_source_supersampled
self._point_source_supersampling_factor = supersampling_factor
return kernel_point_source_supersampled

Expand Down Expand Up @@ -276,4 +275,3 @@ def point_source_supersampling_factor(self):
return self._point_source_supersampling_factor_init
else:
return 1

3 changes: 2 additions & 1 deletion lenstronomy/PointSource/point_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,8 @@ def __init__(
self._point_source_list.append(
PointSourceCached(
SourcePositions(
lens_model, fixed_magnification=fixed_magnification_list[i],
lens_model,
fixed_magnification=fixed_magnification_list[i],
redshift=redshift_list[i],
),
save_cache=save_cache,
Expand Down

0 comments on commit 616b00d

Please sign in to comment.