我在安装pyfasttext时出错。
cogent@MBP: pip install --user pyfasttext
然后我得到了:
收集pyfasttext 正在下载https://files.pythonhosted.org/packages/f5/ef/90606442481d1e4ab10eba8c2b2c449ceaa70c60e9b8d5898bb7504e3634/pyfasttext-0.4.6.tar.gz(244kB) 100%|█████████████████████████████████| 245kB 224kB /秒 已满足要求:将来在/Users/cogent/Library/Python/2.7/lib/python/site-packages中(来自pyfasttext)(0.18.1) 已满足要求:/Users/cogent/Library/Python/2.7/lib/python/site-packages中的cysignals(来自pyfasttext)(1.10.2) 已经满足的要求:/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python中的numpy(来自pyfasttext)(1.8.0rc1) 已满足要求:/Library/Python/2.7/site-packages中的Cython> = 0.28(来自cysignals-> pyfasttext)(0.29.13) 安装收集的软件包:pyfasttext 正在运行setup.py install for pyfasttext ...错误 来自命令/ usr / bin / python -u -c“ import setuptools,tokenize; 文件 ='/ private / var / folders / gm / kpbf6gyx1dx_167zbp2gmdym0000gn / T / pip-install-wuuXwu / pyfasttext的完整输出/setup.py';f=getattr(tokenize,'open',open)(文件); code = f.read()。replace('\ r \ n','\ n' ); f.close(); exec(compile(code, file ,'exec')))安装--record / private / var / folders / gm / kpbf6gyx1dx_167zbp2gmdym0000gn / T / pip-record- Qtcina / install-record.txt-单个版本-外部管理-编译--user --prefix =: 运行安装 运行构建 运行build_ext 建立'pyfasttext'扩展名 创建版本 创建build / temp.macosx-10.14-intel-2.7 创建build / temp.macosx-10.14-intel-2.7 / src 创建build / temp.macosx-10.14-intel-2.7 / src / fastText 创建build / temp.macosx-10.14-intel-2.7 / src / fastText / src cc -DNDEBUG -g -fwrapv -Os -Wall -Wstrict-prototypes -iquote。 -include src / custom_exit.h -arch i386 -arch x86_64 -pipe -Isrc -I / Users / cogent / Library / Python / 2.7 / lib / python / site-packages / cysignals -I。 -Isrc / variant / include -I / System / Library / Frameworks / Python.framework / Versions / 2.7 / include / python2.7 -I / System / Library / Frameworks / Python.framework / Versions / 2.7 / Extras / lib / python / numpy / core / include -c src / pyfasttext.cpp -o build / temp.macosx-10.14-intel-2.7 / src / pyfasttext.o -Wno-sign-compare -std = c ++ 0x 在src / pyfasttext.cpp:53包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/Python.h:85中包含的文件中: /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:534:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册PyObject obj,/ 对象* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:553:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册PyObject obj / 对象* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:575:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册const wchar_t w,/ wchar_t缓冲区* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:593:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册wchar_t w,/ wchar_t缓冲区* / ^ ~~~~~~~~~ 在src / pyfasttext.cpp:53包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/Python.h:94包含的文件中: /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/stringobject.h:173:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册PyObject obj,/ 字符串或Unicode对象* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/stringobject.h:174:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册char ** s,/ *指向缓冲区变量的指针* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/stringobject.h:175:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 将Py_ssize_t len / 指针注册为长度变量或NULL ^ ~~~~~~~~~ 在src / pyfasttext.cpp:676包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/arrayobject.h:4中包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/ndarrayobject.h:17中包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/ndarraytypes.h:1760中包含的文件中: /System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2:警告:“使用不赞成使用的NumPy API,请通过“”将其禁用#定义NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION“ [-W#警告] #warning“使用已弃用的NumPy API,通过” \ ^ 生成8条警告。 在src / pyfasttext.cpp:53包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/Python.h:85中包含的文件中: /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:534:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册PyObject obj,/ 对象* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:553:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册PyObject obj / 对象* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:575:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册const wchar_t w,/ wchar_t缓冲区* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/unicodeobject.h:593:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册wchar_t w,/ wchar_t缓冲区* / ^ ~~~~~~~~~ 在src / pyfasttext.cpp:53包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/Python.h:94包含的文件中: /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/stringobject.h:173:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册PyObject obj,/ 字符串或Unicode对象* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/stringobject.h:174:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 注册char ** s,/ *指向缓冲区变量的指针* / ^ ~~~~~~~~~ /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/stringobject.h:175:5:警告:“寄存器”存储类说明符已弃用,并且与C ++ 17不兼容[-Wdeprecated-寄存器] 将Py_ssize_t len / 指针注册为长度变量或NULL ^ ~~~~~~~~~ 在src / pyfasttext.cpp:676包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/arrayobject.h:4中包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/ndarrayobject.h:17中包含的文件中: 在/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/ndarraytypes.h:1760中包含的文件中: /System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2:警告:“使用不赞成使用的NumPy API,请通过“”将其禁用#定义NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION“ [-W#警告] #warning“使用已弃用的NumPy API,通过” \ ^ 生成8条警告。 cc -DNDEBUG -g -fwrapv -Os -Wall -Wstrict-prototypes -iquote。 -include src / custom_exit.h -arch i386 -arch x86_64 -pipe -Isrc -I / Users / cogent / Library / Python / 2.7 / lib / python / site-packages / cysignals -I。 -Isrc / variant / include -I / System / Library / Frameworks / Python.framework / Versions / 2.7 / include / python2.7 -I / System / Library / Frameworks / Python.framework / Versions / 2.7 / Extras / lib / python / numpy / core / include -c src / fasttext_access.cpp -o build / temp.macosx-10.14-intel-2.7 / src / fasttext_access.o -Wno-sign-compare -std = c ++ 0x src / fasttext_access.cpp:43:1:错误:非类型模板参数不是指向成员常量的指针 ALLOW_METHOD_ACCESS(FastText,bool,checkModel,std :: istream&); ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~ src / private_access.h:55:38:注意:从宏“ ALLOW_METHOD_ACCESS”扩展 模板结构抢 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src / fasttext_access.cpp:54:1:错误:非类型模板参数不是指向成员常量的指针 ALLOW_CONST_METHOD_ACCESS(字典,int32_t,查找,const std :: string&); ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~ src / private_access.h:59:38:注意:从宏“ ALLOW_CONST_METHOD_ACCESS”扩展 模板结构抢 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~ src / fasttext_access.cpp:55:1:错误:非类型模板参数不是指向成员常量的指针 ALLOW_CONST_METHOD_ACCESS(Dictionary,void,pushHash,std :: vector&,int32_t); ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src / private_access.h:59:38:注意:从宏“ ALLOW_CONST_METHOD_ACCESS”扩展 模板结构抢 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~ src / fasttext_access.cpp:56:1:错误:非类型模板参数不是指向成员常量的指针 ALLOW_METHOD_ACCESS(Dictionary,void,initTableDiscard,); ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~ src / private_access.h:55:38:注意:从宏“ ALLOW_METHOD_ACCESS”扩展 模板结构抢 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ src / fasttext_access.cpp:57:1:错误:非类型模板参数不是指向成员常量的指针 ALLOW_METHOD_ACCESS(Dictionary,void,initNgrams,); ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 〜 src / private_access.h:55:38:注意:从宏“ ALLOW_METHOD_ACCESS”扩展 模板结构抢 ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 产生5个错误。 错误:命令“ cc”失败,退出状态为1
----------------------------------------
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/gm/kpbf6gyx1dx_167zbp2gmdym0000gn/T/pip-install-wuuXwu/pyfasttext/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/gm/kpbf6gyx1dx_167zbp2gmdym0000gn/T/pip-record-Qtcina/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /private/var/folders/gm/kpbf6gyx1dx_167zbp2gmdym0000gn/T/pip-install-wuuXwu/pyfasttext/
为什么我收到这些消息?有什么想法吗?非常感谢!