Ocean
NonLinearOptimizationPlane.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) Meta Platforms, Inc. and affiliates.
3  *
4  * This source code is licensed under the MIT license found in the
5  * LICENSE file in the root directory of this source tree.
6  */
7 
8 #ifndef META_OCEAN_GEOMETRY_NON_LINEAR_OPTIMIZATION_PLANE_H
9 #define META_OCEAN_GEOMETRY_NON_LINEAR_OPTIMIZATION_PLANE_H
10 
13 
16 #include "ocean/math/Plane3.h"
17 
18 namespace Ocean
19 {
20 
21 namespace Geometry
22 {
23 
24 /**
25  * This class implements least square or robust optimization algorithms for 3D planes.
26  * @ingroup geometry
27  */
28 class OCEAN_GEOMETRY_EXPORT NonLinearOptimizationPlane : protected NonLinearOptimization
29 {
30  public:
31 
32  /**
33  * Definition of a pair holding to sets of corresponding image points.
34  */
35  typedef std::pair<Vectors2, Vectors2> ImagePointsPair;
36 
37  /**
38  * Definition of a vector holding pairs of corresponding image points.
39  */
40  typedef std::vector<ImagePointsPair> ImagePointsPairs;
41 
42  protected:
43 
44  /**
45  * Forward declaration of a data object allowing to optimize a 3D plane.
46  */
47  class PlaneData;
48 
49  /**
50  * Forward declaration of a data object allowing to optimize a 3D plane and one 6DOF camera pose concurrently.
51  */
52  class OnePoseOnePlaneData;
53 
54  /**
55  * Forward declaration of a data object allowing to optimize a 3D plane and several 6DOF camera poses concurrently.
56  */
57  class PosesPlaneData;
58 
59  /**
60  * Forward declaration of a data object allowing to optimize a 3D plane and several 6DOF camera poses concurrently.
61  */
62  class GeneralizedPosesPlaneData;
63 
64  public:
65 
66  /**
67  * Optimizes a 3D plane by reducing the distance between 3D object points and their projected plane point.
68  * @param plane The plane in 3D space that as to be optimized
69  * @param pointAccessor The accessor providing the 3D object points that define the 3D plane, at least three points
70  * @param optimizedPlane The resulting optimized 3D plane with reduced (optimized) distance between object points and projected plane points
71  * @param iterations The number of iterations to be applied at most, if no convergence can be reached in the meantime, with range [1, infinity)
72  * @param estimator Robust error estimator to be used
73  * @param lambda Initial Levenberg-Marquardt damping value which may be changed after each iteration using the damping factor, with range [0, infinity)
74  * @param lambdaFactor Levenberg-Marquardt damping factor to be applied to the damping value, with range [1, infinity)
75  * @param initialError Optional resulting averaged pixel error for the given initial parameters, w.r.t. the defined estimator
76  * @param finalError Optional resulting averaged pixel error for the final optimized parameters, w.r.t. the defined estimator
77  * @return True, if succeeded
78  */
79  static bool optimizePlane(const Plane3& plane, const ConstIndexedAccessor<Vector3>& pointAccessor, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), Scalar* initialError = nullptr, Scalar* finalError = nullptr);
80 
81  /**
82  * Optimizes the orientation of a plane in 3D spaces and the pose of one camera pose.
83  * The projected 2D image points of several 3D plane object points are observed in two views.<br>
84  * The second pose will be optimized while the first pose defines the static reference system.<br>
85  * The given poses are equivalent to extrinsic camera matrices and thus define a transformation from the camera coordinate system into the world coordinate system.<br>
86  * @param pinholeCamera The pinhole camera object that defines the point projection
87  * @param world_T_cameraFirst First camera pose that corresponds to the first image points
88  * @param world_T_cameraSecond Second camera pose that corresponds to the second image points
89  * @param plane Initial plane on that all object points are located
90  * @param imagePointsFirst The accessor providing the projected plane object points that are visible in the first camera frame
91  * @param imagePointsSecond The accessor providing the projected plane object points that are visible in the second camera frame, one image point for each image point as defined for the first camera frame
92  * @param distortImagePoints True, to apply the distortion parameters of the camera
93  * @param world_T_optimizedCameraSecond Resulting optimized second camera pose providing minimal projection errors
94  * @param optimizedPlane Optimized plane that minimizes the projection errors
95  * @param iterations Number of iterations to be applied at most, if no convergence can be reached
96  * @param estimator Robust error estimator to be used
97  * @param lambda Initial Levenberg-Marquardt damping value which may be changed after each iteration using the damping factor, with range [0, infinity)
98  * @param lambdaFactor Levenberg-Marquardt damping factor to be applied to the damping value, with range [1, infinity)
99  * @param onlyFrontObjectPoints True, to avoid that the optimized 3D position lies behind any camera
100  * @param initialError Optional resulting averaged pixel error for the given initial parameters, in relation to the defined estimator
101  * @param finalError Optional resulting averaged pixel error for the final optimized parameters, in relation to the defined estimator
102  * @return Result of the optimization
103  */
104  static inline bool optimizeOnePoseOnePlane(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& world_T_cameraFirst, const HomogenousMatrix4& world_T_cameraSecond, const Plane3& plane, const ConstIndexedAccessor<Vector2>& imagePointsFirst, const ConstIndexedAccessor<Vector2>& imagePointsSecond, const bool distortImagePoints, HomogenousMatrix4& world_T_optimizedCameraSecond, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), const bool onlyFrontObjectPoints = true, Scalar* initialError = nullptr, Scalar* finalError = nullptr);
105 
106  /**
107  * Optimizes the orientation of a plane in 3D spaces and the pose of one camera pose.
108  * The projected 2D image points of several 3D plane object points are observed in two views.<br>
109  * The second pose will be optimized while the first pose defines the static reference system.<br>
110  * The given poses must be inverted and flipped around the new x axis by 180 degree.<br>
111  * @see optimizeOnePoseOnePlane().
112  */
113  static bool optimizeOnePoseOnePlaneIF(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& flippedCameraFirst_T_world, const HomogenousMatrix4& flippedCameraSecond_T_world, const Plane3& plane, const ConstIndexedAccessor<Vector2>& imagePointsFirst, const ConstIndexedAccessor<Vector2>& imagePointsSecond, const bool distortImagePoints, HomogenousMatrix4& optimizedFlippedCameraSecond_T_world, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), const bool onlyFrontObjectPoints = true, Scalar* initialError = nullptr, Scalar* finalError = nullptr);
114 
115  /**
116  * Optimizes the orientation of a plane in 3D spaces and several camera poses concurrently.
117  * 3D plane object points are observed in several individual camera frames (with individual camera poses).<br>
118  * The first pose defines the static reference system while the remaining poses will be optimized accordingly.<br>
119  * The given poses are equivalent to extrinsic camera matrices and thus define a transformation from the camera coordinate system into the world coordinate system.
120  * @param pinholeCamera The pinhole camera profile defining the projection
121  * @param world_T_camera First camera pose of the first frame (corresponding with the first set of image points)
122  * @param imagePointsFirst The first set of observations of the plane object points (visible in the first camera frame)
123  * @param world_T_cameras Further camera poses, at least 1
124  * @param plane Initial plane on that all object points are located
125  * @param imagePointGroups The group of observations of the plane object points, one group for each further pose
126  * @param distortImagePoints True, to apply the distortion parameters of the camera
127  * @param world_T_optimizedCameras Resulting optimized camera poses providing minimal projection errors
128  * @param optimizedPlane Optimized plane that minimizes the projection errors
129  * @param iterations Number of iterations to be applied at most, if no convergence can be reached
130  * @param estimator Robust error estimator to be used
131  * @param lambda Initial Levenberg-Marquardt damping value which may be changed after each iteration using the damping factor, with range [0, infinity)
132  * @param lambdaFactor Levenberg-Marquardt damping factor to be applied to the damping value, with range [1, infinity)
133  * @param onlyFrontObjectPoints True, to avoid that the optimized 3D position lies behind any camera
134  * @param initialError Optional resulting averaged pixel error for the given initial parameters, in relation to the defined estimator
135  * @param finalError Optional resulting averaged pixel error for the final optimized parameters, in relation to the defined estimator
136  * @return True, if succeeded
137  */
138  static inline bool optimizePosesPlane(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& world_T_camera, const Vectors2& imagePointsFirst, const HomogenousMatrices4& world_T_cameras, const Plane3& plane, const ImagePointGroups& imagePointGroups, const bool distortImagePoints, HomogenousMatrices4& world_T_optimizedCameras, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), const bool onlyFrontObjectPoints = true, Scalar* initialError = nullptr, Scalar* finalError = nullptr);
139 
140  /**
141  * Optimizes the orientation of a plane in 3D spaces and several (inverted and flipped) camera poses concurrently.
142  * 3D plane object points are observed in several individual camera frames (with individual camera poses).<br>
143  * The first pose defines the static reference system while the remaining poses will be optimized accordingly.<br>
144  * The given poses must be inverted and flipped around the new x axis by 180 degree.
145  * @see minimizePosesPlane().
146  */
147  static bool optimizePosesPlaneIF(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& flippedCamera_T_world, const Vectors2& imagePointsFirst, const HomogenousMatrices4& flippedCameras_T_world, const Plane3& plane, const ImagePointGroups& imagePointGroups, const bool distortImagePoints, HomogenousMatrices4& optimizedFlippedCameras_T_world, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), const bool onlyFrontObjectPoints = true, Scalar* initialError = nullptr, Scalar* finalError = nullptr);
148 
149  /**
150  * Optimizes the orientation of a plane in 3D spaces and several camera poses concurrently.
151  * 3D plane object points are observed in several individual camera frames (with individual camera poses).<br>
152  * The first pose defines the static reference system while the remaining poses will be optimized accordingly.<br>
153  * The given poses are equivalent to extrinsic camera matrices and thus define a transformation from the camera coordinate system into the world coordinate system.
154  * @param pinholeCamera The pinhole camera profile defining the projection
155  * @param world_T_camera First camera pose of the first frame (corresponding with the first set of image points)
156  * @param world_T_cameras Further camera poses, at least 1
157  * @param imagePointPairGroups Groups of image pairs, one group for each further camera pose, each pair combines the observation of an plane object point in the first camera frame with the observation of the same object point in the further camera frame
158  * @param plane Initial plane on that all object points are located
159  * @param distortImagePoints True, to apply the distortion parameters of the camera
160  * @param world_T_optimizedCameras Resulting optimized camera poses providing minimal projection errors
161  * @param optimizedPlane Optimized plane that minimizes the projection errors
162  * @param iterations Number of iterations to be applied at most, if no convergence can be reached
163  * @param estimator Robust error estimator to be used
164  * @param lambda Initial Levenberg-Marquardt damping value which may be changed after each iteration using the damping factor, with range [0, infinity)
165  * @param lambdaFactor Levenberg-Marquardt damping factor to be applied to the damping value, with range [1, infinity)
166  * @param onlyFrontObjectPoints True, to avoid that the optimized 3D position lies behind any camera
167  * @param initialError Optional resulting averaged pixel error for the given initial parameters, in relation to the defined estimator
168  * @param finalError Optional resulting averaged pixel error for the final optimized parameters, in relation to the defined estimator
169  * @return True, if succeeded
170  */
171  static inline bool optimizePosesPlane(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& world_T_camera, const HomogenousMatrices4& world_T_cameras, const ImagePointsPairs& imagePointPairGroups, const Plane3& plane, const bool distortImagePoints, HomogenousMatrices4& world_T_optimizedCameras, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), const bool onlyFrontObjectPoints = true, Scalar* initialError = nullptr, Scalar* finalError = nullptr);
172 
173  /**
174  * Optimizes the orientation of a plane in 3D spaces and several (inverted and flipped) camera poses concurrently.
175  * 3D plane object points are observed in several individual camera frames (with individual camera poses).<br>
176  * The first pose defines the static reference system while the remaining poses will be optimized accordingly.<br>
177  * The given poses must be inverted and flipped around the new x axis by 180 degree.
178  * @see optimizePosesPlaneIF().
179  */
180  static bool optimizePosesPlaneIF(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& flippedCamera_T_world, const HomogenousMatrices4& flippedCameras_T_world, const ImagePointsPairs& imagePointPairGroups, const Plane3& plane, const bool distortImagePoints, HomogenousMatrices4& optimizedFlippedCameras_T_world, Plane3& optimizedPlane, const unsigned int iterations = 20u, const Estimator::EstimatorType estimator = Estimator::ET_SQUARE, Scalar lambda = Scalar(0.001), const Scalar lambdaFactor = Scalar(5), const bool onlyFrontObjectPoints = true, Scalar* initialError = nullptr, Scalar* finalError = nullptr);
181 };
182 
183 inline bool NonLinearOptimizationPlane::optimizeOnePoseOnePlane(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& world_T_cameraFirst, const HomogenousMatrix4& world_T_cameraSecond, const Plane3& plane, const ConstIndexedAccessor<Vector2>& imagePointsFirst, const ConstIndexedAccessor<Vector2>& imagePointsSecond, const bool distortImagePoints, HomogenousMatrix4& world_T_optimizedCameraSecond, Plane3& optimizedPlane, const unsigned int iterations, const Estimator::EstimatorType estimator, Scalar lambda, const Scalar lambdaFactor, const bool onlyFrontObjectPoints, Scalar* initialError, Scalar* finalError)
184 {
185  ocean_assert(pinholeCamera.isValid());
186  ocean_assert(world_T_cameraFirst.isValid() && world_T_cameraSecond.isValid());
187  ocean_assert(imagePointsFirst.size() == imagePointsSecond.size());
188 
189  const HomogenousMatrix4 flippedCameraFirst_T_world(PinholeCamera::standard2InvertedFlipped(world_T_cameraFirst));
190  const HomogenousMatrix4 flippedCameraSecond_T_world(PinholeCamera::standard2InvertedFlipped(world_T_cameraSecond));
191 
192  if (!optimizeOnePoseOnePlaneIF(pinholeCamera, flippedCameraFirst_T_world, flippedCameraSecond_T_world, plane, imagePointsFirst, imagePointsSecond, distortImagePoints, world_T_optimizedCameraSecond, optimizedPlane, iterations, estimator, lambda, lambdaFactor, onlyFrontObjectPoints, initialError, finalError))
193  {
194  return false;
195  }
196 
197  world_T_optimizedCameraSecond = PinholeCamera::invertedFlipped2Standard(world_T_optimizedCameraSecond);
198  return true;
199 }
200 
201 inline bool NonLinearOptimizationPlane::optimizePosesPlane(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& world_T_cameraFirst, const Vectors2& imagePointsFirst, const HomogenousMatrices4& world_T_cameras, const Plane3& plane, const ImagePointGroups& imagePointGroups, const bool distortImagePoints, HomogenousMatrices4& world_T_optimizedCameras, Plane3& optimizedPlane, const unsigned int iterations, const Estimator::EstimatorType estimator, Scalar lambda, const Scalar lambdaFactor, const bool onlyFrontObjectPoints, Scalar* initialError, Scalar* finalError)
202 {
203  const HomogenousMatrix4 flippedCameraFirst_T_world(PinholeCamera::standard2InvertedFlipped(world_T_cameraFirst));
204  const HomogenousMatrices4 flippedCameras_T_world(PinholeCamera::standard2InvertedFlipped(world_T_cameras));
205 
206  if (!optimizePosesPlaneIF(pinholeCamera, flippedCameraFirst_T_world, imagePointsFirst, flippedCameras_T_world, plane, imagePointGroups, distortImagePoints, world_T_optimizedCameras, optimizedPlane, iterations, estimator, lambda, lambdaFactor, onlyFrontObjectPoints, initialError, finalError))
207  {
208  return false;
209  }
210 
211  world_T_optimizedCameras = PinholeCamera::invertedFlipped2Standard(world_T_optimizedCameras);
212  return true;
213 }
214 
215 inline bool NonLinearOptimizationPlane::optimizePosesPlane(const PinholeCamera& pinholeCamera, const HomogenousMatrix4& firstPose, const HomogenousMatrices4& poses, const ImagePointsPairs& imagePointPairGroups, const Plane3& plane, const bool distortImagePoints, HomogenousMatrices4& world_T_optimizedCameras, Plane3& optimizedPlane, const unsigned int iterations, const Estimator::EstimatorType estimator, Scalar lambda, const Scalar lambdaFactor, const bool onlyFrontObjectPoints, Scalar* initialError, Scalar* finalError)
216 {
218 
219  if (!optimizePosesPlaneIF(pinholeCamera, PinholeCamera::standard2InvertedFlipped(firstPose), posesIF, imagePointPairGroups, plane, distortImagePoints, world_T_optimizedCameras, optimizedPlane, iterations, estimator, lambda, lambdaFactor, onlyFrontObjectPoints, initialError, finalError))
220  {
221  return false;
222  }
223 
224  world_T_optimizedCameras = PinholeCamera::invertedFlipped2Standard(world_T_optimizedCameras);
225  return true;
226 }
227 
228 }
229 
230 }
231 
232 #endif // META_OCEAN_GEOMETRY_NON_LINEAR_OPTIMIZATION_PLANE_H
virtual size_t size() const =0
Returns the number of accessible elements of this accessor object.
static HomogenousMatrixT4< U > standard2InvertedFlipped(const HomogenousMatrixT4< U > &world_T_camera)
Transforms a standard homogenous 4x4 viewing (extrinsic camera) matrix into an inverted and flipped c...
Definition: Camera.h:734
static HomogenousMatrixT4< U > invertedFlipped2Standard(const HomogenousMatrixT4< U > &flippedCamera_T_world)
Transforms an inverted and flipped camera pose into a standard camera pose.
Definition: Camera.h:757
EstimatorType
Definition of individual robust estimator types.
Definition: Estimator.h:34
@ ET_SQUARE
The standard square error estimator (L2).
Definition: Estimator.h:52
This class implements the basic functions for least square or robust optimization algorithms for non ...
Definition: NonLinearOptimization.h:34
This class implements least square or robust optimization algorithms for 3D planes.
Definition: NonLinearOptimizationPlane.h:29
static bool optimizeOnePoseOnePlaneIF(const PinholeCamera &pinholeCamera, const HomogenousMatrix4 &flippedCameraFirst_T_world, const HomogenousMatrix4 &flippedCameraSecond_T_world, const Plane3 &plane, const ConstIndexedAccessor< Vector2 > &imagePointsFirst, const ConstIndexedAccessor< Vector2 > &imagePointsSecond, const bool distortImagePoints, HomogenousMatrix4 &optimizedFlippedCameraSecond_T_world, Plane3 &optimizedPlane, const unsigned int iterations=20u, const Estimator::EstimatorType estimator=Estimator::ET_SQUARE, Scalar lambda=Scalar(0.001), const Scalar lambdaFactor=Scalar(5), const bool onlyFrontObjectPoints=true, Scalar *initialError=nullptr, Scalar *finalError=nullptr)
Optimizes the orientation of a plane in 3D spaces and the pose of one camera pose.
static bool optimizePosesPlaneIF(const PinholeCamera &pinholeCamera, const HomogenousMatrix4 &flippedCamera_T_world, const HomogenousMatrices4 &flippedCameras_T_world, const ImagePointsPairs &imagePointPairGroups, const Plane3 &plane, const bool distortImagePoints, HomogenousMatrices4 &optimizedFlippedCameras_T_world, Plane3 &optimizedPlane, const unsigned int iterations=20u, const Estimator::EstimatorType estimator=Estimator::ET_SQUARE, Scalar lambda=Scalar(0.001), const Scalar lambdaFactor=Scalar(5), const bool onlyFrontObjectPoints=true, Scalar *initialError=nullptr, Scalar *finalError=nullptr)
Optimizes the orientation of a plane in 3D spaces and several (inverted and flipped) camera poses con...
std::pair< Vectors2, Vectors2 > ImagePointsPair
Definition of a pair holding to sets of corresponding image points.
Definition: NonLinearOptimizationPlane.h:35
static bool optimizeOnePoseOnePlane(const PinholeCamera &pinholeCamera, const HomogenousMatrix4 &world_T_cameraFirst, const HomogenousMatrix4 &world_T_cameraSecond, const Plane3 &plane, const ConstIndexedAccessor< Vector2 > &imagePointsFirst, const ConstIndexedAccessor< Vector2 > &imagePointsSecond, const bool distortImagePoints, HomogenousMatrix4 &world_T_optimizedCameraSecond, Plane3 &optimizedPlane, const unsigned int iterations=20u, const Estimator::EstimatorType estimator=Estimator::ET_SQUARE, Scalar lambda=Scalar(0.001), const Scalar lambdaFactor=Scalar(5), const bool onlyFrontObjectPoints=true, Scalar *initialError=nullptr, Scalar *finalError=nullptr)
Optimizes the orientation of a plane in 3D spaces and the pose of one camera pose.
Definition: NonLinearOptimizationPlane.h:183
std::vector< ImagePointsPair > ImagePointsPairs
Definition of a vector holding pairs of corresponding image points.
Definition: NonLinearOptimizationPlane.h:40
static bool optimizePosesPlaneIF(const PinholeCamera &pinholeCamera, const HomogenousMatrix4 &flippedCamera_T_world, const Vectors2 &imagePointsFirst, const HomogenousMatrices4 &flippedCameras_T_world, const Plane3 &plane, const ImagePointGroups &imagePointGroups, const bool distortImagePoints, HomogenousMatrices4 &optimizedFlippedCameras_T_world, Plane3 &optimizedPlane, const unsigned int iterations=20u, const Estimator::EstimatorType estimator=Estimator::ET_SQUARE, Scalar lambda=Scalar(0.001), const Scalar lambdaFactor=Scalar(5), const bool onlyFrontObjectPoints=true, Scalar *initialError=nullptr, Scalar *finalError=nullptr)
Optimizes the orientation of a plane in 3D spaces and several (inverted and flipped) camera poses con...
static bool optimizePlane(const Plane3 &plane, const ConstIndexedAccessor< Vector3 > &pointAccessor, Plane3 &optimizedPlane, const unsigned int iterations=20u, const Estimator::EstimatorType estimator=Estimator::ET_SQUARE, Scalar lambda=Scalar(0.001), const Scalar lambdaFactor=Scalar(5), Scalar *initialError=nullptr, Scalar *finalError=nullptr)
Optimizes a 3D plane by reducing the distance between 3D object points and their projected plane poin...
static bool optimizePosesPlane(const PinholeCamera &pinholeCamera, const HomogenousMatrix4 &world_T_camera, const Vectors2 &imagePointsFirst, const HomogenousMatrices4 &world_T_cameras, const Plane3 &plane, const ImagePointGroups &imagePointGroups, const bool distortImagePoints, HomogenousMatrices4 &world_T_optimizedCameras, Plane3 &optimizedPlane, const unsigned int iterations=20u, const Estimator::EstimatorType estimator=Estimator::ET_SQUARE, Scalar lambda=Scalar(0.001), const Scalar lambdaFactor=Scalar(5), const bool onlyFrontObjectPoints=true, Scalar *initialError=nullptr, Scalar *finalError=nullptr)
Optimizes the orientation of a plane in 3D spaces and several camera poses concurrently.
Definition: NonLinearOptimizationPlane.h:201
bool isValid() const
Returns whether this matrix is a valid homogeneous transformation.
Definition: HomogenousMatrix4.h:1806
bool isValid() const
Returns whether this camera is valid.
Definition: PinholeCamera.h:1572
std::vector< ImagePoints > ImagePointGroups
Definition of a vector holding image points, so we have groups of image points.
Definition: geometry/Geometry.h:141
float Scalar
Definition of a scalar type.
Definition: Math.h:128
std::vector< HomogenousMatrix4 > HomogenousMatrices4
Definition of a vector holding HomogenousMatrix4 objects.
Definition: HomogenousMatrix4.h:73
std::vector< Vector2 > Vectors2
Definition of a vector holding Vector2 objects.
Definition: Vector2.h:64
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15