HUB
Sign inSign up
alphafold3 logo

getwilds/alphafold3

Sponsored OSS

By Fred Hutch Data Science Lab

•Updated 3 days ago

Docker image for AlphaFold 3 in Fred Hutch OCDO's WILDS

Image
0

106

getwilds/alphafold3 repository overview

⁠AlphaFold 3

This directory contains Docker images for AlphaFold 3⁠, Google DeepMind's biomolecular structure prediction system, which predicts the joint 3D structure of proteins, nucleic acids, small molecules, ions, and modified residues from sequence and ligand inputs. Official documentation is in the upstream repository⁠.

⁠Available Versions

⁠Platform Availability

AlphaFold 3 images are available for AMD64 (x86_64) only due to CUDA/GPU dependencies.

⁠Image Details

These Docker images are built from nvidia/cuda:12.9.2-base-ubuntu24.04 and follow the reference recipe in the upstream docker/Dockerfile⁠. They include:

  • AlphaFold 3 v3.0.5: Cloned from the upstream release tag into /app/alphafold
  • Python 3.12 with a uv⁠ (v0.13.6) managed virtual environment at /alphafold3_venv, installed with uv sync --frozen so the dependency tree matches upstream's lockfile (JAX with CUDA 12 support, Haiku, RDKit, etc.)
  • HMMER 3.4 built from source (sha256-verified) with the upstream speedup patches (jackhmmer_seq_limit, easel_fast_fasta_parsing, jackhmmer_parallel_fasta), installed at /hmmer (license notices in /hmmer/licenses)
  • The chemical components database, generated at build time with build_data
  • The XLA settings recommended upstream (XLA_FLAGS, XLA_PYTHON_CLIENT_PREALLOCATE, XLA_CLIENT_MEM_FRACTION), tuned for folding up to 5,120 tokens on an A100 80 GB

The image is large (roughly 8 GB uncompressed, mostly JAX and its CUDA libraries), which is an exception to this repository's usual size target.

The virtual environment and HMMER are on PATH, so python and jackhmmer work without uv run. The working directory is /app/alphafold, so python /app/alphafold/run_alphafold.py (the path used by WILDS WDL modules) is valid. A run_alphafold launcher is also on PATH.

⁠Important Notes

⁠Model Weights and Databases Are Not Included

These images contain neither the AlphaFold 3 model parameters nor the genetic databases. The weights are access-restricted, and you must request them from Google DeepMind yourself (see the upstream instructions⁠). We cannot and do not distribute them. The databases (UniRef90, MGnify, BFD, PDB, etc., roughly 630 GB when unpacked) must be downloaded separately with upstream's fetch_databases.sh script and should live on fast (ideally SSD) storage.

Mount both at runtime. The examples below use the same container paths as upstream:

Host contentContainer path
Model parameters/root/models
Genetic databases/root/public_databases
Input JSON files/root/af_input
Output directory/root/af_output
⁠GPU Requirements

AlphaFold 3 requires an NVIDIA GPU with CUDA support (compute capability 8.0 or higher is recommended; the default XLA_FLAGS in this image are for such GPUs, and upstream documents an alternate setting for capability 7.x). Upstream recommends an A100 80 GB or H100 80 GB for large inputs. The data pipeline (MSA and template search) is CPU-only and can be run separately with --norun_inference, and inference can be run separately with --norun_data_pipeline.

⁠License and Terms of Use
  • Source code: AlphaFold 3 source code is Copyright 2024 DeepMind Technologies Limited and licensed under the Apache License, Version 2.0⁠. This image installs it unmodified from the upstream release tag (only the HMMER patches provided by upstream are applied).
  • Dockerfile: Adapted from upstream's Apache 2.0 licensed docker/Dockerfile⁠. WILDS changes include cloning the source at a pinned tag instead of copying a local checkout, pinning apt package versions, adding metadata labels, a run_alphafold launcher and a smoke test, and running AlphaFold 3 without uv run by default.
  • Model weights: The weights are not covered by the Apache license. You may only use them if received directly from Google, and use is subject to the Weights Terms of Use⁠ and Prohibited Use Policy⁠. Among other things, the weights and their output are only available for non-commercial use by, or on behalf of, non-commercial organizations; the weights must not be shared outside your organization; and output must not be used to train similar structure prediction models. Output is also subject to the Output Terms of Use⁠ and is not intended for clinical use. This summary is not complete, so read the terms before use. Building or using this image does not grant any rights to the weights.
  • WILDS contributions to the Dockerfiles are MIT licensed, as for the rest of this repository.

⁠Citation

If you use AlphaFold 3 in your research, please cite the original authors:

Abramson, J., Adler, J., Dunger, J., Evans, R., Green, T., Pritzel, A., ... & Jumper, J. M. (2024).
Accurate structure prediction of biomolecular interactions with AlphaFold 3.
Nature, 630, 493-500.
DOI: 10.1038/s41586-024-07487-w

Tool homepage: https://github.com/google-deepmind/alphafold3⁠

Publication: https://doi.org/10.1038/s41586-024-07487-w⁠

⁠Usage

⁠Docker
# Pull the latest version
docker pull getwilds/alphafold3:latest

# Or pull a specific version
docker pull getwilds/alphafold3:3.0.5

# Alternatively, pull from GitHub Container Registry
docker pull ghcr.io/getwilds/alphafold3:latest
⁠Singularity/Apptainer
# Pull the latest version
apptainer pull docker://getwilds/alphafold3:latest

# Or pull a specific version
apptainer pull docker://getwilds/alphafold3:3.0.5

# Alternatively, pull from GitHub Container Registry
apptainer pull docker://ghcr.io/getwilds/alphafold3:latest
⁠Example Commands
# Check that the image works (no GPU, weights, or databases needed)
# Note: this prints the help text but exits with status 1
docker run --rm getwilds/alphafold3:3.0.5 python /app/alphafold/run_alphafold.py --help

# Run a full prediction with Docker (GPU)
docker run --rm --gpus all \
  --volume $HOME/af_input:/root/af_input \
  --volume $HOME/af_output:/root/af_output \
  --volume /path/to/model_parameters:/root/models \
  --volume /path/to/public_databases:/root/public_databases \
  getwilds/alphafold3:3.0.5 \
  python /app/alphafold/run_alphafold.py \
  --json_path=/root/af_input/fold_input.json \
  --model_dir=/root/models \
  --db_dir=/root/public_databases \
  --output_dir=/root/af_output

# Run a full prediction with Apptainer (GPU)
apptainer exec --nv \
  --bind $HOME/af_input:/root/af_input \
  --bind $HOME/af_output:/root/af_output \
  --bind /path/to/model_parameters:/root/models \
  --bind /path/to/public_databases:/root/public_databases \
  docker://getwilds/alphafold3:3.0.5 \
  python /app/alphafold/run_alphafold.py \
  --json_path=/root/af_input/fold_input.json \
  --model_dir=/root/models \
  --db_dir=/root/public_databases \
  --output_dir=/root/af_output

# Data pipeline only (CPU, no GPU or weights needed)
docker run --rm \
  --volume $HOME/af_input:/root/af_input \
  --volume $HOME/af_output:/root/af_output \
  --volume /path/to/public_databases:/root/public_databases \
  getwilds/alphafold3:3.0.5 \
  python /app/alphafold/run_alphafold.py \
  --json_path=/root/af_input/fold_input.json \
  --db_dir=/root/public_databases \
  --output_dir=/root/af_output \
  --norun_inference

Note that the commands above use /root/... paths inside the container, so Apptainer runs that bind mounts to those paths may need a writable /root or --no-home depending on site configuration. See the upstream input documentation⁠ for the fold_input.json format.

⁠Dockerfile Structure

The Dockerfile follows these main steps:

  1. Uses nvidia/cuda:12.9.2-base-ubuntu24.04 as the base image and adds metadata labels
  2. Installs Python 3.12, git, compilers, and zlib (versions pinned with apt-cache policy)
  3. Installs uv v0.13.6 and creates the virtual environment at /alphafold3_venv
  4. Clones the AlphaFold 3 v3.0.5 tag into /app/alphafold (instead of copying a local checkout as upstream does)
  5. Downloads HMMER 3.4, verifies its sha256, applies the three upstream patches taken from the clone, builds, and installs it
  6. Runs uv sync --frozen --all-groups --no-editable, then uv run --no-sync build_data (--no-sync keeps the install non-editable)
  7. Sets the XLA environment variables recommended upstream
  8. Smoke tests the install (jackhmmer -h and importing AlphaFold 3 and JAX)

⁠Security Scanning and CVEs

These images are regularly scanned for vulnerabilities using Docker Scout. However, due to the nature of bioinformatics software and their dependencies, some Docker images may contain components with known vulnerabilities (CVEs).

Use at your own risk: While we strive to minimize security issues, these images are primarily designed for research and analytical workflows in controlled environments.

For the latest security information about this image, please check the CVEs_*.md files in this directory⁠, which are automatically updated through our GitHub Actions workflow. If a particular vulnerability is of concern, please file an issue⁠ in the GitHub repo citing which CVE you would like to be addressed.

⁠Source Repository

These Dockerfiles are maintained in the WILDS Docker Library⁠ repository.


Tag summary
Recent tags
Content type
Image
Digest
sha256:23f75990c…
Size
3.6 GB
Last updated
3 days ago
docker pull getwilds/alphafold3:latest