Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-15431

Add Jacobian BoundedField accessor to SkyWcs

    Details

    • Type: Story
    • Status: Done
    • Resolution: Done
    • Fix Version/s: None
    • Component/s: afw
    • Labels:
      None

      Description

      We've agreed that it should not be the responsibility of the PhotoCalib to include a Jacobian derived from the WCS, because we don't always want to apply that.  Instead, SkyWcs should have the ability (given a pixel bounding box) to return a BoundedField that evaluates to the determinant of the Jacobian of the pixelToSky transform (aka the pixel area in angular units) at every point in that bounding box efficiently.  This probably involves a new BoundedField class (though it's possible there's a way to do this with TransformBoundedField).

      A reference implementation can be found in meas_mosaic's calculateJacobian functions, though a different approach to vectorization may be necessary to get good performance from AST.

        Attachments

          Issue Links

            Activity

            Hide
            jbosch Jim Bosch added a comment -

            I suspect the plugin as it exists now would be better off using something based on getPixelScale() (and perhaps renaming it to make that clear).   For completely different reasons (computing shapes and centroids in sky coordinates from pixel-coordinate measurements) we're going to also want to start saving all of the matrix elements returned from linearizePixelToSky independently, and I imagine we'll do that in the same plugin.

            Show
            jbosch Jim Bosch added a comment - I suspect the plugin as it exists now would be better off using something based on getPixelScale() (and perhaps renaming it to make that clear).   For completely different reasons (computing shapes and centroids in sky coordinates from pixel-coordinate measurements) we're going to also want to start saving all of the matrix elements returned from linearizePixelToSky independently, and I imagine we'll do that in the same plugin.
            Hide
            Parejkoj John Parejko added a comment -

            While reviewing fgcm, I discovered SingleFrameJacobianPlugin in meas_base plugins.py. It uses linearizePixelToSky().determinant (my version 2 above), so it should be very close to the pixel area calculation implemented here. However, it does result in the question of whether we need both of these approaches (the plugin itself doesn't appear to be used anywhere).

            Show
            Parejkoj John Parejko added a comment - While reviewing fgcm, I discovered SingleFrameJacobianPlugin in meas_base plugins.py . It uses linearizePixelToSky().determinant (my version 2 above), so it should be very close to the pixel area calculation implemented here. However, it does result in the question of whether we need both of these approaches (the plugin itself doesn't appear to be used anywhere).
            Hide
            Parejkoj John Parejko added a comment -

            Thanks for the review.

            Merged and done.

            Show
            Parejkoj John Parejko added a comment - Thanks for the review. Merged and done.
            Hide
            price Paul Price added a comment -

            Reviews completed on the GitHub PRs. Minor comments in afw that should be addressed before merging. I don't understand how the changes in jointcal relate, since they don't use the new functionality in afw, but you say it's useful so I won't stand in your way; nevertheless, the commit messages should be fixed.

            Show
            price Paul Price added a comment - Reviews completed on the GitHub PRs. Minor comments in afw that should be addressed before merging. I don't understand how the changes in jointcal relate, since they don't use the new functionality in afw, but you say it's useful so I won't stand in your way; nevertheless, the commit messages should be fixed.
            Hide
            Parejkoj John Parejko added a comment -

            Paul Price: do you mind taking on this medium sized review (~350 new lines)?

            The handful of new lines in jointcal were from my initial testing, but I figured they were useful enough to be added to the python layer.

            If Jira doesn't pick up the afw PR, it's here: https://github.com/lsst/afw/pull/411

            Show
            Parejkoj John Parejko added a comment - Paul Price : do you mind taking on this medium sized review (~350 new lines)? The handful of new lines in jointcal were from my initial testing, but I figured they were useful enough to be added to the python layer. If Jira doesn't pick up the afw PR, it's here: https://github.com/lsst/afw/pull/411

              People

              • Assignee:
                Parejkoj John Parejko
                Reporter:
                jbosch Jim Bosch
                Reviewers:
                Paul Price
                Watchers:
                Eli Rykoff, Jim Bosch, John Parejko, John Swinbank, Paul Price, Russell Owen
              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Summary Panel