Tôi đang cố gắng cài đặt Landsat-produc trên Ubuntu 16.04. Tôi đang chạy Ubuntu như một máy ảo bên trong Windows. Tôi đang sử dụng cài đặt sạch (không có gói nào được cài đặt) với hy vọng tránh mọi xung đột phụ thuộc.
Tôi đã làm theo các hướng dẫn trên trang này , nhưng tôi gặp lỗi mỗi lần khi tôi cố gắng thực hiện lệnh này:
$: pip install landsat-util
Đây là một đoạn trích từ đầu ra:
Running setup.py bdist_wheel for pycurl ... error
Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-oH9kCk/pycurl/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" bdist_wheel -d /tmp/tmpgxvEEBpip-wheel- --python-tag cp27:
Using curl-config (libcurl 7.47.0)
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
creating build/lib.linux-x86_64-2.7/curl
copying python/curl/__init__.py -> build/lib.linux-x86_64-2.7/curl
running build_ext
building 'pycurl' extension
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/src
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -DPYCURL_VERSION="7.43.0" -DHAVE_CURL_GNUTLS=1 -DHAVE_CURL_SSL=1 -I/usr/include/python2.7 -c src/docstrings.c -o build/temp.linux-x86_64-2.7/src/docstrings.o
In file included from src/docstrings.c:4:0:
src/pycurl.h:173:30: fatal error: gnutls/gnutls.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Failed building wheel for pycurl
Running setup.py clean for pycurl
Running setup.py bdist_wheel for toolz ... done
Stored in directory: /home/jim/.cache/pip/wheels/b0/84/bf/7089262387e8ea60bdefb1fdb84d2ee99427f6d09c9c7ba37d
Successfully built landsat-util usgs termcolor rasterio homura polyline matplotlib click requests-futures click-plugins humanize toolz
Failed to build pycurl
Installing collected packages: click, requests, futures, requests-futures, usgs, six, python-dateutil, numpy, termcolor, affine, cligj, pyparsing, snuggs, click-plugins, enum34, rasterio, scipy, toolz, dask, pytz, cycler, matplotlib, pillow, decorator, networkx, scikit-image, humanize, pycurl, homura, boto, polyline, ratelim, geocoder, landsat-util
Running setup.py install for pycurl ... error
Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-oH9kCk/pycurl/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-pvaIdU-record/install-record.txt --single-version-externally-managed --compile --user --prefix=:
Using curl-config (libcurl 7.47.0)
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
creating build/lib.linux-x86_64-2.7/curl
copying python/curl/__init__.py -> build/lib.linux-x86_64-2.7/curl
running build_ext
building 'pycurl' extension
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/src
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -DPYCURL_VERSION="7.43.0" -DHAVE_CURL_GNUTLS=1 -DHAVE_CURL_SSL=1 -I/usr/include/python2.7 -c src/docstrings.c -o build/temp.linux-x86_64-2.7/src/docstrings.o
In file included from src/docstrings.c:4:0:
src/pycurl.h:173:30: fatal error: gnutls/gnutls.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-oH9kCk/pycurl/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-pvaIdU-record/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-build-oH9kCk/pycurl/
Tôi đã thử cài đặt Landsat trong nhiều môi trường khác nhau (Windows 10, Ubuntu 14.04, Ubuntu chạy Anaconda, Ubuntu chạy Miniconda), nhưng tôi luôn gặp vấn đề tương tự. Có vẻ như Landsat-produc phụ thuộc vào rất nhiều gói khác rất khó cài đặt.
Làm thế nào tôi có thể làm cho tiện ích này hoạt động?