graspnet / anygrasp_sdk

222 stars 22 forks source link

cuda out of memory when executing `anygrasp.get_grasp(points, colors, lims)` #29

Closed elenacliu closed 7 months ago

elenacliu commented 7 months ago

I run your code of grasp detection to get grasp poses for my own experiment.

I use a gpu with 40GB memory and profile the gpu memory usage line by line with set_trace function, confused to see before executing anygrasp.get_grasp(points, colors, lims), the program's memory usage is under 10GB, but while executing anygrasp.get_grasp(points, colors, lims), it allocates so much memory that my program raises an out-of-memory exception. The points and colors both have a shape of (1003434, 3). It will be helpful to know why the program applies for more than 30GB memory.

chenxi-wang commented 7 months ago

That's probably caused by the extremely large scale of the input point cloud. Check the range of input coordinates and make sure they are in meters.

elenacliu commented 7 months ago

I see. Thank you