Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/HKUST-Aerial-Robotics/Vins-Fusion/llms.txt

Use this file to discover all available pages before exploring further.

VINS-Fusion is structured as three independent ROS nodes — vins_node (the core VIO estimator), loop_fusion_node (place recognition and pose graph optimization), and global_fusion_node (GPS-fused global odometry). Each node has a defined set of subscribed and published topics. Understanding these interfaces is essential for integrating VINS-Fusion with your own sensor stack, recording the right topics for post-processing, or connecting downstream navigation software.

vins_node (rosrun vins vins_node)

Subscribed Topics

TopicTypeNotes
IMU_TOPICsensor_msgs/ImuConfigured via imu_topic in the YAML config (e.g. /imu0). Subscribed only when imu: 1 in config. Queue depth 2000, TCP no-delay hint applied.
IMAGE0_TOPICsensor_msgs/ImageLeft (or mono) camera image. Configured via image0_topic in the YAML config. Queue depth 100. Accepts mono8 or 8UC1 encoding.
IMAGE1_TOPICsensor_msgs/ImageRight camera image for stereo. Configured via image1_topic. Queue depth 100. Subscribed only when num_of_cam: 2 (stereo mode).
/feature_tracker/featuresensor_msgs/PointCloudPre-tracked feature points from the feature tracker node. Each point carries normalized coordinates, pixel UV, optical flow velocity, and optionally ground-truth 3D position. Queue depth 2000.
/vins_restartstd_msgs/BoolWhen true, clears the estimator state and reloads parameters — equivalent to a soft restart without killing the node. Queue depth 100.
/vins_imu_switchstd_msgs/BoolDynamically enables (true) or disables (false) IMU integration at runtime by calling estimator.changeSensorType. Queue depth 100.
/vins_cam_switchstd_msgs/BoolDynamically switches between stereo (true) and monocular left-camera-only (false) mode at runtime. Queue depth 100.

Published Topics

All topics are published under the vins_estimator namespace (the node’s private namespace ~). With the default rosrun invocation the full topic paths are:
TopicTypeNotes
/vins_estimator/odometrynav_msgs/OdometryBody-frame pose (position + orientation + linear velocity) in the world frame. Published only when the solver is in NON_LINEAR (fully initialized) state.
/vins_estimator/imu_propagatenav_msgs/OdometryHigh-rate odometry propagated by IMU integration between vision updates. Published on every IMU message.
/vins_estimator/pathnav_msgs/PathAccumulated trajectory of all NON_LINEAR state estimates. Frame ID world.
/vins_estimator/point_cloudsensor_msgs/PointCloudTriangulated 3D landmarks in the world frame for the current sliding window (used by features seen in ≥2 frames and not yet marginalized).
/vins_estimator/margin_cloudsensor_msgs/PointCloud3D landmarks that are about to be marginalized out of the sliding window. Useful for building a longer-horizon map for visualization.
/vins_estimator/key_posesvisualization_msgs/MarkerSPHERE_LIST marker showing the positions of all keyframes in the current sliding window. Colored red.
/vins_estimator/camera_posenav_msgs/OdometryPose of the left camera in the world frame (derived from body pose + extrinsic calibration tic[0], ric[0]).
/vins_estimator/camera_pose_visualvisualization_msgs/MarkerArray3D camera frustum visualization for RViz. Includes both cameras in stereo mode.
/vins_estimator/keyframe_posenav_msgs/OdometryPose of the keyframe at WINDOW_SIZE - 2 when a marginalization event occurs. Consumed by loop_fusion_node.
/vins_estimator/keyframe_pointsensor_msgs/PointCloud3D points and 2D pixel coordinates associated with the keyframe pose above. Consumed by loop_fusion_node for DBoW2 loop detection.
/vins_estimator/extrinsicnav_msgs/OdometryOnline-calibrated camera-IMU extrinsic transform (tic[0], ric[0]), expressed as a pose. Published via pubTF every time TF is broadcast.
/vins_estimator/image_tracksensor_msgs/ImageDebug image showing tracked feature points overlaid on the current frame. BGR8 encoding.

loop_fusion_node (rosrun loop_fusion loop_fusion_node)

Subscribed Topics

TopicTypeNotes
/vins_estimator/odometrynav_msgs/OdometryVIO odometry used to propagate the loop-corrected path in real time.
image0_topic (from config)sensor_msgs/ImageRaw camera image used to build BRIEF descriptors for DBoW2 place recognition. Topic name read from image0_topic in the YAML config.
/vins_estimator/keyframe_posenav_msgs/OdometryKeyframe pose used to create new KeyFrame objects for the pose graph.
/vins_estimator/keyframe_pointsensor_msgs/PointCloud3D-2D point correspondences for the keyframe, used during PnP-based loop verification.
/vins_estimator/extrinsicnav_msgs/OdometryLive extrinsic calibration used to transform poses between body and camera frames inside the pose graph.
/vins_estimator/margin_cloudsensor_msgs/PointCloudMarginalized points re-published (with loop-corrected drift) for visualization.

Published Topics

All topics are under the loop_fusion private namespace:
TopicTypeNotes
/loop_fusion/match_imagesensor_msgs/ImageDebug image showing matched keypoints between the current frame and the retrieved loop-closure candidate.
/loop_fusion/camera_pose_visualvisualization_msgs/MarkerArrayCamera frustum showing the drift-corrected camera pose in the world frame.
/loop_fusion/point_cloud_loop_rectsensor_msgs/PointCloudKeyframe 3D points after drift correction from pose graph optimization.
/loop_fusion/margin_cloud_loop_rectsensor_msgs/PointCloudMarginalized points after drift correction.
/loop_fusion/odometry_rectnav_msgs/OdometryLoop-corrected body odometry, computed by applying the pose graph’s drift transform to the incoming VIO odometry.
The pose graph itself (nodes, edges, loop-closure links) is published internally via posegraph.registerPub(n) and posegraph.publish().

global_fusion_node (rosrun global_fusion global_fusion_node)

Subscribed Topics

TopicTypeNotes
/vins_estimator/odometrynav_msgs/OdometryVIO odometry input. GPS measurements are temporally aligned to this stream with a ±10 ms tolerance.
/gpssensor_msgs/NavSatFixGPS measurements (latitude, longitude, altitude + position covariance). The topic name is hardcoded as /gps.

Published Topics

All topics are under the globalEstimator private namespace:
TopicTypeNotes
/globalEstimator/global_odometrynav_msgs/OdometryGPS-fused global odometry in the world frame, published on every VIO callback after GPS alignment.
/globalEstimator/global_pathnav_msgs/PathAccumulated GPS-fused trajectory path. Frame ID world. Shown in blue in the default RViz config.
/globalEstimator/car_modelvisualization_msgs/MarkerArray3D car mesh visualization used in the KITTI car demonstration.
The global fusion node does not take a config file argument and does not need one — it only requires that /vins_estimator/odometry and /gps are being published before it is started. For the KITTI GPS example, kitti_gps_test publishes /gps from the dataset’s raw GPS data.

Build docs developers (and LLMs) love