This is to capture the work effort in testing the performance of FIrelfy image display in NB deployed at Kubernetes commons in NCSA.
The work and suggestions are here:
The performance study was prompted by demos of the qa_explorer notebook at the DMLT, with the ginga and the Firefly backends. Using the lsst-lspdev notebook environment and Firefly server, I checked the performance of Firefly panning at zoom level=1 on a 4k by 4k image. Panning to a new position typically took 5-10 seconds but occasionally as long as 20. There is a strong caching effect when panning to a position previously visited, as then the pan typically took between 0.2 and 1 second.
With assistance from Simon, I was able to install the qa_explorer notebook and operate its interactive feature of selecting a star or galaxy from a scatter plot, and zooming and panning to its location on the closest coadd image. The ginga backend typically took a few to 5 seconds to display the desired location. The Firefly backend typically took 15-20 seconds for the display, zoom and pan.
The Firefly display backend always shows the entire image fit to a frame, before zooming and panning to the desired location. Performance could be improved by batching together the initial display, zoom and pan. Alternatively, if DAX imageserv were available it would be more efficient to make a cutout at the desired location and then display it — a solution we used in our forced photometry demo on the PDAC.
The show_fits method of FireflyClient will take an initial zoom level as an argument. For the qa_explorer application, it would be better to set the initial zoom level to 1, to skip the time-consuming display of the entire image. Currently the afw.display abstraction doesn’t support this — it was developed for ds9 where zooming is easy. The mtv method of afw.display could be modified to take optional arguments like zoom level and a position on which to center the display.