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

Add lazy-product BoundedField class

    XMLWordPrintable

    Details

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

      Description

      Eli Rykoff would like a BoundedField implementation that simply multiplies two other BoundedFields, and I've long said I'll add it as soon as it becomes a pressing need - that kind of composition is something I've always had in mind for BoundedField but hadn't prioritized.

       

        Attachments

          Issue Links

            Activity

            Hide
            erykoff Eli Rykoff added a comment -

            Ah, thanks, I'll look at that. I think for purposes of applying a ChebyshevBoundedField the appropriate default scaling would be what's in the center of the bounding box (in fact, this is what FGCM does internally). So this would be one way for a ProductBoundedField to implement a "mean" – take the product at the center of the bbox. But I can do this within fgcmcal by hand, as you point out. I'll look into that.
            The place I'm creating this is within fgcmcal. Right now, within fgcm I multiply multiple chebyshev fields together (representing the overall illumination correction and the per-visit gray correction) but it would be more correct to take both and have the stack multiply them together (plus the upcoming PixelAreaBoundedField.
            But this other constructor is probably exactly what I need to make use of the ProductBoundedField.

            Show
            erykoff Eli Rykoff added a comment - Ah, thanks, I'll look at that. I think for purposes of applying a ChebyshevBoundedField the appropriate default scaling would be what's in the center of the bounding box (in fact, this is what FGCM does internally). So this would be one way for a ProductBoundedField to implement a "mean" – take the product at the center of the bbox. But I can do this within fgcmcal by hand, as you point out. I'll look into that. The place I'm creating this is within fgcmcal . Right now, within fgcm I multiply multiple chebyshev fields together (representing the overall illumination correction and the per-visit gray correction) but it would be more correct to take both and have the stack multiply them together (plus the upcoming PixelAreaBoundedField . But this other constructor is probably exactly what I need to make use of the ProductBoundedField .
            Hide
            erykoff Eli Rykoff added a comment -

            Indeed! This seems to do exactly what I need it to do with that tip. Though I'm not sure how to document this correctly.

            Show
            erykoff Eli Rykoff added a comment - Indeed! This seems to do exactly what I need it to do with that tip. Though I'm not sure how to document this correctly.
            Hide
            erykoff Eli Rykoff added a comment -

            See comments on PR.

            Show
            erykoff Eli Rykoff added a comment - See comments on PR.
            Hide
            Parejkoj John Parejko added a comment -

            How to document what?

            Show
            Parejkoj John Parejko added a comment - How to document what?
            Hide
            erykoff Eli Rykoff added a comment -

            If you use a ProductBoundedField in place of a ChebyshevBoundedField to construct a PhotoCalib, you get a NotImplementedError or something like that. But it turns out you can skip over that by explicitly initializing with the mean of your field (however you choose to compute it). I'm not sure how to communicate that other than through a thread on a Jira ticket...

            Show
            erykoff Eli Rykoff added a comment - If you use a ProductBoundedField in place of a ChebyshevBoundedField to construct a PhotoCalib , you get a NotImplementedError or something like that. But it turns out you can skip over that by explicitly initializing with the mean of your field (however you choose to compute it). I'm not sure how to communicate that other than through a thread on a Jira ticket...

              People

              Assignee:
              jbosch Jim Bosch
              Reporter:
              jbosch Jim Bosch
              Reviewers:
              Eli Rykoff
              Watchers:
              Eli Rykoff, Jim Bosch, John Parejko
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: