diff --git a/tools/docker/ubuntu_1804_atari b/tools/docker/ubuntu_1804_atari new file mode 100644 index 000000000..34189e151 --- /dev/null +++ b/tools/docker/ubuntu_1804_atari @@ -0,0 +1,47 @@ +# Docker for running tf-agents with atari and user provided ROMs. +# +# For current details on installing ROMs for atari-py read their instructions: +# https://github.com/openai/atari-py/blob/master/README.md. +# +# As of 12-AUG-2021 the suggestion from OpenAI is to: +# wget http://www.atarimania.com/roms/Roms.rar && unrar x Roms.rar \ +# && unzip ROMS.zip && unzip HC\ ROMS.zip +# +# After unzipping, the Pong ROM is located at: +# `HC ROMS/BY ALPHABET/S-Z/Video Olympics - Pong Sports.bin` +# +# Example usage: +# This docker builds on the core tf-agents docker. +# +# Builds a core tf-agents image with the nightly version of TF-Agents and +# Tensorflow. +# docker build --pull -t tf_agents/core \ +# --build-arg tf_agents_pip_spec=tf-agents-nightly[reverb] \ +# -f ./tools/docker/ubuntu_1804_tf_agents ./tools/docker +# +# Builds a docker that installs user provided ROMs located in +# ./tools/docker/roms into the atari-py package. +# docker build -t tf_agents/atari -f ./tools/docker/ubuntu_1804_atari \ +# ./tools/docker +# +# +# Builds a core tf-agnets docker with the latest stable TF-Agents and +# Tensorflow. +# docker build --pull -t tf_agents/core \ +# --build-arg tf_agents_pip_spec=tf-agents[reverb] \ +# --build-arg tensorflow_pip_spec=tensorflow \ +# -f ./tools/docker/ubuntu_1804_tf_agents ./tools/docker +# +# Builds a docker that installs user provided ROMs located in +# ./tools/docker/roms into the atari-py package. +# docker build -t tf_agents/atari -f ./tools/docker/ubuntu_1804_atari \ +# ./tools/docker +# +FROM tf_agents/core as tf_agents_core +ARG rom_dir=roms + +# Copies ROMs into image. +COPY ${rom_dir} /roms + +# Installs the ROMs into the atari python package. +RUN python3 -m atari_py.import_roms /roms