Error during installation of MLBox
zuliani99 opened this issue · comments
Riccardo Zuliani commented
Hi,
I'm trying to install mlbox on my device but after running the usual pip3 install mlbox, it ended with the follow error:
Collecting mlbox
Using cached mlbox-0.8.5.tar.gz (31 kB)
Collecting hyperopt==0.2.3
Using cached hyperopt-0.2.3-py3-none-any.whl (1.9 MB)
Collecting joblib==0.14.1
Using cached joblib-0.14.1-py2.py3-none-any.whl (294 kB)
Collecting lightgbm==2.3.1
Using cached lightgbm-2.3.1-py2.py3-none-manylinux1_x86_64.whl (1.2 MB)
Collecting matplotlib==3.0.3
Using cached matplotlib-3.0.3.tar.gz (36.6 MB)
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-14pjbker/matplotlib/setup.py'"'"'; __file__='"'"'/tmp/pip-install-14pjbker/matplotlib/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-14pjbker/matplotlib/pip-egg-info
cwd: /tmp/pip-install-14pjbker/matplotlib/
Complete output (51 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-14pjbker/matplotlib/setup.py", line 225, in <module>
msg = pkg.install_help_msg()
File "/tmp/pip-install-14pjbker/matplotlib/setupext.py", line 650, in install_help_msg
release = platform.linux_distribution()[0].lower()
AttributeError: module 'platform' has no attribute 'linux_distribution'
IMPORTANT WARNING:
pkg-config is not installed.
matplotlib may not be able to find some of its dependencies
============================================================================
Edit setup.cfg to change the build options
BUILDING MATPLOTLIB
matplotlib: yes [3.0.3]
python: yes [3.8.5 (default, Jan 27 2021, 15:41:15) [GCC
9.3.0]]
platform: yes [linux]
REQUIRED DEPENDENCIES AND EXTENSIONS
numpy: yes [version 1.20.2]
install_requires: yes [handled by setuptools]
libagg: yes [pkg-config information for 'libagg' could not
be found. Using local copy.]
freetype: no [The C/C++ header for freetype2 (ft2build.h)
could not be found. You may need to install the
development package.]
png: no [pkg-config information for 'libpng' could not
be found.]
qhull: yes [pkg-config information for 'libqhull' could not
be found. Using local copy.]
OPTIONAL SUBPACKAGES
sample_data: yes [installing]
toolkits: yes [installing]
tests: no [skipping due to configuration]
toolkits_tests: no [skipping due to configuration]
OPTIONAL BACKEND EXTENSIONS
agg: yes [installing]
tkagg: yes [installing; run-time loading from Python Tcl /
Tk]
macosx: no [Mac OS-X only]
windowing: no [Microsoft Windows only]
OPTIONAL PACKAGE DATA
dlls: no [skipping due to configuration]
============================================================================
* The following required packages can not be built:
* freetype, png
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
I've tried also to install separately matplotlib, freetype, png and rerun pip3 install mlbox but the sema error appears.
OS: WIndows 10 (Ubuntu subystem)
Martín Cepeda commented
Clone the repo and install with pip:
git clone git://github.com/AxeldeRomblay/mlbox
Change all ==
in requirements.txt
to >=
Install:
cd mlbox
pip install .