【问题标题】:How to install python-Levenshtein windows如何安装 python-Levenshtein windows
【发布时间】:2013-01-16 03:08:18
【问题描述】:

我看到有人问过关于在 python 中安装 levenshtein 的类似问题,但被另一个用户指示我自己启动,所以就这样吧。

我正在运行 Windows 8 64 位。当我尝试安装 Levenshtein 时,出现以下错误。

C:\Python27\Lib\site-packages\python-Levenshtein-0.10.2>python setup.py install
running install
running bdist_egg
running egg_info
writing requirements to python_Levenshtein.egg-info\requires.txt
writing python_Levenshtein.egg-info\PKG-INFO
writing namespace_packages to python_Levenshtein.egg-info\namespace_packages.txt

writing top-level names to python_Levenshtein.egg-info\top_level.txt
writing dependency_links to python_Levenshtein.egg-info\dependency_links.txt
writing entry points to python_Levenshtein.egg-info\entry_points.txt
reading manifest file 'python_Levenshtein.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching '*' under directory 'docs'
warning: no previously-included files matching '*pyc' found anywhere in distribu
tion
warning: no previously-included files matching '.project' found anywhere in dist
ribution
warning: no previously-included files matching '.pydevproject' found anywhere in
 distribution
writing manifest file 'python_Levenshtein.egg-info\SOURCES.txt'
installing library code to build\bdist.win32\egg
running install_lib
running build_ext
building 'Levenshtein' extension
error: Unable to find vcvarsall.bat

我被指示安装 setup-tools,我已经完成了。还有

http://www.microsoft.com/en-us/download/details.aspx?id=6506下载vcsetup.exe运行它

完成后打开你的command.exe

type :easy_install python-Levenshtein(假设您已经有 setuptools)

但是,当我键入“easy_install”时,我收到以下消息。我也对措辞感到困惑。我应该指向 setup.py 吗?

C:\Python27\Lib\site-packages\python-Levenshtein-0.10.2>easy_install python-Leve
nshtein
'easy_install' is not recognized as an internal or external command,
operable program or batch file.

【问题讨论】:

标签: python windows-8 levenshtein-distance


【解决方案1】:

easy_install 的问题是因为您的 python 脚本文件夹不在 PATH 中。只需将以下内容添加到 PATH:

 C:\Python27\Scripts

关于你最初的问题,你应该看看this question的答案。

【讨论】:

    猜你喜欢
    • 2012-10-23
    • 2023-03-18
    • 1970-01-01
    • 2021-04-10
    • 2015-09-25
    • 1970-01-01
    • 2016-01-13
    • 2010-10-27
    • 2021-05-28
    相关资源
    最近更新 更多