Skip to content

Commit

Permalink
[docs] Update Releases info, OSX, and some fixes (microsoft#2524)
Browse files Browse the repository at this point in the history
  • Loading branch information
rajat2004 authored Apr 5, 2020
1 parent 19ea831 commit 9e3aed1
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 34 deletions.
16 changes: 10 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Welcome to AirSim

AirSim is a simulator for drones, cars and more, built on [Unreal Engine](https://www.unrealengine.com/) (we now also have an experimental [Unity](https://unity3d.com/) release). It is open-source, cross platform, and supports hardware-in-loop with popular flight controllers such as PX4 for physically and visually realistic simulations. It is developed as an Unreal plugin that can simply be dropped into any Unreal environment. Similarly, we have an experimental release for a Unity plugin.
AirSim is a simulator for drones, cars and more, built on [Unreal Engine](https://www.unrealengine.com/) (we now also have an experimental [Unity](https://unity3d.com/) release). It is open-source, cross platform, and supports hardware-in-loop with popular flight controllers such as PX4 for physically and visually realistic simulations. It is developed as an Unreal plugin that can simply be dropped into any Unreal environment. Similarly, we have an experimental release for a Unity plugin.

Our goal is to develop AirSim as a platform for AI research to experiment with deep learning, computer vision and reinforcement learning algorithms for autonomous vehicles. For this purpose, AirSim also exposes APIs to retrieve data and control vehicles in a platform independent way.

Expand All @@ -15,9 +15,9 @@ Cars in AirSim
[![AirSim Car Demo Video](docs/images/car_demo_video.png)](https://youtu.be/gnz1X3UNM5Y)

## What's New
* A ROS wrapper for multirotors is available. See [airsim_ros_pkgs](https://github.com/microsoft/AirSim/blob/master/ros/src/airsim_ros_pkgs) for the ROS API, and [airsim_tutorial_pkgs](https://github.com/microsoft/AirSim/blob/master/ros/src/airsim_tutorial_pkgs) for tutorials.
* [Added sensor APIs for Barometer, IMU, GPS, Magnetometer, Distance Sensor](https://microsoft.github.io/AirSim/sensors)
* Added support for [docker in ubuntu](https://github.com/microsoft/AirSim/blob/master/docs/docker_ubuntu.md)
* A ROS wrapper for multirotors is available. See [airsim_ros_pkgs](https://github.com/microsoft/AirSim/blob/master/ros/src/airsim_ros_pkgs) for the ROS API, and [airsim_tutorial_pkgs](https://github.com/microsoft/AirSim/blob/master/ros/src/airsim_tutorial_pkgs) for tutorials.
* [Added sensor APIs for Barometer, IMU, GPS, Magnetometer, Distance Sensor](https://microsoft.github.io/AirSim/sensors)
* Added support for [docker in ubuntu](https://github.com/microsoft/AirSim/blob/master/docs/docker_ubuntu.md)
* Added Weather Effects and [APIs](https://microsoft.github.io/AirSim/apis#weather-apis)
* Added [Time of Day API](https://microsoft.github.io/AirSim/apis#time-of-day-api)
* An experimental integration of [AirSim on Unity](https://github.com/Microsoft/AirSim/tree/master/Unity) is now available. Learn more in [Unity blog post](https://blogs.unity3d.com/2018/11/14/airsim-on-unity-experiment-with-autonomous-vehicle-simulation).
Expand All @@ -37,6 +37,10 @@ For complete list of changes, view our [Changelog](CHANGELOG.md)
* [Build it](https://microsoft.github.io/AirSim/build_windows)

### Linux
* [Download binaries](https://microsoft.github.io/AirSim/use_precompiled)
* [Build it](https://microsoft.github.io/AirSim/build_linux)

### macOS
* [Build it](https://microsoft.github.io/AirSim/build_linux)

[![Build Status](https://travis-ci.org/Microsoft/AirSim.svg?branch=master)](https://travis-ci.org/Microsoft/AirSim)
Expand Down Expand Up @@ -74,11 +78,11 @@ There are two ways you can generate training data from AirSim for deep learning.

![record screenshot](docs/images/record_data.png)

A better way to generate training data exactly the way you want is by accessing the APIs. This allows you to be in full control of how, what, where and when you want to log data.
A better way to generate training data exactly the way you want is by accessing the APIs. This allows you to be in full control of how, what, where and when you want to log data.

### Computer Vision mode

Yet another way to use AirSim is the so-called "Computer Vision" mode. In this mode, you don't have vehicles or physics. You can use the keyboard to move around the scene, or use APIs to position available cameras in any arbitrary pose, and collect images such as depth, disparity, surface normals or object segmentation.
Yet another way to use AirSim is the so-called "Computer Vision" mode. In this mode, you don't have vehicles or physics. You can use the keyboard to move around the scene, or use APIs to position available cameras in any arbitrary pose, and collect images such as depth, disparity, surface normals or object segmentation.

[More details](https://microsoft.github.io/AirSim/image_apis/)

Expand Down
29 changes: 17 additions & 12 deletions docs/build_linux.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
# Build AirSim on Linux

The current recommended and tested environment is **Ubuntu 16.04 LTS**. Theoretically, you can build on other distros and OSX as well, but we haven't tested it.
The current recommended and tested environment is **Ubuntu 18.04 LTS**. Theoretically, you can build on other distros as well, but we haven't tested it.

We've two options - you can either build inside docker containers or your host machine.
**Note**: It should be possible to build AirSim on OSX as well, but it isn't actively tested. Only macOS Catalina (10.15) is supported. Follow the same steps as Linux for building AirSim.

## Docker
We've two options - you can either build inside docker containers or your host machine.

## Docker
Please see instructions [here](https://github.com/Microsoft/AirSim/blob/master/docs/docker_ubuntu.md)

## Host machine

### Build Unreal Engine and Airsim
- Make sure you are [registered with Epic Games](https://docs.unrealengine.com/latest/INT/Platforms/Linux/BeginnerLinuxDeveloper/SettingUpAnUnrealWorkflow/1/index.html). This is required to get source code access for Unreal Engine.

- Clone Unreal in your favorite folder and build it (this may take a while!). **Note**: We only support >= Unreal 4.22 at present. We recommend using 4.24.
- Clone Unreal in your favorite folder and build it (this may take a while!). **Note**: We only support Unreal >= 4.22 at present. We recommend using 4.24.

```bash
# go to the folder where you clone GitHub projects
git clone -b 4.24 https://github.com/EpicGames/UnrealEngine.git
Expand All @@ -23,20 +26,22 @@ Please see instructions [here](https://github.com/Microsoft/AirSim/blob/master/d
```

- Clone AirSim and build it:

```bash
# go to the folder where you clone GitHub projects
git clone https://github.com/Microsoft/AirSim.git
cd AirSim
```

By default AirSim recommends using clang 5 to build the binaries as those will be compatible with Unreal. The setup script
will install the right version of cmake, llvm, and eigen:
By default AirSim recommends using clang 8 to build the binaries as those will be compatible with UE 4.24. The setup script will install the right version of cmake, llvm, and eigen.

```bash
./setup.sh
./build.sh
```

Optionally, if you need GCC binaries for some other reason, you can simply add gcc to the setup and build invocation, like this:

```bash
./setup.sh --gcc
./build.sh --gcc
Expand Down Expand Up @@ -74,7 +79,7 @@ See [Using APIs](apis.md) and [settings.json](settings.md) for various options a
* If you see other compile errors in console then open up those source files and see if it is due to changes you made. If not, then report it as issue on GitHub.

- Unreal crashed! How do I know what went wrong?
* Go to the `MyUnrealProject/Saved/Crashes` folder and search for the file `MyProject.log` within its subdirectories. At the end of this file you will see the stack trace and messages.
* Go to the `MyUnrealProject/Saved/Crashes` folder and search for the file `MyProject.log` within its subdirectories. At the end of this file you will see the stack trace and messages.
You can also take a look at the `Diagnostics.txt` file.

- How do I use an IDE on Linux?
Expand All @@ -84,15 +89,15 @@ See [Using APIs](apis.md) and [settings.json](settings.md) for various options a
* Yes, you can, but we haven't tested it. You can find the instructions [here](https://docs.unrealengine.com/latest/INT/Platforms/Linux/GettingStarted/index.html).

- What compiler and stdlib does AirSim use?
* We use the same compiler that Unreal Engine uses, **Clang 5.0**, and stdlib, **libc++**. AirSim's `setup.sh` will automatically download them both. The libc++ source code is cloned into the `llvm-source-(version)` folder and is built into the `llvm-build` folder, from where CMake uses libc++.
* We use the same compiler that Unreal Engine uses, **Clang 8**, and stdlib, **libc++**. AirSim's `setup.sh` will automatically download them.

- What version of CMake does the AirSim build use?
* 3.9.0 or higher. This is *not* the default in Ubuntu 16.04 so setup.sh installs it for you. You can check your CMake version using `cmake --version`. If you have an older version, follow [these instructions](cmake_linux.md) or see the [CMake website](https://cmake.org/install/).
* 3.10.0 or higher. This is *not* the default in Ubuntu 16.04 so setup.sh installs it for you. You can check your CMake version using `cmake --version`. If you have an older version, follow [these instructions](cmake_linux.md) or see the [CMake website](https://cmake.org/install/).

- Can I compile AirSim in BashOnWindows?
* Yes, however, you can't run Unreal from BashOnWindows. So this is kind of useful to check a Linux compile, but not for an end-to-end run.
See the [BashOnWindows install guide](https://msdn.microsoft.com/en-us/commandline/wsl/install_guide).
Make sure to have the latest version (Windows 10 Creators Edition) as previous versions had various issues.
* Yes, however, you can't run Unreal from BashOnWindows. So this is kind of useful to check a Linux compile, but not for an end-to-end run.
See the [BashOnWindows install guide](https://msdn.microsoft.com/en-us/commandline/wsl/install_guide).
Make sure to have the latest version (Windows 10 Creators Edition) as previous versions had various issues.
Also, don't invoke `bash` from `Visual Studio Command Prompt`, otherwise CMake might find VC++ and try and use that!

- Where can I find more info on running Unreal on Linux?
Expand Down
26 changes: 13 additions & 13 deletions docs/sensors.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
# Sensors in AirSim

AirSim currently supports the following sensors.
AirSim currently supports the following sensors.
Each sensor is associated with a integer enum specifying its sensor type.

* Camera
* Barometer = 1
* Imu = 2
* Gps = 3
* Magnetometer = 4
* Distance Sensor = 5
* Distance Sensor = 5
* Lidar = 6

**Note** : Cameras are configured differently than the other sensors and do not have an enum associated with them. Look at [general settings](settings.md) and [image API](image_apis.md) for camera config and API.
**Note** : Cameras are configured differently than the other sensors and do not have an enum associated with them. Look at [general settings](settings.md) and [image API](image_apis.md) for camera config and API.

## Default sensors

Expand All @@ -29,7 +29,7 @@ If no sensors are specified in the `settings.json`, the the following sensors ar
### ComputerVision
* None

Behind the scenes, 'createDefaultSensorSettings' method in [AirSimSettings.hpp](https://github.com/Microsoft/AirSim/blob/master/AirLib/include/common/AirSimSettings.hpp) which sets up the above sensors with their default parameters, depending on the sim mode specified in the `settings.json` file.
Behind the scenes, `createDefaultSensorSettings` method in [AirSimSettings.hpp](https://github.com/Microsoft/AirSim/blob/master/AirLib/include/common/AirSimSettings.hpp) sets up the above sensors with their default parameters, depending on the sim mode specified in the `settings.json` file.

## Configuring the default sensor list

Expand Down Expand Up @@ -57,7 +57,7 @@ The default sensor list can be configured in settings json:
"SensorType": 5,
"Enabled" : true
},
"Lidar2": {
"Lidar2": {
"SensorType": 6,
"Enabled" : true,
"NumberOfChannels": 4,
Expand All @@ -68,7 +68,7 @@ The default sensor list can be configured in settings json:

## Configuring vehicle-specific sensor list

If a vehicle provides its sensor list, it **must** provide the whole list. Selective add/remove/update of the default sensor list is **NOT** supported.
If a vehicle provides its sensor list, it **must** provide the whole list. Selective add/remove/update of the default sensor list is **NOT** supported.
A vehicle specific sensor list can be specified in the vehicle settings part of the json.
e.g.,

Expand All @@ -80,15 +80,15 @@ e.g.,
"AutoCreate": true,
...
"Sensors": {
"MyLidar1": {
"MyLidar1": {
"SensorType": 6,
"Enabled" : true,
"NumberOfChannels": 16,
"PointsPerSecond": 10000,
"X": 0, "Y": 0, "Z": -1,
"DrawDebugPoints": true
},
"MyLidar2": {
"MyLidar2": {
"SensorType": 6,
"Enabled" : true,
"NumberOfChannels": 4,
Expand All @@ -102,11 +102,11 @@ e.g.,
```

### Sensor specific settings
Each sensor-type has its own set of settings as well.
Each sensor-type has its own set of settings as well.
Please see [lidar](lidar.md) for example of Lidar specific settings.

## Sensor APIs
Jump straight to [`hello_drone.py`](https://github.com/Microsoft/AirSim/blob/master/PythonClient/multirotor/hello_drone.py) or [`hello_drone.cpp`](https://github.com/Microsoft/AirSim/blob/master/HelloDrone/main.cpp) for example usage, or see follow below for the full API.
## Sensor APIs
Jump straight to [`hello_drone.py`](https://github.com/Microsoft/AirSim/blob/master/PythonClient/multirotor/hello_drone.py) or [`hello_drone.cpp`](https://github.com/Microsoft/AirSim/blob/master/HelloDrone/main.cpp) for example usage, or see follow below for the full API.

- Barometer

Expand All @@ -122,7 +122,7 @@ Jump straight to [`hello_drone.py`](https://github.com/Microsoft/AirSim/blob/mas

- IMU

C++
C++
```cpp
msr::airlib::ImuBase::Output getImuData(const std::string& imu_name = "", const std::string& vehicle_name = "");
```
Expand Down Expand Up @@ -165,5 +165,5 @@ C++
distance_sensor_name = getDistanceSensorData(distance_sensor_name = "", vehicle_name = "")
```

- Lidar
- Lidar
See [lidar](lidar.md) for Lidar API.
12 changes: 9 additions & 3 deletions docs/use_precompiled.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ You can simply download precompiled binaries and run to get started immediately.

### Unreal Engine

**Windows**: Download the binaries for the environment of your choice from the [latest release](https://github.com/Microsoft/AirSim/releases).
**Windows, Linux**: Download the binaries for the environment of your choice from the [latest release](https://github.com/Microsoft/AirSim/releases).

**Linux**: Binaries for Ubuntu 16.04 LTS is coming soon. For now you will need to [build it on Linux](build_linux.md) yourself.
**macOS**: You will need to [build it yourself](https://microsoft.github.io/AirSim/build_linux/)

### Unity (Experimental)
A free environment called Windridge City is available at [Unity Asset Store](https://assetstore.unity.com/) as an experimental release of AirSim on Unity. Please note that this is work in progress and all features may not work yet.
A free environment called Windridge City is available at [Unity Asset Store](https://assetstore.unity.com/) as an experimental release of AirSim on Unity. **Note**: This is an old release, and many of the features and APIs might not work.

## Controlling Vehicles
Most of our users typically use [APIs](apis.md) to control the vehicles. However if you can also control vehicles manually. You can drive the car using keyboard, gamepad or [steering wheel](steering_wheel_installation.md). To fly drone manually, you will need either XBox controller or a remote control (feel free to [contribute](../CONTRIBUTING.md) keyboard support). Please see [remote control setup](remote_control.md) for more details. Alternatively you can use [APIs](apis.md) for programmatic control or use so-called [Computer Vision mode](image_apis.md) to move around in environment using the keyboard.
Expand All @@ -20,3 +20,9 @@ The AirSim binaries, like CityEnviron, requires a beefy GPU to run smoothly. You
start CityEnviron -ResX=640 -ResY=480 -windowed
```

For Linux binaries, use the `Blocks.sh` or corresponding shell script as follows -
```
./Blocks.sh -ResX=640 -ResY=480 -windowed
```

UE 4.24 uses Vulkan drivers by default, but they can consume more GPU memory. If you get memory allocation errors, then you can try switching to OpenGL using `-opengl`

0 comments on commit 9e3aed1

Please sign in to comment.