Factor that represents bearing and range measurements that incorporate a semantic class measurement.
More...
#include <SemanticBearingRangeFactor.h>
|
| SemanticBearingRangeFactor ()=default |
|
| SemanticBearingRangeFactor (const gtsam::Key &poseKey, const gtsam::Key &pointKey, const gtsam::DiscreteKey &discreteKey, const std::vector< double > measuredProbs, const BearingType &measuredBearing, const RangeType &measuredRange, const gtsam::SharedNoiseModel &model) |
|
virtual | ~SemanticBearingRangeFactor ()=default |
|
SemanticBearingRangeFactor & | operator= (const SemanticBearingRangeFactor &rhs) |
|
double | error (const gtsam::Values &continuousVals, const DiscreteValues &discreteVals) const override |
|
size_t | dim () const override |
|
boost::shared_ptr< gtsam::GaussianFactor > | linearize (const gtsam::Values &continuousVals, const DiscreteValues &discreteVals) const override |
|
bool | equals (const DCFactor &other, double tol=1e-9) const override |
|
double | logNormalizingConstant (const gtsam::Values &values) const override |
|
| DCFactor ()=default |
|
| DCFactor (const gtsam::KeyVector &continuousKeys, const gtsam::DiscreteKeys &discreteKeys) |
|
| DCFactor (const gtsam::DiscreteKeys &discreteKeys) |
|
DCFactor & | operator= (const DCFactor &rhs) |
|
virtual | ~DCFactor ()=default |
|
gtsam::DiscreteKeys | discreteKeys () const |
|
virtual gtsam::DecisionTreeFactor | toDecisionTreeFactor (const gtsam::Values &continuousVals, const DiscreteValues &discreteVals) const |
|
template<typename NonlinearFactorType > |
double | nonlinearFactorLogNormalizingConstant (const NonlinearFactorType &factor, const gtsam::Values &values) const |
|
std::vector< double > | evalProbs (const gtsam::DiscreteKey &dk, const gtsam::Values &continuousVals) const |
|
gtsam::DecisionTreeFactor | conditionalTimes (const gtsam::DecisionTreeFactor &f, const gtsam::Values &continuousVals, const DiscreteValues &discreteVals) const |
|
template<typename PoseType, typename PointType, typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
class dcsam::SemanticBearingRangeFactor< PoseType, PointType, BearingType, RangeType >
Factor that represents bearing and range measurements that incorporate a semantic class measurement.
◆ Base
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
◆ SemanticBearingRangeFactor() [1/2]
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
◆ SemanticBearingRangeFactor() [2/2]
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
dcsam::SemanticBearingRangeFactor< PoseType, PointType, BearingType, RangeType >::SemanticBearingRangeFactor |
( |
const gtsam::Key & |
poseKey, |
|
|
const gtsam::Key & |
pointKey, |
|
|
const gtsam::DiscreteKey & |
discreteKey, |
|
|
const std::vector< double > |
measuredProbs, |
|
|
const BearingType & |
measuredBearing, |
|
|
const RangeType & |
measuredRange, |
|
|
const gtsam::SharedNoiseModel & |
model |
|
) |
| |
|
inline |
◆ ~SemanticBearingRangeFactor()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
◆ dim()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
Returns the number of rows in the Jacobian with respect to the continuous variables for this factor. Internally this is used in the conversion to a gtsam::NonlinearFactor
TODO(kevin): not sure if needed???
This will be specific to the model being implemented, so it is a pure virtual function and must be overridden
- Returns
- the dimension (number of rows) in the Jacobian of the
error
function with respect to continuous variables for
Implements dcsam::DCFactor.
◆ equals()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
Returns true when the DCFactor is equal to other
This will be specific to the model being implemented, so it is a pure virtual function and must be overridden.
- Parameters
-
other | - the DCFactor for which to test equality. |
tol | = 1e-9 - numerical tolerance for any floating point comparisons. |
Implements dcsam::DCFactor.
◆ error()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
Return the error for the DCFactor given an assignment to the variables referenced by the discrete keys and the continuous keys (keys_
).
This will be specific to the model being implemented, so it is a pure virtual function and must be overridden.
NOTE: Depending on the application, it may be important that the error function is normalized, i.e. it corresponds to a proper negative log-likelihood, rather than the negative log-likelihood with normalization constants discarded.
- Parameters
-
continuousVals | - the values assigned to the continuous variables, must contain keys in keys_ member variable |
discreteVals | - likewise, the values assigned to discrete variables, must contain keys in discreteKeys_ |
- Returns
- error (usually the negative log-likelihood) for the measurement model as a double.
Implements dcsam::DCFactor.
◆ linearize()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
Linearize the error function with respect to the continuous variables (given in keys_
) at the point specified by continuousVals
. Since this Jacobian can be dependent on the assignment to discrete variables as well, they are required as a parameter.
This will be specific to the model being implemented, so it is a pure virtual function and must be overridden.
- Parameters
-
continuousVals | - Assignment to the continuous variables in keys_ |
discreteVals | - Likewise, assignment to the discrete variables in discreteKeys__ . |
Implements dcsam::DCFactor.
◆ logNormalizingConstant()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
Calculate a normalizing constant for this DCFactor. Most implementations will be able to use the helper function nonlinearFactorLogNormalizingConstant provided below for most of the calculation. TODO(Kurran) is this the cleanest way to do this? Seems necessary for the DCMaxMixtureFactor implementations etc...
Reimplemented from dcsam::DCFactor.
◆ operator=()
template<typename PoseType , typename PointType , typename BearingType = typename gtsam::Bearing<PoseType, PointType>::result_type, typename RangeType = typename gtsam::Range<PoseType, PointType>::result_type>
The documentation for this class was generated from the following file: