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

Pedsim agent avoid robot #1

Open
NamTruongTran0 opened this issue Aug 12, 2023 · 3 comments
Open

Pedsim agent avoid robot #1

NamTruongTran0 opened this issue Aug 12, 2023 · 3 comments

Comments

@NamTruongTran0
Copy link

NamTruongTran0 commented Aug 12, 2023

Hey Stephen,

thank you so much for your help. I fixed the issue. Now i can start your house example.

do you know which parameter should i change to update the global costmap more frequently? In my video you can see the agent walking from point A to point B but the path is very short thats why the global costmap always mark the path of the agent as an obstacle.

Link to the video: https://streamable.com/f3f3k6

Thank you in advance stephen ;)

@stephenadhi
Copy link
Owner

Hi, sorry for the late reply. The navigation is unfortunately out of the scope of this package. However, I am planning to release some examples using Nav2 in a separate repository in the near future :)

@BadrEssabri
Copy link

@NamTruongTran0: I saw that you edited your comment with the original asking "The pedsim agents always avoiding the robot while walking. Where can i change this setting? I want that the agent not avoiding the robot."

I had a similar question. My problem is that the agents (from the simulation) do not even see human. I also do not see in change in the social force, when they are near. This leads to the agents colliding with the robot.

Have you fixed this issue? Or maybe @stephenadhi can help solving this?

I have looked at other git issues from the original repo, but those proposed solutions did not work for me:
srl-freiburg#22
srl-freiburg#46
srl-freiburg#55
srl-freiburg#65

@BadrEssabri
Copy link

Nevermind, I found the solution to the problem.

In case anyone else encounters this issue, you should consider these things:

  1. Make sure that on the topic /pedsim_simulator/robot_position, the robot position is being published
  2. In the scenario file you have created a robot agent (denoted by type 2), like this:

The waypoints do not seem to matter that much. I am using nav2 for the robot controller and planner and it works even when not considering any of the waypoints set in the scenario file.

  1. This might also be necessary, but I have not tested it: In the config file of the pedsim_simulator package, you need to set the robot_mode (op_mode in the config file) to 0, like this:

pedsim_simulator:
ros__parameters:
odom_frame_id: "map" <------ (4)
base_frame_id: "base_footprint"
groups_enabled: true
max_robot_speed: 0.3
update_rate: 25.0
simulation_factor: 1.0
op_mode: 0 <------- (3)

  1. Lastly make sure that the parent frame of the both the agents and the robot align. As you can see in the config file, I set the odom_frame_id to "map" so that the frames align.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants