meiqua / pose_refine

cuda icp for 6D pose estimation
BSD 2-Clause "Simplified" License
96 stars 25 forks source link

interrupt error #7

Open donglimf opened 4 years ago

donglimf commented 4 years ago

When I run function "depth2cloud_cuda",it will interrupt in file"icp.cu " line 274.

meiqua commented 4 years ago

interrupt error means segmentation fault or what? Maybe you can insert "gpuErrchk(cudaPeekAtLastError());" before line 274 to see more error messages.

meiqua commented 4 years ago

By the way, Does the depth image seem normal if comments back the test.cpp line 64-67?

donglimf commented 4 years ago

1、I insert "cudaDeviceSynchronize();" and "cudaGetLastError();" befor line 270,it return 77,maybe depth2mask is error,Let me have check. 2、Depth image look normal.

Thanks for you review.

meiqua commented 4 years ago

depth2mask seems too simple to be wrong. Will this happen if you insert codes before depth2mask?

donglimf commented 4 years ago

I have solve the problem,in function " render_cuda_keep_in_gpu ",if I copy depth_cuda from device to host in Function of the internal(renderer.cu),it works,but if I copy depth_cuda from device to host in test.cpp,it doesn't work.So I copy the thrust data into a device pointer,and return it.Test.cpp now works well,but I don't know why does this happen?

meiqua commented 4 years ago

Any function related to gpu should be in .cu file. If you want depth on cpu side, just use render_cuda.

donglimf commented 4 years ago

It is no need to do that,cudaMemcpy can work in .cpp file. But kernel function should be in .cu file.