Python3 fails to install caffe in anaconda, and python3caffe

Source: Internet
Author: User

Python3 fails to install caffe in anaconda, and python3caffe

Python and Python3 are both languages.

0x00 import caffe FAILED
  
The environment is Ubuntu 16 cuda 8.0 NVIDIA 361.77 Anaconda2. Caffe was unavailable yesterday:

>>> import caffeTraceback (most recent call last):  File "<stdin>", line 1, in <module>  File "/home/duchengyao/project/caffe/python/caffe/__init__.py", line 1, in <module>    from .pycaffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, RMSPropSolver, AdaDeltaSolver, AdamSolver  File "/home/duchengyao/project/caffe/python/caffe/pycaffe.py", line 13, in <module>    from ._caffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, \ImportError: /home/duchengyao/project/caffe/python/caffe/../../build/lib/libcaffe.so.1.0.0-rc3: undefined symbol: _ZN2cv8imencodeERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayERSt6vectorIhSaIhEERKSB_IiSaIiEE

All kinds of tossing are invalid. After Anaconda is reinstalled, the error disappears,import caffeSuccessful.

  0x01 import FAILED again after "$ conda install opencv"
  
After using conda install opencv to install Opencv, the same error message is displayed. The error disappears after uninstallation.
  
After Conda is installed, the Opencv version is 2.4.10, and the apt version is 2.4.9.1. I tried to install version 2.4.9 from conda, but I need to handle a lot of conflict.
  
Finally, I had no way to prepare to replace it with Anaconda3. After the environment was set up, it was awkward to run the program, and the various libraries were incompatible. I finally realized that Python and Python3 are completely two languages for the old birds.
  
  0x02 Solution
  
The temporary solution is to discard anaconda, use apt to install software packages, and use the default Opencv of the system to run successfully.

Attachment: Chinese Python3 tutorial pdf http://www.gooln.com/document/519354.html

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.