Brew install opencv3 obviously successful, but cv2.so and cv2.py are missing

I am trying to set up a working environment on my mac:

brew install opencv3 --c++11 --with-contrib --with-gphoto2 --with-python3 ==> Installing opencv3 from homebrew/homebrew-science 

...

 ==> cmake .. -DCMAKE_C_FLAGS_RELEASE= -DCMAKE_CXX_FLAGS_RELEASE= -DCMAKE_INSTALL ==> make ==> make install ==> Caveats This formula is keg-only, which means it was not symlinked into /usr/local. opencv3 and opencv install many of the same files. Generally there are no consequences of this for you. If you build your own software and it requires this formula, you'll need to add to your build variables: LDFLAGS: -L/usr/local/opt/opencv3/lib CPPFLAGS: -I/usr/local/opt/opencv3/include ==> Summary 🍺 /usr/local/Cellar/opencv3/3.0.0: 351 files, 110M, built in 5.4 minutes 

So, homegrown it seems that the installation went well, but finding cv2.so does not find anything ...

 locate *cv*.so 

finds only

 /usr/local/Cellar/opencv3/3.0.0/lib/python3.5/site-packages/cv2.cpython-35m-darwin.so 

and

 /usr/local/lib/python3.5/site-packages/cv2.cpython-35m-darwin.so 

cv2.py or cv.py also doesn't exist ... Any ideas?

+5
source share
1 answer

I saw this error before using raspian, it is also visible in ubuntu, renaming cv2.cpython-35m-darwin.so to cv2.so can help fix the problem.

ive heard this only a standard naming error.

+1
source

Source: https://habr.com/ru/post/1237935/


All Articles