Go to the documentation of this file.
41 template<
class BaseOptimizerParameters>
91 <<
"setMaxIterations: changing the max nr of iters might lead to less accurate solutions and is not recommended! "
123 for (
size_t i = 0;
i < knownIn.size();
i++){
134 for (
size_t i = 0;
i < knownOut.size();
i++){
151 std::cout <<
str <<
"\n";
154 std::cout <<
"lossType: Geman McClure" <<
"\n";
157 std::cout <<
"lossType: Truncated Least-squares" <<
"\n";
160 throw std::runtime_error(
"GncParams::print: unknown loss type.");
163 std::cout <<
"muStep: " <<
muStep <<
"\n";
165 std::cout <<
"weightsTol: " <<
weightsTol <<
"\n";
166 std::cout <<
"verbosity: " <<
verbosity <<
"\n";
FastVector< uint64_t > IndexVector
Slots in the factor graph corresponding to measurements that we know are inliers.
Array< double, 1, 3 > e(1./3., 0.5, 2.)
void setWeightsTol(double value)
Set the maximum difference between the weights and their rounding in {0,1} to stop iterating.
std::vector< T, typename internal::FastDefaultVectorAllocator< T >::type > FastVector
A nonlinear optimizer that uses the Levenberg-Marquardt trust-region scheme.
IndexVector knownInliers
Slots in the factor graph corresponding to measurements that we know are outliers.
void setMuStep(const double step)
Set the graduated non-convexity step: at each GNC iteration, mu is updated as mu <- mu * muStep.
void setKnownInliers(const IndexVector &knownIn)
IndexVector knownOutliers
double weightsTol
If the weights are within weightsTol from being binary, stop iterating (only for TLS)
void setLossType(const GncLossType type)
Set the robust loss function to be used in GNC (chosen among the ones in GncLossType).
size_t maxIterations
Maximum number of iterations.
void setKnownOutliers(const IndexVector &knownOut)
double muStep
Multiplicative factor to reduce/increase the mu in gnc.
void setRelativeCostTol(double value)
Set the maximum relative difference in mu values to stop iterating.
GncParams()
Default constructor.
Verbosity verbosity
Verbosity level.
def step(data, isam, result, truth, currPoseIndex, isamArgs=())
void print(const std::string &str) const
Print.
GncLossType lossType
any other specific GNC parameters:
Verbosity
Verbosity levels.
BaseOptimizerParameters::OptimizerType OptimizerType
For each parameter, specify the corresponding optimizer: e.g., GaussNewtonParams -> GaussNewtonOptimi...
void setVerbosityGNC(const Verbosity value)
Set the verbosity level.
BaseOptimizerParameters baseOptimizerParams
GNC parameters.
GncLossType
Choice of robust loss function for GNC.
double relativeCostTol
If relative cost change is below this threshold, stop iterating.
bool equals(const GncParams &other, double tol=1e-9) const
Equals.
void setMaxIterations(const size_t maxIter)
Set the maximum number of iterations in GNC (changing the max nr of iters might lead to less accurate...
GncParams(const BaseOptimizerParameters &baseOptimizerParams)
Constructor.
gtsam
Author(s):
autogenerated on Fri Nov 1 2024 03:32:39