astropy-tutorials icon indicating copy to clipboard operation
astropy-tutorials copied to clipboard

Tutorial idea: replacing IRAF image registration workflow with Astropy equivalents

Open stargaser opened this issue 4 years ago • 2 comments

From a request from a colleague:

  • precisely register two images, one to the other

    • typically two HST images, although possibly not with the same camera (e.g. ACS vs WFC3)
    • sometimes one image is ground-based, one image is space-based
    • procedure is to obtain accurate centroids of stars in common between the 2 image datasets, and then use geomap to determine the astrometric solution to transform image 2 to image 1 with geotran or geoxytran
    • this does not use the WCS for each image; it is purely in pixel coordinates. The application is to map the pixel position of the celestial object in one image to pixel position in the other.
  • Second procedure used sometimes but less frequently than the first, is to determine the WCS/plate solution by hand for an image, using ccmap, again with accurate centroids for a number of stars which save, say, Gaia EDR3 counterparts. Then apply with WCS to a centroid list from the image using cctran.

How can someone do these things in Astropy or any of the other available Python-based tools?

stargaser avatar Mar 24 '21 16:03 stargaser

I feel like STScI already has tools for things like this. Maybe @stsci-hack knows.

pllim avatar Mar 24 '21 18:03 pllim

:+1: from me. I have a workflow I used with a student here: https://github.com/keflavich/W51-GTC-2020/blob/master/notebooks/ExamineW51Files.ipynb

or here: https://nbviewer.jupyter.org/github/keflavich/W51-GTC-2020/blob/master/notebooks/ExamineW51Files.ipynb

it goes through catalog cross-matching & WCS fitting. So more like the second approach.

The reprojection step is done w/the reproject package, and is a one-liner, but it was done here in case that's helpful: https://nbviewer.jupyter.org/github/keflavich/W51-GTC-2020/blob/master/parker/Reproject.ipynb

(These notebooks were not written to be general-use tutorials, but could be revised for that purpose without too much difficulty, given the appropriate data set)

keflavich avatar Jun 30 '21 13:06 keflavich