5

I am running an ubuntu 14.04 system with CUDA 6.5 installed. I am trying to use the gpu implementation of feature matching of OpenCV library and my openCV library version is 2.4.9. cmake .. is ok but when I want to make project it gives me errors like:

> /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...

Alex
  • 3,382
  • 2
  • 32
  • 41
afsaneh R
  • 51
  • 1
  • 3

1 Answers1

6

put using namespace std; before you include gpu.hpp

example

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

this works for me

MooMoo
  • 1,086
  • 12
  • 22
  • Using namespace std makes me sad, taking https://stackoverflow.com/questions/2152925/can-i-undo-the-effect-of-using-namespace-in-c into consideration ... – Audrius Meškauskas Aug 16 '18 at 08:53