The problem want to solve is to generate the topological map incrementally during the investigation of robot such that the motion planning can benefit from it.
Yuan, Y. & Schwertfeger, S. (2019). Incrementally building topology graphs via distance maps. In 2019 IEEE International Conference on Real-time Computing and Robotics (RCAR). IEEE.
The implementation can be found in github.