-
Notifications
You must be signed in to change notification settings - Fork 149
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SymForce] Add helpful err msg if unopt'zed factor
As demonstrated in #318 the AssertionError that's raised if the user attempts to create an optimizer with a factor that doesn't touch any optimized keys isn't very helpful. Adds a test that the intersection of the factor keys and the keys to optimize is not empty and raises a ValueError with extra information if it is (the old `AssertionError` would have been raised otherwise). Topic: err_msg_if_py_factor_unoptimized GitOrigin-RevId: bed40079b586a82a2c3e7072cf7c5a8bdf91ceb3
- Loading branch information
1 parent
6c3902d
commit f8cad34
Showing
2 changed files
with
26 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters