Skip to content
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

Fix warnings and docs #1181

Merged
merged 3 commits into from
May 1, 2022
Merged

Fix warnings and docs #1181

merged 3 commits into from
May 1, 2022

Conversation

varunagrawal
Copy link
Collaborator

  1. Fix the warnings due to type mismatch in newly introduced methods.
  2. Update docs for IMU factors clarifying what frame the measurements are in.

@varunagrawal varunagrawal added the quick-review Quick and easy PR to review label Apr 29, 2022
@varunagrawal varunagrawal self-assigned this Apr 29, 2022
@@ -365,7 +365,7 @@ boost::optional<Pose2> Pose2::Align(const Matrix& a, const Matrix& b) {
"Pose2:Align expects 2*N matrices of equal shape.");
}
Point2Pairs ab_pairs;
for (size_t j=0; j < a.cols(); j++) {
for (size_t j=0; j < size_t(a.cols()); j++) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the pr, I was also thinking of fixing them :-)
IMO, for C++ the C-type cast used here might be replaced by the more explicit static_cast.
That's in general. For these pair of warnings in particular I think it may make more sense to replace the loop counter variable from size_t to Eigen::Index, that should avoid casts at all and fix warnings, but haven't tried it yet...

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great suggestion. I'll try them out and update!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Eigen::Index works great!

Copy link
Member

@jlblancoc jlblancoc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jlblancoc jlblancoc merged commit f4bcb11 into develop May 1, 2022
@jlblancoc jlblancoc deleted the fix/warnings branch May 1, 2022 07:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
quick-review Quick and easy PR to review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants