ctcsound not a valid Win32 Application

156 views Asked by At

I already checked other questions for this topic but none of the solutions worked when I attempted them. As far as I can tell the rest of my code has nothing to do with this issue. I downloaded csound from the csound.com and it comes with a python module called ctcsound. However every time I attempt to import ctcsound in my script I get the following:

Traceback (most recent call last):
File "C:/Users/pvedi/PycharmProjects/Data_Sonification_Class/Paul_Vedier_Soni1.py", line 1, in <module>
import ctcsound
File "C:\Program Files\Csound6_x64\bin\ctcsound.py", line 31, in <module>
libcsound = cdll.csound64
File "C:\Users\pvedi\AppData\Local\Programs\Python\Python36-32\lib\ctypes\__init__.py", line 418, in __getattr__
dll = self._dlltype(name)
File "C:\Users\pvedi\AppData\Local\Programs\Python\Python36-32\lib\ctypes\__init__.py", line 348, in __init__
self._handle = _dlopen(self._name, mode)
OSError: [WinError 193] %1 is not a valid Win32 application

I'm doing this for a class and after asking my teacher for help, he yelled at me in class for basically using a windows computer instead of a Mac because he doesn't know how to use a windows machine. Any help would be super appreciate so that he doesn't fail me. Thanks guys!

1

There are 1 answers

0
Steven Yi On

Are you using a 64-bit Python installation? Looks like it might be related to this:

https://github.com/mit-nlp/MITIE/issues/150

I'm pretty sure the Csound installation from csound.com is a 64-bit Windows executable and library.