ethz-asl / panoptic_mapping

A flexible submap-based framework towards spatio-temporally consistent volumetric mapping and scene understanding.
BSD 3-Clause "New" or "Revised" License
275 stars 31 forks source link

Submap saving without RViz visualization #65

Closed leonard-git-acc closed 1 year ago

leonard-git-acc commented 1 year ago

Hi, i have been trying to use the Multi-TSDF approach to map multiple scenes from the ScanNet dataset. I have encountered a problem, while having visualization turned off. The maps, when saved, have heavily reduced size (from ~60mb -> ~7mb) compared to ones saved while the visualization was running. Additionally they seem to contain substantially less submaps (as far as i have loaded and looked at them). The same problem seems to appear, when I am mapping and saving the flat_dataset example. Is there any way to change this behavior? On a side note, is it good practice to call the finish_mapping service before saving? I am asking, because the callback has a comment, that it is a preliminary tool.

Thanks for any help in advance.

Schmluk commented 1 year ago

Hi @LeonardRabes

Thank you for pointing out this issue! The reason for this is that the submap meshes are required to track the input data, but these were only updated when visualization was turned on. This must've been 'optimized away' along the way, but should be fixed in #66. Can you give it a try and potentially compare the maps obtained with visualization turned on vs off?

Regarding your second question, the finish_mapping service simply terminates all tracks, i.e. all currently tracked submaps are moved to the inactive state, which is typically what would happen between mapping sessions. Thus, calling the service should give you intended behavior if the loaded map and the newly processed data are meant to be two sessions, and should be avoided if the data is considered one continuous stream.

Hope this helps!

leonard-git-acc commented 1 year ago

Hi @Schmluk, the fix seems to work very well. The exported map for the flat_dataset/run1 now has a size of 45.5mb with 47 exported submaps (without calling finish_mapping) with and without visualization. If I encounter any problems with it, i will tell you about it.

Thank you a lot for your help.

Schmluk commented 1 year ago

Happy to hear!

Fixed as of #66.