From ec68cdb4ec337b6933f4939ba42c7cff9bfb5fbc Mon Sep 17 00:00:00 2001 From: Roaim Date: Sun, 25 Jan 2026 21:11:11 +0500 Subject: [PATCH 1/2] feat: Implementing parallelization for unzipping files --- README.md | 5 +++-- scripts/download_pdb_mmcif.sh | 7 ++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index e0d1aa108..4c6f0722f 100644 --- a/README.md +++ b/README.md @@ -64,7 +64,7 @@ Please follow these steps: * Install `aria2c`. On most Linux distributions it is available via the package manager as the `aria2` package (on Debian-based distributions this can be installed by running `sudo apt install aria2`). - Same for `rsync`. + Same for `rsync` and `parallel` (`sudo apt install rsync parallel`). * Please use the script `scripts/download_all_data.sh` to download and set up full databases. This may take substantial time (download size is 556 @@ -150,7 +150,7 @@ Please follow these steps: ### Genetic databases -This step requires `aria2c` to be installed on your machine. +This step requires `aria2c` and `rsync` to be installed on your machine. `GNU Parallel` is also highly recommended to speed up the unzipping process. AlphaFold needs multiple genetic (sequence) databases to run: @@ -731,6 +731,7 @@ and packages: * [Docker](https://www.docker.com) * [HH Suite](https://github.com/soedinglab/hh-suite) * [HMMER Suite](http://eddylab.org/software/hmmer) +* [GNU Parallel](https://www.gnu.org/software/parallel/) * [Haiku](https://github.com/deepmind/dm-haiku) * [JAX](https://github.com/google/jax/) * [Kalign](https://msa.sbc.su.se/cgi-bin/msa.cgi) diff --git a/scripts/download_pdb_mmcif.sh b/scripts/download_pdb_mmcif.sh index 7de637f03..0c2c396d1 100755 --- a/scripts/download_pdb_mmcif.sh +++ b/scripts/download_pdb_mmcif.sh @@ -50,7 +50,12 @@ rsync --recursive --links --perms --times --compress --info=progress2 --delete - "${RAW_DIR}" echo "Unzipping all mmCIF files..." -find "${RAW_DIR}/" -type f -iname "*.gz" -exec gunzip {} + +if command -v parallel >/dev/null 2>&1 +then + find "${RAW_DIR}/" -type f -iname "*.gz" -print0 | parallel -0 -j -1 gunzip +else + find "${RAW_DIR}/" -type f -iname "*.gz" -exec gunzip {} + +fi echo "Flattening all mmCIF files..." mkdir --parents "${MMCIF_DIR}" From b362e034ebe238bba4a8e957b398e519e641afa7 Mon Sep 17 00:00:00 2001 From: Roaim Date: Fri, 13 Feb 2026 09:42:13 +0500 Subject: [PATCH 2/2] Update scripts/download_pdb_mmcif.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: 史雲昔 (Vincy SHI) --- scripts/download_pdb_mmcif.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/download_pdb_mmcif.sh b/scripts/download_pdb_mmcif.sh index 0c2c396d1..f29ba84cb 100755 --- a/scripts/download_pdb_mmcif.sh +++ b/scripts/download_pdb_mmcif.sh @@ -52,7 +52,7 @@ rsync --recursive --links --perms --times --compress --info=progress2 --delete - echo "Unzipping all mmCIF files..." if command -v parallel >/dev/null 2>&1 then - find "${RAW_DIR}/" -type f -iname "*.gz" -print0 | parallel -0 -j -1 gunzip + find "${RAW_DIR}/" -type f -iname "*.gz" -print0 | parallel -0 -j -1 --xargs gunzip else find "${RAW_DIR}/" -type f -iname "*.gz" -exec gunzip {} + fi