liger_iris_sim.utils.iris_utils

Functions

iris_ifs_to_spatial(ydet, xdet, scale, size)

Convert IFS spaxel coordinates to spatial coordinates.

iris_imager_to_spatial(xdet, ydet[, scale])

Convert imager detector coordinates to spatial coordinates.

iris_sky_to_imager(ra_deg, dec_deg, scale, size)

Convert sky coordinates (RA, DEC) relative to the center of the imager to detector coordinates (pixels).

iris_skyrel_to_imager(xs, ys, scale)

Convert relative sky coordinates to imager coordinates.

iris_ifs_to_spatial(ydet: float, xdet: float, scale: float, size: tuple[int, int])[source]

Convert IFS spaxel coordinates to spatial coordinates.

Parameters:
  • ydet (float) – The y-coordinate of the spaxel in detector coordinates (pixels).

  • xdet (float) – The x-coordinate of the spaxel in detector coordinates (pixels).

  • scale (float) – The plate scale in mas.

  • size (tuple[int, int]) – The size of the detector in pixels.

Returns:
  • ys (float) – The x-coordinate of the spaxel in spatial coordinates (arcsec).

  • xs (float) – The y-coordinate of the spaxel in spatial coordinates (arcsec).

iris_imager_to_spatial(xdet: float, ydet: float, scale: float = 0.004) tuple[float, float][source]

Convert imager detector coordinates to spatial coordinates.

Parameters:
  • xdet (float) – X coordinate in pixels.

  • ydet (float) – Y coordinate in pixels.

  • scale (float) – Plate scale in arcsec. Default is 0.004 arcsec/pixel.

Returns:
  • xs (float) – X coordinate in arcsec.

  • ys (float) – Y coordinate in arcsec.

iris_sky_to_imager(ra_deg: float, dec_deg: float, scale: float, size: tuple[int, int]) tuple[float, float][source]

Convert sky coordinates (RA, DEC) relative to the center of the imager to detector coordinates (pixels).

Parameters:
  • ra_deg (float) – RA offset in degrees relative to the center.

  • dec_deg (float) – Dec offset in degrees relative to the center.

  • scale (float) – Plate scale in mas.

  • size (tuple[int, int]) – Size of the detector in pixels.

Returns:
  • x_pixel (float) – X coordinate in pixels.

  • y_pixel (float) – Y coordinate in pixels.

iris_skyrel_to_imager(xs: float, ys: float, scale: float) tuple[float, float][source]

Convert relative sky coordinates to imager coordinates.

Parameters:
  • xs (float) – X coordinate in arcsec relative to on-axis.

  • ys (float) – Y coordinate in arcsec relative to on-axis.

  • scale (float) – Plate scale in arcsec.

Returns:
  • xdet (float) – X coordinate in pixels.

  • ydet (float) – Y coordinate in pixels.