Skip to content

New WCS TPV support doesn't work with DECAM images #3904

Closed

Description

@eteq

Sorry to say this, @mdboom - but I just attempted the procedure I described in my comment in #3845, and it still doesn't seem to work even after #3878 . I've copied my procedure below, although not a critical change: it seem to work with neither all_pix2world nor wcs_pix2world now...

  1. Go to http://www.portal-nvo.noao.edu/search/query and select "CTIO 4m + DECam imager" under Telescope&Instrument, and check "calibrated images" for "Mosaic, NEWFIRM, and DECam". If you want exactly the file I tested on, you'll also want to choose Program number="2012B-0001", but I don't think that actually matters
  2. Hit "search", and then find the first result the search returns that has "Product"="image". Hit "retreive" on that row and it will download a DECam image.
  3. You should see this with that image:
>>> f = fits.open('c4d_130831_235507_ooi_g_d3.fits.fz')
>>> w = wcs.WCS(f[1].header)
>>> ra, dec = w.all_pix2world([0,10, 15],[0,10, 20],0)
>>> ra
array([ 301.2065433,  301.2065433,  301.2065433])
>>> dec
array([-50.93399553, -50.93399553, -50.93399553])

which is clearly wrong: they should be different ra/dec.
4. Also, I see this:

>>> ra, dec = w.wcs_pix2world([0,10, 15],[0,10, 20],0)
>>> ra
array([ 301.2065433,  301.2065433,  301.2065433])
>>> dec
array([-50.93399553, -50.93399553, -50.93399553])

which is the same incorrect answer, as opposed to when I tried this in #3845, where wcs_pix2world did work.

Activity

  1. mdboom commented on Jun 30, 2015

    @mdboom
    Contributor

    I think this is (another) instance of wcscopy being broken. The polynomial distortion coefficients are somehow ending up as all zeros (which is why the results are always the same). Looking into it now.

  2. mdboom commented on Jun 30, 2015

    @mdboom
    Contributor

    It is an issue with copying the wcs struct, but it appears to have already been fixed in wcslib 5.7. I have a PR almost ready to go on that.

  3. added a commit that references this issue on Jun 30, 2015
  4. eteq commented on Jul 1, 2015

    @eteq
    MemberAuthor

    Looks like #3905 fixes this (see my comment there)

  5. added a commit that references this issue on Aug 11, 2015
  6. bsipocz commented on Jun 28, 2017

    @bsipocz
    Member

    #3905 missed to auto-close this, closing now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions