-
Notifications
You must be signed in to change notification settings - Fork 3
Installation
CheckAMG requires Python 3.11 or 3.12. PyTorch, the PyG torch_scatter extension, and FAISS must be installed before CheckAMG, in the order below. torch_scatter must be source-built against your installed torch.
Pick the block matching your hardware and run it top to bottom. Then download the databases.
conda create -y -n CheckAMG python=3.11
conda activate CheckAMG
python -m ensurepip --upgrade
python -m pip install --upgrade pip setuptools wheel packaging uv
uv pip install torch==2.8.0 --index-url https://download.pytorch.org/whl/cpu
uv pip install torch_geometric
uv cache clean torch_scatter
uv pip install torch_scatter --no-build-isolation --no-binary torch_scatter --refresh
uv pip install faiss-cpu
uv pip install checkamgH100/H200 require cu126 or newer. Use cu128 instead of cu126 if your driver toolkit needs CUDA 12.8.
conda create -y -n CheckAMG python=3.11
conda activate CheckAMG
python -m ensurepip --upgrade
python -m pip install --upgrade pip setuptools wheel packaging uv
uv pip install torch==2.8.0 --index-url https://download.pytorch.org/whl/cu126
uv pip install torch_geometric
uv cache clean torch_scatter
uv pip install torch_scatter --no-build-isolation --no-binary torch_scatter --refresh
uv pip install faiss-gpu-cu12
uv pip install checkamgconda create -y -n CheckAMG python=3.11
conda activate CheckAMG
python -m ensurepip --upgrade
python -m pip install --upgrade pip setuptools wheel packaging uv
uv pip install torch==2.8.0 --index-url https://download.pytorch.org/whl/cu118
uv pip install torch_geometric
uv cache clean torch_scatter
uv pip install torch_scatter --no-build-isolation --no-binary torch_scatter --refresh
uv pip install faiss-gpu-cu11
uv pip install checkamgAbout 116 GB of free disk space is required during download (~97 GB after, with --rm-hmm).
checkamg download -d /path/to/db/destination --rm-hmmIf you do not plan on running checkamg de-novo or checkamg end-to-end, you will not need the de novo database, and can skip downloading it to save an additional 76 GB of disk space:
checkamg download -d /path/to/db/destination --no-download-denovo-db --rm-hmmpython - <<'PY'
import torch, torch_scatter, torch_geometric, faiss, pst, pyhmmer
print("torch:", torch.__version__, "| cuda available:", torch.cuda.is_available())
print("torch_scatter:", torch_scatter.__version__)
print("faiss:", faiss.__version__)
PY
checkamg --versionMost failures are a precompiled torch_scatter wheel being used instead of a source build (segfault, GLIBC_2.XX not found, undefined symbol: _ZN3c10..., or std::length_error / Aborted (core dumped) on checkamg -h). Fix:
uv pip uninstall torch_scatter
uv cache clean torch_scatter
uv pip install torch_scatter --no-build-isolation --no-binary torch_scatter --refresh-
checkamgreinstalled the wrongtorch— Step order matters. Installtorchbeforecheckamg, or pip pulls the default PyPItorch. Recreate the env and run a block above in order. -
torch.cuda.is_available()isFalseon a GPU node — yourtorchCUDA build does not match the driver. Reinstall with a differentcuXXXbuild (thetorch_scatterstep rebuilds automatically). -
torch_scatterbuild fails withcommand 'gcc' failed— install a compiler, then re-run thetorch_scatterline:conda install -c conda-forge gxx_linux-64. -
faiss-gpu-cu1Xaborts on import — install via conda instead:conda install -n CheckAMG -c conda-forge "faiss-gpu=*=*py311*".
Can be useful if you need to package the conda environment for transferring across notes on a computing cluster:
conda install -y -n base -c conda-forge conda-pack
conda activate CheckAMG
for pkg in pip setuptools wheel packaging; do
rm -f "$CONDA_PREFIX/conda-meta/${pkg}-"*.json
done
conda pack -n CheckAMG -o checkamg_env.tar.gzThe rm loop is required: pip replaced these conda-managed packages during install, and conda pack refuses to package the env until conda's stale records for them are removed. If conda pack names another package, add a matching rm and re-pack.