简体   繁体   English

使用CUDA 6.5的openCV 2.4.9编译错误

[英]openCV 2.4.9 compilation error with CUDA 6.5

I am running an ubuntu 14.04 system with CUDA 6.5 installed. 我正在运行安装了CUDA 6.5的ubuntu 14.04系统。 I am trying to use the gpu implementation of feature matching of OpenCV library and my openCV library version is 2.4.9. 我正在尝试使用OpenCV库的功能匹配的gpu实现,我的openCV库版本是2.4.9。 cmake .. is ok but when I want to make project it gives me errors like: cmake ..还可以,但是当我想制作项目时,它会给我一些错误:

> /usr/local/include/opencv2/gpu/gpu.hpp:432:29: error: ‘vector’ does
> not name a type  CV_EXPORTS void merge(const vector<GpuMat>& src,
> GpuMat& dst, Stream& stream = Stream::Null());
>                              ^ /usr/local/include/opencv2/gpu/gpu.hpp:432:35: error: expected ‘,’ or
> ‘...’ before ‘<’ token  CV_EXPORTS void merge(const vector<GpuMat>&
> src, GpuMat& dst, Stream& stream = Stream::Null());

Could you please help me with this? 你能帮帮我吗? Thanks... 谢谢...

put using namespace std; 使用命名空间std; before you include gpu.hpp 在包含gpu.hpp之前

example

using namespace std;
#include <opencv2/gpu/gpu.hpp>

this works for me 这对我有用

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM