cannot install dependencies
timaschew opened this issue · comments
Hi,
I don't know much about python.
I'm using OSX and have python and python3 available, also pip and pip3.
There is no instruction how to install dependencies and which version of python and pip is required.
Anyhow, I tried it this:
pip3 install -r requirements.txt
Collecting dlib==19.9.0 (from -r requirements.txt (line 4))
Using cached https://files.pythonhosted.org/packages/23/7a/891d4c46cdf755fb69eec0f06a53033d3754bf68ace5342ad56aeb540aa1/dlib-19.9.0.tar.gz
Collecting numpy==1.13.1 (from -r requirements.txt (line 8))
Using cached https://files.pythonhosted.org/packages/c0/3a/40967d9f5675fbb097ffec170f59c2ba19fc96373e73ad47c2cae9a30aed/numpy-1.13.1.zip
Collecting opencv==3.4.3.18 (from -r requirements.txt (line 14))
Could not find a version that satisfies the requirement opencv==3.4.3.18 (from -r requirements.txt (line 14)) (from versions: )
No matching distribution found for opencv==3.4.3.18 (from -r requirements.txt (line 14))
but as you see it failed.
Install it via pip3 install opencv-python
worked.
Then I removed opencv from requirements.txt file and tried again:
The output started with this
pip3 install -r requirements.txt
Collecting dlib==19.9.0 (from -r requirements.txt (line 4))
Using cached https://files.pythonhosted.org/packages/23/7a/891d4c46cdf755fb69eec0f06a53033d3754bf68ace5342ad56aeb540aa1/dlib-19.9.0.tar.gz
Collecting numpy==1.13.1 (from -r requirements.txt (line 8))
Using cached https://files.pythonhosted.org/packages/c0/3a/40967d9f5675fbb097ffec170f59c2ba19fc96373e73ad47c2cae9a30aed/numpy-1.13.1.zip
Collecting scipy==0.18.0 (from -r requirements.txt (line 16))
Using cached https://files.pythonhosted.org/packages/01/a1/dce70d47377d662aa4b0895df8431aee92cea6faefaab9dae21b0f901ded/scipy-0.18.0.tar.gz
Building wheels for collected packages: dlib, numpy, scipy
Running setup.py bdist_wheel for dlib ... error
Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-5dbk1pv7/dlib/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-wheel-p9qb_qxu --python-tag cp37:
running bdist_wheel
running build
running build_py
package init file 'dlib/__init__.py' not found (or not a regular file)
running build_ext
Invoking CMake setup: 'cmake /private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-5dbk1pv7/dlib/tools/python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-5dbk1pv7/dlib/build/lib.macosx-10.12-x86_64-3.7 -DPYTHON_EXECUTABLE=/usr/local/opt/python/bin/python3.7 -DCMAKE_BUILD_TYPE=Release'
error: [Errno 2] No such file or directory: 'cmake': 'cmake'
----------------------------------------
Failed building wheel for dlib
Running setup.py clean for dlib
Running setup.py bdist_wheel for numpy ... -
after a while it stopped with this output:
clang -bundle -undefined dynamic_lookup build/temp.macosx-10.12-x86_64-3.7/build/src.macosx-10.12-x86_64-3.7/numpy/linalg/umath_linalg.o build/temp.macosx-10.12-x86_64-3.7/numpy/linalg/lapack_lite/python_xerbla.o -L/usr/local/lib -L/usr/local/opt/openssl/lib -L/usr/local/opt/sqlite/lib -Lbuild/temp.macosx-10.12-x86_64-3.7 -lnpymath -o build/lib.macosx-10.12-x86_64-3.7/numpy/linalg/_umath_linalg.cpython-37m-darwin.so -Wl,-framework -Wl,Accelerate
building 'numpy.random.mtrand' extension
compiling C sources
C compiler: clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall
creating build/temp.macosx-10.12-x86_64-3.7/numpy/random
creating build/temp.macosx-10.12-x86_64-3.7/numpy/random/mtrand
compile options: '-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -Inumpy/core/include -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/include/numpy -Inumpy/core/src/private -Inumpy/core/src -Inumpy/core -Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath -Inumpy/core/src/npysort -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -c'
clang: numpy/random/mtrand/mtrand.c
numpy/random/mtrand/mtrand.c:44374:65: error: too many arguments to function call, expected 3, have 4
return (*((__Pyx_PyCFunctionFast)meth)) (self, args, nargs, NULL);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~
/Library/Developer/CommandLineTools/usr/lib/clang/9.0.0/include/stddef.h:105:16: note: expanded from macro 'NULL'
# define NULL ((void*)0)
^~~~~~~~~~
numpy/random/mtrand/mtrand.c:44793:21: error: no member named 'exc_type' in 'struct _ts'
*type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44794:22: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
*value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44795:19: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
*tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44802:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44803:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44804:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44805:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44806:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44807:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44862:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44863:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44864:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44865:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = local_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44866:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = local_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44867:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = local_tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
16 errors generated.
numpy/random/mtrand/mtrand.c:44374:65: error: too many arguments to function call, expected 3, have 4
return (*((__Pyx_PyCFunctionFast)meth)) (self, args, nargs, NULL);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~
/Library/Developer/CommandLineTools/usr/lib/clang/9.0.0/include/stddef.h:105:16: note: expanded from macro 'NULL'
# define NULL ((void*)0)
^~~~~~~~~~
numpy/random/mtrand/mtrand.c:44793:21: error: no member named 'exc_type' in 'struct _ts'
*type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44794:22: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
*value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44795:19: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
*tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44802:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44803:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44804:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44805:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44806:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44807:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44862:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44863:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44864:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44865:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = local_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44866:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = local_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44867:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = local_tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
16 errors generated.
error: Command "clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -Inumpy/core/include -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/include/numpy -Inumpy/core/src/private -Inumpy/core/src -Inumpy/core -Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath -Inumpy/core/src/npysort -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -c numpy/random/mtrand/mtrand.c -o build/temp.macosx-10.12-x86_64-3.7/numpy/random/mtrand/mtrand.o -MMD -MF build/temp.macosx-10.12-x86_64-3.7/numpy/random/mtrand/mtrand.o.d" failed with exit status 1
----------------------------------------
Failed building wheel for numpy
Running setup.py clean for numpy
Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/numpy/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" clean --all:
Running from numpy source directory.
`setup.py clean` is not supported, use one of the following instead:
- `git clean -xdf` (cleans all files)
- `git clean -Xdf` (cleans all versioned files, doesn't touch
files that aren't checked into the git repo)
Add `--force` to your command to use it anyway if you must (unsupported).
----------------------------------------
Failed cleaning build dir for numpy
Running setup.py bdist_wheel for scipy ... error
Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/scipy/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-wheel-_exhtpet --python-tag cp37:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/scipy/setup.py", line 415, in <module>
setup_package()
File "/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/scipy/setup.py", line 395, in setup_package
from numpy.distutils.core import setup
ModuleNotFoundError: No module named 'numpy'
----------------------------------------
Failed building wheel for scipy
Running setup.py clean for scipy
Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/scipy/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" clean --all:
`setup.py clean` is not supported, use one of the following instead:
- `git clean -xdf` (cleans all files)
- `git clean -Xdf` (cleans all versioned files, doesn't touch
files that aren't checked into the git repo)
Add `--force` to your command to use it anyway if you must (unsupported).
----------------------------------------
Failed cleaning build dir for scipy
Failed to build dlib numpy scipy
Installing collected packages: dlib, numpy, scipy
Running setup.py install for dlib ... error
Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/dlib/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/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-record-aaifzc0w/install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
package init file 'dlib/__init__.py' not found (or not a regular file)
running build_ext
Invoking CMake setup: 'cmake /private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/dlib/tools/python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/dlib/build/lib.macosx-10.12-x86_64-3.7 -DPYTHON_EXECUTABLE=/usr/local/opt/python/bin/python3.7 -DCMAKE_BUILD_TYPE=Release'
error: [Errno 2] No such file or directory: 'cmake': 'cmake'
----------------------------------------
Command "/usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/dlib/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/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-record-aaifzc0w/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/q8/d_g_4vls0c1bg9q77gj621l80000gp/T/pip-install-d1ueaqyd/dlib/
Maybe you should first install cmake
using brew
.
Oh, right...
But why I can't install opencv through the requirements.txt file?
Anyhow I installed cmake (keeping opencv omitted from requirements.txt), but didn't help.
I run sudo pip3 install -r requirements.txt
compile options: '-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -Inumpy/core/include -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/include/numpy -Inumpy/core/src/private -Inumpy/core/src -Inumpy/core -Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath -Inumpy/core/src/npysort -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -c'
clang: numpy/random/mtrand/mtrand.c
numpy/random/mtrand/mtrand.c:44374:65: error: too many arguments to function call, expected 3, have 4
return (*((__Pyx_PyCFunctionFast)meth)) (self, args, nargs, NULL);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~
/Library/Developer/CommandLineTools/usr/lib/clang/9.0.0/include/stddef.h:105:16: note: expanded from macro 'NULL'
# define NULL ((void*)0)
^~~~~~~~~~
numpy/random/mtrand/mtrand.c:44793:21: error: no member named 'exc_type' in 'struct _ts'
*type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44794:22: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
*value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44795:19: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
*tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44802:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44803:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44804:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44805:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44806:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44807:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44862:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44863:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44864:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44865:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = local_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44866:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = local_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44867:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = local_tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
16 errors generated.
numpy/random/mtrand/mtrand.c:44374:65: error: too many arguments to function call, expected 3, have 4
return (*((__Pyx_PyCFunctionFast)meth)) (self, args, nargs, NULL);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~
/Library/Developer/CommandLineTools/usr/lib/clang/9.0.0/include/stddef.h:105:16: note: expanded from macro 'NULL'
# define NULL ((void*)0)
^~~~~~~~~~
numpy/random/mtrand/mtrand.c:44793:21: error: no member named 'exc_type' in 'struct _ts'
*type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44794:22: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
*value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44795:19: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
*tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44802:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44803:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44804:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44805:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44806:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44807:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44862:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44863:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44864:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
numpy/random/mtrand/mtrand.c:44865:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = local_type;
~~~~~~ ^
numpy/random/mtrand/mtrand.c:44866:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = local_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
numpy/random/mtrand/mtrand.c:44867:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = local_tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
16 errors generated.
error: Command "clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -Inumpy/core/include -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/include/numpy -Inumpy/core/src/private -Inumpy/core/src -Inumpy/core -Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath -Inumpy/core/src/npysort -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/private -Ibuild/src.macosx-10.12-x86_64-3.7/numpy/core/src/npymath -c numpy/random/mtrand/mtrand.c -o build/temp.macosx-10.12-x86_64-3.7/numpy/random/mtrand/mtrand.o -MMD -MF build/temp.macosx-10.12-x86_64-3.7/numpy/random/mtrand/mtrand.o.d" failed with exit status 1
----------------------------------------
Rolling back uninstall of numpy
Command "/usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-install-agp0fa8b/numpy/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/tmp/pip-record-mkpfkhjd/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/tmp/pip-install-agp0fa8b/numpy/
Opencv
depends onlibopencv
, that's why we can not install it withpip
.- You'd better try
pip install numpy
and see if it works. Anaconda
is a better environment, I recommend you to use it as your python environment.