Skip to content

feat: add vloss clipping to jax ppo. #1486

feat: add vloss clipping to jax ppo.

feat: add vloss clipping to jax ppo. #1486

Workflow file for this run

name: tests
on:
push:
paths-ignore:
- '**/README.md'
- 'docs/**/*'
- 'cloud/**/*'
pull_request:
paths-ignore:
- '**/README.md'
- 'docs/**/*'
- 'cloud/**/*'
jobs:
test-core-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# classic control tests
- name: Install core dependencies
run: poetry install -E pytest
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Run core tests
run: poetry run pytest tests/test_classic_control.py
- name: Install jax
if: runner.os == 'Linux' || runner.os == 'macOS'
run: poetry install -E "pytest jax"
- name: Run gymnasium migration dependencies
run: poetry run pip install "stable_baselines3==2.0.0a1"
- name: Run gymnasium tests
run: poetry run pytest tests/test_classic_control_gymnasium.py
- name: Run core tests with jax
if: runner.os == 'Linux' || runner.os == 'macOS'
run: poetry run pytest tests/test_classic_control_jax_gymnasium.py
- name: Run gae tests with jax
if: runner.os == 'Linux' || runner.os == 'macOS'
run: poetry run pytest tests/test_jax_compute_gae.py
- name: Install tuner dependencies
run: poetry install -E "pytest optuna"
- name: Run tuner tests
run: poetry run pytest tests/test_tuner.py
test-atari-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# atari tests
- name: Install atari dependencies
run: poetry install -E "pytest atari"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Run atari tests
run: poetry run pytest tests/test_atari.py
- name: Install jax
if: runner.os == 'Linux' || runner.os == 'macOS'
run: poetry install -E "pytest atari jax"
- name: Run gymnasium migration dependencies
run: poetry run pip install "stable_baselines3==2.0.0a1" "gymnasium[atari,accept-rom-license]==0.28.1" "ale-py==0.8.1"
- name: Run gymnasium tests
run: poetry run pytest tests/test_atari_gymnasium.py
- name: Run gymnasium tests with jax
if: runner.os == 'Linux' || runner.os == 'macOS'
run: poetry run pytest tests/test_atari_jax_gymnasium.py
test-procgen-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# procgen tests
- name: Install core dependencies
run: poetry install -E "pytest procgen"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Run procgen tests
run: poetry run pytest tests/test_procgen.py
test-mujoco-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# mujoco tests
- name: Install dependencies
run: poetry install -E "pytest mujoco dm_control jax"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Run gymnasium migration dependencies
run: poetry run pip install "stable_baselines3==2.0.0a1"
- name: install mujoco dependencies
run: |
sudo apt-get update && sudo apt-get -y install libgl1-mesa-glx libosmesa6 libglfw3
- name: Run mujoco tests
continue-on-error: true # MUJOCO_GL=osmesa results in `free(): invalid pointer`
run: poetry run pytest tests/test_mujoco.py
# test-mujoco-envs-mac:
# strategy:
# fail-fast: false
# matrix:
# python-version: [3.8]
# poetry-version: [1.3.1]
# os: [macos-latest]
# runs-on: ${{ matrix.os }}
# steps:
# - uses: actions/checkout@v2
# - uses: actions/setup-python@v2
# with:
# python-version: ${{ matrix.python-version }}
# - name: Run image
# uses: abatilo/[email protected]
# with:
# poetry-version: ${{ matrix.poetry-version }}
# # mujoco tests
# - name: Install dependencies
# run: poetry install -E "pytest mujoco dm_control jax"
# - name: Downgrade setuptools
# run: poetry run pip install setuptools==59.5.0
# - name: Run gymnasium migration dependencies
# run: poetry run pip install "stable_baselines3==2.0.0a1"
# - name: Run mujoco tests
# run: poetry run pytest tests/test_mujoco.py
test-mujoco_py-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# mujoco_py tests
- name: Install dependencies
run: poetry install -E "pytest mujoco_py mujoco jax"
- name: Run gymnasium migration dependencies
run: poetry run pip install "stable_baselines3==2.0.0a1"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: install mujoco_py dependencies
run: |
sudo apt-get update && sudo apt-get -y install wget unzip software-properties-common \
libgl1-mesa-dev \
libgl1-mesa-glx \
libglew-dev \
libosmesa6-dev patchelf
- name: Run mujoco_py tests
run: poetry run pytest tests/test_mujoco_py.py
test-envpool-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# envpool tests
- name: Install envpool dependencies
run: poetry install -E "pytest envpool jax ppo_atari_envpool_xla_jax_scan"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Run envpool tests
run: poetry run pytest tests/test_envpool.py
test-atari-multigpu-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# atari multigpu tests
- name: Install atari dependencies
run: poetry install -E "pytest atari"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Run atari tests
run: poetry run pytest tests/test_atari_multigpu.py
test-pettingzoo-envs:
strategy:
fail-fast: false
matrix:
python-version: [3.8]
poetry-version: [1.3.1]
os: [ubuntu-22.04]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/[email protected]
with:
poetry-version: ${{ matrix.poetry-version }}
# pettingzoo tests
- name: Install pettingzoo dependencies
run: poetry install -E "pytest pettingzoo atari"
- name: Downgrade setuptools
run: poetry run pip install setuptools==59.5.0
- name: Install ROMs
run: poetry run AutoROM --accept-license
- name: Run pettingzoo tests
run: poetry run pytest tests/test_pettingzoo_ma_atari.py