refactor readme / docs, add no view settings, good old housekeeping
This commit is contained in:
Родитель
2b0760f5fd
Коммит
d4204f5ac9
|
@ -1,3 +1,4 @@
|
|||
baselines/__pycache__
|
||||
*pyc
|
||||
env/
|
||||
ADRL/
|
||||
|
|
98
README.md
98
README.md
|
@ -1,86 +1,32 @@
|
|||
# AirSim Drone Racing Lab
|
||||
|
||||
|
||||
## Quickstart
|
||||
- [Website](https://microsoft.github.io/AirSim-Drone-Racing-Lab/)
|
||||
- [Linux and Windows Binaries](https://github.com/microsoft/AirSim-Drone-Racing-Lab/releases)
|
||||
- [Python API Doc](https://microsoft.github.io/AirSim-Drone-Racing-Lab/api.html), [airsimdroneracinglab PyPI package](https://pypi.org/project/airsimdroneracinglab/)
|
||||
|
||||
<img src="https://github.com/madratman/airsim_neurips_gifs/blob/master/imgs/neurips_b99_3_drones.gif?raw=true" width="275"> <img src="https://github.com/madratman/airsim_neurips_gifs/blob/master/imgs/neurips_soccer_field_8_drones.gif?raw=true" width="275"> <img src="https://github.com/madratman/airsim_neurips_gifs/blob/master/imgs/neurips_zhangjiajie_4_drones.gif?raw=true" width="275">
|
||||
|
||||
## Quickstart
|
||||
- [Linux and Windows Binaries](https://github.com/microsoft/AirSim-Drone-Racing-Lab/releases)
|
||||
- Python API
|
||||
- Installation:
|
||||
- [`pip install airsimdroneracinglab`](https://pypi.org/project/airsimdroneracinglab/)
|
||||
- [API Docs](https://microsoft.github.io/AirSim-Drone-Racing-Lab/api.html)
|
||||
|
||||
Note: If you use this repository in your research, please cite our pre-print, [AirSim Drone Racing Lab](https://arxiv.org/abs/2003.05654).
|
||||
|
||||
```
|
||||
@article{madaan2020airsim,
|
||||
title={AirSim Drone Racing Lab},
|
||||
author={Madaan, Ratnesh and Gyde, Nicholas and Vemprala, Sai and Brown, Matthew and Nagami, Keiko and Taubner, Tim and Cristofalo, Eric and Scaramuzza, Davide and Schwager, Mac and Kapoor, Ashish},
|
||||
journal={arXiv preprint arXiv:2003.05654},
|
||||
year={2020}
|
||||
}
|
||||
```
|
||||
|
||||
### Using AirSim Drone Racing Lab Binaries
|
||||
#### Downloading
|
||||
- Linux
|
||||
- Use the [download_linux_binaries.sh](download_linux_binaries.sh) script
|
||||
- Python client:
|
||||
`pip install airsimdroneracinglab`
|
||||
|
||||
- Windows
|
||||
|
||||
#### Running
|
||||
- Linux
|
||||
- Running in windowed mode:
|
||||
```
|
||||
./ADRL/ADRL.sh -windowed
|
||||
```
|
||||
- Running headless (with rendering of images enabled):
|
||||
```
|
||||
DISPLAY= ./ADRL/ADRL.sh
|
||||
```
|
||||
- To disable rendering completely for training planning and / or control policies, you can use:
|
||||
```
|
||||
./ADRL/ADRL.sh -nullrhi
|
||||
```
|
||||
Note that `simGetImages` will not work with this option.
|
||||
- To increase speed of `simGetImages` / increase speed of Unreal Engine's game thread;
|
||||
- Add the `"ViewMode": "NoDisplay"` to your settings.json file, or use [this file](https://gist.github.com/madratman/5fadbb08f65e9c0187ccc1f5090fc086) directly.
|
||||
This disables rendering in the main viewport camera.
|
||||
Then run the binary with the following options.
|
||||
```
|
||||
./AirSimDroneRacingLab.sh -windowed -NoVSync -BENCHMARK
|
||||
```
|
||||
You can also use the Unreal console commands `Stat FPS`, `Stat UnitGraph`, `r.VSync`, `t.maxFPS`. See [Issue #111](https://github.com/microsoft/AirSim-Drone-Racing-Lab/issues/111) for more details.
|
||||
|
||||
- Windows
|
||||
- Navigate to the `ADRL/` directory, and double-click `run.bat` (or `ADRL.exe -windowed`)
|
||||
|
||||
## Using Docker
|
||||
- Prerequisites:
|
||||
- Install [docker-ce](https://docs.docker.com/install/linux/docker-ce/ubuntu/).
|
||||
- Complete the desired [post-installation steps for linux](https://docs.docker.com/install/linux/linux-postinstall/) after installing docker.
|
||||
At the minimum, the page tells you how torun docker without root, and other useful setup options.
|
||||
- Install [nvidia-docker2](https://github.com/NVIDIA/nvidia-docker/wiki/Installation-(version-2.0)).
|
||||
|
||||
- Dockerfile:
|
||||
We provide a sample [dockerfile](docker/Dockerfile) you can modify.
|
||||
It downloads the training and qualification binaries automatically, and installs the python client.
|
||||
By default, it uses Ubuntu 18.04 and CUDA 10.0 with OpenGL, and is build on top of [nvidia/cudagl:10.0-devel-ubuntu18.04](https://hub.docker.com/r/nvidia/cudagl).
|
||||
This can be changed of course, as explained in the following section.
|
||||
|
||||
- Building the docker image:
|
||||
You can use [build_docker_image.py](docker/build_docker_image.py) to build the dockerfile above (or your own custom one)
|
||||
**Usage** (with default arguments)
|
||||
```shell
|
||||
cd docker/;
|
||||
python3 build_docker_image.py \
|
||||
--dockerfile Dockerfile \
|
||||
--base_image nvidia/cudagl:10.0-devel-ubuntu18.04 \
|
||||
-- target_image airsim_neurips:10.0-devel-ubuntu18.04
|
||||
```
|
||||
- Running the docker image:
|
||||
See [docker/run_docker_image.sh](docker/run_docker_image.sh) to run the docker image:
|
||||
**Usage**
|
||||
- for running default image, training binaries, in windowed mode:
|
||||
`$ ./run_docker_image.sh "" training`
|
||||
- for running default image, training binaries, in headless mode:
|
||||
`$ ./run_docker_image.sh "" training headless`
|
||||
- for running a custom image in windowed mode, pass in you image name and tag:
|
||||
`$ ./run_docker_image.sh DOCKER_IMAGE_NAME:TAG`
|
||||
- for running a custom image in headless mode, pass in you image name and tag, followed by "headless":
|
||||
`$ ./run_docker_image.sh DOCKER_IMAGE_NAME:TAG headless`
|
||||
- [Linux](docs/using_binaries.md#linux)
|
||||
- [Windows](docs/using_binaries.md#windows)
|
||||
- [Docker on Linux](docs/docker.md)
|
||||
|
||||
## AirSim Drone Racing Lab Features and API
|
||||
- The API is documented at [airsimdroneracinglab API doc](https://microsoft.github.io/AirSim-Drone-Racing-Lab/api.html)
|
||||
- The API is documented [here](https://microsoft.github.io/AirSim-Drone-Racing-Lab/api.html)
|
||||
|
||||
## Questions
|
||||
Please open a Github Issue on **this** repository (not [AirSim](https://github.com/microsoft/AirSim)) for any technical questions associated with AirSim Drone Racing Lab.
|
||||
|
|
|
@ -0,0 +1,34 @@
|
|||
## Using Docker with Linux Binaries
|
||||
- Prerequisites:
|
||||
- Install [docker-ce](https://docs.docker.com/install/linux/docker-ce/ubuntu/).
|
||||
- Complete the desired [post-installation steps for linux](https://docs.docker.com/install/linux/linux-postinstall/) after installing docker.
|
||||
At the minimum, the page tells you how torun docker without root, and other useful setup options.
|
||||
- Install [nvidia-docker2](https://github.com/NVIDIA/nvidia-docker/wiki/Installation-(version-2.0)).
|
||||
|
||||
- Dockerfile:
|
||||
We provide a sample [dockerfile](docker/Dockerfile) you can modify.
|
||||
It downloads the training and qualification binaries automatically, and installs the python client.
|
||||
By default, it uses Ubuntu 18.04 and CUDA 10.0 with OpenGL, and is build on top of [nvidia/cudagl:10.0-devel-ubuntu18.04](https://hub.docker.com/r/nvidia/cudagl).
|
||||
This can be changed of course, as explained in the following section.
|
||||
|
||||
- Building the docker image:
|
||||
You can use [build_docker_image.py](docker/build_docker_image.py) to build the dockerfile above (or your own custom one)
|
||||
**Usage** (with default arguments)
|
||||
```shell
|
||||
cd docker/;
|
||||
python3 build_docker_image.py \
|
||||
--dockerfile Dockerfile \
|
||||
--base_image nvidia/cudagl:10.0-devel-ubuntu18.04 \
|
||||
-- target_image airsim_neurips:10.0-devel-ubuntu18.04
|
||||
```
|
||||
- Running the docker image:
|
||||
See [docker/run_docker_image.sh](docker/run_docker_image.sh) to run the docker image:
|
||||
**Usage**
|
||||
- for running default image, training binaries, in windowed mode:
|
||||
`$ ./run_docker_image.sh "" training`
|
||||
- for running default image, training binaries, in headless mode:
|
||||
`$ ./run_docker_image.sh "" training headless`
|
||||
- for running a custom image in windowed mode, pass in you image name and tag:
|
||||
`$ ./run_docker_image.sh DOCKER_IMAGE_NAME:TAG`
|
||||
- for running a custom image in headless mode, pass in you image name and tag, followed by "headless":
|
||||
`$ ./run_docker_image.sh DOCKER_IMAGE_NAME:TAG headless`
|
|
@ -0,0 +1,51 @@
|
|||
## Using ADRL Binaries
|
||||
### Linux
|
||||
- Downloading
|
||||
- Use the [download_linux_binaries.sh](../download_linux_binaries.sh) script.
|
||||
- Python client:
|
||||
`pip install airsimdroneracinglab`
|
||||
|
||||
- Running
|
||||
- Running in windowed mode:
|
||||
```
|
||||
./ADRL/ADRL.sh -windowed
|
||||
```
|
||||
|
||||
- Running headless (with rendering of images enabled):
|
||||
```
|
||||
DISPLAY= ./ADRL/ADRL.sh
|
||||
```
|
||||
|
||||
- For more command line options, see [here](#command-line-options).
|
||||
|
||||
### Windows
|
||||
- Downloading
|
||||
- Go to the [release tab](https://github.com/microsoft/AirSim-Drone-Racing-Lab/releases).
|
||||
- Download `ADRL.zip` from the latest windows release, and unzip it.
|
||||
- Download and move the settings.json file to `~/Documents/AirSim/settings.json`.
|
||||
|
||||
- Python client:
|
||||
`pip install airsimdroneracinglab`
|
||||
|
||||
- Running
|
||||
- Navigate to the `ADRL/` directory, and double-click `run.bat` (or `ADRL.exe -windowed`)
|
||||
- For more command line options, see [here](#command-line-options).
|
||||
|
||||
## Command Line Options
|
||||
The following command line options are provided by Unreal Engine, and work in Linux and Windows both.
|
||||
Here's a [complete list](https://docs.unrealengine.com/en-US/Programming/Basics/CommandLineArguments/index.html) of possible command line arguments.
|
||||
|
||||
- To disable rendering completely for training planning and / or control policies, you can use:
|
||||
```
|
||||
./ADRL/ADRL.sh -nullrhi
|
||||
```
|
||||
Note that `simGetImages` will not work with this option.
|
||||
|
||||
- To increase speed of `simGetImages`:
|
||||
- Add `"ViewMode": "NoDisplay"` to your `~/Documents/AirSim/settings.json` file, or replace its contents with [this file](../settings/settings_no_view.json).
|
||||
This disables rendering in the main viewport camera.
|
||||
Then run the binary with the following options.
|
||||
```
|
||||
./AirSimDroneRacingLab.sh -windowed -NoVSync -BENCHMARK
|
||||
```
|
||||
- You can use [Unreal Engine's Stat commands](https://docs.unrealengine.com/en-US/Engine/Performance/StatCommands/index.html) `Stat FPS`, `Stat UnitGraph`, `r.VSync`, `t.maxFPS` for monitoring performance.
|
|
@ -0,0 +1,45 @@
|
|||
{
|
||||
"ClockSpeed": 1,
|
||||
"SeeDocsAt": "https://github.com/Microsoft/AirSim/blob/master/docs/settings.md",
|
||||
"SettingsVersion": 1.2,
|
||||
"SimMode": "Multirotor",
|
||||
"ViewMode": "NoDisplay",
|
||||
"Vehicles": {
|
||||
"drone_1": {
|
||||
"Cameras": {
|
||||
"fpv_cam": {
|
||||
"CaptureSettings": [
|
||||
{
|
||||
"FOV_Degrees": 90,
|
||||
"Height": 240,
|
||||
"ImageType": 0,
|
||||
"Width": 320
|
||||
}
|
||||
],
|
||||
"Pitch": 0.0,
|
||||
"Roll": 0.0,
|
||||
"X": 0.25,
|
||||
"Y": 0.0,
|
||||
"Yaw": 0.0,
|
||||
"Z": 0.0
|
||||
}
|
||||
},
|
||||
"Pitch": 0.0,
|
||||
"Roll": 0.0,
|
||||
"VehicleType": "SimpleFlight",
|
||||
"X": 0.0,
|
||||
"Y": 0.0,
|
||||
"Yaw": 0.0,
|
||||
"Z": 0.0
|
||||
},
|
||||
"drone_2": {
|
||||
"Pitch": 0.0,
|
||||
"Roll": 0.0,
|
||||
"VehicleType": "SimpleFlight",
|
||||
"X": 0.0,
|
||||
"Y": 0.0,
|
||||
"Yaw": 0.0,
|
||||
"Z": 0.0
|
||||
}
|
||||
}
|
||||
}
|
Загрузка…
Ссылка в новой задаче