Closed MichaelGrupp closed 3 years ago
@MichaelGrupp Can you explain a bit about the context when you see large memory consumption from odometry data? Is this for pure localization or SLAM? It would seem that odometry data is very small compared to the other data we keep.
The motivation for this was localization. Concrete example: we run a robot with pure localization mode that can be "idle" for some time, e.g. during a charging phase, but we want to keep Cartographer running. In this case, our motion filter is configured to not add new nodes to the pose graph unless we move again, which works fine. But we noticed that we were still accumulating odometry data that has no additional value without movement. Filtering odometry data that is close to zero prevents that and I didn't observe any side effects on the optimization since the values with information (when moving) still enter the pose graph.
The motivation for this was localization. Concrete example: we run a robot with pure localization mode that can be "idle" for some time, e.g. during a charging phase, but we want to keep Cartographer running. In this case, our motion filter is configured to not add new nodes to the pose graph unless we move again, which works fine. But we noticed that we were still accumulating odometry data that has no additional value without movement. Filtering odometry data that is close to zero prevents that and I didn't observe any side effects on the optimization since the values with information (when moving) still enter the pose graph.
It makes sense. I think most robots have certain idle time where you would still want to keep localization alive.
@wohe can you have a look again if you have time?
Done.
This introduces an option to control the amount of odometry data that enters the pose graph by motion-filtering it. This is very useful to bound memory when standing still for longer periods of time.
If the new option is not configured, all odometry data goes unfiltered into the pose graph as usual.
Signed-off-by: Michael Grupp grupp@magazino.eu