Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "ScopeSim"
version = "0.11.2a1"
version = "0.11.2a2"
description = "Generalised telescope observation simulator"
license = {text = "GPL-3.0-or-later"}
authors = [
Expand Down
6 changes: 4 additions & 2 deletions scopesim/effects/psfs/discrete.py
Original file line number Diff line number Diff line change
Expand Up @@ -405,8 +405,9 @@ def get_kernel(self, fov):
self.current_data = self._file[ext].data

# compare the fov and psf pixel scales
kernel_pixel_scale = self._file[ext].header["CDELT1"]
fov_pixel_scale = fov.header["CDELT1"]
kernel_pixel_unit = u.Unit(self._file[ext].header.get("CUNIT1", "deg"))
kernel_pixel_scale = self._file[ext].header["CDELT1"] * kernel_pixel_unit
fov_pixel_scale = fov.header["CDELT1"] * u.Unit(fov.header["CUNIT1"])

# get the spatial map of the kernel cube layers
strl_hdu = self.strehl_imagehdu
Expand All @@ -426,6 +427,7 @@ def get_kernel(self, fov):
# TODO: should the mask also be rescaled?
# rescale the pixel scale of the kernel to match the fov images
pix_ratio = fov_pixel_scale / kernel_pixel_scale
pix_ratio = pix_ratio.to_value(1).round(5)
if abs(pix_ratio - 1) > self.meta["flux_accuracy"]:
spline_order = from_currsys(
"!SIM.computing.spline_order", cmds=self.cmds)
Expand Down
Loading