CUDA SURF build problem SURF CUDA build

I’ve found a SURF library that use OpenCV and CUDA.
http://www.mis.tu-darmstadt.de/surf
I just can’t build it on windows XP 32bit professional

I list my environment setting as following:
CMake 2.8.2
CUDA ToolKit 3.2 and CUDA SDK3.2
OpenCV 2…0.0
Microsoft Visual C++ 2008
hardware:
nVidia Geforce 9500GT

The attached file depicts the build procedure step by step.

Has anyone built it successfully?
Compile.doc (666 KB)

I’ve found a SURF library that use OpenCV and CUDA.
http://www.mis.tu-darmstadt.de/surf
I just can’t build it on windows XP 32bit professional

I list my environment setting as following:
CMake 2.8.2
CUDA ToolKit 3.2 and CUDA SDK3.2
OpenCV 2…0.0
Microsoft Visual C++ 2008
hardware:
nVidia Geforce 9500GT

The attached file depicts the build procedure step by step.

Has anyone built it successfully?

From the error in your last image it looks like it doesn’t find “Images/img1.jpg” and thus you get a NULL pointer exception soon after. You should first try if changing those to absolute paths and see if it fixes your problem. After that if you still want to use relative paths you can try either setting the working directory for the project or try various locations in your build path for where those images need to be for it to find it.
I did try SURFGPU myself and I don’t remember running into this particular problem (or maybe i just solved it quickly, i don’t know) but in the end it still didn’t work for me for some reason, it didn’t detect the features properly and i haven’t tried since then. But ofcourse maybe I just did something wrong…

From the error in your last image it looks like it doesn’t find “Images/img1.jpg” and thus you get a NULL pointer exception soon after. You should first try if changing those to absolute paths and see if it fixes your problem. After that if you still want to use relative paths you can try either setting the working directory for the project or try various locations in your build path for where those images need to be for it to find it.
I did try SURFGPU myself and I don’t remember running into this particular problem (or maybe i just solved it quickly, i don’t know) but in the end it still didn’t work for me for some reason, it didn’t detect the features properly and i haven’t tried since then. But ofcourse maybe I just did something wrong…

Thanks for your help. I forget to copy the images for execution.

But after that, as the attached picture shows, I got a problem that the error message shows that “buildSURFDescriptorsCUDA() execution failed : too many resources requested for launch.”.

Have you ever faced the same problem? And I don’t know how to solve it?

thanks.
error.JPG

Thanks for your help. I forget to copy the images for execution.

But after that, as the attached picture shows, I got a problem that the error message shows that “buildSURFDescriptorsCUDA() execution failed : too many resources requested for launch.”.

Have you ever faced the same problem? And I don’t know how to solve it?

thanks.

Hi. I don’t know if you have found the solution or not, but here it is. The problem is that there are too many threads in the thread block of buildSURFDescriptorsGPU.cu. To fix this, change the following in buildSURFDescriptorsGPU.cu.

dim3 thread_block(5, 5, 16);

dim3 block_grid(num_ipoints, 1);

to

dim3 thread_block(5, 5, 8);

dim3 block_grid(num_ipoints, 2);

Also, make sure to change the following in buildSURFDescriptorsCUDA.cu

const int subSquareId = threadIdx.z;

to

const int subSquareId = blockIdx.y*blockDim.y + threadIdx.z;

I hope this helps (helped me). You may try to play with the numbers if this does not work (i.e. from 8 and 2, you can go to 4 and 4).