请输入您要查询的百科知识:

 

词条 Perspective-n-Point
释义

  1. Problem Specification

      Definition    Assumptions and Data Characteristics  

  2. Methods

      P3P    EPnP    Using RANSAC  

  3. See also

  4. References

  5. External links

Perspective-n-Point is the problem of estimating the pose of a calibrated camera given a set of {{math|n}} 3D points in the world and their corresponding 2D projections in the image. The camera pose consists of 6 degrees-of-freedom (DOF) which are made up of the rotation (roll, pitch, and yaw) and 3D translation of the camera with respect to the world. This problem originates from camera calibration and has many applications in computer vision and other areas, including 3D pose estimation, robotics and augmented reality. A commonly used solution to the problem exists for {{math|n {{=}} 3}} called P3P, and many solutions are available for the general case of {{math|n ≥ 3}}. Implementations of these solutions are also available in open source software.

Problem Specification

Definition

Given a set of {{math|n}} 3D points in a world reference frame and their corresponding 2D image projections as well as the calibrated intrinsic camera parameters, determine the 6 DOF pose of the camera in the form of its rotation and translation with respect to the world. This follows the perspective project model for cameras:

.

where is the homogeneous world point, is the corresponding homogeneous image point, is the matrix of intrinsic camera parameters, (where and are the scaled focal lengths, is the skew parameter which is sometimes assumed to be 0, and is the principal point), is a scale factor for the image point, and and are the desired 3D rotation and 3D translation of the camera (extrinsic parameters) that are being calculated. This leads to the following equation for the model:

.

Assumptions and Data Characteristics

There are a few preliminary aspects of the problem that are common to all solutions of PnP. The assumption made in most solutions is that the camera is already calibrated. Thus, its intrinsic properties are already known, such as the focal length, principal image point, skew parameter, and other parameters. Some methods, such as UPnP.[1] or the Direct Linear Transform (DLT) applied to the projection model, are exceptions to this assumption as they estimate these intrinsic parameters as well as the extrinsic parameters which make up the pose of the camera that the original PnP problem is trying to find.

For each solution to PnP, the chosen point correspondences cannot be coplanar. In addition, PnP can have multiple solutions, and choosing a particular solution would require post-processing of the solution set. RANSAC is also commonly used with a PnP method to make the solution robust to outliers in the set of point correspondences. Most methods, however, assume that the data is noise-free.

Methods

This following section describes two common methods that can be used to solve the PnP problem that are also readily available in open source software and how RANSAC can be used to deal with outliers in the data set.

P3P

When {{math|n {{=}} 3}}, the PnP problem is in its minimal form of P3P and can be solved with three point correspondences. However, with just three point correspondences, P3P yields many solutions, so a fourth correspondence is used in practice to remove ambiguity. The setup for the problem is as follows.

Let P be the center of projection for the camera, A, B, and C be 3D world points with corresponding images points u, v, and w. Let X = |PA|, Y = |PB|, Z = |PC|, , , , , , , , , . This forms triangles PBC, PAC, and PAB from which we obtain the equation system for P3P:

.

It's common to normalize the image points before solving P3P. Solving the P3P system results in four possible solutions for {{math|R}} and {{math|T}}. The fourth world point D and its corresponding image point z are then used to find the best solution among the four. The algorithm for solving the problem as well as the complete solution classification for it is given in the 2003 IEEE Transactions on Pattern Analysis and Machine Intelligence paper by Gao, et al.[2] An open source implementation of the P3P can be found in OpenCV's calib3d module in the solvePnP function.[3]

EPnP

Efficient PnP (EPnP) is a method developed by Lepetit, et al. in their 2008 International Journal of Computer Vision paper[4] that solves the general problem of PnP for {{math|n ≥ 3}}. This method is based on the notion that each of the n points (which are called reference points) can be expressed as a weighted sum of four virtual control points. Thus, the coordinates of these control points become the unknowns of the problem. It is from these control points that the final pose of the camera is solved for.

As an overview of the process, first note that each of the {{math|n}} reference points in the world frame, , and their corresponding image points, , are weighted sums of the four controls points, and respectively, and the weights are normalized per reference point as shown below. All points are expressed in homogeneous form.

From this, the derivation of the image reference points becomes

.

The homogeneous image control point has the form . Rearranging the image reference point equation yields the following two linear equations for each reference point:

.

Using these two equations for each of the {{math|n}} reference points, the system can be formed where . The solution for the control points exists in the null space of {{math|M}} and is expressed as

where is the number of null singular values in and each is the corresponding right singular vector of . can range from 1 to 4. After calculating the initial coefficients , the Gauss-Newton algorithm is used to refine them. The {{math|R}} and {{math|T}} matrices that minimize the reprojection error of the world reference points, , and their corresponding actual image points , are then calculated.

This solution has complexity and works in the general case of PnP for both planar and non-planar control points. Open source software implementations of this method can be found in OpenCV's Camera Calibration and 3D Reconstruction module in the solvePnP function[3] as well as from the code published by Lepetit, et al. at their website, CVLAB at EPFL.[5]

Using RANSAC

PnP is prone to errors if there are outliers in the set of point correspondences. Thus, RANSAC can be used in conjunction with existing solutions to make the final solution for the camera pose more robust to outliers. An open source implementation of PnP methods with RANSAC can be found in OpenCV's Camera Calibration and 3D Reconstruction module in the solvePnPRansac function[6]

See also

  • Camera resectioning

References

1. ^{{cite journal |last1=Penate-Sanchez |first1=A. |last2=Andrade-Cetto |first2=J. |last3=Moreno-Noguer |first3=F. |title=Exhaustive Linearization for Robust Camera Pose and Focal Length Estimation |journal=IEEE Transactions on Pattern Analysis and Machine Intelligence |date=2013 |volume=35 |issue=10 |pages=2387–2400 |doi=10.1109/TPAMI.2013.36|pmid=23969384 |hdl=2117/22931 }}
2. ^{{cite journal|last1=Gao|first1=Xiao-Shan|last2=Hou|first2=Xiao-Rong|last3=Tang|first3=Jianliang|last4=Cheng|first4=Hang-Fei|title=Complete Solution Classification for the Perspective-Three-Point Problem|journal=IEEE Transactions on Pattern Analysis and Machine Intelligence|date=2003|volume=25|issue=8|pages=930–943|doi=10.1109/tpami.2003.1217599}}
3. ^{{cite web|title=Camera Calibration and 3D Reconstruction|url=https://docs.opencv.org/master/d9/d0c/group__calib3d.html#ga549c2075fac14829ff4a58bc931c033d|website=OpenCV}}
4. ^{{cite journal|last1 = Lepetit|first1 = V.|last2 = Moreno-Noguer|first2 = M.|last3 = Fua|first3 = P.|title = EPnP: An Accurate O(n) Solution to the PnP Problem|journal = International Journal of Computer Vision|date = 2009|volume = 81|issue = 2|pages = 155–166|doi=10.1007/s11263-008-0152-6|hdl = 2117/10327}}
5. ^{{cite web|title=EPnP: Efficient Perspective-n-Point Camera Pose Estimation|url=http://cvlab.epfl.ch/EPnP/index.php|website=EPFL-CVLAB}}
6. ^{{cite web|title=Camera Calibration and 3D Reconstruction|url=https://docs.opencv.org/master/d9/d0c/group__calib3d.html#ga50620f0e26e02caa2e9adc07b5fbf24e|website=OpenCV}}

External links

  • OpenCV Camera Calibration and 3D Reconstruction Module
  • EPFL's CVLAB: EPnP

2 : Science of photography|Photogrammetry

随便看

 

开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。

 

Copyright © 2023 OENC.NET All Rights Reserved
京ICP备2021023879号 更新时间:2024/11/13 11:39:01