Closed brendancol closed 4 years ago
@philippjfr This was an issue that I think might be already resolved in a holoviews branch. The symptom here was that the datashaded plots wouldn't redraw after zoom.
more specifically, only the first tab redraws, the others don't
@dharhas As of version a4b6758d6bff454490c9839dc17a8870cf03c914 Skyplots are working (I think) as expected. Follows a series of screenshots where two plots have their datapoints moved in the canvas.
init:
move first tab/plot
move second tab/plot
reset first tab/plot
@philippjfr just to return to this, as I'm now able to check things out here-- this is still an open issue, in that the datashaded maps on the linked tabs do not resample upon zoom.
Any suggestions? Clue for me is that the console displays the following repeatedly:
Parameter name clashes for keys {'y_range', 'x_range'}
Perhaps in the different tabs we just have to rename those dimensions somehow?
I can't actually reproduce the issue you're describing so I'd have to know more about your environment.
Parameter name clashes for keys {'y_range', 'x_range'}
This is annoying but does not indicate an actual issue so is likely unrelated.
(lsst-scipipe) [tmorton@lsst-dev01 ~]$ panel --version
panel 0.7.0.post7+g088e33c
and I've just pip-installed hv, bokeh, datashader etc fresh.
Haven't tried to make a minimal example yet, so I'll have to dig into what's happening in the code a bit.
I can merge @timothydmorton latest PR in and make a new test dataset, so we can test this locally without being dependent on the LSST cluster stack (which is a kludgy mix of conda & pip). I am seeing this too but I'm not currently sure if its only cluster deployments or local as well.
@philippjfr I've updated master to work on local test datasets. The download.sh contains links to two test datasets one around 750mb and the other around 6gb as tar.gz files. They need to be untarred after download. I'm seeing the same behavior with only the first tab reshading/resampling in a clean local env with latest panel master and the smaller test dataset. Haven't checked the larger but I assume it will be the same.
@philippjfr here's a minimal demo:
import holoviews as hv
import numpy as np
import panel as pn
import pandas as pd
from holoviews.operation.datashader import datashade
import datashader as ds
pn.extension()
N = 1000000
x = np.random.random(N)
y = np.random.random(N)
dset = hv.Dataset(pd.DataFrame({'x': x,
'y': y,
'z1': x*y,
'z2': -x*y}))
pts1 = hv.Points(dset, kdims=['x', 'y'], vdims=['z1'])
pts2 = hv.Points(dset, kdims=['x', 'y'], vdims=['z2'])
opts = dict(height=800, width=800)
plot1 = datashade(pts1, aggregator=ds.mean('z1')).options(**opts)
plot2 = datashade(pts2, aggregator=ds.mean('z2')).options(**opts)
pn.Tabs(*[('z1', pn.panel(plot1)), ('z2', pn.panel(plot2))])
For me, only the first tab re-renders the datashaded image, running in a fresh env with latest master of panel. Is this an issue for hv, datashader, or panel?
As far as I can tell this is resolved when using latest Panel/HoloViews.
The Tabs are created here in
lsst_dashboard/gui.py::linked_tab_plots(self)
.