Fixing a variable/value in the factor graph

956 views
Skip to first unread message

Mathias Bürki

unread,
Oct 7, 2020, 8:24:13 AM10/7/20
to gtsam users
Hi,

I am wondering if there's a way to fix a variable/value in the factor graph, such that it does not get optimized/updated during the optimization phase, equivalent e.g. to 'SetParameterBlockConstant" in Ceres.

To clarify, I do not want to a add a (very strong) prior factor on the variable (which might have a similar effect), but really kind of "turn off" the variable from being optimized altogether, such that the complexity of optimizing the factor graph is reduced accordingly. 

I came across the NonlinearEquality constraint, but wasn't quite sure if this is really equivalent to setting a variable/value constant?

Any help regarding this is highly appreciated. Thanks!

Cheers, 
Mathias

Dellaert, Frank

unread,
Oct 7, 2020, 10:07:00 AM10/7/20
to Mathias Bürki, gtsam users
Yes, NonlinearEquality is what you want. We are working on actually enabling this (unary hard constraints) and very densely connected hard constraints at the optimizer level. Esp. the latter should yield great computational savings. NonlinearEquality factors should be very fast, but because the variables are still in the graph they do create extra connectivity that we could avoid in the new implementation of this.

Frank

From: gtsam...@googlegroups.com <gtsam...@googlegroups.com> on behalf of Mathias Bürki <mathias...@gmail.com>
Sent: Wednesday, October 7, 2020 8:24:13 AM
To: gtsam users <gtsam...@googlegroups.com>
Subject: [GTSAM] Fixing a variable/value in the factor graph
 
--
You received this message because you are subscribed to the Google Groups "gtsam users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gtsam-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gtsam-users/96162783-3b5e-4a7d-b5ee-c64ada8bbabfn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages