メインコンテンツ

structure from motion

インクリメンタル structure from motion と NeRF を使用して、複数のビューから 3 次元シーン構造を再構成する

Structure from motion (SfM) とは、異なる視点から撮影された一連の 2 次元イメージから、シーンの 3 次元構造を推定するプロセスです。Computer Vision Toolbox™ は、特徴検出、マッチング、カメラ姿勢推定、三角測量、バンドル調整などを含む、エンドツーエンドの SfM パイプラインを提供します。これらの機能は、3 次元地図作成、フォトグラメトリ、自律ナビゲーションなどの用途において不可欠です。

インクリメンタル structure-from-motion パイプラインに関する段階ごとの包括的な解説については、Structure from Motion from Multiple Viewsの一連の例を参照してください。この一連の例では、bag-of-features アプローチを使用してカメラ ビューからビュー グラフを作成する方法、幾何学的制約を使用してビュー グラフを調整する方法、ロバストな初期ビュー ペアを選択して 3 次元再構成を初期化する方法、そして残りのカメラ ビューを統合して完全な 3 次元シーンを再構成する方法を示します。シーンのスパースな 3 次元点群を使用して高密度の 3 次元メッシュを生成する方法については、Dense 3-D Reconstruction of Asteroid Surface from Image Sequenceの例を参照してください。

高密度再構成と新規視点合成のために、ツールボックスはニューラル放射輝度場 (NeRF) をサポートしています。trainNerfacto 関数を使用して、イメージ コレクションで NeRF モデルに学習させ、新規視点を生成します。その後、pc2surfacemesh (Lidar Toolbox) 関数を使用し、その点群を用いて 3 次元メッシュを生成できます。

関数

すべて展開する

detectSIFTFeaturesScale Invariant Feature Transform (SIFT) 特徴の検出 (R2021b 以降)
detectORBFeaturesORB キーポイントの検出
detectBRISKFeaturesBRISK 特徴の検出
detectFASTFeaturesFAST アルゴリズムを使用したコーナーの検出
detectHarrisFeaturesHarris–Stephens アルゴリズムを使用したコーナーの検出
detectMinEigenFeatures最小固有値アルゴリズムを使用したコーナーの検出
detectMSERFeaturesMSER 特徴の検出
detectSURFFeaturesSURF 特徴の検出
detectKAZEFeaturesKAZE 特徴の検出
extractFeatures関心点記述子の抽出
matchFeaturesマッチする特徴の検出
matchFeaturesInRadiusFind matching features within specified radius
vision.PointTrackerKanade-Lucas-Tomasi (KLT) アルゴリズムを使用したビデオ内の点の追跡

イメージとカメラ データの保存

imageviewsetManage data for structure-from-motion, visual odometry, and visual SLAM
worldpointsetManage 3-D to 2-D point correspondences
cameraIntrinsics内部カメラ パラメーターを格納するオブジェクト
rigidtform3d3 次元剛体幾何学的変換 (R2022b 以降)
affinetform3d3 次元アフィン幾何学的変換 (R2022b 以降)

カメラの姿勢の推定

estimateEssentialMatrixイメージのペア内の対応する点から基本行列を推定
estimateFundamentalMatrixステレオ イメージ内の対応する点から基礎行列を推定
estworldpose3 次元対 2 次元の点の対応関係からのカメラ姿勢の推定 (R2022b 以降)
estrelposeカメラの姿勢間の相対的な回転と並進の計算 (R2022b 以降)

イメージ ポイントの三角測量

pointTrackObject for storing matching points from multiple views
findTracksFind matched points across multiple views
triangulateステレオ イメージでの歪み補正後のマッチする点の 3 次元位置
triangulateMultiview3-D locations of world points matched across multiple images

カメラの姿勢と 3 次元点の最適化

bundleAdjustment3 次元の点とカメラの姿勢のコレクションの調整
bundleAdjustmentMotionAdjust collection of 3-D points and camera poses using motion-only bundle adjustment
bundleAdjustmentStructureRefine 3-D points using structure-only bundle adjustment
nerfactoDense reconstruction and novel view synthesis using Nerfacto Neural Radiance Field (NeRF) model (R2026a 以降)
trainNerfactoCreate and train Nerfacto Neural Radiance Field (NeRF) model (R2026a 以降)
compareTrajectoriesCompare estimated trajectory against ground truth (R2024b 以降)
trajectoryErrorMetricsStore accuracy metrics for trajectories (R2024b 以降)
stereoAnaglyphCreate red-cyan anaglyph from stereo pair of images
pcshow3 次元点群のプロット
plotCamera3 次元座標でのカメラのプロット
showMatchedFeatures対応する特徴点を表示
rotmat2vec3d3 次元回転行列から回転ベクトルへの変換 (R2022b 以降)
rotvec2mat3d3 次元回転ベクトルから回転行列への変換 (R2022b 以降)
quaternionCreate quaternion array (R2023b 以降)

トピック

インクリメンタル Structure from Motion

基礎

注目の例