Cannot get the Python API to work on Windows
Hi,
First many thanks for gmsh, which is indeed a fantastic tool.
I'm sorry if I posted this at the wrong place. I'm a total rookie when it comes to using things such as gitlab. I had gmsh and the Python API easily working on both Linuw and MacOs.
Hence, following the same procedure as for my Macbook on the windows Laptop i'm "forced" to use, I installed gmsh for windows and then the gmsh-sdk for Python via pip install
. Unfornately, the simple instruction import gmsh
fails and I displayed the result below. Being unconfortable with Windows, I tried to dig as deep in the system as I could but to no avail.
I'm conscious that I undoubtedly miss one point, e.g. the name of the directory where gmsh should be installed, but I don't quite get what it should be.
Any help fo a confined researcher stuck with a windows laptop will be a great relief.
Olivier Bodart, University of Saint-Etienne (gitlab & windows rookie:) )
*Windows PowerShell Copyright (C) Microsoft Corporation. Tous droits réservés.
PS C:\Users\bo52414h\Dropbox\pyvolc> pip install gmsh-sdk Collecting gmsh-sdk Using cached gmsh-sdk-4.5.5.post1.tar.gz (10 kB) Installing collected packages: gmsh-sdk Running setup.py install for gmsh-sdk ... done Successfully installed gmsh-sdk-4.5.5.post1 PS C:\Users\bo52414h\Dropbox\pyvolc> python Python 3.7.4 (tags/v3.7.4:e09359112e, Jul 8 2019, 19:29:22) [MSC v.1916 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information.
import gmsh Traceback (most recent call last): File "", line 1, in File "C:\Users\bo52414h\AppData\Local\Programs\Python\Python37-32\lib\site-packages\gmsh-4.5.5-Windows64-sdk\lib\gmsh.py", line 39, in lib = CDLL(libpath) File "C:\Users\bo52414h\AppData\Local\Programs\Python\Python37-32\lib\ctypes__init__.py", line 364, in init self._handle = _dlopen(self._name, mode) OSError: [WinError 193] %1 n’est pas une application Win32 valide*