I can't get any HoloViews graphics to display in any Google Colabs notebook.
For example even the simple Bokeh example right out fo the HoloViews introduction
points = hv.Points(np.random.randn(500,2))
points.hist(num_bins=51, dimension=['x','y'])
fails to show anything, without any error being reported, while the same code (and all example code from HoloViews) works fine in local Jupyter notebooks.
If I download the Colabs notebook locally and open it, I see the following where I say nothing for output in Colabs:
No (safe) renderer could be found for output. It has the following MIME types: application/javascript, application/vnd.bokehjs_load.v0+json
How do I get Bokeh HoloViews to display in Google Colabs notebooks?
See https://github.com/pyviz/holoviews/issues/3551 . Colaboratory has some serious limitations on how it handles notebooks, and for now you have to do this once:
import os, holoviews as hv
os.environ['HV_DOC_HTML'] = 'true'
Then for every single cell with a plot in it you have to re-load the JS:
hv.extension('bokeh')
hv.Curve([1, 2, 3])
It would be great if Google could fix that, as it's unworkable in my opinion.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With