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

Allow configuring more statistical options for assembleCoadds.py

    Details

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

      Description

      The assembleCoadd.py task has a configuration option doSigmaClip which chooses between MEAN and MEANCLIP. Please replace this with an option to specify the algorithm to be used. Note that afwMath.stringToStatisticsProperty can be used to convert a string to an enum value. In particular, this would allow me to specify a MEDIAN stack if desired (e.g. to make pretty RGB images)

        Attachments

          Issue Links

            Activity

            Hide
            rhl Robert Lupton added a comment -

            This is really an HSC request, but if possible we should do it on the LSST side and cherry pick to HSC not vice-versa.

            Show
            rhl Robert Lupton added a comment - This is really an HSC request, but if possible we should do it on the LSST side and cherry pick to HSC not vice-versa.
            Hide
            yusra Yusra AlSayyad added a comment -

            Bob, do you have time to review this? Allowing all statistics on coadds required removing the doClip argument to `assemble`, and hence some changes to SafeClipAssembleCoadd. I sought to imitate the original behavior of SafeClipAssemble:

            • ignore doSigmaClip
            • allow only "MEAN" for the final coadd
            • pass configs `sigmaClip` and `clipIter` to the child task that creates the MEANCLIP'ped coadd.

            One interesting discovery was that we pass the coadd variance plane as the weighting to `coaddUtils.setCoaddEdgeBits`. Most stats, such as NPOINT, SUM, don't have an uncertainty computed and the variance is 0. If a stat without an uncertainty is requested and doInterp=True, the whole image gets replaced with the median value. I chose to validate that doInterp=False when those stats are chosen, rather than reformulate how we set the NO_DATA bits for pixels zero variance.

            Show
            yusra Yusra AlSayyad added a comment - Bob, do you have time to review this? Allowing all statistics on coadds required removing the doClip argument to `assemble`, and hence some changes to SafeClipAssembleCoadd. I sought to imitate the original behavior of SafeClipAssemble: ignore doSigmaClip allow only "MEAN" for the final coadd pass configs `sigmaClip` and `clipIter` to the child task that creates the MEANCLIP'ped coadd. One interesting discovery was that we pass the coadd variance plane as the weighting to `coaddUtils.setCoaddEdgeBits`. Most stats, such as NPOINT, SUM, don't have an uncertainty computed and the variance is 0. If a stat without an uncertainty is requested and doInterp=True, the whole image gets replaced with the median value. I chose to validate that doInterp=False when those stats are chosen, rather than reformulate how we set the NO_DATA bits for pixels zero variance.

              People

              • Assignee:
                yusra Yusra AlSayyad
                Reporter:
                rhl Robert Lupton
                Reviewers:
                Bob Armstrong
                Watchers:
                Bob Armstrong, Robert Lupton, Yusra AlSayyad
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Summary Panel