-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Description
I have recently been testing Airsim + Unreal on a gaming desktop to see if I can get better performance than what I was able to get on a laptop. For reference, this is the desktop:
Alienware Aurora Ryzen™ Edition R10 Gaming Desktop
https://www.dell.com/en-us/shop/cty/pdp/spd/alienware-aurora-r10-desktop/wdryzr10mx?configurationid=8e4e7c7e-3794-4eef-abb4-173cdc0a3004
As part of my work, I am interested in flying a drone along a pre-programmed path, with the images from the cameras being captured at a high frame rate, ideally 30fps, which would recreate the video feed of a camera attached to a real drone. I am using this video for evaluation of different VSLAM/VO/VIO algorithms in the simulated environment with the goal of validating an approach before deploying it to a real environment. I have a stereo camera pair instantiated with individual resolutions of 848x800.
The issue I am having is that despite trying multiple different approaches, the only way I can get a decent frame rate of image capture is by running the simulation at a very low clock speed, like 0.1. I have tried using the built in recording tool in the Unreal editor, and even some custom python scripting which will record the pose of the robot and the camera image, so that I have ground truth information for each recorded frame.
My current simulation approach looks like this:
- set the clock speed to 0.1 in settings
- Set the display type to NoDisplay in settings
- Start the simulation
- Start the logging script, which records images at and pose of the drone. The recording script is done in a way that the rate limit of the capture loop will be defined by how fast the image capturing calls will allow it to run. I am using something of the form of the following to get the images, following the example script provided in the airsim source:
responses = client.simGetImages([
airsim.ImageRequest("front_left_custom", airsim.ImageType.Scene, False, True),
airsim.ImageRequest("front_right_custom", airsim.ImageType.Scene, False, True)]) - Allow the simulation to run, and halt the capturing script when the simulation is complete.
What I am seeing right now is that the performance of this logging program doesn't improve much, even when run on more powerful hardware. I would have expected with enough CPU, GPU, and RAM available, and with no display showing, that the image capture could run close to real time at a high frame rate.
Is there maybe something I am missing here? I have seen similar performance when trying to get the images over ros topic too. This is very easily done in gazebo so I am surprised that I am having so much trouble with airsim, which I expected to be much better. I took a scan of the issues on git and I am seeing some others mentioning similar issues.