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

Many refraction functions are documented to return float but return Quantity

    Details

      Description

      The new refraction code in afw has many functions that claim to return float, but actually return astropy Quantity.

      This has two issues:

      • The code in refraction is hard to understand because atmosTerm1 and 2 have units of Pa / mbar but they are supposed to be dimensionless. It's hard to see how one gets radians from that. For clarity I think some values should be converted to floats instead of being left as Quantities.
      • The documented return value is wrong for many of the functions.

      I stumbled across this while implementing DM-14429 and had some trouble figuring out what was going on.

        Attachments

          Activity

          Hide
          sullivan Ian Sullivan added a comment -

          Thanks for catching the bug.

          Show
          sullivan Ian Sullivan added a comment - Thanks for catching the bug.
          Hide
          rowen Russell Owen added a comment -

          a few comments on github but overall looks good

          Show
          rowen Russell Owen added a comment - a few comments on github but overall looks good

            People

            • Assignee:
              sullivan Ian Sullivan
              Reporter:
              rowen Russell Owen
              Reviewers:
              Russell Owen
              Watchers:
              Ian Sullivan, Russell Owen
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Summary Panel