Skip to content

AirSim ROS wrapper uses settings.json at default path, regardless of settings given to AirSim  #3530

Description

@ercanburak

Bug report

  • AirSim Version/#commit: v1.4.0 - Linux / 6d20663
  • UE/Unity version: UE4 version 4.25.1
  • autopilot version: N/A
  • OS Version: Ubuntu 18.04

What's the issue you encountered?

AirSim has the ability to load settings using 4 different ways, as described in docs. For example, one can give the path to a specific settings file with the --settings command line argument, instead of loading the settings from ~/Documents/AirSim/settings.json. However, while AirSim can load the correct settings as described in the docs, the AirSim ROS wrapper always uses settings from the file at default path, i.e. ~/Documents/AirSim/settings.json.

Therefore, if one starts an Unreal Engine environment binary with different settings (other than the one at the default path), this gives result to an inconsistency between the real settings used by AirSim, and the settings AirSim ROS wrapper thinks that are used. This inconsistency can cause many more issues on the ROS side. As an example, please read the settings and reproducing steps below.

Settings

I use two different setting files to demonstrate the issue, which I share in this gist. First, we have a my_settings.json file that we give to AirSim, with a command like /home/bercan/Downloads/LandscapeMountains/LinuxNoEditor/LandscapeMountains.sh --settings '/home/bercan/Documents/AirSim/my_settings.json'. Second, we have a settings.json file with the default name, which we put at the default path (under ~/Documents/AirSim on Linux systems). Both of these setting files include a camera, and the only difference they have is the camera name, with my_settings.json having MyCamera1 as the name, and settings.json having Camera1.

How can the issue be reproduced?

  1. Have two different setting files ready, with inconsistent settings, with first having the default name settings.json and second having a different name, such as the ones that I share in this gist, and put them on default folder (under ~/Documents/AirSim on Linux systems).
  2. Run AirSim by giving the path to the second settings file (by using the first option in the doc), with a command like /home/bercan/Downloads/LandscapeMountains/LinuxNoEditor/LandscapeMountains.sh --settings '/home/bercan/Documents/AirSim/my_settings.json', and observe that the correct settings at 'my_settings.json' are loaded, as in the screenshot below.
    airsim_settings
  3. Have your AirSim ROS wrapper built and sourced as described in docs, and launch the AirSim ROS wrapper node with the command roslaunch airsim_ros_pkgs airsim_node.launch
  4. By using a command like rostopic list, observe that the AirSim ROS wrapper tries to publish camera images from a camera named Camera1 as in settings.json, instead of MyCamera1 as in my_settings.json.
  5. Also, by using a command like rostopic echo /airsim_node/MyCar/Camera1/Scene/compressed, observe that the camera images are not actually published.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions