← all repositories
anibali/docker-pytorch

PyTorch Docker images that generate themselves

It packages PyTorch and CUDA into tagged Docker images, using a template generator to keep a growing version matrix from becoming a maintenance nightmare.

987 stars Dockerfile ML Frameworks
docker-pytorch
Not currently ranked — collecting fresh signals.
star history

What it does

This project maintains a collection of Docker images bundling PyTorch with Ubuntu and optional CUDA support. A Python script and YAML configuration drive a templating engine that stamps out Dockerfiles for different version combinations. The resulting images are published to Docker Hub and ready to run PyTorch programs with optional GPU passthrough.

The interesting bit

The real work is the templating engine. Rather than maintaining a dozen nearly identical Dockerfiles by hand, the project generates them automatically, which makes supporting a matrix of PyTorch and CUDA releases almost manageable. It is the kind of boring automation that prevents bit-rot.

Key highlights

  • Prebuilt images cover common PyTorch and CUDA version pairings.
  • Dockerfiles are auto-generated from templates via manager.py and images.yml.
  • Includes support for GPU passthrough and host X11 forwarding for graphical apps.
  • Designed to be used as a base image for deriving custom environments.

Caveats

  • CUDA support has only been tested on Ubuntu Linux hosts.
  • The X11 forwarding instructions are explicitly labeled “quick-and-dirty (but INSECURE)” by the author.

Verdict

Grab this if you need reproducible PyTorch environments across multiple CUDA versions without hand-rolling base images. If your local Conda setup already works or you avoid containers, skip it.

Frequently asked

What is anibali/docker-pytorch?
It packages PyTorch and CUDA into tagged Docker images, using a template generator to keep a growing version matrix from becoming a maintenance nightmare.
Is docker-pytorch open source?
Yes — anibali/docker-pytorch is open source, released under the MIT license.
What language is docker-pytorch written in?
anibali/docker-pytorch is primarily written in Dockerfile.
How popular is docker-pytorch?
anibali/docker-pytorch has 987 stars on GitHub.
Where can I find docker-pytorch?
anibali/docker-pytorch is on GitHub at https://github.com/anibali/docker-pytorch.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.