0

I want to use this for my python project Github here's the steps I followed

1/ Downloaded and installed visual studio 14 2015 x64 community then cuda toolkit cuda_8.0.61_win10

2/ Installed cmake and created the project files using

mkdir build
cd build
cmake ..  -DCMAKE_WINDOWS_EXPORT_ALL_SYMBOLS=TRUE -DBUILD_SHARED_LIBS=TRUE -G "Visual Studio 14 2015 Win64"

3/ Built the project using visual studio with no errors

4/ Installed Thundersvm using pip install thundersvm

The issue now whenever I try to import thundersvm I get this error

C:\Users\frenn\PycharmProjects\charinpt\venv\Scripts\python.exe C:/Users/frenn/PycharmProjects/charinpt/test.py
Traceback (most recent call last):
  File "C:/Users/frenn/PycharmProjects/charinpt/test.py", line 15, in <module>
    import thundersvm.thundersvm
  File "C:\Users\frenn\PycharmProjects\charinpt\venv\lib\site-packages\thundersvm\__init__.py", line 10, in <module>
    from .thundersvm import *
  File "C:\Users\frenn\PycharmProjects\charinpt\venv\lib\site-packages\thundersvm\thundersvm.py", line 39, in <module>
    thundersvm = CDLL(lib_path)
  File "C:\Users\frenn\AppData\Local\Programs\Python\Python37-32\lib\ctypes\__init__.py", line 356, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: [WinError 193] %1 is not a valid Win32 application

Process finished with exit code 1

I'm probably doing something wrong with how the python package should be installed. Here's what the library folder for thundersvm looks like after installing, I think it's missing other stuff.

Thundersvm folder

  • Where is the DLL? – tripleee Sep 18 '19 at 09:52
  • What do you mean? it's there in the python library location, do you want me to post the DLL file? – frenn fren Sep 18 '19 at 09:57
  • The error message indicates that Python can't load it correctly, or perhaps cannot find it. I'm guessing it needs to be spelled out (or you need to run the command in the directory where the DLL lives). – tripleee Sep 18 '19 at 10:06
  • Is your python 32-bit or 64-bit? See [here](https://stackoverflow.com/questions/1842544/how-do-i-detect-if-python-is-running-as-a-64-bit-application). ThunderSVM prebuilt binaries (pip install) are 64-bit. – Robert Crovella Sep 18 '19 at 11:37
  • Thanks, switching to python 64-bit fixed my issue. – frenn fren Sep 18 '19 at 15:19

0 Answers0