Go to the documentation of this file.
35 std::vector<std::tuple<Point2, Point2, Point2>>
70 const std::vector<std::tuple<Point2, Point2, Point2>>& triplets,
81 return {
F1.matrix(), F2.matrix()};
83 return {
F1.matrix(), F2.matrix().transpose()};
85 return {
F1.matrix().transpose(), F2.matrix()};
87 return {
F1.matrix().transpose(), F2.matrix().transpose()};
89 throw std::runtime_error(
90 "TransferFactor: invalid EdgeKey configuration.");
98 std::function<
Vector(
const F&,
const F&)> transfer = [&](
const F&
F1,
104 const auto& [pa, pb,
pc] =
tuple;
107 errors.segment<2>(idx) =
error;
112 if (H1) *H1 = numericalDerivative21<Vector, F, F>(transfer,
F1, F2);
113 if (H2) *H2 = numericalDerivative22<Vector, F, F>(transfer,
F1, F2);
114 return transfer(
F1, F2);
std::vector< std::tuple< Point2, Point2, Point2 > > triplets_
Point triplets.
double error(const Values &c) const override
Point2 EpipolarTransfer(const Matrix3 &Fca, const Point2 &pa, const Matrix3 &Fcb, const Point2 &pb)
Transfer projections from cameras a and b to camera c.
Some functions to compute numerical derivatives.
std::uint32_t i() const
Retrieve high 32 bits.
TransferFactor(EdgeKey key1, EdgeKey key2, const Point2 &pa, const Point2 &pb, const Point2 &pc, const SharedNoiseModel &model=nullptr)
Constructor for a single triplet of points.
TransferFactor(EdgeKey key1, EdgeKey key2, const std::vector< std::tuple< Point2, Point2, Point2 >> &triplets, const SharedNoiseModel &model=nullptr)
Constructor that accepts a vector of point triplets.
noiseModel::Base::shared_ptr SharedNoiseModel
int RealScalar int RealScalar int RealScalar * pc
noiseModel::Diagonal::shared_ptr model
Non-linear factor base classes.
std::pair< Matrix3, Matrix3 > getMatrices(const F &F1, const F &F2) const
EdgeKey key2_
the two EdgeKeys
std::uint32_t j() const
Retrieve low 32 bits.
Matrix * OptionalMatrixType
Vector evaluateError(const F &F1, const F &F2, OptionalMatrixType H1=nullptr, OptionalMatrixType H2=nullptr) const override
vector of errors returns 2*N vector
gtsam
Author(s):
autogenerated on Fri Nov 1 2024 03:42:30