[Csnd] Error importing csnd6 in Python3.6
Date | 2018-07-03 13:08 |
From | luis antunes pena |
Subject | [Csnd] Error importing csnd6 in Python3.6 |
I'm trying some of these examples
https://github.com/csound/csoundAPI_examples/tree/master/python of
running csound in python using the API. It looks like python can't
load the csnd6 library. Output of the terminal is below. I have installed python3.6 and csound 6.11 (double samples) May 11 2018 on mac osx 10.12.6. Any help appreciated. Luis Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 05:52:31)
|
Date | 2018-07-03 13:10 |
From | Victor Lazzarini |
Subject | Re: [Csnd] Error importing csnd6 in Python3.6 |
csnd6 only works on Python 2.* You need to use ctcsound on Python 3 ======================== Prof. Victor Lazzarini Dean of Arts, Celtic Studies, and Philosophy, Maynooth University, Maynooth, Co Kildare, Ireland Tel: 00 353 7086936 Fax: 00 353 1 7086952 > On 3 Jul 2018, at 13:08, luis antunes pena |
Date | 2018-07-03 13:27 |
From | luis antunes pena |
Subject | Re: [Csnd] Error importing csnd6 in Python3.6 |
Thanks Victor. After installing numpy I have this error: >>> import ctcsound This is probably due to the fact that I'm running a tcsh shell and not a bash one. Is there something I can do to import the library without havng to change the shell? Thanks, Luis
Am 03.07.18 um 14:10 schrieb Victor
Lazzarini:
csnd6 only works on Python 2.* You need to use ctcsound on Python 3 ======================== Prof. Victor Lazzarini Dean of Arts, Celtic Studies, and Philosophy, Maynooth University, Maynooth, Co Kildare, Ireland Tel: 00 353 7086936 Fax: 00 353 1 7086952On 3 Jul 2018, at 13:08, luis antunes pena <antunespena@WEB.DE> wrote: I'm trying some of these examples https://github.com/csound/csoundAPI_examples/tree/master/python of running csound in python using the API. It looks like python can't load the csnd6 library. Output of the terminal is below. I have installed python3.6 and csound 6.11 (double samples) May 11 2018 on mac osx 10.12.6. Any help appreciated. Luis Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 05:52:31) [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)] on darwin Type "help", "copyright", "credits" or "license" for more information.import csnd6Traceback (most recent call last): File "/Library/Python/3.6/site-packages/csnd6.py", line 14, in swig_import_helper return importlib.import_module(mname) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 994, in _gcd_import File "<frozen importlib._bootstrap>", line 971, in _find_and_load File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 658, in _load_unlocked File "<frozen importlib._bootstrap>", line 571, in module_from_spec File "<frozen importlib._bootstrap_external>", line 922, in create_module File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed ImportError: dlopen(/Library/Python/3.6/site-packages/_csnd6.so, 2): Symbol not found: _PyClass_Type Referenced from: /Library/Python/3.6/site-packages/_csnd6.so Expected in: flat namespace in /Library/Python/3.6/site-packages/_csnd6.so During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Library/Python/3.6/site-packages/csnd6.py", line 17, in <module> _csnd6 = swig_import_helper() File "/Library/Python/3.6/site-packages/csnd6.py", line 16, in swig_import_helper return importlib.import_module('_csnd6') File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) ImportError: dlopen(/Library/Python/3.6/site-packages/_csnd6.so, 2): Symbol not found: _PyClass_Type Referenced from: /Library/Python/3.6/site-packages/_csnd6.so Expected in: flat namespace in /Library/Python/3.6/site-packages/_csnd6.so -- http://luisantunespena.eu http://sumtone.com Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted hereCsound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here |
Date | 2018-07-03 13:38 |
From | Francois PINOT |
Subject | Re: [Csnd] Error importing csnd6 in Python3.6 |
On some Macs, sysctl is located in /sbin/ instead of /usr/sbin/ . You should add /sbin to your PATH variable (I'm supposing you're using a Mac, aren't you?)François 2018-07-03 14:27 GMT+02:00 luis antunes pena <antunespena@web.de>:
|
Date | 2018-07-03 13:53 |
From | luis antunes pena |
Subject | Re: [Csnd] Error importing csnd6 in Python3.6 |
Thank you François. I'm on mac os 10.12.6. I found sysctl in
/usr/sbin and now both /sbin and /usr/sbin are added to PATH and I
can load the library ctcsound. Thanks! Am 03.07.18 um 14:38 schrieb Francois
PINOT:
|