hvplot.image(rasterize=True) not working with holoviews>=1.13.4
See original GitHub issueAfter upgrading holoviews from 1.13.3 to 1.13.4 hvplot.xarray.image(rasterize=True, dynamic=True)
no longer works. displayed image resolution is not updated upon zooming into an image plot
ALL software version info
(linux or macos)
conda create -n holoviews python=3.7 holoviews xarray rasterio hvplot datashader jupyter
holoviews 1.13.4 pyh9f0ad1d_0 conda-forge
bokeh 2.2.2 py37hc8dfbb8_0 conda-forge
hvplot 0.6.0 pyh9f0ad1d_0 conda-forge
datashader 0.11.1 pyh9f0ad1d_0 conda-forge
Description of expected behavior and the observed behavior
Zooming into a subregion of an image with raster with rasterize=True, dynamic=True
should update displayed resolution
Complete, minimal, self-contained example code that reproduces the issue
This uses an example image from AWS public data
import os
import xarray as xr
import hvplot.xarray
os.environ['GDAL_DISABLE_READDIR_ON_OPEN']='EMPTY_DIR'
os.environ['AWS_NO_SIGN_REQUEST']='YES'
href = 's3://sentinel-s1-rtc-indigo/tiles/RTC/1/IW/10/T/ET/2020/S1B_20200106_10TET_ASC/Gamma0_VV.tif'
da = xr.open_rasterio(href)
da.hvplot.image(rasterize=True, dynamic=True, clim=(0,0.4), aspect='equal', frame_width=600, cmap='gray')
Stack traceback and/or browser JavaScript console output
No tracebacks, not sure how to output console messages.
downgrading to holoviews 1.13.3
things work as expected. cc @rsignell-usgs
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
hvplot.image(rasterize=True) not working with holoviews ...
After upgrading holoviews from 1.13.3 to 1.13.4 hvplot.xarray.image(rasterize=True, dynamic=True) no longer works. displayed image ...
Read more >Geographic Data — hvPlot 0.8.2 documentation
import xarray as xr import hvplot.pandas # noqa import hvplot.xarray # noqa ... to project the data before rasterizing it, e.g. to address...
Read more >Customization — hvPlot 0.8.2 documentation
The hvPlot API is closely modeled on the pandas plot API but also diverges ... Responsive mode will only work if at least...
Read more >hvPlot — hvPlot 0.8.2 documentation
A familiar and high-level API for data exploration and visualization. hvPlot diagram .hvplot() is a powerful and interactive Pandas-like .plot() API ...
Read more >Fix range of colormap for hvplot.image with rasterize=True
Hi all, I'm trying to display some discrete raster data. The values are 0 - 9, and represent the land use classification for...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Fixed in https://github.com/holoviz/holoviews/pull/4654, will release 1.13.5 tomorrow.
Good question. If you have any influence, try to get @jsignell to come back to the project so that things will run more smoothly. 😃 Meanwhile, I can’t comment on what this particular issue indicates about stability, since I can’t see what the problem could be.
I don’t have rasterio in my usual environment but this problem appears to be reproducible with one of the stock examples:
Here the image updates with either
rasterize
ordatashade
for hv=1.13.3, but for hv=1.13.4 or hv=1.14.0a2, it only updates fordatashade=True
, notrasterize=True
. The same happens forrasterize(air2d.hvplot.image(width=400))
, so I’ve moved it from hvPlot to HoloViews, where I’m assuming the problem originates (and also since it depends on the hv version and not the hvPlot version).I didn’t see any relevant warnings or errors on the console. @philippjfr ?