I want to install opencv3 for python 3.6 on macOS Sierra. I have tried to use it through homebrew using this link http://www.pyimagesearch.com/2016/12/19/install-opencv-3-on-macos-with-homebrew-the-easy-way/ but I am getting this error
Error: opencv3: Does not support building both Python 2 and 3 wrappers
How to resolve this??
Install Python 3 with the Official Installer First, download an installer package from the Python website. To do that, visit https://www.python.org/downloads/ on your Mac; it detects your operating system automatically and shows a big button for downloading the latest version of Python installer on your Mac.
brew install opencv3 --with-contrib --with-python3 --without-python
this error is caused by this commit.
With brew edit opencv3
you have to comment the four lines:
if build.with?("python3") && build.with?("python")
# Opencv3 Does not support building both Python 2 and 3 versions
odie "opencv3: Does not support building both Python 2 and 3 wrappers"
end
save and rerun the installation:
brew install opencv3 --with-contrib --with-python3
after that everything works for me
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With