f1tenth / f1tenth_gym_ros

Containerized ROS communication bridge for F1TENTH gym environment.
MIT License
154 stars 106 forks source link

only one agent showed up despite num_agent changed to 2 in sim.yaml #22

Closed yqchau closed 2 years ago

yqchau commented 2 years ago

Describe the bug Only one vehicle showed up in the simulator despite changing the num_agent parameter in config/sim.yaml

To Reproduce Steps to reproduce the behavior:

  1. change num_agent=2 in config/sim.yaml
  2. docker exec -it f1tenth_gym_ros_sim_1 /bin/bash
  3. source /opt/ros/foxy/setup.bash
  4. source install/local_setup.bash
  5. ros2 launch f1tenth_gym_ros gym_bridge_launch.py

Expected behavior 2 vehicles showed up at their respective starting pose as indicated in config/sim.yaml

Screenshots

Screenshot 2022-03-15 at 4 40 50 PM

Laptop:

Additional context I am trying to race 2 vehicles against each other.

hzheng40 commented 2 years ago

You'll need to call colcon build after you change the yaml file. (after step 2 in your steps described)

xkhainguyen commented 1 year ago

It seems like multi-agent mode is in different branch and run in ROS Melodic. Could you clarify it? @hzheng40

hzheng40 commented 1 year ago

No it runs in the same branch.

xkhainguyen commented 1 year ago

I checked it again and I had to add a new node in rviz to see it. Thanks.