hku-mars/HBA

Large RAM issue

Closed this issue · 8 comments

Hello, @samsdolphin . Great work!

I tested with data (Mid-70) of about 6k frames with 3, 4, 5 layer respectively. However, even with 5 layer setting, the RAM is exceed the max about 16GB. However, from your paper, the RAM cost is smaller than 5GB with 6k frames. What is the reason for this?

image

Hi @wwtinwhu, thanks for your question. In our paper, we calculate each layer's local BA separately. This is to say, from 1st layer to 2nd layer and from 2nd layer to 3rd layer, etc. However, this means you need to execute the code several times, even in just one iteration, which is very inconvenient. Thus, we re-organize our code and write everything in one .cpp file, however, this would lead to huge RAM consumption because the RAM consumed in each layer is added together.

For your scenario, I would recommend using 32GiB or even 64 GiB RAM computer, which can save the total computation time. In our early development stage, we calculate each layer separately, and we need to save and read each layer's pcds again and again. The local BA, global BA and pose graph optimization functions are performed in different launch files. I thought it might be better to combine them together. Hope this helps.

For your scenario, I would recommend using 32GiB or even 64 GiB RAM computer, which can save the total computation time. In our early development stage, we calculate each layer separately, and we need to save and read each layer's pcds again and again. The local BA, global BA and pose graph optimization functions are performed in different launch files. I thought it might be better to combine them together. Hope this helps.

原来如此,感谢解答!

How well is HBA working with your Mid-70 setup @wwtinwhu ? Is it producing nice results now the RAM issue is resolved?

We have a similar setup and will try it soon so I'm curious since Mid-70 has lower point density than the Avia lidar.

Thanks again for @samsdolphin. The issue here is caused by putting pose.json in the pcd directory. After correcting this, the RAM used is around 4GB with my test data.

That's good. Thanks for confirming.

Do the results look "good"? Does the HBA optimisation work well with your Mid-70 data?

@samsdolphin Maybe add a check for opening pose file in read_pose function :)

@seajayshore Hello! I am testing it now! What's your testing scene? Maybe we can communicate with email, and you can find my email in my profile.