Skip to content

Custom factors and degrees of freedom. #1104

Answered by mikesheffler
biggibig asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, you can! GPS is a good example of affecting only a subset of the full 6DOF pose. Another is the Relative Elevation factor, where z, if you will, is being affected, but rotations and other changes in translation (x, and y) are not. Take a look at the evaluateError method for that class.

The only bit of warning is that it is very easy to be wrong when calculating the Jacobians for your custom factor. Take a look at an overview of some relevant math for hints on how to do your calculations. Check your work by putting together a unit test that uses GTSAM's numerical derivative capabilities; for example, here's the unit test for the Relative Elevation factor.

Finally, consider expression …

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@biggibig
Comment options

Answer selected by ProfFan
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants