MegviiRobot / MegBA

MegBA: A GPU-Based Distributed Library for Large-Scale Bundle Adjustment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

memory leak when solve multi-time GBA

xingweiqu opened this issue · comments

Hi thanks for your amazing work and open sourced code

Start with error: 0.105238, log error: -0.977827, elapsed 4 ms
CUDA error 700 [/usr/local/cuda-11.3/include/cub/block/../iterator/../util_device.cuh, 635]: an illegal memory access was encountered
CUDA error 700 [/usr/local/cuda-11.3/include/thrust/system/cuda/detail/extrema.h, 210]: an illegal memory access was encountered
terminate called after throwing an instance of 'thrust::system::system_error'
  what():  extrema failed on 1st step: cudaErrorIllegalAddress: an illegal memory access was encountered

I have a cuda error 700, when I construct solver and solve GBA multi-times, this error would happen. It seems that there is some raw pointer error. Could you plz to help me for this problem?

Hi @xingweiqu
try this fork I think the second commit in it is the solution for your problem, I suffered from the same problem and that was the solution.
https://github.com/khshmt/MegBA