适用于 python 2.7 的音频实验室
我的系统中安装了 python 2.7,我需要使用 audiolab 模块。 我从以下站点下载:http://www.lfd.uci。 edu/~gohlke/pythonlibs/#scikits.audiolab
当我导入 scikits.audiolab 时,出现以下错误:
Traceback (most recent call last):
File "C:/Python27/trystuff", line 1, in <module>
from scikits.audiolab import formatinfo as format
File "C:\Python27\lib\site-packages\scikits\__init__.py", line 1, in <module>
__import__('pkg_resources').declare_namespace(__name__)
ImportError: No module named pkg_resources
我应该做什么?
I have python 2.7 installed in my system and I need to use the audiolab module.
I downloaded from the following site: http://www.lfd.uci.edu/~gohlke/pythonlibs/#scikits.audiolab
When I import scikits.audiolab I get the following error:
Traceback (most recent call last):
File "C:/Python27/trystuff", line 1, in <module>
from scikits.audiolab import formatinfo as format
File "C:\Python27\lib\site-packages\scikits\__init__.py", line 1, in <module>
__import__('pkg_resources').declare_namespace(__name__)
ImportError: No module named pkg_resources
What should I do?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这里有一个适用于 python 2.7 的 scikits.audiolab(以及很多其他东西)的 Windows 二进制版本:
http://www.lfd.uci.edu/~gohlke/pythonlibs/ #scikits.audiolab
audiolab 还需要 libsndfile。该链接就在该页面上,但我也会把它放在这里,因为 libsndfile 很棒:
http://www.mega-nerd.com/libsndfile/#Download
PS:您需要将 libsndfile-1.dll 放在 python 可以找到的地方。如果您不介意浪费一点点磁盘空间,可以将其副本放在 Python27\Lib\site-packages\scikits\audiolab\pysndfile 目录中。
There is a Windows binary build of scikits.audiolab (and a whole lot of other stuff) for python 2.7 here:
http://www.lfd.uci.edu/~gohlke/pythonlibs/#scikits.audiolab
audiolab will also require libsndfile. The link is right there on that page, but I'll put it here too since libsndfile is great:
http://www.mega-nerd.com/libsndfile/#Download
PS: You will need to put the libsndfile-1.dll someplace python can find it. If you don't mind wasting at tiny bit of disk space, you can drop a copy of it in the Python27\Lib\site-packages\scikits\audiolab\pysndfile directory.
您需要 pkg_resources 模块,它是 setup_tools 或较新的分支 分发。您链接的站点还提供 Windows 二进制文件供您安装。我推荐分发模块。它们还为您提供第三方模块的轻松安装/卸载功能。
You need pkg_resources module which is a part of setup_tools or the newer fork distribute. The site you linked also has Windows binaries for you to install. I'd recommend the distribute module. They also provide you easy install/uninstall capabilities for third-party modules.