|
103 | 103 | conda deactivate |
104 | 104 | conda env remove --prefix ./cloned_env |
105 | 105 | done |
| 106 | + |
| 107 | +# For this version "gym[accept-rom-license]" is required. |
| 108 | +for GYM_VERSION in '0.27' |
| 109 | +do |
| 110 | + # Create a copy of the conda env and work with this |
| 111 | + conda deactivate |
| 112 | + conda create --prefix ./cloned_env --clone ./env -y |
| 113 | + conda activate ./cloned_env |
| 114 | + |
| 115 | + echo "Testing gym version: ${GYM_VERSION}" |
| 116 | + pip3 install 'gymnasium[accept-rom-license]'==$GYM_VERSION |
| 117 | + |
| 118 | + |
| 119 | + if [[ $OSTYPE != 'darwin'* ]]; then |
| 120 | + # install ale-py: manylinux names are broken for CentOS so we need to manually download and |
| 121 | + # rename them |
| 122 | + PY_VERSION=$(python --version) |
| 123 | + if [[ $PY_VERSION == *"3.7"* ]]; then |
| 124 | + wget https://files.pythonhosted.org/packages/ab/fd/6615982d9460df7f476cad265af1378057eee9daaa8e0026de4cedbaffbd/ale_py-0.8.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 125 | + pip install ale_py-0.8.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 126 | + rm ale_py-0.8.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 127 | + elif [[ $PY_VERSION == *"3.8"* ]]; then |
| 128 | + wget https://files.pythonhosted.org/packages/0f/8a/feed20571a697588bc4bfef05d6a487429c84f31406a52f8af295a0346a2/ale_py-0.8.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 129 | + pip install ale_py-0.8.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 130 | + rm ale_py-0.8.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 131 | + elif [[ $PY_VERSION == *"3.9"* ]]; then |
| 132 | + wget https://files.pythonhosted.org/packages/a0/98/4316c1cedd9934f9a91b6e27a9be126043b4445594b40cfa391c8de2e5e8/ale_py-0.8.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 133 | + pip install ale_py-0.8.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 134 | + rm ale_py-0.8.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 135 | + elif [[ $PY_VERSION == *"3.10"* ]]; then |
| 136 | + wget https://files.pythonhosted.org/packages/60/1b/3adde7f44f79fcc50d0a00a0643255e48024c4c3977359747d149dc43500/ale_py-0.8.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
| 137 | + mv ale_py-0.8.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl ale_py-0.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 138 | + pip install ale_py-0.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 139 | + rm ale_py-0.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
| 140 | + fi |
| 141 | + pip install gymnasium[atari] |
| 142 | + else |
| 143 | + pip install gymnasium[atari] |
| 144 | + fi |
| 145 | + |
| 146 | + $DIR/run_test.sh |
| 147 | + |
| 148 | + # delete the conda copy |
| 149 | + conda deactivate |
| 150 | + conda env remove --prefix ./cloned_env |
| 151 | +done |
0 commit comments