yolo No package 'opencv' found解决方法

在使用Opencv编译YOLO时遇到:

 

Package opencv was not found in the pkg-config search path.
Perhaps you should add the directory containing `opencv.pc'
to the PKG_CONFIG_PATH environment variable
No package 'opencv' found
Package opencv was not found in the pkg-config search path.
Perhaps you should add the directory containing `opencv.pc'
to the PKG_CONFIG_PATH environment variable
No package 'opencv' found

 

该如何解决呢?首先我们可以对opencv进行源码编译,但这种方法非常耗时,我们可以使用一条语句

 

sudo apt install libopencv-dev 

 

即可解决问题!

你可能感兴趣的:(yolo No package 'opencv' found解决方法)