-
Notifications
You must be signed in to change notification settings - Fork 773
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some refactoring and new test #1349
Conversation
Working on this, #1343 is the WIP PR. I'm having a bit of trouble initializing the updated |
} | ||
|
||
/********************************************************************************* | ||
// Create a hybrid nonlinear factor graph f(x0, x1, m0; z0, z1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This docstring should say "Create a hybrid linear/gaussian factor graph", right?
return discreteElimination(factors, frontalKeys); | ||
} | ||
|
||
} else { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any particular reason for this nesting? Even an else if
will only evaluate if discrete_only
is false.
@@ -99,6 +99,7 @@ std::function<double(const Assignment<Key> &, double)> prunerFunc( | |||
} | |||
|
|||
/* ************************************************************************* */ | |||
// TODO(dellaert): what is this non-const method used for? Abolish it? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is used internally to update the BayesNet with the pruned conditionals after pruning them based on the prunedDecisionTree
.
@varunagrawal I refactored the test (and a bit of the elimination code). I expected a normalized DiscreteConditional on m after elimination, rather than an unnormalized factor. I propose you approve and merge this PR and then let's discuss about why that's not true.