skoch9 / meshplot

Plot 3D triangle meshes
GNU General Public License v3.0
142 stars 35 forks source link

meshplot.plot function not displaying mesh #13

Closed SelvamArul closed 4 years ago

SelvamArul commented 4 years ago

When I call meshplot.plot function, instead of the mesh being displayed, I get just the following text displayed. Renderer(camera=PerspectiveCamera(children=(DirectionalLight(color='white', intensity=0.6, position=(-0.016860… A screenshot of demonstrating this issue:

image

I am running jupyter lab version 1.1.4

I am not sure what other information regarding my system setup would be helpful. If needed, I will be glad to provide it.

skoch9 commented 4 years ago

Hi, you need to activate the front-end extension for pythreejs as described here. Either for the notebooks or jupyterlab.

SelvamArul commented 4 years ago

Thanks for the reply.

yw5aj commented 3 years ago

Sorry for bothering - I was using Jupyter Lab 2.2.6 and I see the same problem. I tried jupyter labextension install jupyter-threejs but the problem still persists. Did anyone also run into this?

florentjousse commented 3 years ago

Same issue here @yw5aj did you find a solution ?

skoch9 commented 3 years ago

@yw5aj @cryckx Did you install the labextension for ipywidgets, as described here: https://ipywidgets.readthedocs.io/en/stable/user_install.html

surya-1729 commented 2 years ago

I am using Jupyter Notebook 6.1.4 in a Conda environment:

import igl import meshplot as mp import numpy as np

v, f = igl.read_triangle_mesh("./earth.ply") k = igl.gaussian_curvature(v, f) mp.plot(v, f, k, return_plot = True)

OUTPUT: <meshplot.Viewer.Viewer at 0x1b53eb03fa0>

it is not displaying the mesh. it just outputs the location it stored in memory. Please help me.

stigersh commented 2 years ago

I am using Jupyter Notebook 6.1.4 in a Conda environment:

import igl import meshplot as mp import numpy as np

v, f = igl.read_triangle_mesh("./earth.ply") k = igl.gaussian_curvature(v, f) mp.plot(v, f, k, return_plot = True)

OUTPUT: <meshplot.Viewer.Viewer at 0x1b53eb03fa0>

it is not displaying the mesh. it just outputs the location it stored in memory. Please help me.

I still have this issue, nothing above worked.. Any ideas please..?

ziyi-zhang commented 2 years ago

Hi @stigersh, this link could be useful. You could also try the html approach.

If you are using VSCode, i recently ran into a very tricky case. Try to click the "..." in the output cell, and "change presentation", if you have a "Jupyter Ipywidget renderer" choice, very likely the plot is already rendered. But your ipywidget is showing nothing, not even a blank window. In my case, i uninstalled the jupyter renderer extensions VSCode suggests and it works again.

stigersh commented 1 year ago

OMG the html approach worked! Thank you so much! btw - it works for jupyter notebook only, for jupyter lab 80% of the screen gets gray immediately after..

SerinaSerena commented 1 year ago

Hi @stigersh, this link could be useful. You could also try the html approach.

If you are using VSCode, i recently ran into a very tricky case. Try to click the "..." in the output cell, and "change presentation", if you have a "Jupyter Ipywidget renderer" choice, very likely the plot is already rendered. But your ipywidget is showing nothing, not even a blank window. In my case, i uninstalled the jupyter renderer extensions VSCode suggests and it works again.

It's not work for me. Please help me. vertices,faces,, = marching_cubes(predImg,method='lewiner') mp.jupyter() mp.plot(vertices, faces, return_plot=True)

Output <meshplot.Viewer.Viewer at 0x22281d74ee0>