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

Migrate meas_algorithms to modern afwDisplay

    Details

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

      Description

      meas_algorithms contains several (e.g. #1, #2, there are more) explicit uses of lsst.afw.display.ds9. These should be replaced by calls to the generic (backend-independent) lsst.afw.display system.

        Attachments

          Issue Links

            Activity

            Hide
            pgee Perry Gee added a comment -

            Robert Lupton Robert, are you the expert on display?

            There is a "global fig" followed by a line "if not fig" in objectSizeStarSelector.py, but fig is not defined prior to this line, so an exception occurs. I can use a "try/except NameError" to test that fig is defined, or I could define "fig = None" outside local scope, unless you can suggest another solution which you like better.

            Also, the name "fig" is used locally in another routine. I assume this is really a separate usage?

            Show
            pgee Perry Gee added a comment - Robert Lupton Robert, are you the expert on display? There is a "global fig" followed by a line "if not fig" in objectSizeStarSelector.py, but fig is not defined prior to this line, so an exception occurs. I can use a "try/except NameError" to test that fig is defined, or I could define "fig = None" outside local scope, unless you can suggest another solution which you like better. Also, the name "fig" is used locally in another routine. I assume this is really a separate usage?
            Hide
            rhl Robert Lupton added a comment -

            Merlin just ran into something similar. I think someone probably removed a block at global scope:

            try:
               fig
            except NameError:
               fig = None
            

            Show
            rhl Robert Lupton added a comment - Merlin just ran into something similar. I think someone probably removed a block at global scope: try: fig except NameError: fig = None
            Hide
            pgee Perry Gee added a comment -

            Yes, that is how I solved it. I just wanted to be sure that there wasn't some other intention to share this global with other routines outside of plot().

            Show
            pgee Perry Gee added a comment - Yes, that is how I solved it. I just wanted to be sure that there wasn't some other intention to share this global with other routines outside of plot().
            Hide
            pgee Perry Gee added a comment -

            Note the changes required to https://developer.lsst.io/coding/debug.html. If you run from a cmdLineTask, there is no -d option, and debug.py must be in your PYTHONPATH.

            Show
            pgee Perry Gee added a comment - Note the changes required to https://developer.lsst.io/coding/debug.html . If you run from a cmdLineTask, there is no -d option, and debug.py must be in your PYTHONPATH.
            Hide
            wmwood-vasey Michael Wood-Vasey added a comment -

            The code changes look fine.
            Rebase to current master (sorry for the extensive delay in reviewing this).

            I've spent 3 hours trying to get the display itself tested, but have been unable to do so. DM-11125 is just one symptom.

            I suggest the best way forward at this point is to merge this.

            Show
            wmwood-vasey Michael Wood-Vasey added a comment - The code changes look fine. Rebase to current master (sorry for the extensive delay in reviewing this). I've spent 3 hours trying to get the display itself tested, but have been unable to do so. DM-11125 is just one symptom. I suggest the best way forward at this point is to merge this.
            Hide
            swinbank John Swinbank added a comment -

            Done on DM-13432.

            Show
            swinbank John Swinbank added a comment - Done on DM-13432 .

              People

              • Assignee:
                pgee Perry Gee
                Reporter:
                swinbank John Swinbank
                Reviewers:
                Michael Wood-Vasey
                Watchers:
                John Swinbank, Michael Wood-Vasey, Perry Gee, Robert Lupton
              • Votes:
                1 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Summary Panel