Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Class OutputModel not found in module jupyter-js-widgets #1183
I'm actually do not understand how brand new "rendering widgets in nbviewer" is expected to work, but I found, how it is not working.
I created a simple demo plotting a graph with
The code is the following:
import ipywidgets as widgets import matplotlib.pyplot as plt %matplotlib inline import numpy as np @widgets.interact(a=widgets.FloatSlider(min=0, max=10, value=1, step=1e-3), b=widgets.FloatSlider(min=0, max=10, value=1, step=1e-3)) def plot_sin(a, b): x = np.linspace(-4,4,300) plt.ylim(-2,2) plt.plot(np.sin(a*x)*b) plt.show()
Then I selected Widgets → Save Notebook with Widgets menu item, then uploaded ipynb-file to the server, then opened with nbviewer, see the link.
The actual sliders are rendered, but the output is not and I have the following error message instead of rendered content:
Actually, I didn't expect that my pictures will be shown correctly as they are dynamically created (depending on the positions of the sliders) on python side and nbviewer does not execute Python code. (The behaviour I theoretically might expect is that Jupyter tries to generate all possible combinations of pictures and instruct nbviewer to show the correct one depending on sliders, but it is obviously very time and space-consuming thing, especially if several widgets presented.) Anyway, currently the error message seem to be unclear for me. Is it a bug? A feature?
+1, having the same issue with