From 3bbfd807a898c40e35e20b53570dc8a4389d5c87 Mon Sep 17 00:00:00 2001 From: Wouter Jansen Date: Mon, 22 Apr 2024 17:30:17 +0200 Subject: [PATCH] cleanup for 5.2.1 upgrade --- CHANGELOG.md | 4 ++ PythonClient/imitation_learning/README.md | 2 +- Unreal/Environments/Blocks/package.bat | 2 +- build.cmd | 2 +- docs/build_linux.md | 29 +++++---- docs/build_windows.md | 23 ++----- docs/matlab.md | 2 +- docs/ros_python.md | 2 +- docs/unreal_custenv.md | 6 +- tools/build_all_ue_projects.bat | 74 ----------------------- 10 files changed, 31 insertions(+), 115 deletions(-) delete mode 100644 tools/build_all_ue_projects.bat diff --git a/CHANGELOG.md b/CHANGELOG.md index 38639866c..133208821 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +### May 2024 +* Merge of [Colosseum by Codex Laboratories LLC](https://github.com/CodexLabsLLC/Colosseum). +* Updated Unreal to 5.2.1 + ### April 2024 * Merge of Cosys-Lab fork with last Public Microsoft AirSim branch version * Updated Unreal to 4.27 (custom fork: [https://github.com/WouterJansen/UnrealEngine/tree/4.27-cosys](https://github.com/WouterJansen/UnrealEngine/tree/4.27-cosys)) diff --git a/PythonClient/imitation_learning/README.md b/PythonClient/imitation_learning/README.md index 784d046e6..6379ba3e8 100644 --- a/PythonClient/imitation_learning/README.md +++ b/PythonClient/imitation_learning/README.md @@ -6,7 +6,7 @@ The code in this section is based on the [Autonomous Driving Cookbook](https://g ## Prerequisites * Operating system: Windows 10 * GPU: Nvidia GTX 1080 or higher (recommended) -* Software: Unreal Engine 4.27.3 (Cosys-lab fork) and Visual Studio 2022 +* Software: Unreal Engine 5.2.1 and Visual Studio 2022 * Development: CUDA 9.0 and python 3.5. * Python libraries: Keras 2.1.2, TensorFlow 1.6.0. * Note: Newer versions of keras or tensorflow are recommended but can cause syntax errors. diff --git a/Unreal/Environments/Blocks/package.bat b/Unreal/Environments/Blocks/package.bat index decc780ee..c90d8e037 100644 --- a/Unreal/Environments/Blocks/package.bat +++ b/Unreal/Environments/Blocks/package.bat @@ -7,7 +7,7 @@ set OutPath=%1 set ToolPath=%2 set UEVer=%3 -if "%UEVer%"=="" set "UEVer=4.27.3" +if "%UEVer%"=="" set "UEVer=5.2.1" set "_ToolPath=%PROGRAMFILES%\Epic Games\UE_%UEVer%\Engine\Build\BatchFiles" if "%ToolPath%"=="" set ToolPath=%_ToolPath% diff --git a/build.cmd b/build.cmd index a119818cb..0f545dbd1 100644 --- a/build.cmd +++ b/build.cmd @@ -15,7 +15,7 @@ if "%VisualStudioVersion%" == "" ( ) if "%VisualStudioVersion%" lss "17.0" ( echo( - echo Hello there! We just upgraded AirSim to Unreal Engine 4.27 and Visual Studio 2022. + echo Hello there! We just upgraded AirSim to Unreal Engine 5.2.1 and Visual Studio 2022. echo Here are few easy steps for upgrade so everything is new and shiny: echo https://github.com/Microsoft/AirSim/blob/main/docs/unreal_upgrade.md goto :buildfailed_nomsg diff --git a/docs/build_linux.md b/docs/build_linux.md index 621bdf0bd..c39f4c307 100644 --- a/docs/build_linux.md +++ b/docs/build_linux.md @@ -1,23 +1,22 @@ # Build AirSim on Linux -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. +The current recommended and tested environment is **Ubuntu 20.04 LTS**. Theoretically, you can build on other distros as well, but we haven't tested it. ## Host machine -### Build Unreal Engine and Airsim -This branch uses a custom version of the Unreal Engine! -- Make sure you are [registered with Epic Games and have linked your Epic Games account with your GitHub account](https://www.unrealengine.com/en-US/ue-on-github). 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.27.3 (Cosys-Lab) at present. - ```bash - # go to the folder where you clone GitHub projects - git clone https://github.com/WouterJansen/UnrealEngine.git - cd UnrealEngine - ./Setup.sh - ./GenerateProjectFiles.sh - make - ``` - +### Build Unreal Engine +- Make sure you are [registered with Epic Games](https://docs.unrealengine.com/en-US/SharingAndReleasing/Linux/BeginnerLinuxDeveloper/SettingUpAnUnrealWorkflow/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 5.2.1 at present. +```bash +# go to the folder where you clone GitHub projects +git clone -b 5.2 git@github.com:EpicGames/UnrealEngine.git +cd UnrealEngine +./Setup.sh +./GenerateProjectFiles.sh +make +``` + +### Build Airsim - Clone AirSim and build it: ```bash # go to the folder where you clone GitHub projects diff --git a/docs/build_windows.md b/docs/build_windows.md index 9c021672d..0bcd82e29 100644 --- a/docs/build_windows.md +++ b/docs/build_windows.md @@ -1,24 +1,11 @@ # Build AirSim on Windows ## Install Unreal Engine -This branch uses a custom version of the Unreal Engine! -- Make sure you are [registered with Epic Games and have linked your Epic Games account with your GitHub account](https://www.unrealengine.com/en-US/ue-on-github). 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.27.3 (Cosys-Lab fork) at present. - ```bash - # go to the folder where you clone GitHub projects - git clone https://github.com/WouterJansen/UnrealEngine.git - cd UnrealEngine - ``` - -Visual Studio 2012 is required for building. -- To install the correct components for UE4 development, check the "Game Development with C++" workload and the “.net 4.6.2”, "Unreal Engine Installer" and "Nuget Package Manager" optional individual components. -- run `Setup.bat` -- run `GenerateProjectFiles.bat ` as administrator - -## Build UnrealEngine -- Open the generated Visual Studio project `UE4.sln` in the root of the repository. Once it is open you need to set it to build the _Development Editor_ configuration for _Win64_. -- Once that is set, you can right click the UE4 target in the Solution Explorer on the right side of the window and press build. This will take a while. -- please run `Engine\Binaries\Win64\UnrealVersionSelector-Win64-Shipping.exe` once so it is detectable by your system. +1. [Download](https://www.unrealengine.com/download) the Epic Games Launcher. While the Unreal Engine is open source and free to download, registration is still required. +2. Run the Epic Games Launcher, open the `Unreal Engine` tab on the left pane. +Click on the `Install` button on the top right, which should show the option to download **Unreal Engine 5.2.1**. Chose the install location to suit your needs, as shown in the images below. If you have multiple versions of Unreal installed then **make sure the version you are using is set to `current`** by clicking down arrow next to the Launch button for the version. +![Unreal Engine Tab UI Screenshot](images/ue_install.png) +![Unreal Engine Install Location UI Screenshot](images/ue_install_location.png) ## Build AirSim * Start `x64 Native Tools Command Prompt for VS 2022`. diff --git a/docs/matlab.md b/docs/matlab.md index 677e7d5c4..fd52d42bf 100644 --- a/docs/matlab.md +++ b/docs/matlab.md @@ -4,7 +4,7 @@ AirSim and Matlab can be integrated using Python. an example Matlab client is pr ## Prerequisites -These instructions are for Matlab 2023b (with toolboxes for the client: Computer Vision, Aerospace, Signal Processing Toolbox) UE4 4.24.4 and latest AirSim release. +These instructions are for Matlab 2023b (with toolboxes for the client: Computer Vision, Aerospace, Signal Processing Toolbox) UE 5.2.1 and latest AirSim release. It also requires the AirSim python package to be installed. For this go into the _PythonClient_ folder and use pip to install it to your python environment that is also used in Matlab with `pip install .` You can find out in Matlab what Python version is used with diff --git a/docs/ros_python.md b/docs/ros_python.md index 60cd0cad9..0123b03b0 100644 --- a/docs/ros_python.md +++ b/docs/ros_python.md @@ -4,7 +4,7 @@ AirSim and ROS can be integrated using Python. Some example ROS node are provide ## Prerequisites -These instructions are for Ubuntu 20.04, ROS Noetic, UE4 4.24.4 and latest AirSim release. +These instructions are for Ubuntu 20.04, ROS Noetic, UE 5.2.1 and latest AirSim release. You should have these components installed and working before proceeding. **Note that you need to install the Python module first for this to work. More information [here](apis.md) in the section 'Installing AirSim Package'.** diff --git a/docs/unreal_custenv.md b/docs/unreal_custenv.md index a5a64ebb5..3d2d1595e 100644 --- a/docs/unreal_custenv.md +++ b/docs/unreal_custenv.md @@ -8,7 +8,7 @@ There is no `Epic Games Launcher` for Linux which means that if you need to crea ## Step by Step Instructions -1. Make sure AirSim is built and Unreal 4.27.3 (Cosys-Lab fork) is installed as described in [build instructions](build_windows.md). +1. Make sure AirSim is built and Unreal 5.2.1 is installed as described in [build instructions](build_windows.md). 2. In `Epic Games Launcher` click the Learn tab then scroll down and find `Landscape Mountains`. Click the `Create Project` and download this content (~2GB download). ![current version](images/landscape_mountains.png) @@ -19,7 +19,7 @@ There is no `Epic Games Launcher` for Linux which means that if you need to crea !!!note - The Landscape Mountains project is supported up to Unreal Engine version 4.24. If you do not have 4.24 installed, you should see a dialog titled `Select Unreal Engine Version` with a dropdown to select from installed versions. Select 4.27 or greater to migrate the project to a supported engine version. If you have 4.24 installed, you can manually migrate the project by navigating to the corresponding .uproject file in Windows Explorer, right-clicking it, and selecting the `Switch Unreal Engine version...` option. + The Landscape Mountains project is supported up to Unreal Engine version 4.24. If you do not have 4.24 installed, you should see a dialog titled `Select Unreal Engine Version` with a dropdown to select from installed versions. Select 5.2.1 to migrate the project to a supported engine version. If you have 4.24 installed, you can manually migrate the project by navigating to the corresponding .uproject file in Windows Explorer, right-clicking it, and selecting the `Switch Unreal Engine version...` option. 1. From the `File menu` select `New C++ class`, leave default `None` on the type of class, click `Next`, leave default name `MyClass`, and click `Create Class`. We need to do this because Unreal requires at least one source file in project. It should trigger compile and open up Visual Studio solution `LandscapeMountains.sln`. @@ -34,7 +34,7 @@ There is no `Epic Games Launcher` for Linux which means that if you need to crea ```json { "FileVersion": 3, - "EngineAssociation": "4.27", + "EngineAssociation": "", "Category": "Samples", "Description": "", "Modules": [ diff --git a/tools/build_all_ue_projects.bat b/tools/build_all_ue_projects.bat deleted file mode 100644 index 91c3a1e55..000000000 --- a/tools/build_all_ue_projects.bat +++ /dev/null @@ -1,74 +0,0 @@ -@echo off -REM //---------- set up variable ---------- -setlocal -set ROOT_DIR=%~dp0 - -REM should rebuild? -set RebuildAirSim=%1 -REM root folder containing all Unreal projects you want to build -set UnrealProjsPath=%2 -REM Output folder where the builds would be stored -set OutputPath=%3 -REM folder containing AirSim repo -set AirSimPath=%4 -REM path for UE toolset -set ToolPath=%5 - -REM set defaults if ars are not supplied -if "%UnrealProjsPath%"=="" set "UnrealProjsPath=D:\vso\msresearch\Theseus" -if "%AirSimPath%"=="" set "AirSimPath=C:\GitHubSrc\AirSim" -if "%OutputPath%"=="" set "OutputPath=%ROOT_DIR%build" -if "%RebuildAirSim%"=="" set "RebuildAirSim=true" - -REM re-build airsim -if "%RebuildAirSim%"=="true" ( - cd /D "%AirSimPath%" - CALL clean - CALL build - if ERRORLEVEL 1 goto :failed - cd /D "%ROOT_DIR%" -) - -IF NOT EXIST "%OutputPath%" mkdir "%OutputPath%" - -call:doOneProject "TalkingHeads" -call:doOneProject "ZhangJiaJie" -call:doOneProject "AirSimEnvNH" -call:doOneProject "SimpleMaze" -call:doOneProject "LandscapeMountains" -call:doOneProject "Africa_001" "Africa" -call:doOneProject "Forest" -call:doOneProject "Coastline" -call:doOneProject "TrapCamera" -call:doOneProject "CityEnviron" -call:doOneProject "Warehouse" -call:doOneProject "Plains" "" 4.19 - -goto :done - -:doOneProject -REM args: OutputPath ToolPath UEVer -if "%~2"=="" ( - cd /D "%UnrealProjsPath%\%~1" -) else ( - cd /D "%UnrealProjsPath%\%~2" -) -if ERRORLEVEL 1 goto :failed - -robocopy "%AirSimPath%\Unreal\Environments\Blocks" . *.bat /njh /njs /ndl /np - -CALL update_from_git.bat "%AirSimPath%" -if ERRORLEVEL 1 goto :failed - -CALL package.bat "%OutputPath%" "%ToolPath%" %~3 -if ERRORLEVEL 1 goto :failed - -goto :done - -:failed -echo "Error occured while building all UE projects" -exit /b 1 - -:done -cd "%ROOT_DIR%" -if "%1"=="" pause \ No newline at end of file