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

Add initial pose subscriber #45

Merged
merged 3 commits into from
Jan 6, 2023
Merged

Add initial pose subscriber #45

merged 3 commits into from
Jan 6, 2023

Conversation

nahueespinosa
Copy link
Member

This patch adds an initial pose subscriber to beluga_amcl that logs the received pose.

Related to #41.

@nahueespinosa nahueespinosa self-assigned this Jan 5, 2023
@nahueespinosa nahueespinosa added cpp Related to C++ code ros Related to ROS enhancement New feature or request labels Jan 5, 2023
glpuga
glpuga previously approved these changes Jan 5, 2023
Copy link
Collaborator

@glpuga glpuga left a comment

Choose a reason for hiding this comment

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

LGTM.

If we are not going to fully implement this functionality soon, I'd add a very visible WARNING log at the end of the callback to announce that for the time being the new pose is only logged, but not really used.

If we are going to address this in the next few days, then there's no need to add any log.

beluga_amcl/src/amcl_node.cpp Outdated Show resolved Hide resolved
@olmerg
Copy link
Collaborator

olmerg commented Jan 6, 2023

I was making the same solution in branch initial_pose_ol, but after I transform to eigen I cannot update the estimated particle filter pose. I test with

  particle_filter_->update_motion( out); 
  particle_filter_->importance_sample();
  particle_filter_->resample();

It take a lot of time(steps) to update the estimated pose (I only rotate the robot).
y
I will follow the solution to understand Beluga :)

Just to take account about this issue nav2_amcl also support add a initialpose parameter:

  get_parameter("set_initial_pose", set_initial_pose_);
  get_parameter("initial_pose.x", initial_pose_x_);
  get_parameter("initial_pose.y", initial_pose_y_);
  get_parameter("initial_pose.z", initial_pose_z_);
  get_parameter("initial_pose.yaw", initial_pose_yaw_);

@nahueespinosa
Copy link
Member Author

I'd add a very visible WARNING log at the end of the callback to announce that for the time being the new pose is only logged, but not really used.

@glpuga Sounds good! Done in 7519731.

@olmerg Right, there is no way to set an initial pose for the particle filter yet. About the parameters, that's correct, it's mentioned in #41.

@nahueespinosa nahueespinosa merged commit 8862b86 into master Jan 6, 2023
@nahueespinosa nahueespinosa deleted the nahuel/initial_pose branch January 6, 2023 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cpp Related to C++ code enhancement New feature or request ros Related to ROS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants