-
Notifications
You must be signed in to change notification settings - Fork 769
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
Test and fix all conditionals #1386
Conversation
…fy invariants there, as well.
For reviewing, look at |
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.
Approving, but I would really like to understand why K cannot be dependent on any arguments. Or should it be "K should not depend on any arguments"?
See my comment above. It is predicated on invariants set forth in Conditional.h. I will do some more commits in this PR as I think GaussianMixtureFactor is still wrong as well. |
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.
I think this looks great.
To explain the previous behavior: I put the normalization constants as a DiscreteFactor, which should be somewhat equivalent, but of course a lot more hacky.
Yeah, GMF will need the same modifications |
I started addressing issues with GMF in a different PR, and I also made the requested changes there… |
Turns out GaussianMixture error() was wrong! I added very thorough checking of all conditionals with all supported arguments, in both C++ and python, and made sure all compiled and worked. In the process I found out that GaussianMixture did not satisfy its invariants. The resolution is documented in GaussianMixture.h:
This was a lot of work but I think this level of care is needed to ensure correctness in hybrid inference.