Building NativeRL - PathmindAI/nativerl GitHub Wiki
It should take about an hour or two to build the NativeRL library. Please follow the instructions below exactly to get started. If there are any issues, feel free to submit a Github issue.
Required Software
- A Linux distribution. I'm currently using Rocky Linux which works fine.
- A Docker environment if you don’t have a Linux machine.
Commands
Assuming that you are building NativeRL via Docker, follow the commands below exactly.
1. Create Docker Image
docker pull rockylinux
2. Mount the NativeRL directory
Clone the NativeRL Github repository and mount it to your Docker container. Make sure to replace the path below with the path to your local NativeRL directory.
docker run -v /User/usename/Documents/Github/nativerl:/nativerl -it rockylinux:latest
3. Install Dependencies
yum install sudo -y
sudo yum install cmake3
sudo yum install make
4. Install Anaconda
wget https://repo.anaconda.com/archive/Anaconda3-2019.03-Linux-x86_64.sh
bash Anaconda3-2019.03-Linux-x86_64.sh
conda install -c conda-forge conda-pack
5. Install Python Libraries
pip install ray[rllib]==1.3.0
pip install tensorflow
pip install fire
6. Build NativeRL
Run the command below and pluck out "nativerl-1.8.1-SNAPSHOT-bin.zip" from the "target" folder (should be in your "nativerl" folder).
mvn clean install -Djavacpp.platform.custom -Djavacpp.platform.linux-x86_64 -Djavacpp.platform.macosx-x86_64 -Djavacpp.platform.windows-x86_64
7. Build Conda Environment
This will generate a file called "rllibpack.tar.gz". Pluck out this file too as you will need it later.
conda pack -o rllibpack.tar.gz
8. Save Docker Image For Future Use
docker commit [container_id] rockylinux:latest