ViZDoom: Doom-Based Reinforcement Learning
ViZDoom is a reinforcement learning research platform that turns the 1993 game Doom into a pixel-based control environment for training AI agents. The README reports sync-mode speeds up to 7000 steps per second on one CPU thread, with Gymnasium-ready Python bindings and a C++ API. Reach for it if you want a fast RL testbed with Gymnasium wrappers built in; skip it if you need a modern 3D engine or large-scale multi-agent training.
What is ViZDoom?
ViZDoom is a reinforcement learning research platform built on the ZDoom engine that lets you train AI bots to play Doom using nothing but the screen buffer as input. It exposes a Python API (with Gymnasium/Gym wrappers) and a C++ API for building and running scenarios, and per the README it's also usable for learning from demonstration and apprenticeship learning, not just plain RL.
Key Capabilities for AI Development
- โA Python API with Gymnasium/Gym wrappers installed alongside the package, plus a separate C++ API for the same simulator - Python methods use snake_case, C++ ones use camelCase.
- โSync mode reportedly reaches up to 7000 frames per second on a single CPU thread, per the README, so the simulator itself isn't the bottleneck in a training loop.
- โBeyond the RGB screen buffer, ViZDoom exposes a depth buffer for 3D vision, an audio buffer, and automatic labeling of visible game objects.
- โAccess to the list of in-game actors and objects, map geometry, and in-game text or notifications - not just rendered frames.
- โBoth async and sync simulation modes, in single-player and multiplayer configurations, with customizable resolution and rendering parameters.
- โOff-screen rendering, episode recording, and in-game time scaling for async mode are all built in.
- โCustom scenarios can be built with visual map editors and a scripting language inherited from the ZDoom engine, with example scenarios shipped in the repo.
Who Benefits from ViZDoom?
ViZDoom fits researchers and engineers who want a fast, pixel-based 3D environment for deep reinforcement learning experiments and don't need a modern game engine's fidelity to get useful results - the built-in Gymnasium wrappers mean you can plug it into an existing training pipeline without writing a custom env class. It also suits anyone studying visual or multimodal perception in RL, since the depth buffer, audio buffer, and object labels provide signal beyond raw pixels. It's a poor fit if you need an actively developed modern 3D game beyond Doom-era mechanics, or if Windows is your only target platform and you need first-class, well-tested support there.
Getting Started with ViZDoom Installation
On Linux, `pip install vizdoom` pulls prebuilt wheels for Python 3.10+ on both x86-64 and ARM64; enabling audio separately requires OpenAL from your package manager - `apt install libopenal-dev` on Debian/Ubuntu, or `dnf install openal-soft-devel` on Fedora/RHEL-family distros. The same `pip install vizdoom` command works on macOS, though starting with version 1.3.0 the prebuilt wheel targets only Apple Silicon on macOS 14.0 or newer; Intel Mac users on macOS 13.0+ instead pin the older release with `pip install vizdoom==1.2.4`. On Windows, `pip install vizdoom` covers x86-64 with Python 3.10+ wheels, but the README flags Windows as less tested than the other two platforms and points to Docker or WSL for anything beyond light experimentation. Outside those wheel combinations, pip falls back to building from source, which needs a C++11-capable compiler alongside CMake 3.12 or newer, Boost 1.54 or newer, and SDL2, with OpenAL optional. Gymnasium/Gym wrapper environments install automatically with the package on every supported platform.
Building and Training AI Agents
Training code lives in the repo's examples folder rather than a single quick-start script: the Python examples are the most integrated, with some wired up to PyTorch, TensorFlow, and Theano, while the C++ examples cover the same scenarios with a smaller set. The Python and C++ surfaces mirror each other, differing mainly in casing convention (snake_case in Python, camelCase in C++), so a Gymnasium-style Python prototype maps fairly directly onto the C++ side if you need to port it later. The Gymnasium/Gym wrapper is what most RL codebases will actually import - the repo has a dedicated Gymnasium doc and an example script for wiring it into a standard training loop. One quirk to know before you start: ViZDoom can't ship the original Doom assets, so scenarios render with Freedoom graphics by default; if you own Doom or Doom II, you can drop your own doom2.wad into the working directory, or point at any Doom-engine WAD with the set_doom_game_path/setDoomGamePath method instead.
Strengths
- โGenuinely fast for a 3D environment - the README reports sync-mode speeds up to 7000 steps per second on a single CPU thread, which matters when an RL run needs millions of steps.
- โMore than RGB pixels: depth buffer, audio buffer, object labeling, and map/actor data are all exposed, so perception research isn't limited to plain screen-buffer control.
- โGymnasium and Gym wrappers ship by default rather than as a bolt-on community package, so plugging into standard RL training code doesn't require writing a custom env wrapper.
- โBacked by two peer-reviewed papers - the 2016 IEEE CIG paper that won that conference's Best Paper award, and the 2019 IEEE Transactions on Games paper that won a 2022 Outstanding Paper award - not just README claims.
- โA small ecosystem of community projects already built on it (Sample Factory, EnvPool, LevDoom, COOM, HASARD, MazeExplorer), so you're not the first to run large-scale or generalization experiments on it.
Considerations and Known Limitations
- โณLicensing isn't a single blanket grant: the README says ViZDoom's own code is MIT, but the ZDoom engine underneath pulls in code with its own separately varying license terms, so check ZDoom's license page before assuming MIT covers everything you ship.
- โณWindows support is explicitly flagged as less tested than the Linux and macOS builds, with the README recommending Docker or WSL for anything beyond light, exploratory runs.
- โณPrebuilt wheels only cover Python 3.10+; older Python versions or unsupported distros fall back to a from-source build needing a C++11 compiler, CMake, Boost, and SDL2.
- โณIntel Mac users don't get a current prebuilt wheel - the README pins them to the older 1.2.4 release rather than the latest version.
- โณNo original Doom visuals out of the box: scenarios render with Freedoom graphics unless you supply your own licensed WAD file.
- โณThe README doesn't publish a version changelog or a broader benchmark suite beyond the single sync-mode throughput figure, so comparing performance across ViZDoom releases isn't something the source material supports.
Related Tools and Alternatives
Frequently Asked Questions about ViZDoom
ViZDoom ships APIs for Python and C++, with the Python side including Gymnasium and Gym wrapper support by default. The two surfaces are nearly identical, differing mainly in casing convention - snake_case in Python, camelCase in C++.
ViZDoom can't legally distribute the original Doom or Doom II graphics, so it renders scenarios with Freedoom assets by default. If you own the original games, you can supply your own doom2.wad, or point to any Doom-engine WAD via the set_doom_game_path/setDoomGamePath method.
ViZDoom's own original code is released under the MIT license, per its README. The ZDoom engine it's built on pulls in code from multiple sources under separately varying license terms, so check ZDoom's own license page for that part.
ViZDoom is compatible with Gymnasium - its wrapper environments install automatically alongside the base package and are available on every platform ViZDoom supports, per the README and its dedicated Gymnasium documentation.
ViZDoom supports Linux, macOS, and Windows. Linux gets prebuilt wheels for Python 3.10+ on x86-64 and ARM64, macOS wheels currently target Apple Silicon on macOS 14.0+ (Intel needs the older 1.2.4 release), and Windows wheels cover x86-64 only, with the README calling Windows support less tested than the other two.
ViZDoom's README reports sync-mode throughput of up to 7000 frames (steps) per second, running single-threaded on a modern CPU, and describes the simulator itself as lightweight, at just a few megabytes.
The problem it solves
Reinforcement learning researchers testing visual, pixel-based control need an environment cheap enough to run millions of simulation steps but complex enough to actually stress perception - most repurposed game engines are too heavy for that or don't expose the buffers researchers actually want. ViZDoom addresses this by wrapping the ZDoom engine (the engine behind the 1993 Doom) into a lightweight, few-MB simulator that hands back not just the screen buffer but depth, object labels, and audio too, so a bot can be trained on visual information alone, the way the README frames it.
Best use cases
- โขBenchmarking pixel-based deep reinforcement learning algorithms where you want a fast, inexpensive 3D environment instead of a full modern game engine.
- โขResearch that needs more than RGB frames - depth buffers, object labels, or audio - for visual or multimodal perception work in an RL agent.
- โขBuilding custom training scenarios with ViZDoom's visual editors and scripting language rather than relying only on the stock example configs.
- โขPrototyping in Gymnasium-standard Python before porting a trained approach to a C++ pipeline, since the two APIs are nearly identical.
- โขAcademic work citing ViZDoom's own platform papers - the 2016 IEEE CIG paper (Best Paper award) and the 2019 IEEE Transactions on Games paper (2022 Outstanding Paper award).
Related repositories
Want a second opinion on ViZDoom?
Ask an AI that can read this page โ one click and you get its take on ViZDoom.
