Anaconda3.6环境下安装TA_Lib遇到如下问题:
C:\Users\admin\Downloads>pip install TA_Lib
Collecting TA_Lib
Downloading https://files.pythonhosted.org/packages/90/05/d4c6a778d7a7de0be366
bc4a850b4ffaeac2abad927f95fa8ba6f355a082/TA-Lib-0.4.17.tar.gz (717kB)
35% |███████████▍ | 256kB 250kB/s eta 0:00:02
37% |███████████▉ | 266kB 255kB/s eta 0:00:02
38% |████████████▎ | 276kB 255kB/s eta 0:00:0
39% |████████████▉ | 286kB 245kB/s eta 0:00:0
41% |█████████████▎ | 296kB 222kB/s eta 0:00:
42% |█████████████▊ | 307kB 249kB/s eta 0:00:
44% |██████████████▏ | 317kB 267kB/s eta 0:00
45% |██████████████▋ | 327kB 222kB/s eta 0:00
47% |███████████████ | 337kB 253kB/s eta 0:00
48% |███████████████▌ | 348kB 244kB/s eta 0:0
49% |████████████████ | 358kB 244kB/s eta 0:0
51% |████████████████▍ | 368kB 255kB/s eta 0:
52% |█████████████████ | 378kB 218kB/s eta 0:
54% |█████████████████▍ | 389kB 258kB/s eta 0
55% |█████████████████▉ | 399kB 244kB/s eta 0
57% |██████████████████▎ | 409kB 210kB/s eta
58% |██████████████████▊ | 419kB 243kB/s eta
59% |███████████████████▏ | 430kB 248kB/s eta
61% |███████████████████▋ | 440kB 250kB/s eta
62% |████████████████████ | 450kB 259kB/s eta
64% |████████████████████▌ | 460kB 222kB/s et
65% |█████████████████████ | 471kB 248kB/s et
67% |█████████████████████▌ | 481kB 248kB/s e
68% |██████████████████████ | 491kB 214kB/s e
69% |██████████████████████▍ | 501kB 248kB/s
71% |██████████████████████▉ | 512kB 254kB/s
72% |███████████████████████▎ | 522kB 254kB/s
74% |███████████████████████▊ | 532kB 253kB/s
75% |████████████████████████▏ | 542kB 218kB/
77% |████████████████████████▋ | 552kB 249kB/
78% |█████████████████████████ | 563kB 241kB/
79% |█████████████████████████▋ | 573kB 178kB
81% |██████████████████████████ | 583kB 203kB
82% |██████████████████████████▌ | 593kB 201k
84% |███████████████████████████ | 604kB 201k
85% |███████████████████████████▍ | 614kB 215
87% |███████████████████████████▉ | 624kB 213
88% |████████████████████████████▎ | 634kB 24
89% |████████████████████████████▊ | 645kB 19
91% |█████████████████████████████▏ | 655kB 1
92% |█████████████████████████████▊ | 665kB 2
94% |██████████████████████████████▏ | 675kB
95% |██████████████████████████████▋ | 686kB
97% |███████████████████████████████ | 696kB
98% |███████████████████████████████▌| 706kB
99% |████████████████████████████████| 716kB
100% |████████████████████████████████| 727k
B 311kB/s
Requirement already satisfied: numpy in c:\programdata\anaconda3\lib\site-packag
es (from TA_Lib)
Building wheels for collected packages: TA-Lib
Running setup.py bdist_wheel for TA-Lib ... error
Complete output from command C:\ProgramData\Anaconda3\python.exe -u -c "import
setuptools, tokenize;__file__='C:\\Users\\admin\\AppData\\Local\\Temp\\pip-buil
d-myhyn8hg\\TA-Lib\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f
.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" b
dist_wheel -d C:\Users\admin\AppData\Local\Temp\tmpqhhjxqubpip-wheel- --python-t
ag cp36:
C:\Users\admin\AppData\Local\Temp\pip-build-myhyn8hg\TA-Lib\setup.py:79: UserW
arning: Cannot find ta-lib library, installation may fail.
warnings.warn('Cannot find ta-lib library, installation may fail.')
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-3.6
creating build\lib.win-amd64-3.6\talib
copying talib\abstract.py -> build\lib.win-amd64-3.6\talib
copying talib\deprecated.py -> build\lib.win-amd64-3.6\talib
copying talib\stream.py -> build\lib.win-amd64-3.6\talib
copying talib\test_abstract.py -> build\lib.win-amd64-3.6\talib
copying talib\test_data.py -> build\lib.win-amd64-3.6\talib
copying talib\test_func.py -> build\lib.win-amd64-3.6\talib
copying talib\test_pandas.py -> build\lib.win-amd64-3.6\talib
copying talib\test_stream.py -> build\lib.win-amd64-3.6\talib
copying talib\__init__.py -> build\lib.win-amd64-3.6\talib
running build_ext
skipping 'talib\_ta_lib.c' Cython extension (up-to-date)
building 'talib._ta_lib' extension
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C+
+ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools
----------------------------------------
Failed building wheel for TA-Lib
Running setup.py clean for TA-Lib
Failed to build TA-Lib
Installing collected packages: TA-Lib
Running setup.py install for TA-Lib ... error
Complete output from command C:\ProgramData\Anaconda3\python.exe -u -c "impo
rt setuptools, tokenize;__file__='C:\\Users\\admin\\AppData\\Local\\Temp\\pip-bu
ild-myhyn8hg\\TA-Lib\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code
=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))"
install --record C:\Users\admin\AppData\Local\Temp\pip-65x2jy1d-record\install-
record.txt --single-version-externally-managed --compile:
C:\Users\admin\AppData\Local\Temp\pip-build-myhyn8hg\TA-Lib\setup.py:79: Use
rWarning: Cannot find ta-lib library, installation may fail.
warnings.warn('Cannot find ta-lib library, installation may fail.')
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.6
creating build\lib.win-amd64-3.6\talib
copying talib\abstract.py -> build\lib.win-amd64-3.6\talib
copying talib\deprecated.py -> build\lib.win-amd64-3.6\talib
copying talib\stream.py -> build\lib.win-amd64-3.6\talib
copying talib\test_abstract.py -> build\lib.win-amd64-3.6\talib
copying talib\test_data.py -> build\lib.win-amd64-3.6\talib
copying talib\test_func.py -> build\lib.win-amd64-3.6\talib
copying talib\test_pandas.py -> build\lib.win-amd64-3.6\talib
copying talib\test_stream.py -> build\lib.win-amd64-3.6\talib
copying talib\__init__.py -> build\lib.win-amd64-3.6\talib
running build_ext
skipping 'talib\_ta_lib.c' Cython extension (up-to-date)
building 'talib._ta_lib' extension
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual
C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools
----------------------------------------
Command "C:\ProgramData\Anaconda3\python.exe -u -c "import setuptools, tokenize;
__file__='C:\\Users\\admin\\AppData\\Local\\Temp\\pip-build-myhyn8hg\\TA-Lib\\se
tup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n'
, '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Use
rs\admin\AppData\Local\Temp\pip-65x2jy1d-record\install-record.txt --single-vers
ion-externally-managed --compile" failed with error code 1 in C:\Users\admin\App
Data\Local\Temp\pip-build-myhyn8hg\TA-Lib\
You are using pip version 9.0.1, however version 10.0.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' comm
and.
------------------------------------------------------------------
解决办法:
到https://www.lfd.uci.edu/~gohlke/pythonlibs/
这个网站搜索TA_Lib,因为我安装的是python3.6,所以找到这个文件
-
TA_Lib?0.4.17?cp36?cp36m?win_amd64.whl
然后使用pip install TA_Lib?0.4.17?cp36?cp36m?win_amd64.whl
安装结果显示如下:
C:\Users\admin\Downloads>pip install TA_Lib-0.4.17-cp36-cp36m-win_amd64.whl
Processing c:\users\admin\downloads\ta_lib-0.4.17-cp36-cp36m-win_amd64.whl
Installing collected packages: TA-Lib
Successfully installed TA-Lib-0.4.17
You are using pip version 9.0.1, however version 10.0.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' comm
and.
当前名称:python安装TA_Lib遇到问题
当前链接:
http://bzwzjz.com/article/ppgscc.html