pysph icon indicating copy to clipboard operation
pysph copied to clipboard

Error trying to view pysph examples (windows 10, anaconda, python 3.7.4)

Open githubrho opened this issue 4 years ago • 5 comments

@prabhuramachandran

I get

RuntimeError: No pyface.toolkits plugin could be loaded for qt4

pyqt is installed (according to anaconda navigator). Should PyQT be downgraded to PyQT4?

githubrho avatar Jul 03 '21 19:07 githubrho

Sorry this is an issue with bitrot on the pysph repo that I will fix ASAP -- the ETS_TOOLKIT used to be qt4 now it is qt, for now do this export ETS_TOOLKIT=qt to fix the problem. Please let me know if that fixes it. Thanks.

prabhuramachandran avatar Jul 04 '21 06:07 prabhuramachandran

Actually it may not be this at all. What have you installed pyqt5 or pyside2? It is possible that there is some incompatibility with the VTK you have installed and pyqt. You can test in python with:

import vtk
from PyQt5 import QtGui

assuming pyqt5 above. If that import is failing there is an issue.

prabhuramachandran avatar Jul 04 '21 06:07 prabhuramachandran

According to anaconda navigator I have QT Console 5.1.0. When I tried import vtk in python I get:

Traceback (most recent call last): File "C:\Users---\Anaconda3\lib\site-packages\vtkmodules\vtkIOParallel.py", line 5, in from .vtkIOParallelPython import * ImportError: DLL load failed: The specified procedure could not be found.

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "", line 1, in File "C:\Users---\Anaconda3\lib\site-packages\vtk.py", line 32, in all_spec.loader.exec_module(all_m) File "C:\Users---\Anaconda3\lib\site-packages\vtkmodules\all.py", line 83, in from .vtkIOParallel import * File "C:\Users---\Anaconda3\lib\site-packages\vtkmodules\vtkIOParallel.py", line 9, in from vtkIOParallelPython import * ModuleNotFoundError: No module named 'vtkIOParallelPython'

githubrho avatar Jul 04 '21 13:07 githubrho

Actually I have python 3.7.4

Python 3.7.4 (default, Aug 9 2019, 18:34:13) [MSC v.1915 64 bit (AMD64)] :: Anaconda, Inc. on win32

I have vtk 8.2.0 and vtk--PKG (not sure what this is) installed

githubrho avatar Jul 04 '21 13:07 githubrho

So the VTK modules are not installed properly in your environment. I have found that it is easiest to just pip install vtk to install VTK. Can you try with that?

prabhuramachandran avatar Feb 24 '22 15:02 prabhuramachandran