I'm trying to replicate this. The below works for me. Can you provide instructions for reproducing your error?
conda create --prefix threejstest notebook python ipywidgets pythreejs source activate ./threejstest jupyter nbextension enable --py --sys-prefix widgetsnbextension jupyter nbextension enable --py --sys-prefix pythreejs source activate ./threejstest kernelname=`echo $CONDA_DEFAULT_ENV | sed s:/:_:g` ipython kernel install --name $kernelname --display-name conda-$kernelname --sys-prefix jupyter notebook And then I opened the pythreejs example file with the environment kernel and the first example executed just fine. Looking at the errors you show, it seems that you have widgets installed. It also seems that you have pythreejs installed. I would check to see if the pythreejs extension is enabled: jupyter nbextension enable --py --sys-prefix pythreejs And I would also check to see if there are any errors in the javascript console. Thanks, Jason On Fri, Jun 30, 2017 at 2:42 AM <[email protected]> wrote: > I am having the same problem. > > Simple sphere and text > <http://localhost:8888/notebooks/ScratchNotebooks/pythreejs_examples.ipynb#Simple-sphere-and-text> > In [2]: > > ball = Mesh(geometry=SphereGeometry(radius=1), > > material=LambertMaterial(color='red'), > > position=[2, 1, 0]) > > > > scene = Scene(children=[ball, AmbientLight(color='#777777')]) > > > > c = PerspectiveCamera(position=[0, 5, 5], up=[0, 0, 1], > > children=[DirectionalLight(color='white', > > position=[3, 5, 1], > > intensity=0.5)]) > > renderer = Renderer(camera=c, > > scene=scene, > > controls=[OrbitControls(controlling=c)]) > > display(renderer) > > × > Could not create model: > Model name RendererModel > Model module jupyter-threejs > Model module version * > Script error for "jupyter-threejs" > http://requirejs.org/docs/errors.html#scripterror > > On Friday, 12 May 2017 16:09:44 UTC+8, Henri Girard wrote: >> >> >> >> Le jeudi 4 mai 2017 10:47:30 UTC+2, Henri Girard a écrit : >>> >>> Hi, >>> Jupyter nbextension works fine : >>> jupyter nbextension enable --py --sys-prefix widgetsnbextension >>> Apparently that's the only one : >>> After installing pythreejs with pip successfully this command failed : >>> jupyter nbextension enable --py --sys-prefix pythreejs >>> >>> return __import__(parts[0]) >>> ImportError: No module named pythreejs >>> >>> I tried to do it with others : k3d >>> >>> Only flatsurf succeeded >>> >>> Any help ? >>> >>> Regards >>> Henri >>> >>> Yes ... Sorry for double mail >>> >> >> >> Installing /home/pi/sage/pythreejs/pythreejs/static -> jupyter-threejs >> Symlinking: /home/pi/sage/local/share/jupyter/nbextensions/jupyter-threejs >> -> /home/pi/sage/pythreejs/pythreejs/static >> - Validating: OK >> >> To initialize this nbextension in the browser every time the notebook >> (or other app) loads: >> >> jupyter nbextension enable pythreejs --py --sys-prefix >> >> Enabling notebook extension jupyter-threejs/extension... >> - Validating: OK >> ball = Mesh(geometry=SphereGeometry(radius=1), >> material=LambertMaterial(color='red'), >> position=[2, 1, 0]) >> >> scene = Scene(children=[ball, AmbientLight(color='#777777')]) >> >> c = PerspectiveCamera(position=[0, 5, 5], up=[0, 0, 1], >> children=[DirectionalLight(color='white', >> position=[3, 5, 1], >> intensity=0.5)]) >> renderer = Renderer(camera=c, >> scene=scene, >> controls=[OrbitControls(controlling=c)]) >> display(renderer) >> Could not create model: >> >> >> >> >> >> >> Model name RendererModel >> Model module jupyter-threejs >> Model module version 0.3.0-alpha.0 >> Script error for "jupyter-threejs" >> http://requirejs.org/docs/errors.html#scripterror >> >> >> >> >> >> >> >> > -- > You received this message because you are subscribed to the Google Groups > "Project Jupyter" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/jupyter/ecc0f2a3-702e-4b3c-91b9-3e4f617c71de%40googlegroups.com > <https://groups.google.com/d/msgid/jupyter/ecc0f2a3-702e-4b3c-91b9-3e4f617c71de%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Project Jupyter" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jupyter/CAPDWZHy5YNo6andyJaitnrdH1oyLSrpq0dL8BVtK953p_A5Qog%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
