メインコンテンツ

Visual SLAM

単眼カメラ、RGB-D カメラ、またはステレオ カメラと慣性センサー フュージョンによるリアルタイムの視覚自己位置推定・地図作成 (vSLAM) と展開サポート

Visual simultaneous localization and mapping (vSLAM) とは、カメラの位置と向きを推定すると同時に、視覚的入力を使用して周囲の環境地図を作成するプロセスです。Computer Vision Toolbox™ は、単眼カメラ、RGB-D カメラ、ステレオ カメラに対応した vSLAM ワークフローをサポートしており、精度向上のためのオプションとして慣性センサー フュージョンも利用できます。これらの機能は、ロボティクス、拡張現実、自律ナビゲーションなどの用途において不可欠です。vSLAM ワークフローの選択に関するガイダンスについては、Choose SLAM Workflow Based on Sensor Dataを参照してください。

各 visual SLAM オブジェクト (monovslamrgbdvslam、および stereovslam) は、フレームの追加、キーフレームの追跡、3 次元マップ点の計算、カメラ姿勢の推定、ループ閉じ込み、カメラ軌跡全体にわたるデータの可視化を行うための、即利用可能なツールを提供します。compareTrajectories 関数を使用して、推定されたカメラ軌跡をグラウンド トゥルースと比較し、vSLAM アルゴリズムの性能を評価することもできます。ツールボックスには、独自の visual SLAM パイプラインを構築するための機能も備わっています。

ツールボックスを使用して、vSLAM アルゴリズムのコード生成と展開を実行することもできます。詳細については、Build and Deploy Visual SLAM Algorithm with ROS in MATLABPerformant and Deployable Monocular Visual SLAMを参照してください。

関数

すべて展開する

monovslamVisual simultaneous localization and mapping (vSLAM) and visual-inertial sensor fusion with monocular camera (R2023b 以降)
addFrameAdd image frame to visual SLAM object (R2023b 以降)
hasNewKeyFrameCheck if new key frame added in visual SLAM object (R2023b 以降)
checkStatusCheck status of visual SLAM object (R2023b 以降)
isDoneEnd-of-file status (logical)
mapPointsBuild 3-D map of world points (R2023b 以降)
posesAbsolute camera poses of key frames (R2023b 以降)
plotPlot 3-D map points and estimated camera trajectory in visual SLAM (R2023b 以降)
resetReset visual SLAM object (R2023b 以降)
rgbdvslamFeature-based visual simultaneous localization and mapping (vSLAM) and visual-inertial sensor fusion with RGB-D camera (R2024a 以降)
addFrameAdd pair of color and depth images to RGB-D visual SLAM object (R2024a 以降)
hasNewKeyFrameCheck if new key frame added in RGB-D visual SLAM object (R2024a 以降)
checkStatusCheck status of visual RGB-D SLAM object (R2024a 以降)
isDoneEnd-of-processing status for RGB-D visual SLAM object (R2024a 以降)
mapPointsBuild 3-D map of world points from RGB-D vSLAM object (R2024a 以降)
posesAbsolute camera poses of RGB-D vSLAM key frames (R2024a 以降)
plotPlot 3-D map points and estimated camera trajectory in RGB-D visual SLAM (R2024a 以降)
resetReset RGB-D visual SLAM object (R2024a 以降)
stereovslamFeature-based visual simultaneous localization and mapping (vSLAM) and visual-inertial sensor fusion with stereo camera (R2024a 以降)
addFrameAdd pair of color and depth images to stereo visual SLAM object (R2024a 以降)
hasNewKeyFrameCheck if new key frame added in stereo visual SLAM object (R2024a 以降)
checkStatusCheck status of stereo visual SLAM object (R2024a 以降)
isDoneEnd-of-processing status for stereo visual SLAM object (R2024a 以降)
mapPointsBuild 3-D map of world points from stereo vSLAM object (R2024a 以降)
posesAbsolute camera poses of stereo key frames (R2024a 以降)
plotPlot 3-D map points and estimated camera trajectory in stereo visual SLAM (R2024a 以降)
resetReset stereo visual SLAM object (R2024a 以降)
compareTrajectoriesCompare estimated trajectory against ground truth (R2024b 以降)
trajectoryErrorMetricsStore accuracy metrics for trajectories (R2024b 以降)
imshowイメージの表示
showMatchedFeatures対応する特徴点を表示
plotPlot image view set views and connections
plotCamera3 次元座標でのカメラのプロット
pcshow3 次元点群のプロット
pcplayerストリーミング 3 次元点群データの可視化

特徴の検出、抽出、およびマッチング

detectSURFFeaturesSURF 特徴の検出
detectORBFeaturesORB キーポイントの検出
extractFeatures関心点記述子の抽出
matchFeaturesマッチする特徴の検出
matchFeaturesInRadiusFind matching features within specified radius

3 次元構造の再構成

triangulateステレオ イメージでの歪み補正後のマッチする点の 3 次元位置
img2world2dDetermine world coordinates of image points (R2022b 以降)
world2imgイメージへのワールド ポイントの投影 (R2022b 以降)

動きの推定

estgeotform2dマッチする点のペアからの 2 次元幾何学的変換の推定 (R2022b 以降)
estgeotform3dEstimate 3-D geometric transformation from matching point pairs (R2022b 以降)
estimateFundamentalMatrixステレオ イメージ内の対応する点から基礎行列を推定
estworldpose3 次元対 2 次元の点の対応関係からのカメラ姿勢の推定 (R2022b 以降)
findWorldPointsInViewFind world points observed in view
findWorldPointsInTracksFind world points that correspond to point tracks
estrelposeカメラの姿勢間の相対的な回転と並進の計算 (R2022b 以降)

動きおよび 3 次元構造の最適化

optimizePosesOptimize absolute poses using relative pose constraints
createPoseGraphCreate pose graph
bundleAdjustment3 次元の点とカメラの姿勢のコレクションの調整
bundleAdjustmentMotionAdjust collection of 3-D points and camera poses using motion-only bundle adjustment
bundleAdjustmentStructureRefine 3-D points using structure-only bundle adjustment

ループ閉じ込み

bagOfFeaturesbag of visual words オブジェクト
bagOfFeaturesDBoWBag of visual words using DBoW2 library (R2024b 以降)
dbowLoopDetectorDetect loop closure using visual features (R2024b 以降)
indexImagesCreate image search index
invertedImageIndexSearch index that maps visual words to images

データの管理

imageviewsetManage data for structure-from-motion, visual odometry, and visual SLAM
worldpointsetManage 3-D to 2-D point correspondences

変換

se3SE(3) homogeneous transformation (R2026a 以降)
so3SO(3) rotation (R2026a 以降)

トピック

即利用可能な Visual SLAM 関数

独自の Visual SLAM パイプラインの構築

注目の例