Uploaded image for project: 'Request For Comments'
  1. Request For Comments
  2. RFC-466

Change SpherePoint.getVector to return a sphgeom UnitVector3d

    Details

    • Type: RFC
    • Status: Implemented
    • Resolution: Done
    • Component/s: DM
    • Labels:
      None

      Description

      I would like to change SpherePoint.getVector() to return a sphgeom UnitVector3d instead of a lsst::afw::geom::Point3D. Conceptually this change makes sense because it is a unit vector that is being returned.

      Pragmatically it will help us replace geom with sphgeom as part of implementing RFC-460.

      The only usage of geom in our stack is for creating convex polygons by calling convexHull. This function exists in both geom and sphgeom, but the sphgeom version is written in C++ and so is picky about its inputs: it wants a std::vector<UnitVector3d>.

      This change will not be very disruptive.

      Existing Python code will need no changes because in all cases the vector simply needs to be an indexable sequence of 3 floats (even when calling the geom version of convexHull).

      There are a few C++ files that will need to be changed, but the changes are very simple and, in at least one case, result in simpler code.

        Attachments

          Container Issues

            Issue Links

              Activity

                People

                • Assignee:
                  rowen Russell Owen
                  Reporter:
                  rowen Russell Owen
                  Watchers:
                  Jim Bosch, Krzysztof Findeisen, Russell Owen, Tim Jenness
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Planned End:

                    Summary Panel