-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot run pyvista examples on npps0 #76
Comments
I can confirm that I can reproduce the issue. |
@plexoos I think that I found the solution to the issue. Need to use the vtk os-mesa variant. See pyvista/pyvista#4024
After this, the command runs without error.
Can you please verify? |
Can confirm that I can run this example and save the image output to pdf
|
Thank you Sakib! I followed your instructions and the command indeed ran without errors on npps0. On my laptop, however, when I run the same pyvista example I get an interactive window displaying some 3D capabilities. I wonder if there is something else is missing from our setup on npps0... |
@dmitri: Is that the 3D window you mentioned? |
If it is interactive and the object can be rotated with your mouse pointer then yes. Here is the command I use |
@plexoos It actually worked, i.e. I can rotate the puppy. I just installed pyvista into a fresh virtual env on npps0, and am running a ssh session remotely from my workstation at home, with X11 forwarding. |
Great! It means the problem is on my side. Could you freeze your virtual environment and share it with me so I can reproduce? Also, if there is anything else you think I need to adjust in my environment please let me know. |
@plexoos I really did nothing special, just "python -m venv blah",with the standard Python 3.12 as installed on our node, then "pip install pyvista". If there is anything suspect it's the pipeline for graphics from npps0 to your screen (not a strong theory but still). I'm on mobaXterm. Are you sure you have the X11 forwarding in place? |
AFAICT, my X11 forwarding works and I can open graphical windows (xclock, xeyes) on my laptop from npps0. However, when I do the test as in the original post I get nothing and the command just exits. @rahmans1 does it open a window for you on your remote terminal? @buddhasystem there must be something different in your environment on npps0 as both Sakib and I see the errors as reported but in your case it simply works with the default vtk |
Well, since I did this with the virtual env, and I don't have extras, it really boils down to something external to the host, npps0. But there are more mysteries -- when running examples on my local WSL2 machine, I see black screen in the pyvista GUI. When I kill the app the true picture appears briefly. I tried my GL trick I use with Geant, it didn't help. Unfortunately, there is something arcane in how pyvista works wrt drivers. |
Well, if you claim that the remote setup on npps0 is identical for us then what difference on our local machines we should look into? It sounds like you are on a windows machine whereas I am on a mac. Do you have a mac to test this by any chance? Doesn't the rendering happen on the remote machine anyway? I'd still love Sakib to confirm whether the test opens a remote window for him. BTW, the test runs locally on my i9 mac without any issues out of the box. |
The issue may be quite complex i.e. qt and vtk version related: pyvista/pyvistaqt#54 |
@plexoos ...and I also tested on a standalone Debian machine with an older NVIdia GPU where things "just work". So in the end, we are looking at some combinatorial situation with vtk, qt, pyvista and perhaps actual drivers. Do we like this platform? |
My assumption is that we use the same libraries on the same machine with the same drivers... Isn't it the case? |
Can confirm that it doesn't open an interactive window when I remote login from Mac. Has to be something to do with port-forwarding and not intrinsic to this case. For example, even this does not open a window for me.
|
I also cannot open x windows when using the default python on npps0:
However, the official python image works just fine
From that I conclude that there is something wrong with how python was installed on npps0 |
@plexoos No, there is nothing wrong with Python on npps0. It's the qt bit that was missing, and I suspect some incongruity with the Qt explains the pyvista problem. Case in point, this matplotlib example of yours works affter "pip install PyQt5". |
Just to add that the airplane example works 100% for me on npps0: |
...and yet, this forces us to install indirect dependencies like pyqt. What else do we need to install to make the pyvista example work? |
please provide complete instructions so we can also verify that |
Nope, same error for me
|
Looks like one need to enable GLX on the MacOs X-window side
With this the pyvista test command at least tries to open a local window but it is black and disappears right away. The new error message is:
|
@plexoos Can we try using a different platform plugin than what it defaults to. Check out this issue. |
Sure, I am open to any solution. Have you tried to use xvfb? |
@plexoos I don't have permission to install xvfb on npps0. |
hm... looks like you are in the |
@plexoos I would really like to understand what we are pursuing here. If it's just validation of the Opticks tests, would an export to PDF work as a reasonable approximation? Unless this "pyvista" is a part of our final product, there is no sense in trying to make this finicky package work for all cases. Alternatively, I can lend you an extra desktop for your office where you can visualize with pyvista -- if it's about going through the opticks example, it should do the trick. |
This is becoming a time sink. |
If you have better suggestions how to visualize the results from an opticks tests, please let us know. pyvista was suggested by the author, see https://groups.io/g/opticks/message/526 |
@plexoos I made a suggestion which is workable, use any computer other than Mac to visualize it. This is the most expedient solution. |
I am closing this issue as we have found a workaround for Mac users to view graphical windows (with 3D OpenGL graphics) by utilizing remote desktops such as tigervnc. It appears the Windows users may have better luck opening such windows directly from a remote GPU host. |
The error message is:
To reproduce on npps0 run:
The libGL errors disappear if the following environment variable is set:
The text was updated successfully, but these errors were encountered: