The Arcade Learning Environment (ALE) - a platform for AI research.
Project description
The Arcade Learning Environment
The Arcade Learning Environment (ALE) is a simple framework that allows researchers and hobbyists to develop AI agents for Atari 2600 games. It is built on top of the Atari 2600 emulator Stella and separates the details of emulation from agent design. This video depicts over 50 games currently supported in the ALE.
For an overview of our goals for the ALE read The Arcade Learning Environment: An Evaluation Platform for General Agents. If you use ALE in your research, we ask that you please cite this paper in reference to the environment. See the Citing section for BibTeX entries.
Features
- Object-oriented framework with support to add agents and games.
- Emulation core uncoupled from rendering and sound generation modules for fast emulation with minimal library dependencies.
- Automatic extraction of game score and end-of-game signal for more than 100 Atari 2600 games.
- Multi-platform code (compiled and tested under macOS, Windows, and several Linux distributions).
- Python bindings through pybind11.
- Native support for OpenAI Gym.
- Visualization tools.
Quick Start
The ALE currently supports three different interfaces: C++, Python, and OpenAI Gym.
Python
You simply need to install the ale-py
package distributed via PyPI:
pip install ale-py
Note: Make sure you're using an up to date version of pip
or the install may fail.
You can now import the ALE in your Python projects with
from ale_py import ALEInterface
ale = ALEInterface()
ROM Management
The ALE doesn't distribute ROMs but we do provide a couple tools for managing your ROMs. First is the command line tool ale-import-roms
. You can simply specify a directory as the first argument to this tool and we'll import all supported ROMs by the ALE.
ale-import-roms roms/
[SUPPORTED] breakout roms/breakout.bin
[SUPPORTED] freeway roms/freeway.bin
[NOT SUPPORTED] roms/custom.bin
Imported 2/3 ROMs
Furthermore, Python packages can expose ROMs for discovery using the special ale-py.roms
entry point. For more details check out the example python-rom-package.
Once you've imported a supported ROM you can simply import the path from the ale-py.roms
package and load the ROM in the ALE:
from ale_py.roms import Breakout
ale.loadROM(Breakout)
OpenAI Gym
Gym support is included in ale-py
. Simply install the Python package using the instructions above. You can also install gym[atari]
which also installs ale-py
with Gym.
As of Gym v0.20 and onwards all Atari environments are provided via ale-py
. We do recommend using the new v5
environments in the ALE
namespace:
import gym
env = gym.make('ALE/Breakout-v5')
The v5
environments follow the latest methodology set out in Revisiting the Arcade Learning Environment by Machado et al..
The only major change difference from Gym's AtariEnv
is that we'd recommend not using the env.render()
method in favour of supplying the render_mode
keyword argument during environment initialization. The human
render mode will give you the advantage of: frame perfect rendering, audio support, and proper resolution scaling. For more information check out docs/gym-interface.md.
For more information on changes to the Atari environments in OpenAI Gym please check out the following blog post.
C++
The following instructions will assume you have a valid C++17 compiler and vcpkg
installed.
We use CMake as a first class citizen, and you can use the ALE directly with any CMake project. To compile and install the ALE you can run
mkdir build && cd build
cmake ../ -DCMAKE_BUILD_TYPE=Release
cmake --build . --target install
There are optional flags -DSDL_SUPPORT=ON/OFF
to toggle SDL support (i.e., display_screen
and sound
support; OFF
by default), -DBUILD_CPP_LIB=ON/OFF
to build
the ale-lib
C++ target (ON
by default), and -DBUILD_PYTHON_LIB=ON/OFF
to build the pybind11 wrapper (ON
by default).
Finally, you can link agaisnt the ALE in your own CMake project as follows
find_package(ale REQUIRED)
target_link_libraries(YourTarget ale::ale-lib)
Citing
If you use the ALE in your research, we ask that you please cite the following.
M. G. Bellemare, Y. Naddaf, J. Veness and M. Bowling. The Arcade Learning Environment: An Evaluation Platform for General Agents, Journal of Artificial Intelligence Research, Volume 47, pages 253-279, 2013.
In BibTeX format:
@Article{bellemare13arcade,
author = {{Bellemare}, M.~G. and {Naddaf}, Y. and {Veness}, J. and {Bowling}, M.},
title = {The Arcade Learning Environment: An Evaluation Platform for General Agents},
journal = {Journal of Artificial Intelligence Research},
year = "2013",
month = "jun",
volume = "47",
pages = "253--279",
}
If you use the ALE with sticky actions (flag repeat_action_probability
), or if
you use the different game flavours (mode and difficulty switches), we ask you
that you also cite the following:
M. C. Machado, M. G. Bellemare, E. Talvitie, J. Veness, M. J. Hausknecht, M. Bowling. Revisiting the Arcade Learning Environment: Evaluation Protocols and Open Problems for General Agents, Journal of Artificial Intelligence Research, Volume 61, pages 523-562, 2018.
In BibTex format:
@Article{machado18arcade,
author = {Marlos C. Machado and Marc G. Bellemare and Erik Talvitie and Joel Veness and Matthew J. Hausknecht and Michael Bowling},
title = {Revisiting the Arcade Learning Environment: Evaluation Protocols and Open Problems for General Agents},
journal = {Journal of Artificial Intelligence Research},
volume = {61},
pages = {523--562},
year = {2018}
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
File details
Details for the file ale_py-0.7.5-cp310-cp310-win_amd64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp310-cp310-win_amd64.whl
- Upload date:
- Size: 935.2 kB
- Tags: CPython 3.10, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a72f8a311887fe3800964976c7ce3567dd701e7d9b77209d3a05c5cdf9c6af0 |
|
MD5 | 93da939eb880ad2c05539fd2bd129510 |
|
BLAKE2b-256 | 8f402e17459fbd34c19de1398e8eec39d3204dd398b69b35fce4ed98dc2bc7a0 |
File details
Details for the file ale_py-0.7.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.6 MB
- Tags: CPython 3.10, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a30270d4aec820527be7a643aad381d0d1c932dc476740f63cc649dd200e065 |
|
MD5 | e40b4bd14fa165ff50ec035c39448d9e |
|
BLAKE2b-256 | b726d4a03d3064c04c65e95dbc47c6fcef4579a5a57d80e607355d826ba2c88c |
File details
Details for the file ale_py-0.7.5-cp310-cp310-macosx_11_0_arm64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp310-cp310-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.0 MB
- Tags: CPython 3.10, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 003725a8b6f02353066564ab417f4228adc886434aa4c8d314489a7f79fe9dfd |
|
MD5 | b4841e041922c199ed5d880b5fa6bd83 |
|
BLAKE2b-256 | 35b68126a3dd8299db4f4575bd9798b41d3087c16cc001e234c3f94e5086d50c |
File details
Details for the file ale_py-0.7.5-cp310-cp310-macosx_10_15_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp310-cp310-macosx_10_15_x86_64.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.10, macOS 10.15+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c68d3960f0e14738362069798ff5baa85ecb337038168cb61bd4855125deb894 |
|
MD5 | d676d02c6cc3bf3feed9f5f45fce5f02 |
|
BLAKE2b-256 | 88af8220255414213e3c1c98b5fa37e2116f71b322b748716ee07e886340c214 |
File details
Details for the file ale_py-0.7.5-cp39-cp39-win_amd64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp39-cp39-win_amd64.whl
- Upload date:
- Size: 935.2 kB
- Tags: CPython 3.9, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9976ceea0251ccad7e562e2021c337d5e9a9b24b5f9eecfe82573c2279337016 |
|
MD5 | 01f59e14a59082fe14ab2f4bed1be38d |
|
BLAKE2b-256 | 3e874b98e37febfc8e0e11f947c165964b1b5187a258f6aee3f322a5a286193b |
File details
Details for the file ale_py-0.7.5-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.6 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e513799fbb5128fa045cfb9a31cffa7f7c188dbe885665188b6c4cb50e9d983c |
|
MD5 | 3584e1425e32cc64a43689db5f27e515 |
|
BLAKE2b-256 | 6caceb6bd862984f1c81bf08e39e138ad0b061f19dd50b1ffed45df7ceff7fcd |
File details
Details for the file ale_py-0.7.5-cp39-cp39-macosx_11_0_arm64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp39-cp39-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.0 MB
- Tags: CPython 3.9, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | da5be311285a00e587b886805ea56762d44bf4f1da672229c1fbaff209bfcdc2 |
|
MD5 | ebdc77dee9bb96bb51d6ba3129a10741 |
|
BLAKE2b-256 | 1f1b4694238733bc7609fceffe68d1df190d1a5464e888799c93ebe280b34c7b |
File details
Details for the file ale_py-0.7.5-cp39-cp39-macosx_10_15_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp39-cp39-macosx_10_15_x86_64.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.9, macOS 10.15+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4c7e7fed3ce2b305d2db9ca2f87106e3df6da2c4fc2363103782ffd5975b4549 |
|
MD5 | f5fe3fbbb61552caf4ff0a599c22322a |
|
BLAKE2b-256 | e9aa9932e97aa30783155649dceb021bf02ab4382814e76829eaa32a357811a2 |
File details
Details for the file ale_py-0.7.5-cp38-cp38-win_amd64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp38-cp38-win_amd64.whl
- Upload date:
- Size: 935.0 kB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1f8694a091e13be45c8704a089462b1519f7112a85e1c1b61c842c69a2608a98 |
|
MD5 | dd88a5b0604b444189dde6c51c0f5b46 |
|
BLAKE2b-256 | 99e408be2a4b38177781a864d3346fc69306391806b7238e4f924f443f9317d2 |
File details
Details for the file ale_py-0.7.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.6 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dec87873c6fe65c71129e20c52ce35dd4507ca409fa1233f4ae9c511144a9c99 |
|
MD5 | f3270636c0d0814d1a7dd5292a961f24 |
|
BLAKE2b-256 | d4d89ee7bc0e8682328bf91bca45991ff189a15bf24540cb341b53e3af9c0628 |
File details
Details for the file ale_py-0.7.5-cp38-cp38-macosx_11_0_arm64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp38-cp38-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.0 MB
- Tags: CPython 3.8, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b2680b9a3c577865572dd9b8f24303189bb22c67b1b9668dcad3c20f59285e78 |
|
MD5 | b35e4a52d9d5eb333953231c1a3ed6d3 |
|
BLAKE2b-256 | 2587e284ab173389d9acee86de8486afc217811dab00cbca60b4dbb7e7de808a |
File details
Details for the file ale_py-0.7.5-cp38-cp38-macosx_10_15_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp38-cp38-macosx_10_15_x86_64.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.8, macOS 10.15+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 48c5abf2c59bed0b46f17ac60ec6c940e6e7d4abc6ff7e5296246286f80e4a23 |
|
MD5 | c9666927e4740acc09f1729eaec751f2 |
|
BLAKE2b-256 | 47fb093d3f4e49e965ae8ddcd4c2f497268e2b47f820b2b9f267225ceb4e0ce6 |
File details
Details for the file ale_py-0.7.5-cp37-cp37m-win_amd64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp37-cp37m-win_amd64.whl
- Upload date:
- Size: 935.3 kB
- Tags: CPython 3.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 38e9f6c2b1cca246253f41028b8ad92d725beec8d4672c0fe247a217a4c7dc4f |
|
MD5 | 05632112a139f22493faeafd5a985ff0 |
|
BLAKE2b-256 | b1f1865db5bee365c81b25b8b014b49ff710bc325b0f8abd25f8f9feaa6c0305 |
File details
Details for the file ale_py-0.7.5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.6 MB
- Tags: CPython 3.7m, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1f97301b89a8b49b9d2cc034f8a7df55eb6b1930126fb6cb6c6d6239bab8a89d |
|
MD5 | 9a5b43c15a051636c65cfea3e93c514e |
|
BLAKE2b-256 | 34965e615823c0b3611a09bc5cee30c2f00bac523497b28d5b211a5fd3d2a3e5 |
File details
Details for the file ale_py-0.7.5-cp37-cp37m-macosx_10_15_x86_64.whl
.
File metadata
- Download URL: ale_py-0.7.5-cp37-cp37m-macosx_10_15_x86_64.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.7m, macOS 10.15+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 910c5443a836bf0bc6b03c45fefeeb9096254f807d24e247753e214062c12cae |
|
MD5 | 494f040774d09ef5eec52ef59ea74397 |
|
BLAKE2b-256 | 80290533c3e1e55ab1a16c3f8f43ea48c1d9f217c99af5d3ea4f2fc4e0fa17f2 |