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

Replace the lsst.geom package with components from lsst.afw.geom


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


      The lsst.geom package was superseded by a C++ implementation in lsst.sphgeom quite a while ago, and once RFC-458 is implemented, I believe no stack code will be using it.  We should then rename it to lsst-dm/legacy-geom and remove it from lsst_distrib.

      That frees up a high-value package name, and I'd like to reuse it as the new home of much of the current content of lsst.afw.geom.  Currently, lsst.afw.geom contains both:

      • low-level, very-broadly-used code with very few dependencies (this is what I'd like to move out of afw)
      • high-level, moderately-broadly-used code with many dependencies

      That causes two problems:

      • We have circular dependencies between Python sub-packages within afw; these are currently worked-around with a rather fragile system that depends on imports appearing in a particular order (which we can frequently, but not always, guarantee).
      • Some packages that shouldn't have to depend on afw currently do.

      Unlike RFC-430, which addresses these problems as well a few others, the changes proposed here are easy (it's mostly just copying files from afw to a new package) and entirely backwards compatible: we will add typedefs and import statements to afw to make sure all symbols remain accessible from lsst.afw.geom.  Whether to deprecate the old names and attempt to convert old code to use the new names is left to a future RFC.

      The symbols we plan to move are:

      • Point<T,N>
      • Extent<T,N>
      • CoordinateExpr<N>
      • CoordinateBase (CRTP base class of Point, Extent, and CoordinateExpr; should be considered an implementation detail but actually hiding it is out of scope for this RFC).
      • Box2I
      • Box2D
      • LinearTransform
      • AffineTransform
      • Angle
      • SpherePoint

      This should allow the new lsst.geom to depend on just lsst.utils, eigen, and ndarray.  Even those dependencies are weak and could probably be avoided with some very minor API changes, but that is also considered out of scope for this RFC.



          Issue Links



              • Assignee:
                jbosch Jim Bosch
                jbosch Jim Bosch
                Jim Bosch, John Parejko, John Swinbank, Kian-Tat Lim, Krzysztof Findeisen, Pim Schellart [X] (Inactive), Tim Jenness
              • Votes:
                0 Vote for this issue
                7 Start watching this issue


                • Created:
                  Planned End:

                  Summary Panel