From a63e873e4a1f22bd5a3208a2c0b423a28f3f5480 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Mon, 19 May 2025 14:07:29 +1000 Subject: [PATCH 001/150] AF2.3 extract pTM/iPTM --- bin/extract_metrics.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 2d77c1135..cfa823b95 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -87,14 +87,22 @@ def read_pkl(id, pkl_files): # AlphaFold2.3 non-summary, for each pkl. TODO: Need to either read in ranking_debug.json to get the ranking order, or do it later in the workflow. else: model_id = os.path.basename(pkl_file).replace("result_model_", "").replace(".pkl", "") - write_tsv(f"{id}_{model_id}_lddt.tsv", format_msa_rows(data["plddt"])) + #write_tsv(f"{id}_{model_id}_lddt.tsv", format_msa_rows(data["plddt"])) if 'predicted_aligned_error' not in data.keys(): print(f"No PAE output in {pkl_file}, it was likely a monomer calculation") - write_tsv(f"{id}_{model_id}_pae.tsv", None) else: write_tsv(f"{id}_{model_id}_pae.tsv", format_pae_rows(data["predicted_aligned_error"])) + if 'ptm' not in data.keys(): + print(f"No pTM/iPTM output in {pkl_file}, it was likely a monomer calculation") + else: + with open(f"{id}_{model_id}_ptm.tsv", 'w') as f: + f.write(str(np.round(data['ptm'],3))) + with open(f"{id}_{model_id}_iptm.tsv", 'w') as f: + f.write(str(np.round(data['iptm'],3))) + + def read_a3m(id, a3m_files): # ColabFold, RosettaFold-All-Atom, Boltz-1 for a3m_file in a3m_files: @@ -139,7 +147,6 @@ def main(): parser.add_argument("--pts", dest="pts", required=False, nargs="+") # For read RFAA pytorch model to get PAE data parser.add_argument("--structs", dest="structs", required=False, nargs="+") parser.add_argument("--name", default="untitled", dest="name") # might need a --name $meta.id - parser.add_argument("--output_dir", default=".", dest="output_dir") args = parser.parse_args() if args.pkls: From 0e2b3729536f0407e072631d62d7a2b882d8059d Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Mon, 19 May 2025 15:09:18 +1000 Subject: [PATCH 002/150] Catch ColabFold monomer and multimer --- bin/extract_metrics.py | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index cfa823b95..8377892bf 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -127,9 +127,29 @@ def read_json(id, json_files): msa_rows = [[str(AA_to_int.get(residue, 20)) for residue in line] for line in msa_lines] write_tsv(f"{id}_msa.tsv", msa_rows) #AF3 output with PAE info, or HF3 PAE data. TODO: Need to make sure the workflow points to [protein]/[protein]_rank1/all_results.json - elif "pae" in data: + + # TODO: I think I need to capture model_id and inference_id + if 'alphafold2_multimer_v3' or '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer + # Might want to cut more if I just want ${meta.id}_[metric].tsv + model_id = os.path.basename(json_file) + print(model_id) + if 'all_results' in json_file: # Individual predictions in HF3 + model_id = os.path.dirname(json_file).split('-')[3] + + if "pae" not in data.keys(): + print(f"No PAE output in {json_file}, it was likely a monomer calculation") + else: write_tsv(f"{id}_{idx}_pae.tsv", format_pae_rows(data["pae"])) + if "ptm" not in data.keys(): + print(f"No pTM/ipTM output in {json_file}, it was likely a monomer calculation") + else: + with open(f"{id}_{model_id}_ptm.tsv", 'w') as f: + f.write(str(np.round(data['ptm'],3))) + with open(f"{id}_{model_id}_iptm.tsv", 'w') as f: + f.write(str(np.round(data['iptm'],3))) + + def read_pt(id, pt_files): for pt_file in pt_files: with open(pt_file, 'rb') as f: # TODO: point to [protein]_aux.pt From 7ccd9679681ae91111b45e337fd130bbc5e73428 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Mon, 19 May 2025 15:13:57 +1000 Subject: [PATCH 003/150] add HF3 multimer processing, using [protein]-rank* directories --- bin/extract_metrics.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 8377892bf..26008f40a 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -129,12 +129,13 @@ def read_json(id, json_files): #AF3 output with PAE info, or HF3 PAE data. TODO: Need to make sure the workflow points to [protein]/[protein]_rank1/all_results.json # TODO: I think I need to capture model_id and inference_id - if 'alphafold2_multimer_v3' or '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer + if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer # Might want to cut more if I just want ${meta.id}_[metric].tsv model_id = os.path.basename(json_file) print(model_id) - if 'all_results' in json_file: # Individual predictions in HF3 - model_id = os.path.dirname(json_file).split('-')[3] + if 'all_results' in json_file: # Individual predictions in HF3 + # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case + model_id = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") From fa228253f28fbeb0dbdb05c8dc159d3f3741fa4b Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Mon, 19 May 2025 15:27:34 +1000 Subject: [PATCH 004/150] add Boltz ipTM/pTM metrics extraction. Haven't check with --diffusion-samples in Boltz for multiple models --- bin/extract_metrics.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 26008f40a..b6c92a3d9 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -136,6 +136,9 @@ def read_json(id, json_files): if 'all_results' in json_file: # Individual predictions in HF3 # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case model_id = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output + if 'predictions' in json_file: # Boltz-1 confidences in predictions/[protein]/confidence_[protein]_model_*.json + # TODO: haven't tested this for multiple models with --diffusion_samples + model_id = os.path.basename(json_file).split('_model_')[1] if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") From 98806d4726daa13161565651c5318c862b868d50 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 14:50:02 +1000 Subject: [PATCH 005/150] id -> name for code clarity comes from --name arg --- bin/extract_metrics.py | 64 +++++++++++++++++++++--------------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 0072b332f..68d0fd606 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -10,7 +10,7 @@ # TODO: add extraction of other values, iPTM, etc # TODO: look into have a --prog argument that could set filenames etc, logically seperate it? -# {id}_{prog}_{metric}.tsv might be easier for MultiQC to parse a complex workdir, than without the .prog +# {name}_{prog}_{metric}.tsv might be easier for MultiQC to parse a complex workdir, than without the .prog # Mapping of characters to integers for MSA parsing. # 20 is for unknown characters, and 21 is for gaps. @@ -52,7 +52,7 @@ def write_tsv(file_path, rows): writer = csv.writer(out_f, delimiter='\t') writer.writerows(rows) -def extract_structs_plddt_to_tsv(id, structures): +def extract_structs_plddt_to_tsv(name, structures): """ Write out a tsv file contain pLDDTs for reading by MultiQC in nf-core/proteinfold Uses utils function with BioPython PDB package to extract residue pLDDT values from the b-factor column. @@ -68,9 +68,9 @@ def extract_structs_plddt_to_tsv(id, structures): plddt_rows = [["Positions"] + rank_names] res_id_col = list(range(len(plddt_cols[0]))) plddt_rows.extend(zip(res_id_col, *plddt_cols)) # Combine lists column-wise to make rows - write_tsv(f"{id}_plddt.tsv", plddt_rows) + write_tsv(f"{name}_plddt.tsv", plddt_rows) -def read_pkl(id, pkl_files): +def read_pkl(name, pkl_files): """ Adapted from the Galaxy AlphaFold tool (https://github.com/usegalaxy-au/tools-au/blob/de94df520c8dc7b8652aedb92e90f6ebb312f95f/tools/alphafold/scripts/outputs.py), originally authored by @neoformit and @graceahall and funded by Australian Biocommons and QCIF Australia. """ @@ -81,42 +81,42 @@ def read_pkl(id, pkl_files): # Process MSA data if pkl_file.endswith("features.pkl"): # AlphaFold2.3 # TODO: AlphaFold2.3 fills end rows with 0s in AlpahFold muliter for an alanine nf-core/proteinfold Issue #300 - write_tsv(f"{id}_msa.tsv", format_msa_rows(data["msa"])) + write_tsv(f"{name}_msa.tsv", format_msa_rows(data["msa"])) elif pkl_file.endswith("final_features.pkl"): # HelixFold3 - write_tsv(f"{id}_msa.tsv", format_msa_rows(data["feat"]["msa"])) + write_tsv(f"{name}_msa.tsv", format_msa_rows(data["feat"]["msa"])) # AlphaFold2.3 non-summary, for each pkl. TODO: Need to either read in ranking_debug.json to get the ranking order, or do it later in the workflow. else: - model_id = os.path.basename(pkl_file).replace("result_model_", "").replace(".pkl", "") - #write_tsv(f"{id}_{model_id}_lddt.tsv", format_msa_rows(data["plddt"])) + model_name = os.path.basename(pkl_file).replace("result_model_", "").replace(".pkl", "") + #write_tsv(f"{name}_{model_name}_lddt.tsv", format_msa_rows(data["plddt"])) if 'predicted_aligned_error' not in data.keys(): print(f"No PAE output in {pkl_file}, it was likely a monomer calculation") else: - write_tsv(f"{id}_{model_id}_pae.tsv", format_pae_rows(data["predicted_aligned_error"])) + write_tsv(f"{name}_{model_name}_pae.tsv", format_pae_rows(data["predicted_aligned_error"])) if 'ptm' not in data.keys(): print(f"No pTM/iPTM output in {pkl_file}, it was likely a monomer calculation") else: - with open(f"{id}_{model_id}_ptm.tsv", 'w') as f: + with open(f"{name}_{model_name}_ptm.tsv", 'w') as f: f.write(str(np.round(data['ptm'],3))) - with open(f"{id}_{model_id}_iptm.tsv", 'w') as f: + with open(f"{name}_{model_name}_iptm.tsv", 'w') as f: f.write(str(np.round(data['iptm'],3))) -def read_a3m(id, a3m_files): +def read_a3m(name, a3m_files): # ColabFold, RosettaFold-All-Atom, Boltz-1 for a3m_file in a3m_files: int_seqs = a3m_to_int(a3m_file) - write_tsv(f"{id}_msa.tsv", format_msa_rows(int_seqs)) + write_tsv(f"{name}_msa.tsv", format_msa_rows(int_seqs)) -def read_npz(id, npz_files): - for idx, npz_file in enumerate(npz_files): +def read_npz(name, npz_files): + for namex, npz_file in enumerate(npz_files): data = np.load(npz_file) #Boltz PAE files if --write_full_pae is used if npz_file.split('/')[-1].startswith('pae') and npz_file.endswith('.npz'): - write_tsv(f"{id}_{idx}_pae.tsv", format_pae_rows(data["pae"])) + write_tsv(f"{name}_{idx}_pae.tsv", format_pae_rows(data["pae"])) -def read_json(id, json_files): +def read_json(name, json_files): for idx, json_file in enumerate(json_files): with open(json_file, 'r') as f: data = json.load(f) @@ -125,42 +125,42 @@ def read_json(id, json_files): unpaired_MSAs = data['sequences'][0]['protein']['unpairedMsa'] msa_lines = [line for line in unpaired_MSAs.split("\n") if not line.startswith(">") and line.strip()] msa_rows = [[str(AA_to_int.get(residue, 20)) for residue in line] for line in msa_lines] - write_tsv(f"{id}_msa.tsv", msa_rows) + write_tsv(f"{name}_msa.tsv", msa_rows) #AF3 output with PAE info, or HF3 PAE data. TODO: Need to make sure the workflow points to [protein]/[protein]_rank1/all_results.json - - # TODO: I think I need to capture model_id and inference_id + + # TODO: I think I need to capture model_id and inference_id if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer # Might want to cut more if I just want ${meta.id}_[metric].tsv - model_id = os.path.basename(json_file) - print(model_id) + model_name = os.path.basename(json_file) + print(model_name) if 'all_results' in json_file: # Individual predictions in HF3 - # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case - model_id = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output - if 'predictions' in json_file: # Boltz-1 confidences in predictions/[protein]/confidence_[protein]_model_*.json + # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case + model_name = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output + if 'predictions' in json_file: # Boltz-1 confnameences in predictions/[protein]/confidence_[protein]_model_*.json # TODO: haven't tested this for multiple models with --diffusion_samples - model_id = os.path.basename(json_file).split('_model_')[1] - + model_name = os.path.basename(json_file).split('_model_')[1] + if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") else: - write_tsv(f"{id}_{idx}_pae.tsv", format_pae_rows(data["pae"])) + write_tsv(f"{name}_{idx}_pae.tsv", format_pae_rows(data["pae"])) if "ptm" not in data.keys(): print(f"No pTM/ipTM output in {json_file}, it was likely a monomer calculation") else: - with open(f"{id}_{model_id}_ptm.tsv", 'w') as f: + with open(f"{name}_{model_name}_ptm.tsv", 'w') as f: f.write(str(np.round(data['ptm'],3))) - with open(f"{id}_{model_id}_iptm.tsv", 'w') as f: + with open(f"{name}_{model_name}_iptm.tsv", 'w') as f: f.write(str(np.round(data['iptm'],3))) -def read_pt(id, pt_files): +def read_pt(name, pt_files): for pt_file in pt_files: with open(pt_file, 'rb') as f: # TODO: point to [protein]_aux.pt data = torch.load(f, map_location="cpu") if 'pae' in data: # The pt file has the pae data as a tensor that needs to be cast to a list - write_tsv(f"{id}_pae.tsv", format_pae_rows(data["pae"].tolist())) + write_tsv(f"{name}_pae.tsv", format_pae_rows(data["pae"].tolist())) def main(): parser = argparse.ArgumentParser() From 854c81de28b6a911069163e27f3cc8b86a342a48 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 15:03:10 +1000 Subject: [PATCH 006/150] Add (i)pTM extraction to AF non-split --- modules/local/run_alphafold2/main.nf | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/modules/local/run_alphafold2/main.nf b/modules/local/run_alphafold2/main.nf index df4080f0b..63a48b7eb 100644 --- a/modules/local/run_alphafold2/main.nf +++ b/modules/local/run_alphafold2/main.nf @@ -34,6 +34,8 @@ process RUN_ALPHAFOLD2 { // Default is monomer_ptm which does calculate metrics. Good default, metrics worth it for minor performance loss // Nevertheless PAE has to be optional since not all alphafold2 NN models are handled to generate PAE tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes + tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptms + tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptms path "versions.yml", emit: versions when: @@ -41,6 +43,7 @@ process RUN_ALPHAFOLD2 { script: // Exit if running this module with -profile conda / -profile mamba + // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. Just providing conceptual reminder of file types for refactor if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_ALPHAFOLD2 module does not support Conda. Please use Docker / Singularity / Podman instead.") } @@ -73,7 +76,7 @@ process RUN_ALPHAFOLD2 { cp "${fasta.baseName}"/ranked_0.pdb ./"${meta.id}"_alphafold2.pdb extract_metrics.py --name ${meta.id} \\ - --pkls ${fasta.baseName}/features.pkl \\ + --pkls ${fasta.baseName}/features.pkl ${fasta.baseName}/*.pkl \\ --structs ${fasta.baseName}/ranked*.pdb cat <<-END_VERSIONS > versions.yml @@ -88,6 +91,8 @@ process RUN_ALPHAFOLD2 { touch "${meta.id}_plddt.tsv" touch "${meta.id}_msa.tsv" touch "${meta.id}_0_pae.tsv" + touch "${meta.id}_0_ptm.tsv" + touch "${meta.id}_0_iptm.tsv" mkdir "${fasta.baseName}" touch "${fasta.baseName}/ranked_0.pdb" touch "${fasta.baseName}/ranked_1.pdb" From c3f299b54bbf923aa19a5a69a30a0f86a389a150 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 15:07:18 +1000 Subject: [PATCH 007/150] Add (i)pTM extraction to AF2 split --- modules/local/run_alphafold2_pred/main.nf | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/modules/local/run_alphafold2_pred/main.nf b/modules/local/run_alphafold2_pred/main.nf index 617af1de9..78594a9af 100644 --- a/modules/local/run_alphafold2_pred/main.nf +++ b/modules/local/run_alphafold2_pred/main.nf @@ -21,6 +21,7 @@ process RUN_ALPHAFOLD2_PRED { path ('uniref90/*') path ('pdb_seqres/*') path ('uniprot/*') + // TODO: do we ever really want to be dragging arounda meta2? Can't we just augment meta fields for tracebility? tuple val(meta2), path(features) output: @@ -34,6 +35,8 @@ process RUN_ALPHAFOLD2_PRED { // Default is monomer_ptm which does calculate metrics. Good default, metrics worth it for minor performance loss // Nevertheless PAE has to be optional since not all alphafold2 NN models are handled to generate PAE tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes + tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptms + tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptms path "versions.yml" , emit: versions when: @@ -41,6 +44,7 @@ process RUN_ALPHAFOLD2_PRED { script: // Exit if running this module with -profile conda / -profile mamba + // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. Just providing conceptual reminder of file types for refactor if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_ALPHAFOLD2_PRED module does not support Conda. Please use Docker / Singularity / Podman instead.") } @@ -58,7 +62,7 @@ process RUN_ALPHAFOLD2_PRED { cp "${fasta.baseName}"/ranked_0.pdb ./"${meta.id}"_alphafold2.pdb extract_metrics.py --name ${meta.id} \\ - --pkls ${features} \\ + --pkls ${features} ${fasta.baseName}/*.pkl\\ --structs ${fasta.baseName}/ranked*.pdb cat <<-END_VERSIONS > versions.yml @@ -73,6 +77,8 @@ process RUN_ALPHAFOLD2_PRED { touch "${meta.id}_plddt.tsv" touch "${meta.id}_msa.tsv" touch "${meta.id}_0_pae.tsv" + touch "${meta.id}_0_ptm.tsv" + touch "${meta.id}_0_iptm.tsv" mkdir "${fasta.baseName}" touch "${fasta.baseName}/ranked_0.pdb" touch "${fasta.baseName}/ranked_1.pdb" From 5280a4e79c39fb2590124aa1a92a79c5b64e5eb8 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 15:14:33 +1000 Subject: [PATCH 008/150] Add (i)pTM extraction to HF3 --- modules/local/run_helixfold3/main.nf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 28cd39384..116a98d34 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -31,6 +31,8 @@ process RUN_HELIXFOLD3 { tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa // If ${meta.id}-rank*/all_results.json" doesn't have PAE vales in the key, this will be empty tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes + tuple val(meta), path ("${meta.id}_*_ptms.tsv") , optional: true, emit: ptms + tuple val(meta), path ("${meta.id}_*_iptms.tsv") , optional: true, emit: iptms path ("versions.yml") , emit: versions when: From e7e1d5122d692d687238dbc6ec3ef2e16ace76fe Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 15:51:54 +1000 Subject: [PATCH 009/150] fix idx -> name mistake in read_npz --- bin/extract_metrics.py | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 68d0fd606..2b5ce34f9 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -86,20 +86,20 @@ def read_pkl(name, pkl_files): write_tsv(f"{name}_msa.tsv", format_msa_rows(data["feat"]["msa"])) # AlphaFold2.3 non-summary, for each pkl. TODO: Need to either read in ranking_debug.json to get the ranking order, or do it later in the workflow. else: - model_name = os.path.basename(pkl_file).replace("result_model_", "").replace(".pkl", "") - #write_tsv(f"{name}_{model_name}_lddt.tsv", format_msa_rows(data["plddt"])) + model_id = os.path.basename(pkl_file).replace("result_model_", "").replace(".pkl", "") + #write_tsv(f"{name}_{model_id}_lddt.tsv", format_msa_rows(data["plddt"])) if 'predicted_aligned_error' not in data.keys(): print(f"No PAE output in {pkl_file}, it was likely a monomer calculation") else: - write_tsv(f"{name}_{model_name}_pae.tsv", format_pae_rows(data["predicted_aligned_error"])) + write_tsv(f"{name}_{model_id}_pae.tsv", format_pae_rows(data["predicted_aligned_error"])) if 'ptm' not in data.keys(): print(f"No pTM/iPTM output in {pkl_file}, it was likely a monomer calculation") else: - with open(f"{name}_{model_name}_ptm.tsv", 'w') as f: + with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: f.write(str(np.round(data['ptm'],3))) - with open(f"{name}_{model_name}_iptm.tsv", 'w') as f: + with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: f.write(str(np.round(data['iptm'],3))) @@ -110,7 +110,7 @@ def read_a3m(name, a3m_files): write_tsv(f"{name}_msa.tsv", format_msa_rows(int_seqs)) def read_npz(name, npz_files): - for namex, npz_file in enumerate(npz_files): + for idx, npz_file in enumerate(npz_files): data = np.load(npz_file) #Boltz PAE files if --write_full_pae is used if npz_file.split('/')[-1].startswith('pae') and npz_file.endswith('.npz'): @@ -131,14 +131,14 @@ def read_json(name, json_files): # TODO: I think I need to capture model_id and inference_id if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer # Might want to cut more if I just want ${meta.id}_[metric].tsv - model_name = os.path.basename(json_file) - print(model_name) + model_id = os.path.basename(json_file) + print(model_id) if 'all_results' in json_file: # Individual predictions in HF3 # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case - model_name = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output + model_id = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output if 'predictions' in json_file: # Boltz-1 confnameences in predictions/[protein]/confidence_[protein]_model_*.json # TODO: haven't tested this for multiple models with --diffusion_samples - model_name = os.path.basename(json_file).split('_model_')[1] + model_id = os.path.basename(json_file).split('_model_')[1] if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") @@ -148,9 +148,9 @@ def read_json(name, json_files): if "ptm" not in data.keys(): print(f"No pTM/ipTM output in {json_file}, it was likely a monomer calculation") else: - with open(f"{name}_{model_name}_ptm.tsv", 'w') as f: + with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: f.write(str(np.round(data['ptm'],3))) - with open(f"{name}_{model_name}_iptm.tsv", 'w') as f: + with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: f.write(str(np.round(data['iptm'],3))) From 09a9da4e4b6d89bd89e490edbd55ce30bc0459fb Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 15:53:39 +1000 Subject: [PATCH 010/150] Have Boltz use extract_metrics.py. Need to implement npz 'sequence' msa reader --- modules/local/run_boltz/main.nf | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 550384c71..848959191 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -15,13 +15,21 @@ process RUN_BOLTZ { path ('ccd.pkl') output: + // TODO: rename npz into different emit channels as to not conflict with raw (.tsv) PAE etc. As in PR #306 tuple val(meta), path ("boltz_results_*/processed/msa/*.npz") , emit: msa tuple val(meta), path ("boltz_results_*/processed/structures/*.npz") , emit: structures tuple val(meta), path ("boltz_results_*/predictions/*/confidence*.json") , emit: confidence - tuple val(meta), path ("${meta.id}_plddt_mqc.tsv") , emit: multiqc - tuple val(meta), path ("*boltz.pdb") , emit: pdb + tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: multiqc + // TODO: support cif as well like with HelixFold3 + tuple val(meta), path ("${meta.id}_boltz.pdb") , emit: top_ranked_pdb + tuple val(meta), path ("boltz_results_*/predictions/*/*.pdb") , emit: pdb tuple val(meta), path ("boltz_results_*/predictions/*/plddt_*model_0.npz") , emit: plddt tuple val(meta), path ("boltz_results_*/predictions/*/pae_*model_0.npz") , emit: pae + tuple val(meta), path ("${meta.id}_plddt.tsv") , optional: true, emit: plddt_raw + tuple val(meta), path ("${meta.id}_msa.tsv") , optional: true, emit: msa_raw + tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: pae_raw + tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptm_raw + tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptm_raw path "versions.yml", emit: versions @@ -30,6 +38,11 @@ process RUN_BOLTZ { script: // Exit if running this module with -profile conda / -profile mamba + + // TODO: "boltz_results_*" dir should be be further specified using --out_dir when running Boltz, and being able to go "boltz_results_${meta.id}" instead of "boltz_results_*" + // TODO: MSA processing for Boltz is not solid yet. They can come from webserver, local mmseq, or a custom paired .csv (see docs below) + // https://github.com/jwohlwend/boltz/blob/main/docs/prediction.md#yaml-format + // TODO: what I really need to do is add a function to read /processed/msa/*.npz and convert it to a .tsv file if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_BOLTZ module does not support Conda. Please use Docker / Singularity / Podman instead.") } @@ -40,8 +53,10 @@ process RUN_BOLTZ { boltz predict "${fasta}" ${args} --cache ./ --write_full_pae --output_format pdb cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb - echo -e Atom_serial_number"\\t"Atom_name"\\t"Residue_name"\\t"Residue_sequence_number"\\t"pLDDT > ${meta.id}_plddt_mqc.tsv - awk '{print \$2"\\t"\$3"\\t"\$4"\\t"\$6"\\t"\$11}' boltz_results_*/predictions/*/*.pdb | grep -v 'N/A' | uniq >> ${meta.id}_plddt_mqc.tsv + extract_output.py --name ${meta.id} \\ + --structs "boltz_results_*/predictions/*/*.pdb" \\ + --jsons "boltz_results_*/predictions/confidence_*_model_*.json" \\ + --npzs "boltz_results_*/processed/msa/*.npz" "boltz_results_*/predictions/pae_*_model_*.npz" \\ cat <<-END_VERSIONS > versions.yml "${task.process}": @@ -56,14 +71,19 @@ process RUN_BOLTZ { mkdir -p boltz_results_${meta.id}/processed/structures/ mkdir -p boltz_results_${meta.id}/predictions/${meta.id}/ - touch ${meta.id}_boltz.pdb touch boltz_results_${meta.id}/processed/msa/${meta.id}.npz touch boltz_results_${meta.id}/processed/structures/${meta.id}.npz touch boltz_results_${meta.id}/predictions/${meta.id}/confidence_${meta.id}.json touch boltz_results_${meta.id}/predictions/${meta.id}/${meta.id}.pdb touch boltz_results_${meta.id}/predictions/${meta.id}/plddt_${meta.id}_model_0.npz touch boltz_results_${meta.id}/predictions/${meta.id}/pae_${meta.id}_model_0.npz - touch ${meta.id}_plddt_mqc.tsv + + touch "${meta.id}_boltz.pdb" + touch "${meta.id}_plddt.tsv" + touch "${meta.id}_msa.tsv" + touch "${meta.id}_0_pae.tsv" + touch "${meta.id}_0_ptm.tsv" + touch "${meta.id}_0_iptm.tsv" cat <<-END_VERSIONS > versions.yml "${task.process}": From 144e0d9491c94877cb451f14350df7ffa89586b3 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 15:54:18 +1000 Subject: [PATCH 011/150] note clarifying why two *.pkls went in wrong files --- modules/local/run_alphafold2/main.nf | 2 +- modules/local/run_alphafold2_pred/main.nf | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/local/run_alphafold2/main.nf b/modules/local/run_alphafold2/main.nf index 63a48b7eb..b68e0a118 100644 --- a/modules/local/run_alphafold2/main.nf +++ b/modules/local/run_alphafold2/main.nf @@ -43,7 +43,7 @@ process RUN_ALPHAFOLD2 { script: // Exit if running this module with -profile conda / -profile mamba - // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. Just providing conceptual reminder of file types for refactor + // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. Just providing conceptual reminder of file types for future refactor if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_ALPHAFOLD2 module does not support Conda. Please use Docker / Singularity / Podman instead.") } diff --git a/modules/local/run_alphafold2_pred/main.nf b/modules/local/run_alphafold2_pred/main.nf index 78594a9af..5f181d4c2 100644 --- a/modules/local/run_alphafold2_pred/main.nf +++ b/modules/local/run_alphafold2_pred/main.nf @@ -43,8 +43,8 @@ process RUN_ALPHAFOLD2_PRED { task.ext.when == null || task.ext.when script: - // Exit if running this module with -profile conda / -profile mamba - // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. Just providing conceptual reminder of file types for refactor + // Exit if running this module with -profile conda / -profile mamba:w + // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. The use of input: features makes the conceptural separation clear if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_ALPHAFOLD2_PRED module does not support Conda. Please use Docker / Singularity / Podman instead.") } From 31e495654dc97c939c43932a14afaefb6a19f5cf Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 16:06:47 +1000 Subject: [PATCH 012/150] (i)pTM extraction in CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 766617b40..37a0e4b1e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,6 +39,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #305](https://github.com/nf-core/proteinfold/pull/305)] - Stop RFAA and HF3 symlinking scripts into workdir. - [[PR #306](https://github.com/nf-core/proteinfold/pull/306)] - extract_output.py -> extract_metrics.py so pLDDT, MSA, PAE emitted as raw data .tsv files - [[PR #307](https://github.com/nf-core/proteinfold/pull/307)] - Update Boltz-1 boilerplate and formatting. +- [[PR #308](https://github.com/nf-core/proteinfold/pull/308)] - pTM & ipTM metrics now extracted ### Parameters From 2524d3cd266cb4b6a313e972dee326ce5a0c7a14 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 16:07:39 +1000 Subject: [PATCH 013/150] Use actual PR number given --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 37a0e4b1e..cbdf0b550 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,7 +39,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #305](https://github.com/nf-core/proteinfold/pull/305)] - Stop RFAA and HF3 symlinking scripts into workdir. - [[PR #306](https://github.com/nf-core/proteinfold/pull/306)] - extract_output.py -> extract_metrics.py so pLDDT, MSA, PAE emitted as raw data .tsv files - [[PR #307](https://github.com/nf-core/proteinfold/pull/307)] - Update Boltz-1 boilerplate and formatting. -- [[PR #308](https://github.com/nf-core/proteinfold/pull/308)] - pTM & ipTM metrics now extracted +- [[PR #312](https://github.com/nf-core/proteinfold/pull/312)] - pTM & ipTM metrics now extracted ### Parameters From ae59a7e1e7cc67840fad7b7da53b2b76c0180466 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Wed, 21 May 2025 16:18:43 +1000 Subject: [PATCH 014/150] Fix prettier complaint about CHANGELOG --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cbdf0b550..cec699e95 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,7 +39,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #305](https://github.com/nf-core/proteinfold/pull/305)] - Stop RFAA and HF3 symlinking scripts into workdir. - [[PR #306](https://github.com/nf-core/proteinfold/pull/306)] - extract_output.py -> extract_metrics.py so pLDDT, MSA, PAE emitted as raw data .tsv files - [[PR #307](https://github.com/nf-core/proteinfold/pull/307)] - Update Boltz-1 boilerplate and formatting. -- [[PR #312](https://github.com/nf-core/proteinfold/pull/312)] - pTM & ipTM metrics now extracted +- [[PR #312](https://github.com/nf-core/proteinfold/pull/312)] - pTM & ipTM metrics now extracted ### Parameters From 9be7f1ad0457a71db63fbeeac638547934a3dcad Mon Sep 17 00:00:00 2001 From: jscgh <75345304+jscgh@users.noreply.github.com> Date: Wed, 21 May 2025 16:41:58 +1000 Subject: [PATCH 015/150] Removed stray :w --- modules/local/run_alphafold2_pred/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/run_alphafold2_pred/main.nf b/modules/local/run_alphafold2_pred/main.nf index 5f181d4c2..cad646ac6 100644 --- a/modules/local/run_alphafold2_pred/main.nf +++ b/modules/local/run_alphafold2_pred/main.nf @@ -43,7 +43,7 @@ process RUN_ALPHAFOLD2_PRED { task.ext.when == null || task.ext.when script: - // Exit if running this module with -profile conda / -profile mamba:w + // Exit if running this module with -profile conda / -profile mamba // Note: --pkls ${fasta.baseName}/*.pkl redundantly processes the features.pkl file. The use of input: features makes the conceptural separation clear if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_ALPHAFOLD2_PRED module does not support Conda. Please use Docker / Singularity / Podman instead.") From e511555dd3c15ad64800a8ccd539d039973546ff Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 22 May 2025 13:23:05 +1000 Subject: [PATCH 016/150] Add extract_metric to esmfold --- modules/local/run_esmfold/main.nf | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/local/run_esmfold/main.nf b/modules/local/run_esmfold/main.nf index 004f63e72..8cf74b2f8 100644 --- a/modules/local/run_esmfold/main.nf +++ b/modules/local/run_esmfold/main.nf @@ -43,6 +43,9 @@ process RUN_ESMFOLD { mv *.pdb ${meta.id}_esmfold.pdb + extract_metrics.py --name ${meta.id} \\ + --structs ${meta.id}_esmfold.pdb + cat <<-END_VERSIONS > versions.yml "${task.process}": esm-fold: $VERSION From 46bea81e59cea986b8256395db27d54ab798d377 Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 22 May 2025 13:30:44 +1000 Subject: [PATCH 017/150] extract_output corrected to extract_metrics in HF3 --- modules/local/run_helixfold3/main.nf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 116a98d34..2cdaccdbf 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -4,6 +4,7 @@ process RUN_HELIXFOLD3 { tag "$meta.id" label 'process_medium' + label 'process_gpu' container "nf-core/proteinfold_helixfold3:dev" @@ -72,7 +73,7 @@ process RUN_HELIXFOLD3 { cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.cif" "./${meta.id}_helixfold3.cif" - extract_output.py --name ${meta.id} \\ + extract_metrics.py --name ${meta.id} \\ --structs "${fasta.baseName}/${fasta.baseName}-rank*/predicted_structure.pdb" \\ --pkls "${fasta.baseName}/final_features.pkl" \\ --jsons "${fasta.baseName}-rank*/all_results.json" From f3d702875a6c652c8e367a415f01f6eea91043cb Mon Sep 17 00:00:00 2001 From: jscgh Date: Fri, 23 May 2025 12:42:30 +1000 Subject: [PATCH 018/150] Fixes HF3 not running extract_metrics within the right environment --- modules/local/run_helixfold3/main.nf | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 2cdaccdbf..a35ef5b37 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -4,7 +4,6 @@ process RUN_HELIXFOLD3 { tag "$meta.id" label 'process_medium' - label 'process_gpu' container "nf-core/proteinfold_helixfold3:dev" @@ -72,8 +71,7 @@ process RUN_HELIXFOLD3 { cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.pdb" "./${meta.id}_helixfold3.pdb" cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.cif" "./${meta.id}_helixfold3.cif" - - extract_metrics.py --name ${meta.id} \\ + mamba run --name helixfold extract_metrics.py --name ${meta.id} \\ --structs "${fasta.baseName}/${fasta.baseName}-rank*/predicted_structure.pdb" \\ --pkls "${fasta.baseName}/final_features.pkl" \\ --jsons "${fasta.baseName}-rank*/all_results.json" From e3e0becebe85109edecadb0135658efefc5909a9 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Mon, 26 May 2025 15:58:39 +1000 Subject: [PATCH 019/150] id -> name after merge. Expand TODOs in prep for EXTRACT_METRICS process --- bin/extract_metrics.py | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 05474933c..39351af19 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -8,9 +8,20 @@ import csv from utils import plddt_from_struct_b_factor -# TODO: add extraction of other values, iPTM, etc +# TODO: Issue #309, make into a poper separate process, it its own module so that dependencies can be managed better +# TODO: Need a sense of ranking, so that metrics can be traced back to correct model structure, even if they're not in sequential order. The enumerates() here are not sufficient. +# Needs to be program-dependent, (see item below). # TODO: look into have a --prog argument that could set filenames etc, logically seperate it? # {name}_{prog}_{metric}.tsv might be easier for MultiQC to parse a complex workdir, than without the .prog +# TODO: read --prog from ${meta.model} in the NextFlow pipes. This also allows case switching in a proper EXTRACT_METRICS process. +# E.g. in main.nf of EXTACT_METRICS process, we could have: +# match ${meta.mode}: +# case 'alphafold2': +# ... +# case 'rosettafold_all_atom': +# ... +#... +# ^ overwrought with duplication, but can catch program specific weirdness, and lower barrier to adding new programs in the future. # Mapping of characters to integers for MSA parsing. # 20 is for unknown characters, and 21 is for gaps. @@ -80,14 +91,13 @@ def read_pkl(name, pkl_files): # Process MSA data if pkl_file.endswith("final_features.pkl"): # HelixFold3 - This one must be first - write_tsv(f"{id}_msa.tsv", format_msa_rows(data["feat"]["msa"])) + write_tsv(f"{name}_msa.tsv", format_msa_rows(data["feat"]["msa"])) elif pkl_file.endswith("features.pkl"): # AlphaFold2.3 # TODO: AlphaFold2.3 fills end rows with 0s in AlpahFold muliter for an alanine nf-core/proteinfold Issue #300 - write_tsv(f"{id}_msa.tsv", format_msa_rows(data["msa"])) + write_tsv(f"{name}_msa.tsv", format_msa_rows(data["msa"])) # AlphaFold2.3 non-summary, for each pkl. TODO: Need to either read in ranking_debug.json to get the ranking order, or do it later in the workflow. else: model_id = os.path.basename(pkl_file).replace("result_model_", "").replace(".pkl", "") - #write_tsv(f"{name}_{model_id}_lddt.tsv", format_msa_rows(data["plddt"])) if 'predicted_aligned_error' not in data.keys(): print(f"No PAE output in {pkl_file}, it was likely a monomer calculation") @@ -145,7 +155,7 @@ def read_json(name, json_files): else: write_tsv(f"{name}_{idx}_pae.tsv", format_pae_rows(data["pae"])) -def read_pt(id, pt_files): +def read_pt(name, pt_files): import torch # moved to a conditional import since too bulky import if not used for pt_file in pt_files: with open(pt_file, 'rb') as f: # TODO: point to [protein]_aux.pt @@ -153,7 +163,7 @@ def read_pt(id, pt_files): if 'pae' in data: # The pt file contains a tensor that needs to be cast as an array # Squeeze leading dimension (batch?) - write_tsv(f"{id}_pae.tsv", format_pae_rows(np.squeeze(data["pae"].numpy()))) + write_tsv(f"{name}_pae.tsv", format_pae_rows(np.squeeze(data["pae"].numpy()))) def main(): parser = argparse.ArgumentParser() From 1a3026058c8caf8cf11074b224eb5eb7c5c1dd4e Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Mon, 26 May 2025 16:05:43 +1000 Subject: [PATCH 020/150] extract_metrics was merged into esmfold twice: from both tlitfin and jscgh edits --- modules/local/run_esmfold/main.nf | 2 -- 1 file changed, 2 deletions(-) diff --git a/modules/local/run_esmfold/main.nf b/modules/local/run_esmfold/main.nf index a12689741..8cf74b2f8 100644 --- a/modules/local/run_esmfold/main.nf +++ b/modules/local/run_esmfold/main.nf @@ -42,8 +42,6 @@ process RUN_ESMFOLD { $args mv *.pdb ${meta.id}_esmfold.pdb - extract_metrics.py --name ${meta.id} \\ - --structs ${meta.id}_esmfold.pdb extract_metrics.py --name ${meta.id} \\ --structs ${meta.id}_esmfold.pdb From 4f3d027033d8701eede58c614c6b68034cf198de Mon Sep 17 00:00:00 2001 From: tlitfin Date: Wed, 28 May 2025 13:42:42 +1000 Subject: [PATCH 021/150] Fix boltz extract_metrics crashes --- modules/local/run_boltz/main.nf | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 848959191..db9624b9a 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -53,10 +53,11 @@ process RUN_BOLTZ { boltz predict "${fasta}" ${args} --cache ./ --write_full_pae --output_format pdb cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb - extract_output.py --name ${meta.id} \\ - --structs "boltz_results_*/predictions/*/*.pdb" \\ - --jsons "boltz_results_*/predictions/confidence_*_model_*.json" \\ - --npzs "boltz_results_*/processed/msa/*.npz" "boltz_results_*/predictions/pae_*_model_*.npz" \\ + extract_metrics.py --name ${meta.id} \\ + --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ + --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ + --npzs boltz_results_*/processed/msa/*.npz \\ + boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz cat <<-END_VERSIONS > versions.yml "${task.process}": From d9e092a8a6e7f4fde12b7fe2400a227da1987005 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Wed, 28 May 2025 14:25:15 +1000 Subject: [PATCH 022/150] Fix HelixFold3 extract_metrics crash --- modules/local/run_helixfold3/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 0af2e8043..113ee431f 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -72,7 +72,7 @@ process RUN_HELIXFOLD3 { cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.cif" "./${meta.id}_helixfold3.cif" mamba run --name helixfold extract_metrics.py --name ${meta.id} \\ - --structs "${fasta.baseName}/${fasta.baseName}-rank*/predicted_structure.pdb" \\ + --structs ${fasta.baseName}/${fasta.baseName}-rank*/predicted_structure.pdb \\ --pkls "${fasta.baseName}/final_features.pkl" \\ --jsons ${fasta.baseName}/${fasta.baseName}-rank*/all_results.json From 24b40de2d77fe7160b8b672da111a7c5f8a14be1 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Wed, 28 May 2025 17:22:04 +1000 Subject: [PATCH 023/150] Minor style change to run_alphafold2_pred to escape backslashes --- modules/local/run_alphafold2_pred/main.nf | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/modules/local/run_alphafold2_pred/main.nf b/modules/local/run_alphafold2_pred/main.nf index cad646ac6..619662d1e 100644 --- a/modules/local/run_alphafold2_pred/main.nf +++ b/modules/local/run_alphafold2_pred/main.nf @@ -51,18 +51,17 @@ process RUN_ALPHAFOLD2_PRED { def args = task.ext.args ?: '' """ if [ -d params/alphafold_params_* ]; then ln -r -s params/alphafold_params_*/* params/; fi - python3 /app/alphafold/run_predict.py \ - --fasta_paths=${fasta} \ - --model_preset=${alphafold2_model_preset} \ - --output_dir=\$PWD \ - --data_dir=\$PWD \ - --msa_path=${features} \ - $args + python3 /app/alphafold/run_predict.py \\ + --fasta_paths=${fasta} \\ + --model_preset=${alphafold2_model_preset} \\ + --output_dir=\$PWD \\ + --data_dir=\$PWD \\ + --msa_path=${features} $args cp "${fasta.baseName}"/ranked_0.pdb ./"${meta.id}"_alphafold2.pdb extract_metrics.py --name ${meta.id} \\ - --pkls ${features} ${fasta.baseName}/*.pkl\\ + --pkls ${features} ${fasta.baseName}/*.pkl \\ --structs ${fasta.baseName}/ranked*.pdb cat <<-END_VERSIONS > versions.yml From 8d416df1ab1f0c8ab204fe88443f906be17328f3 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Wed, 28 May 2025 18:52:50 +1000 Subject: [PATCH 024/150] Add ipTM and pTM to HelixFold3 and fix numbering --- bin/extract_metrics.py | 26 +++++++++++++++++--------- modules/local/run_helixfold3/main.nf | 4 ++-- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 39351af19..e29c74ece 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -108,9 +108,9 @@ def read_pkl(name, pkl_files): print(f"No pTM/iPTM output in {pkl_file}, it was likely a monomer calculation") else: with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: - f.write(str(np.round(data['ptm'],3))) + f.write(f"{np.round(data['ptm'],3)}\n") with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: - f.write(str(np.round(data['iptm'],3))) + f.write(f"{np.round(data['iptm'],3)}\n") def read_a3m(name, a3m_files): @@ -139,21 +139,29 @@ def read_json(name, json_files): #AF3 output with PAE info, or HF3 PAE data. TODO: Need to make sure the workflow points to [protein]/[protein]_rank1/all_results.json # TODO: I think I need to capture model_id and inference_id - if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer - # Might want to cut more if I just want ${meta.id}_[metric].tsv - model_id = os.path.basename(json_file) - print(model_id) + #if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer + ## Might want to cut more if I just want ${meta.id}_[metric].tsv + # model_id = os.path.basename(json_file) + # print(model_id) if 'all_results' in json_file: # Individual predictions in HF3 # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case - model_id = os.path.dirname(json_file).split('-rank')[1] #Use re-ranked output + model_id = os.path.dirname(json_file).split('-rank')[-1] #Use re-ranked output if 'predictions' in json_file: # Boltz-1 confnameences in predictions/[protein]/confidence_[protein]_model_*.json # TODO: haven't tested this for multiple models with --diffusion_samples - model_id = os.path.basename(json_file).split('_model_')[1] + model_id = os.path.basename(json_file).split('_model_')[-1].split('.json')[0] if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") else: - write_tsv(f"{name}_{idx}_pae.tsv", format_pae_rows(data["pae"])) + write_tsv(f"{name}_{model_id}_pae.tsv", format_pae_rows(data["pae"])) + + if 'ptm' not in data.keys(): + print(f"No pTM/iPTM output in {json_file}, it was likely a monomer calculation") + else: + with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: + f.write(f"{np.round(data['ptm'],3)}\n") + with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: + f.write(f"{np.round(data['iptm'],3)}\n") def read_pt(name, pt_files): import torch # moved to a conditional import since too bulky import if not used diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 113ee431f..c8cfdf09f 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -31,8 +31,8 @@ process RUN_HELIXFOLD3 { tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa // If ${meta.id}-rank*/all_results.json" doesn't have PAE vales in the key, this will be empty tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes - tuple val(meta), path ("${meta.id}_*_ptms.tsv") , optional: true, emit: ptms - tuple val(meta), path ("${meta.id}_*_iptms.tsv") , optional: true, emit: iptms + tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptms + tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptms path ("versions.yml") , emit: versions when: From 9b7fc250291f28e82c253a762a460b97d5cf8c56 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Wed, 28 May 2025 19:18:59 +1000 Subject: [PATCH 025/150] Fix boltz metric numbering --- bin/extract_metrics.py | 3 ++- modules/local/run_boltz/main.nf | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index e29c74ece..b1ba6d6f3 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -124,7 +124,8 @@ def read_npz(name, npz_files): data = np.load(npz_file) #Boltz PAE files if --write_full_pae is used if npz_file.split('/')[-1].startswith('pae') and npz_file.endswith('.npz'): - write_tsv(f"{name}_{idx}_pae.tsv", format_pae_rows(data["pae"])) + model_id = os.path.basename(npz_file).split('_model_')[-1].split('.npz')[0] + write_tsv(f"{name}_{model_id}_pae.tsv", format_pae_rows(data["pae"])) def read_json(name, json_files): for idx, json_file in enumerate(json_files): diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index db9624b9a..f21fb7bdf 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -56,8 +56,7 @@ process RUN_BOLTZ { extract_metrics.py --name ${meta.id} \\ --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ - --npzs boltz_results_*/processed/msa/*.npz \\ - boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz + --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz cat <<-END_VERSIONS > versions.yml "${task.process}": From dad9ad644daccd9188a327628b5355dcb1304b71 Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 12:24:20 +1000 Subject: [PATCH 026/150] Fix typo --- conf/base.config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/base.config b/conf/base.config index a8adf57c4..1ed1ed0b2 100644 --- a/conf/base.config +++ b/conf/base.config @@ -52,7 +52,7 @@ process { withLabel:process_high_memory { memory = { 200.GB * task.attempt } } - withLabled:process_gpu { + withLabel:process_gpu { accelerator = 1 } withLabel:error_ignore { From 239d5eeca70bacdfe40c7449a77fb55426d288f8 Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 12:32:53 +1000 Subject: [PATCH 027/150] Update boltz dockerfile --- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index 527ef86d9..61a5ca024 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -5,12 +5,12 @@ LABEL authors="Ziad Al-Bkhetan " \ Version="1.2.0dev" \ description="Docker image containing all software requirements to run boltz using the nf-core/proteinfold pipeline" -RUN apt-get update && \ +RUN apt-get update && \ apt-get install -y --no-install-recommends \ build-essential \ procps \ + && pip install --no-cache-dir boltz \ + && apt-get purge -y --auto-remove build-essential \ && rm -rf /var/lib/apt/lists/* -RUN pip install boltz - CMD ["boltz"] From 5457f69aec06361f5084df3f288535a7e0bb066f Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 12:58:26 +1000 Subject: [PATCH 028/150] Update container --- modules/local/run_boltz/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 550384c71..2ffaee219 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -6,7 +6,7 @@ process RUN_BOLTZ { label 'process_medium' label 'process_gpu' - container "nf-core/proteinfold_boltz:dev" + container "jscrh/proteinfold_boltz:2" input: tuple val(meta), path(fasta) From e033d1a593a62d996f1a595bb493934209629483 Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 13:07:32 +1000 Subject: [PATCH 029/150] Linted --- CHANGELOG.md | 4 ++-- main.nf | 4 ++-- nextflow_schema.json | 21 ++++++++++++++------- 3 files changed, 18 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f34a2c82f..1a5c7be5f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -156,8 +156,8 @@ Thank you to everyone else that has contributed by reporting bugs, enhancements | `--uniprot_sprot` | `--uniprot_sprot_link` | | `--uniprot_trembl` | `--uniprot_trembl_link` | | `--uniclust30_path` | `--uniref30_alphafold2_path` | -| `--uniref30` | `--uniref30_colabfold_link` | -| `--uniref30_path` | `--uniref30_colabfold_path` | +| `--uniref30` | `--colabfold_uniref30_link` | +| `--uniref30_path` | `--colabfold_uniref30_path` | | `--num_recycle` | `--num_recycles_colabfold` | | | `--num_recycles_esmfold` | | | `--uniref30_alphafold2_link` | diff --git a/main.nf b/main.nf index d228164ac..2bb982504 100644 --- a/main.nf +++ b/main.nf @@ -443,10 +443,10 @@ workflow NFCORE_PROTEINFOLD { params.colabfold_server, params.colabfold_alphafold2_params_path, params.colabfold_db_path, - params.uniref30_colabfold_path, + params.colabfold_uniref30_path, params.colabfold_alphafold2_params_link, params.colabfold_db_link, - params.uniref30_colabfold_link, + params.colabfold_uniref30_link, params.create_colabfold_index ) ch_versions = ch_versions.mix(PREPARE_COLABFOLD_DBS.out.versions) diff --git a/nextflow_schema.json b/nextflow_schema.json index e576fe05b..f38acd850 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -516,7 +516,8 @@ "alphafold2_uniprot_path": { "type": "string", "description": "Path to UniProt database containing the SwissProt and the TrEMBL databases", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/uniprot/*" } } }, @@ -573,32 +574,38 @@ "alphafold3_small_bfd_path": { "type": "string", "description": "Path to the reduced version of the BFD database", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/small_bfd/*" }, "alphafold3_params_path": { "type": "string", "description": "Path to the Alphafold3 parameters", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/params/*" }, "alphafold3_mgnify_path": { "type": "string", "description": "Path to the MGnify database", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/mgnify/*" }, "alphafold3_pdb_mmcif_path": { "type": "string", "description": "Path to the PDB mmCIF database", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/mmcif_files" }, "alphafold3_uniref90_path": { "type": "string", "description": "Path to the UniRef90 database", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/uniref90/*" }, "alphafold3_pdb_seqres_path": { "type": "string", "description": "Path to the PDB SEQRES database", - "fa_icon": "fas fa-folder-open" + "fa_icon": "fas fa-folder-open", + "default": "null/pdb_seqres/*" }, "alphafold3_uniprot_path": { "type": "string", From 6f944ec4e237b07efd1ddbc7d3f0309a38e87ae7 Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 14:01:58 +1000 Subject: [PATCH 030/150] Update python for boltz-2 compatibility --- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index 61a5ca024..0fb1cb32d 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -1,4 +1,4 @@ -FROM python:3.9-slim +FROM python:3.12-slim LABEL authors="Ziad Al-Bkhetan " \ title="nfcore/proteinfold_boltz" \ From 9e55ad3d1619a7e0634396ae3882711ca925a522 Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 22:10:46 +1000 Subject: [PATCH 031/150] Build-essentials --- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index 0fb1cb32d..f35bbef7b 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -9,8 +9,9 @@ RUN apt-get update && \ apt-get install -y --no-install-recommends \ build-essential \ procps \ - && pip install --no-cache-dir boltz \ - && apt-get purge -y --auto-remove build-essential \ + && apt-get autoremove -y \ && rm -rf /var/lib/apt/lists/* +RUN pip install --no-cache-dir + CMD ["boltz"] From a9478f25c74a7b09fba13446050274559c9ae42a Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 23:17:05 +1000 Subject: [PATCH 032/150] Update boltz --- modules/local/run_boltz/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 2ffaee219..fdc77c8c3 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -6,7 +6,7 @@ process RUN_BOLTZ { label 'process_medium' label 'process_gpu' - container "jscrh/proteinfold_boltz:2" + container "jscrh/proteinfold_boltz:2.0.2" input: tuple val(meta), path(fasta) From 3ff9baeb824f92b6221ec67ce9431de97592e14e Mon Sep 17 00:00:00 2001 From: jscgh Date: Sat, 7 Jun 2025 23:23:22 +1000 Subject: [PATCH 033/150] boltz --- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index f35bbef7b..38ac9e111 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -12,6 +12,6 @@ RUN apt-get update && \ && apt-get autoremove -y \ && rm -rf /var/lib/apt/lists/* -RUN pip install --no-cache-dir +RUN pip install --no-cache-dir boltz CMD ["boltz"] From 98c8514c4dfbd2e3ca5f0bb9c8eea2faa147d7fe Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 12:53:14 +1000 Subject: [PATCH 034/150] Update boltz to include boltz-2 --- conf/dbs.config | 6 +++ main.nf | 11 +++++- modules/local/run_boltz/main.nf | 3 ++ nextflow.config | 6 +++ subworkflows/local/prepare_boltz_dbs.nf | 51 +++++++++++++++++++++++-- workflows/boltz.nf | 8 +++- 6 files changed, 79 insertions(+), 6 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 22e7feec3..1e1f93d12 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -55,10 +55,16 @@ params { // Boltz links boltz_ccd_link = 'https://huggingface.co/boltz-community/boltz-1/resolve/main/ccd.pkl' boltz_model_link = 'https://huggingface.co/boltz-community/boltz-1/resolve/main/boltz1_conf.ckpt' + boltz2_aff_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt' + boltz2_conf_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt' + mols_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar' // Boltz paths boltz_ccd_path = "${params.boltz_db}/ccd.pkl" boltz_model_path = "${params.boltz_db}/boltz1_conf.ckpt" + boltz2_aff_path = "${params.boltz_db}/boltz2_aff.ckpt" + boltz2_conf_path = "${params.boltz_db}/boltz2_conf.ckpt" + mols_path = "${params.boltz_db}/mols/" // Colabfold links colabfold_db_link = 'http://wwwuser.gwdg.de/~compbiol/colabfold/colabfold_envdb_202108.tar.gz' diff --git a/main.nf b/main.nf index 2bb982504..bee810069 100644 --- a/main.nf +++ b/main.nf @@ -433,8 +433,14 @@ workflow NFCORE_PROTEINFOLD { PREPARE_BOLTZ_DBS( params.boltz_ccd_path, params.boltz_model_path, + params.boltz2_aff_path, + params.boltz2_conf_path, + params.mols_path, params.boltz_ccd_link, - params.boltz_model_link + params.boltz_model_link, + params.boltz2_aff_link, + params.boltz2_conf_link, + params.mols_link ) ch_versions = ch_versions.mix(PREPARE_BOLTZ_DBS.out.versions) @@ -456,6 +462,9 @@ workflow NFCORE_PROTEINFOLD { ch_versions, PREPARE_BOLTZ_DBS.out.boltz_ccd, PREPARE_BOLTZ_DBS.out.boltz_model, + PREPARE_BOLTZ_DBS.out.boltz2_aff, + PREPARE_BOLTZ_DBS.out.boltz2_conf, + PREPARE_BOLTZ_DBS.out.mols, PREPARE_COLABFOLD_DBS.out.colabfold_db, PREPARE_COLABFOLD_DBS.out.uniref30, params.boltz_use_msa_server diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index fdc77c8c3..025779637 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -13,6 +13,9 @@ process RUN_BOLTZ { path (files) path ('boltz1_conf.ckpt') path ('ccd.pkl') + path ('boltz2_aff.ckpt') + path ('boltz2_conf.ckpt') + path ('mols/') output: tuple val(meta), path ("boltz_results_*/processed/msa/*.npz") , emit: msa diff --git a/nextflow.config b/nextflow.config index ee0cbd0b1..2c94702cf 100644 --- a/nextflow.config +++ b/nextflow.config @@ -75,11 +75,17 @@ params { // Boltz links boltz_ccd_link = null boltz_model_link = null + boltz2_aff_link = null + boltz2_conf_link = null + mols_link = null // Boltz paths boltz_db = null boltz_ccd_path = null boltz_model_path = null + boltz2_aff_path = null + boltz2_conf_path = null + mols_path = null boltz_use_msa_server = true // Colabfold parameters diff --git a/subworkflows/local/prepare_boltz_dbs.nf b/subworkflows/local/prepare_boltz_dbs.nf index 83588cb12..20ee2c813 100644 --- a/subworkflows/local/prepare_boltz_dbs.nf +++ b/subworkflows/local/prepare_boltz_dbs.nf @@ -4,21 +4,34 @@ include { ARIA2 as ARIA2_BOLTZ_CCD - ARIA2 as ARIA2_BOLTZ_MODEL } from '../../modules/nf-core/aria2/main' + ARIA2 as ARIA2_BOLTZ_MODEL + ARIA2 as ARIA2_BOLTZ2_AFF + ARIA2 as ARIA2_BOLTZ2_CONF + ARIA2 as ARIA2_MOLS +} from '../../modules/nf-core/aria2/main' workflow PREPARE_BOLTZ_DBS { take: boltz_ccd boltz_model + boltz2_aff + boltz2_conf + mols boltz_ccd_link boltz_model_link + boltz2_aff_link + boltz2_conf_link + mols_link main: ch_versions = Channel.empty() - if (boltz_ccd) { - ch_boltz_ccd = Channel.value(file(boltz_ccd)) - ch_boltz_model = Channel.value(file(boltz_model)) + if (boltz_ccd && boltz_model && boltz2_aff && boltz2_conf && mols) { + ch_boltz_ccd = Channel.value(file(boltz_ccd)) + ch_boltz_model = Channel.value(file(boltz_model)) + ch_boltz2_aff = Channel.value(file(boltz2_aff)) + ch_boltz2_conf = Channel.value(file(boltz2_conf)) + ch_mols = Channel.value(file(mols)) } else { ARIA2_BOLTZ_CCD( [ @@ -37,10 +50,40 @@ workflow PREPARE_BOLTZ_DBS { ) ch_boltz_model = ARIA2_BOLTZ_MODEL.out.downloaded_file.map{ it[1] } ch_versions = ch_versions.mix(ARIA2_BOLTZ_MODEL.out.versions) + + ARIA2_BOLTZ2_AFF( + [ + [:], + boltz2_aff_link + ] + ) + ch_boltz2_aff = ARIA2_BOLTZ2_AFF.out.downloaded_file.map{ it[1] } + ch_versions = ch_versions.mix(ARIA2_BOLTZ2_AFF.out.versions) + + ARIA2_BOLTZ2_CONF( + [ + [:], + boltz2_conf_link + ] + ) + ch_boltz2_conf = ARIA2_BOLTZ2_CONF.out.downloaded_file.map{ it[1] } + ch_versions = ch_versions.mix(ARIA2_BOLTZ2_CONF.out.versions) + + ARIA2_MOLS( + [ + [:], + mols_link + ] + ) + ch_mols = ARIA2_MOLS.out.downloaded_file.map{ it[1] } + ch_versions = ch_versions.mix(ARIA2_MOLS.out.versions) } emit: boltz_ccd = ch_boltz_ccd boltz_model = ch_boltz_model + boltz2_aff = ch_boltz2_aff + boltz2_conf = ch_boltz2_conf + mols = ch_mols versions = ch_versions } diff --git a/workflows/boltz.nf b/workflows/boltz.nf index 1a8f4c17b..6b65d0d10 100644 --- a/workflows/boltz.nf +++ b/workflows/boltz.nf @@ -48,6 +48,9 @@ workflow BOLTZ { ch_versions // channel: [ path(versions.yml) ] ch_boltz_ccd // channel: [ path(boltz_ccd) ] ch_boltz_model // channel: [ path(model) ] + ch_boltz2_aff // channel: [ path(boltz2_aff) ] + ch_boltz2_conf // channel: [ path(boltz2_conf) ] + ch_mols // channel: [ path(mols) ] ch_colabfold_db // channel: [ path(colabfold_db) ] ch_uniref30 // channel: [ path(uniref30) ] msa_server @@ -107,7 +110,10 @@ workflow BOLTZ { BOLTZ_FASTA.out.formatted_fasta.map{[it[0], it[1]]}, BOLTZ_FASTA.out.formatted_fasta.map{it[2]}, ch_boltz_model, - ch_boltz_ccd + ch_boltz_ccd, + ch_boltz2_aff, + ch_boltz2_conf, + ch_mols ) RUN_BOLTZ From 07ed19a7bd34ba17a695bc324bde494c9bb76a47 Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 13:03:35 +1000 Subject: [PATCH 035/150] Linted --- nextflow_schema.json | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index f38acd850..24fd2a012 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -1133,5 +1133,31 @@ { "$ref": "#/$defs/helixfold3_dbs_and_parameters_link_options" } - ] + ], + "properties": { + "boltz2_aff_link": { + "type": "string", + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt" + }, + "boltz2_conf_link": { + "type": "string", + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt" + }, + "mols_link": { + "type": "string", + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar" + }, + "boltz2_aff_path": { + "type": "string", + "default": "null/boltz2_aff.ckpt" + }, + "boltz2_conf_path": { + "type": "string", + "default": "null/boltz2_conf.ckpt" + }, + "mols_path": { + "type": "string", + "default": "null/mols/" + } + } } From c09565be2d735257033ef84a9b69d72609a3beb1 Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 13:10:14 +1000 Subject: [PATCH 036/150] Organised schema --- modules/local/run_boltz/main.nf | 2 +- nextflow_schema.json | 52 ++++++++++++++++----------------- 2 files changed, 26 insertions(+), 28 deletions(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 025779637..68c94da00 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -15,7 +15,7 @@ process RUN_BOLTZ { path ('ccd.pkl') path ('boltz2_aff.ckpt') path ('boltz2_conf.ckpt') - path ('mols/') + path ('mols') output: tuple val(meta), path ("boltz_results_*/processed/msa/*.npz") , emit: msa diff --git a/nextflow_schema.json b/nextflow_schema.json index 24fd2a012..759dcff2c 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -743,6 +743,18 @@ "description": "Link to download model file", "icon": "fas fa-link", "default": "https://huggingface.co/boltz-community/boltz-1/resolve/main/boltz1_conf.ckpt" + }, + "boltz2_aff_link": { + "type": "string", + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt" + }, + "boltz2_conf_link": { + "type": "string", + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt" + }, + "mols_link": { + "type": "string", + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar" } } }, @@ -768,6 +780,18 @@ "description": "Path to boltz Model file", "icon": "fas folder-open", "default": "null/boltz1_conf.ckpt" + }, + "boltz2_aff_path": { + "type": "string", + "default": "null/boltz2_aff.ckpt" + }, + "boltz2_conf_path": { + "type": "string", + "default": "null/boltz2_conf.ckpt" + }, + "mols_path": { + "type": "string", + "default": "null/mols/" } } }, @@ -1133,31 +1157,5 @@ { "$ref": "#/$defs/helixfold3_dbs_and_parameters_link_options" } - ], - "properties": { - "boltz2_aff_link": { - "type": "string", - "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt" - }, - "boltz2_conf_link": { - "type": "string", - "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt" - }, - "mols_link": { - "type": "string", - "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar" - }, - "boltz2_aff_path": { - "type": "string", - "default": "null/boltz2_aff.ckpt" - }, - "boltz2_conf_path": { - "type": "string", - "default": "null/boltz2_conf.ckpt" - }, - "mols_path": { - "type": "string", - "default": "null/mols/" - } - } + ] } From e15fc54dcdeebceed7c96d4c69060006ea2e7f80 Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 13:32:27 +1000 Subject: [PATCH 037/150] Updated boltz and mols pathing --- conf/dbs.config | 2 +- modules/local/run_boltz/main.nf | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 1e1f93d12..b6d8c915c 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -64,7 +64,7 @@ params { boltz_model_path = "${params.boltz_db}/boltz1_conf.ckpt" boltz2_aff_path = "${params.boltz_db}/boltz2_aff.ckpt" boltz2_conf_path = "${params.boltz_db}/boltz2_conf.ckpt" - mols_path = "${params.boltz_db}/mols/" + mols_path = "${params.boltz_db}/mols*" // Colabfold links colabfold_db_link = 'http://wwwuser.gwdg.de/~compbiol/colabfold/colabfold_envdb_202108.tar.gz' diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 68c94da00..7f682d1ab 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -6,7 +6,7 @@ process RUN_BOLTZ { label 'process_medium' label 'process_gpu' - container "jscrh/proteinfold_boltz:2.0.2" + container "jscrh/proteinfold_boltz:2.0.3" input: tuple val(meta), path(fasta) @@ -15,7 +15,7 @@ process RUN_BOLTZ { path ('ccd.pkl') path ('boltz2_aff.ckpt') path ('boltz2_conf.ckpt') - path ('mols') + path ('*') output: tuple val(meta), path ("boltz_results_*/processed/msa/*.npz") , emit: msa @@ -36,7 +36,7 @@ process RUN_BOLTZ { if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_BOLTZ module does not support Conda. Please use Docker / Singularity / Podman instead.") } - def version = "0.4.1" + def version = "2.0.3" def args = task.ext.args ?: '' """ From 1e6627300cafd5831f45de4fd5f3c348c5f5c0d9 Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 14:30:13 +1000 Subject: [PATCH 038/150] Remove repeated boltz flags and fix caching --- conf/dbs.config | 2 +- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 3 +++ modules/local/run_boltz/main.nf | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index b6d8c915c..1e1f93d12 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -64,7 +64,7 @@ params { boltz_model_path = "${params.boltz_db}/boltz1_conf.ckpt" boltz2_aff_path = "${params.boltz_db}/boltz2_aff.ckpt" boltz2_conf_path = "${params.boltz_db}/boltz2_conf.ckpt" - mols_path = "${params.boltz_db}/mols*" + mols_path = "${params.boltz_db}/mols/" // Colabfold links colabfold_db_link = 'http://wwwuser.gwdg.de/~compbiol/colabfold/colabfold_envdb_202108.tar.gz' diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index 38ac9e111..00b13dea8 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -14,4 +14,7 @@ RUN apt-get update && \ RUN pip install --no-cache-dir boltz +ENV NUMBA_CACHE_DIR=/tmp +ENV HOME=/tmp + CMD ["boltz"] diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 7f682d1ab..7cb71f605 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -15,7 +15,7 @@ process RUN_BOLTZ { path ('ccd.pkl') path ('boltz2_aff.ckpt') path ('boltz2_conf.ckpt') - path ('*') + path ('mols') output: tuple val(meta), path ("boltz_results_*/processed/msa/*.npz") , emit: msa @@ -40,7 +40,7 @@ process RUN_BOLTZ { def args = task.ext.args ?: '' """ - boltz predict "${fasta}" ${args} --cache ./ --write_full_pae --output_format pdb + boltz predict "${fasta}" ${args} --cache ./ cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb echo -e Atom_serial_number"\\t"Atom_name"\\t"Residue_name"\\t"Residue_sequence_number"\\t"pLDDT > ${meta.id}_plddt_mqc.tsv From 0341b903144d7216cef190783a66326c543c197b Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 15:08:16 +1000 Subject: [PATCH 039/150] Moved env variables to run_boltz --- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 3 --- modules/local/run_boltz/main.nf | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index 00b13dea8..38ac9e111 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -14,7 +14,4 @@ RUN apt-get update && \ RUN pip install --no-cache-dir boltz -ENV NUMBA_CACHE_DIR=/tmp -ENV HOME=/tmp - CMD ["boltz"] diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 7cb71f605..478d23e34 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -40,6 +40,9 @@ process RUN_BOLTZ { def args = task.ext.args ?: '' """ + export NUMBA_CACHE_DIR=/tmp + export HOME=/tmp + boltz predict "${fasta}" ${args} --cache ./ cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb From c3776957c0e9435ed4b661c0a8406dda5080547c Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 15:51:06 +1000 Subject: [PATCH 040/150] Fix boltz_fasta preprocessing --- .../local/data_convertor/boltz_fasta/main.nf | 57 +++++++++++++++---- 1 file changed, 47 insertions(+), 10 deletions(-) diff --git a/modules/local/data_convertor/boltz_fasta/main.nf b/modules/local/data_convertor/boltz_fasta/main.nf index 038965fa1..e71950f90 100644 --- a/modules/local/data_convertor/boltz_fasta/main.nf +++ b/modules/local/data_convertor/boltz_fasta/main.nf @@ -24,31 +24,68 @@ process BOLTZ_FASTA { #!/usr/bin/env python3 import os, sys import string + import re #def safe_filename(file: str) -> str: # return "".join([c if c.isalnum() or c in ["_", ".", "-"] else "_" for c in file]) + ".a3m" all_combinations = list(string.ascii_uppercase) + list(string.ascii_lowercase) + [str(x) for x in range(0, 10)] msa_files = [${msa_files}] - seq_type = "protein" + ENTITY_TYPES = ["protein", "ccd", "smiles"] + + def infer_entity_type(header, sequence): + header_lower = header.lower() + for entity in ENTITY_TYPES: + if entity in header_lower: + return entity + seq = sequence.strip() + if re.fullmatch(r"[A-Z]+", seq) and len(seq) > 20: + return "protein" + if re.fullmatch(r"[A-Za-z0-9@+\\-\\[\\]\\(\\)=#\$%]+", seq): + return "smiles" + if re.fullmatch(r"[A-Z0-9]{3,}", seq) and len(seq) <= 10: + return "ccd" + return "unknown" + os.makedirs("output_fasta", exist_ok=True) counter = 0 with open("${fasta}", "r") as f: lines = f.readlines() + msa = "" fasta_data = "" + seq_lines = [] + header = None + for line in lines: line = line.strip() if line.startswith(">"): - if len(msa_files) > 0: - msa = f"|{os.path.basename(msa_files[counter])}" - if msa[1:] not in msa_files: - print(f"Can not find msa file {os.path.basename(msa_files[counter])}") - exit(1) - - fasta_data += f">{all_combinations[counter]}|{seq_type}{msa}\\n" - counter += 1 + # Write previous entry if exists + if header is not None: + sequence = "".join(seq_lines) + entity_type = infer_entity_type(header, sequence) + msa = "" + if len(msa_files) > 0: + msa = f"|{os.path.basename(msa_files[counter])}" + if msa[1:] not in msa_files: + print(f"Can not find msa file {os.path.basename(msa_files[counter])}") + exit(1) + fasta_data += f">{all_combinations[counter]}|{entity_type}{msa}\\n{sequence}\\n" + counter += 1 + header = line + seq_lines = [] else: - fasta_data += f"{line}\\n" + seq_lines.append(line) + # Write last entry + if header is not None: + sequence = "".join(seq_lines) + entity_type = infer_entity_type(header, sequence) + msa = "" + if len(msa_files) > 0: + msa = f"|{os.path.basename(msa_files[counter])}" + if msa[1:] not in msa_files: + print(f"Can not find msa file {os.path.basename(msa_files[counter])}") + exit(1) + fasta_data += f">{all_combinations[counter]}|{entity_type}{msa}\\n{sequence}\\n" if len(fasta_data) > 0: with open(f"output_fasta/${meta.id}.fasta", "w") as outfile: From 7d945369ad6991350ec033f86a76bca3754af44c Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 10 Jun 2025 17:30:31 +1000 Subject: [PATCH 041/150] Update changelog, fix container --- CHANGELOG.md | 1 + modules/local/run_boltz/main.nf | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1a5c7be5f..87fafb112 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -43,6 +43,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #315](https://github.com/nf-core/proteinfold/pull/315)] - Add global db flag. - [[#263](https://github.com/nf-core/proteinfold/issues/263)] - Removed broken colabfold options (`auto` and `alphafold2`) - [[PR #316](https://github.com/nf-core/proteinfold/pull/316)] - Add process_gpu label to modules which use GPU. +- [[PR #329](https://github.com/nf-core/proteinfold/pull/329)] - Updates Boltz module to include Boltz-2. ### Parameters diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 478d23e34..8a24530b8 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -6,7 +6,7 @@ process RUN_BOLTZ { label 'process_medium' label 'process_gpu' - container "jscrh/proteinfold_boltz:2.0.3" + container "nf-core/proteinfold_boltz:dev" input: tuple val(meta), path(fasta) From de4b5b3040395bc1ef6add305b4da165d13ae70f Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 11 Jun 2025 11:08:38 +1000 Subject: [PATCH 042/150] Add boltz args and improve matching for entity type --- conf/modules_boltz.config | 37 +++++++- docs/usage.md | 52 +++++++++++ .../local/data_convertor/boltz_fasta/main.nf | 16 +++- modules/local/run_boltz/main.nf | 2 +- nextflow.config | 31 ++++++- nextflow_schema.json | 88 ++++++++++++++++++- 6 files changed, 216 insertions(+), 10 deletions(-) diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index ed2fb1eab..2405dc6b1 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -12,16 +12,47 @@ process { withName: 'RUN_BOLTZ' { - ext.args = '--write_full_pae --output_format pdb --use_msa_server' + ext.args = [ + params.boltz_out_dir ? "--out_dir ${params.boltz_out_dir}" : "", + params.boltz_cache ? "--cache ${params.boltz_cache}" : "", + params.boltz_checkpoint ? "--checkpoint ${params.boltz_checkpoint}" : "", + params.boltz_devices ? "--devices ${params.boltz_devices}" : "", + params.boltz_accelerator ? "--accelerator ${params.boltz_accelerator}" : "", + params.boltz_recycling_steps ? "--recycling_steps ${params.boltz_recycling_steps}" : "", + params.boltz_sampling_steps ? "--sampling_steps ${params.boltz_sampling_steps}" : "", + params.boltz_diffusion_samples ? "--diffusion_samples ${params.boltz_diffusion_samples}" : "", + params.boltz_max_parallel_samples ? "--max_parallel_samples ${params.boltz_max_parallel_samples}" : "", + params.boltz_step_scale ? "--step_scale ${params.boltz_step_scale}" : "", + params.boltz_output_format ? "--output_format ${params.boltz_output_format}" : "", + params.boltz_num_workers ? "--num_workers ${params.boltz_num_workers}" : "", + params.boltz_method ? "--method ${params.boltz_method}" : "", + params.boltz_preprocessing_threads ? "--preprocessing-threads ${params.boltz_preprocessing_threads}" : "", + params.boltz_affinity_mw_correction ? "--affinity_mw_correction" : "", + params.boltz_sampling_steps_affinity ? "--sampling_steps_affinity ${params.boltz_sampling_steps_affinity}" : "", + params.boltz_diffusion_samples_affinity ? "--diffusion_samples_affinity ${params.boltz_diffusion_samples_affinity}" : "", + params.boltz_affinity_checkpoint ? "--affinity_checkpoint ${params.boltz_affinity_checkpoint}" : "", + params.boltz_max_msa_seqs ? "--max_msa_seqs ${params.boltz_max_msa_seqs}" : "", + params.boltz_subsample_msa ? "--subsample_msa" : "", + params.boltz_num_subsampled_msa ? "--num_subsampled_msa ${params.boltz_num_subsampled_msa}" : "", + params.boltz_no_trifast ? "--no_trifast" : "", + params.boltz_override ? "--override" : "", + params.boltz_use_msa_server ? "--use_msa_server" : "", + params.boltz_msa_server_url ? "--msa_server_url ${params.boltz_msa_server_url}" : "", + params.boltz_msa_pairing_strategy ? "--msa_pairing_strategy ${params.boltz_msa_pairing_strategy}" : "", + params.boltz_use_potentials ? "--use_potentials" : "", + params.boltz_write_full_pae ? "--write_full_pae" : "", + params.boltz_write_full_pde ? "--write_full_pde" : "" + ].findAll{ it }.join(' ').trim() + publishDir = [ [ - path: { "${params.outdir}/boltz/default" }, + path: { "${params.outdir}/boltz" }, mode: 'copy', saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, pattern: '*.*' ], [ - path: { "${params.outdir}/boltz/default/top_ranked_structures" }, + path: { "${params.outdir}/boltz/top_ranked_structures" }, mode: 'copy', saveAs: { "${meta.id}.pdb" }, pattern: '*.pdb' diff --git a/docs/usage.md b/docs/usage.md index 224f5f510..eb8191e83 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -664,3 +664,55 @@ We recommend adding the following line to your environment to limit this (typica ```bash NXF_OPTS='-Xms1g -Xmx4g' ``` + +## Boltz mode + +To run the pipeline in Boltz mode, use the following command: + +```bash +nextflow run nf-core/proteinfold \ + --input samplesheet.csv \ + --outdir \ + --mode boltz \ + --boltz_use_msa_server \ + --use_gpu \ + -profile +``` + +### Boltz parameter descriptions + +| Parameter | Default | Description | +| ------------------------------------ | ------- | --------------------------------------------------- | +| `--boltz_out_dir` | `null` | Output directory for Boltz predictions | +| `--boltz_cache` | `./` | Boltz cache directory | +| `--boltz_checkpoint` | `null` | Optional checkpoint | +| `--boltz_devices` | `null` | Number of devices to use | +| `--boltz_accelerator` | `null` | Accelerator type (`gpu`, `cpu`, `tpu`) | +| `--boltz_recycling_steps` | `null` | Number of recycling steps | +| `--boltz_sampling_steps` | `null` | Number of sampling steps | +| `--boltz_diffusion_samples` | `null` | Number of diffusion samples | +| `--boltz_max_parallel_samples` | `null` | Maximum number of samples to predict in parallel | +| `--boltz_step_scale` | `null` | Step scale (float) | +| `--boltz_output_format` | `pdb` | Output format (`pdb` or `mmcif`) | +| `--boltz_num_workers` | `null` | Number of dataloader workers | +| `--boltz_method` | `null` | Method to use for prediction | +| `--boltz_preprocessing_threads` | `null` | Number of threads for preprocessing | +| `--boltz_affinity_mw_correction` | `null` | Add MW correction to affinity value head (flag) | +| `--boltz_sampling_steps_affinity` | `null` | Number of sampling steps for affinity prediction | +| `--boltz_diffusion_samples_affinity` | `null` | Number of diffusion samples for affinity prediction | +| `--boltz_affinity_checkpoint` | `null` | Optional checkpoint for affinity | +| `--boltz_max_msa_seqs` | `null` | Maximum number of MSA sequences | +| `--boltz_subsample_msa` | `null` | Subsample the MSA (flag) | +| `--boltz_num_subsampled_msa` | `null` | Number of MSA sequences to subsample | +| `--boltz_no_trifast` | `null` | Do not use trifast kernels (flag) | +| `--boltz_override` | `null` | Override existing predictions (flag) | +| `--boltz_use_msa_server` | `null` | Use MSA server to generate MSAs (flag) | +| `--boltz_msa_server_url` | `null` | MSA server URL | +| `--boltz_msa_pairing_strategy` | `null` | MSA pairing strategy (`greedy`, `complete`) | +| `--boltz_use_potentials` | `null` | Use inference time potentials (flag) | +| `--boltz_write_full_pae` | `true` | Save the full PAE matrix as a file (flag) | +| `--boltz_write_full_pde` | `null` | Save the full PDE matrix as a file (flag) | + +> You can override any of these parameters via the command line or a params file. + +--- diff --git a/modules/local/data_convertor/boltz_fasta/main.nf b/modules/local/data_convertor/boltz_fasta/main.nf index e71950f90..393710281 100644 --- a/modules/local/data_convertor/boltz_fasta/main.nf +++ b/modules/local/data_convertor/boltz_fasta/main.nf @@ -38,12 +38,20 @@ process BOLTZ_FASTA { if entity in header_lower: return entity seq = sequence.strip() - if re.fullmatch(r"[A-Z]+", seq) and len(seq) > 20: + seq_set = set(seq) + # RNA: only A,C,U,G,N + if len(seq_set - set("ACUGN")) == 0: + return "rna" + # DNA: only A,C,T,G,N + if len(seq_set - set("ACTGN")) == 0: + return "dna" + # Protein: only 20 AA, not just A,C,T,G,U,N + protein_letters = set("ACDEFGHIKLMNPQRSTVWY") + if len(seq_set - protein_letters) == 0 and not (seq_set <= set("ACUGTN")): return "protein" - if re.fullmatch(r"[A-Za-z0-9@+\\-\\[\\]\\(\\)=#\$%]+", seq): + # SMILES: fallback + if re.fullmatch(r"[A-Za-z0-9@+\-\[\]\(\)=#\$%]+", seq): return "smiles" - if re.fullmatch(r"[A-Z0-9]{3,}", seq) and len(seq) <= 10: - return "ccd" return "unknown" os.makedirs("output_fasta", exist_ok=True) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 8a24530b8..96bd99b6a 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -43,7 +43,7 @@ process RUN_BOLTZ { export NUMBA_CACHE_DIR=/tmp export HOME=/tmp - boltz predict "${fasta}" ${args} --cache ./ + boltz predict "${fasta}" ${args} cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb echo -e Atom_serial_number"\\t"Atom_name"\\t"Residue_name"\\t"Residue_sequence_number"\\t"pLDDT > ${meta.id}_plddt_mqc.tsv diff --git a/nextflow.config b/nextflow.config index 2c94702cf..cfb38e793 100644 --- a/nextflow.config +++ b/nextflow.config @@ -71,6 +71,36 @@ params { alphafold3_pdb_seqres_path = null alphafold3_uniprot_path = null + // Boltz parameters + boltz_out_dir = null + boltz_cache = './' + boltz_checkpoint = null + boltz_devices = null + boltz_accelerator = null + boltz_recycling_steps = null + boltz_sampling_steps = null + boltz_diffusion_samples = null + boltz_max_parallel_samples = null + boltz_step_scale = null + boltz_output_format = 'pdb' + boltz_num_workers = null + boltz_method = null + boltz_preprocessing_threads = null + boltz_affinity_mw_correction = false + boltz_sampling_steps_affinity = null + boltz_diffusion_samples_affinity = null + boltz_affinity_checkpoint = null + boltz_max_msa_seqs = null + boltz_subsample_msa = false + boltz_num_subsampled_msa = null + boltz_no_trifast = false + boltz_override = false + boltz_use_msa_server = false + boltz_msa_server_url = null + boltz_msa_pairing_strategy = null + boltz_use_potentials = false + boltz_write_full_pae = true + boltz_write_full_pde = false // Boltz links boltz_ccd_link = null @@ -86,7 +116,6 @@ params { boltz2_aff_path = null boltz2_conf_path = null mols_path = null - boltz_use_msa_server = true // Colabfold parameters colabfold_server = "webserver" diff --git a/nextflow_schema.json b/nextflow_schema.json index 759dcff2c..698944569 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -227,8 +227,94 @@ "boltz_use_msa_server": { "type": "boolean", "description": "Use the cloud MSA server", - "icon": "fas folder-open", + "icon": "fas folder-open" + }, + "boltz_out_dir": { + "type": "string" + }, + "boltz_cache": { + "type": "string", + "default": "./" + }, + "boltz_checkpoint": { + "type": "string" + }, + "boltz_devices": { + "type": "string" + }, + "boltz_accelerator": { + "type": "string" + }, + "boltz_recycling_steps": { + "type": "string" + }, + "boltz_sampling_steps": { + "type": "string" + }, + "boltz_diffusion_samples": { + "type": "string" + }, + "boltz_max_parallel_samples": { + "type": "string" + }, + "boltz_step_scale": { + "type": "string" + }, + "boltz_output_format": { + "type": "string", + "default": "pdb" + }, + "boltz_num_workers": { + "type": "string" + }, + "boltz_method": { + "type": "string" + }, + "boltz_preprocessing_threads": { + "type": "string" + }, + "boltz_affinity_mw_correction": { + "type": "boolean" + }, + "boltz_sampling_steps_affinity": { + "type": "string" + }, + "boltz_diffusion_samples_affinity": { + "type": "string" + }, + "boltz_affinity_checkpoint": { + "type": "string" + }, + "boltz_max_msa_seqs": { + "type": "string" + }, + "boltz_subsample_msa": { + "type": "boolean" + }, + "boltz_num_subsampled_msa": { + "type": "string" + }, + "boltz_no_trifast": { + "type": "boolean" + }, + "boltz_override": { + "type": "boolean" + }, + "boltz_msa_server_url": { + "type": "string" + }, + "boltz_msa_pairing_strategy": { + "type": "string" + }, + "boltz_use_potentials": { + "type": "boolean" + }, + "boltz_write_full_pae": { + "type": "boolean", "default": true + }, + "boltz_write_full_pde": { + "type": "boolean" } } }, From 732c32afa37773816df402145e4f33684f769582 Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 11 Jun 2025 11:54:02 +1000 Subject: [PATCH 043/150] Fix escaped char --- modules/local/data_convertor/boltz_fasta/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/data_convertor/boltz_fasta/main.nf b/modules/local/data_convertor/boltz_fasta/main.nf index 393710281..8c6a45236 100644 --- a/modules/local/data_convertor/boltz_fasta/main.nf +++ b/modules/local/data_convertor/boltz_fasta/main.nf @@ -50,7 +50,7 @@ process BOLTZ_FASTA { if len(seq_set - protein_letters) == 0 and not (seq_set <= set("ACUGTN")): return "protein" # SMILES: fallback - if re.fullmatch(r"[A-Za-z0-9@+\-\[\]\(\)=#\$%]+", seq): + if re.fullmatch(r"[A-Za-z0-9@+\\-\\[\\]\\(\\)=#\\\$%]+", seq): return "smiles" return "unknown" From 363847215979230a23d6761a2c1dfd3c1eeb089c Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 12 Jun 2025 16:44:16 +1000 Subject: [PATCH 044/150] Added missing --boltz_model --- conf/modules_boltz.config | 1 + docs/usage.md | 1 + nextflow.config | 1 + nextflow_schema.json | 3 +++ 4 files changed, 6 insertions(+) diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index 2405dc6b1..fc88f8a8f 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -13,6 +13,7 @@ process { withName: 'RUN_BOLTZ' { ext.args = [ + params.boltz_model ? "--model ${params.boltz_model}" : "", params.boltz_out_dir ? "--out_dir ${params.boltz_out_dir}" : "", params.boltz_cache ? "--cache ${params.boltz_cache}" : "", params.boltz_checkpoint ? "--checkpoint ${params.boltz_checkpoint}" : "", diff --git a/docs/usage.md b/docs/usage.md index eb8191e83..43a573725 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -683,6 +683,7 @@ nextflow run nf-core/proteinfold \ | Parameter | Default | Description | | ------------------------------------ | ------- | --------------------------------------------------- | +| `--boltz_model` | `null` | The model to use for prediction. Default is Boltz-2 | | `--boltz_out_dir` | `null` | Output directory for Boltz predictions | | `--boltz_cache` | `./` | Boltz cache directory | | `--boltz_checkpoint` | `null` | Optional checkpoint | diff --git a/nextflow.config b/nextflow.config index cfb38e793..952e46b45 100644 --- a/nextflow.config +++ b/nextflow.config @@ -72,6 +72,7 @@ params { alphafold3_uniprot_path = null // Boltz parameters + boltz_model = null boltz_out_dir = null boltz_cache = './' boltz_checkpoint = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 698944569..2b73bcf77 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -315,6 +315,9 @@ }, "boltz_write_full_pde": { "type": "boolean" + }, + "boltz_model": { + "type": "string" } } }, From 0091acf724eb43a84056ff9a11f114a52a911469 Mon Sep 17 00:00:00 2001 From: jscgh Date: Fri, 27 Jun 2025 15:41:05 +1000 Subject: [PATCH 045/150] Updated RFAA dockerfile, mamba and repo versioned --- .../Dockerfile_nfcore-proteinfold_rosettafold_all_atom | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom b/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom index 06a5cdb37..dafdd6f5a 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom @@ -1,5 +1,5 @@ ARG CUDA=12.6.0 -FROM nvidia/cuda:${CUDA}-cudnn-devel-ubuntu24.04 AS builder +FROM nvidia/cuda:${CUDA}-runtime-ubuntu24.04 AS builder # FROM directive resets ARGS, so we specify again (the value is retained if # previously set). ARG CUDA @@ -15,11 +15,13 @@ ENV PYTHONPATH="/app/RoseTTAFold-All-Atom" \ LD_LIBRARY_PATH="/conda/lib:/usr/local/cuda-$(cut -f1,2 -d. <<< ${CUDA})/lib64:$LD_LIBRARY_PATH" RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y wget git && \ - wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" && \ + wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/download/24.11.0-0/Miniforge3-$(uname)-$(uname -m).sh" && \ bash /tmp/Miniforge3-$(uname)-$(uname -m).sh -b -p /conda && \ - rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* /root/.cache && \ + rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* /root/.cache && \ git clone --single-branch --depth 1 https://github.com/Australian-Structural-Biology-Computing/RoseTTAFold-All-Atom.git /app/RoseTTAFold-All-Atom && \ cd /app/RoseTTAFold-All-Atom && \ + git fetch --depth 1 origin e8f94d6d6ddfb07da2119bcfa94359bc6912fd29 && \ + git checkout e8f94d6d6ddfb07da2119bcfa94359bc6912fd29 && \ /conda/bin/mamba env create --file=environment.yaml && \ /conda/bin/mamba run -n RFAA bash -c \ "python /app/RoseTTAFold-All-Atom/rf2aa/SE3Transformer/setup.py install && \ @@ -35,7 +37,7 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-instal rm -rf /root/.cache *.tar.gz && \ apt-get remove --purge -y wget git && apt-get autoremove -y && apt-get clean -y -FROM nvidia/cuda:${CUDA}-cudnn-runtime-ubuntu24.04 +FROM nvidia/cuda:${CUDA}-base-ubuntu24.04 # FROM directive resets ARGS, so we specify again (the value is retained if # previously set). ARG CUDA From d6e26176b74800737e91db407752b6830418339a Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Thu, 3 Jul 2025 12:52:15 +0200 Subject: [PATCH 046/150] Delete unpaired parenthesis --- workflows/boltz.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workflows/boltz.nf b/workflows/boltz.nf index 9b8d0a8d8..407f66a1c 100644 --- a/workflows/boltz.nf +++ b/workflows/boltz.nf @@ -70,7 +70,7 @@ workflow BOLTZ { ] } ) - ) + .map{ def meta = it[0].clone() meta.cnt = it[2] From d6bfe6e14aaac1c3431e3fd53f2b88cf3e5eda08 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 7 Jul 2025 16:28:25 +1000 Subject: [PATCH 047/150] Fixed unmatched parenthesis --- workflows/boltz.nf | 1 - 1 file changed, 1 deletion(-) diff --git a/workflows/boltz.nf b/workflows/boltz.nf index 9b8d0a8d8..131f93db5 100644 --- a/workflows/boltz.nf +++ b/workflows/boltz.nf @@ -70,7 +70,6 @@ workflow BOLTZ { ] } ) - ) .map{ def meta = it[0].clone() meta.cnt = it[2] From 542d806a4b275317c1d3b4a64ecaee51598b64e2 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 7 Jul 2025 16:28:25 +1000 Subject: [PATCH 048/150] Fixed unmatched parenthesis --- workflows/boltz.nf | 1 - 1 file changed, 1 deletion(-) diff --git a/workflows/boltz.nf b/workflows/boltz.nf index b74555d0e..d1a43cb11 100644 --- a/workflows/boltz.nf +++ b/workflows/boltz.nf @@ -73,7 +73,6 @@ workflow BOLTZ { ] } ) - ) .map{ def meta = it[0].clone() meta.cnt = it[2] From d67b4b04d5133869d368ad7e3629f144dcbd3266 Mon Sep 17 00:00:00 2001 From: nf-core-bot Date: Tue, 8 Jul 2025 11:39:41 +0000 Subject: [PATCH 049/150] Template update for nf-core/tools version 3.3.2 --- .github/actions/nf-test/action.yml | 4 - .github/workflows/linting.yml | 2 +- .github/workflows/linting_comment.yml | 2 +- .github/workflows/nf-test.yml | 45 +++---- .github/workflows/release-announcements.yml | 2 +- .nf-core.yml | 2 +- .pre-commit-config.yaml | 2 +- README.md | 6 +- assets/schema_input.json | 4 +- conf/base.config | 1 + modules.json | 2 +- modules/nf-core/multiqc/environment.yml | 4 +- modules/nf-core/multiqc/main.nf | 4 +- modules/nf-core/multiqc/meta.yml | 110 ++++++++++-------- .../nf-core/multiqc/tests/main.nf.test.snap | 18 +-- nextflow.config | 5 +- nf-test.config | 2 +- ro-crate-metadata.json | 21 ++-- .../tests/nextflow.config | 2 +- tests/.nftignore | 1 + tests/nextflow.config | 6 +- 21 files changed, 128 insertions(+), 117 deletions(-) diff --git a/.github/actions/nf-test/action.yml b/.github/actions/nf-test/action.yml index 243e78238..bf44d9612 100644 --- a/.github/actions/nf-test/action.yml +++ b/.github/actions/nf-test/action.yml @@ -54,13 +54,9 @@ runs: conda-solver: libmamba conda-remove-defaults: true - # TODO Skip failing conda tests and document their failures - # https://github.com/nf-core/modules/issues/7017 - name: Run nf-test shell: bash env: - NFT_DIFF: ${{ env.NFT_DIFF }} - NFT_DIFF_ARGS: ${{ env.NFT_DIFF_ARGS }} NFT_WORKDIR: ${{ env.NFT_WORKDIR }} run: | nf-test test \ diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index f2d7d1dd7..8b0f88c36 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -13,7 +13,7 @@ jobs: steps: - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 - - name: Set up Python 3.12 + - name: Set up Python 3.13 uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5 with: python-version: "3.13" diff --git a/.github/workflows/linting_comment.yml b/.github/workflows/linting_comment.yml index 7e8050fb8..d43797d9d 100644 --- a/.github/workflows/linting_comment.yml +++ b/.github/workflows/linting_comment.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Download lint results - uses: dawidd6/action-download-artifact@4c1e823582f43b179e2cbb49c3eade4e41f992e2 # v10 + uses: dawidd6/action-download-artifact@ac66b43f0e6a346234dd65d4d0c8fbb31cb316e5 # v11 with: workflow: linting.yml workflow_conclusion: completed diff --git a/.github/workflows/nf-test.yml b/.github/workflows/nf-test.yml index f03aea0c0..e7b58449b 100644 --- a/.github/workflows/nf-test.yml +++ b/.github/workflows/nf-test.yml @@ -1,12 +1,5 @@ name: Run nf-test on: - push: - paths-ignore: - - "docs/**" - - "**/meta.yml" - - "**/*.md" - - "**/*.png" - - "**/*.svg" pull_request: paths-ignore: - "docs/**" @@ -35,7 +28,7 @@ jobs: nf-test-changes: name: nf-test-changes runs-on: # use self-hosted runners - - runs-on=$-nf-test-changes + - runs-on=${{ github.run_id }}-nf-test-changes - runner=4cpu-linux-x64 outputs: shard: ${{ steps.set-shards.outputs.shard }} @@ -69,7 +62,7 @@ jobs: needs: [nf-test-changes] if: ${{ needs.nf-test-changes.outputs.total_shards != '0' }} runs-on: # use self-hosted runners - - runs-on=$-nf-test + - runs-on=${{ github.run_id }}-nf-test - runner=4cpu-linux-x64 strategy: fail-fast: false @@ -85,7 +78,7 @@ jobs: - isMain: false profile: "singularity" NXF_VER: - - "24.04.2" + - "24.10.5" - "latest-everything" env: NXF_ANSI_LOG: false @@ -97,23 +90,39 @@ jobs: fetch-depth: 0 - name: Run nf-test + id: run_nf_test uses: ./.github/actions/nf-test + continue-on-error: ${{ matrix.NXF_VER == 'latest-everything' }} env: - NFT_DIFF: ${{ env.NFT_DIFF }} - NFT_DIFF_ARGS: ${{ env.NFT_DIFF_ARGS }} NFT_WORKDIR: ${{ env.NFT_WORKDIR }} with: profile: ${{ matrix.profile }} shard: ${{ matrix.shard }} total_shards: ${{ env.TOTAL_SHARDS }} + + - name: Report test status + if: ${{ always() }} + run: | + if [[ "${{ steps.run_nf_test.outcome }}" == "failure" ]]; then + echo "::error::Test with ${{ matrix.NXF_VER }} failed" + # Add to workflow summary + echo "## ❌ Test failed: ${{ matrix.profile }} | ${{ matrix.NXF_VER }} | Shard ${{ matrix.shard }}/${{ env.TOTAL_SHARDS }}" >> $GITHUB_STEP_SUMMARY + if [[ "${{ matrix.NXF_VER }}" == "latest-everything" ]]; then + echo "::warning::Test with latest-everything failed but will not cause workflow failure. Please check if the error is expected or if it needs fixing." + fi + if [[ "${{ matrix.NXF_VER }}" != "latest-everything" ]]; then + exit 1 + fi + fi + confirm-pass: needs: [nf-test] if: always() runs-on: # use self-hosted runners - - runs-on=$-confirm-pass + - runs-on=${{ github.run_id }}-confirm-pass - runner=2cpu-linux-x64 steps: - - name: One or more tests failed + - name: One or more tests failed (excluding latest-everything) if: ${{ contains(needs.*.result, 'failure') }} run: exit 1 @@ -132,11 +141,3 @@ jobs: echo "DEBUG: toJSON(needs) = ${{ toJSON(needs) }}" echo "DEBUG: toJSON(needs.*.result) = ${{ toJSON(needs.*.result) }}" echo "::endgroup::" - - - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - if: always() - run: | - ls -la ./ - rm -rf ./* || true - rm -rf ./.??* || true - ls -la ./ diff --git a/.github/workflows/release-announcements.yml b/.github/workflows/release-announcements.yml index 4abaf4843..0f7324956 100644 --- a/.github/workflows/release-announcements.yml +++ b/.github/workflows/release-announcements.yml @@ -30,7 +30,7 @@ jobs: bsky-post: runs-on: ubuntu-latest steps: - - uses: zentered/bluesky-post-action@4aa83560bb3eac05dbad1e5f221ee339118abdd2 # v0.2.0 + - uses: zentered/bluesky-post-action@6461056ea355ea43b977e149f7bf76aaa572e5e8 # v0.3.0 with: post: | Pipeline release! ${{ github.repository }} v${{ github.event.release.tag_name }} - ${{ github.event.release.name }}! diff --git a/.nf-core.yml b/.nf-core.yml index c0836010b..eda30c3c5 100644 --- a/.nf-core.yml +++ b/.nf-core.yml @@ -3,7 +3,7 @@ lint: - .github/workflows/linting.yml - .github/CONTRIBUTING.md multiqc_config: false -nf_core_version: 3.3.1 +nf_core_version: 3.3.2 repository_type: pipeline template: author: Athanasios Baltzis, Jose Espinosa-Carrasco, Harshil Patel diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9d0b248d3..bb41beec1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,7 +4,7 @@ repos: hooks: - id: prettier additional_dependencies: - - prettier@3.5.0 + - prettier@3.6.2 - repo: https://github.com/pre-commit/pre-commit-hooks rev: v5.0.0 hooks: diff --git a/README.md b/README.md index ec607b245..5064f3a84 100644 --- a/README.md +++ b/README.md @@ -5,12 +5,12 @@ -[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/ci.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/ci.yml) +[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml) [![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX) [![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com) -[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.04.2-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/) -[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.1-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.1) +[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.10.5-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/) +[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.2-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.2) [![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/) [![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/) [![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/) diff --git a/assets/schema_input.json b/assets/schema_input.json index f59d02b34..26195acfb 100644 --- a/assets/schema_input.json +++ b/assets/schema_input.json @@ -17,14 +17,14 @@ "type": "string", "format": "file-path", "exists": true, - "pattern": "^\\S+\\.f(ast)?q\\.gz$", + "pattern": "^([\\S\\s]*\\/)?[^\\s\\/]+\\.f(ast)?q\\.gz$", "errorMessage": "FastQ file for reads 1 must be provided, cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'" }, "fastq_2": { "type": "string", "format": "file-path", "exists": true, - "pattern": "^\\S+\\.f(ast)?q\\.gz$", + "pattern": "^([\\S\\s]*\\/)?[^\\s\\/]+\\.f(ast)?q\\.gz$", "errorMessage": "FastQ file for reads 2 cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'" } }, diff --git a/conf/base.config b/conf/base.config index e5f78fcab..85f55e13e 100644 --- a/conf/base.config +++ b/conf/base.config @@ -61,5 +61,6 @@ process { } withLabel: process_gpu { ext.use_gpu = { workflow.profile.contains('gpu') } + accelerator = { workflow.profile.contains('gpu') ? 1 : null } } } diff --git a/modules.json b/modules.json index 7707b8446..773df5101 100644 --- a/modules.json +++ b/modules.json @@ -7,7 +7,7 @@ "nf-core": { "multiqc": { "branch": "master", - "git_sha": "f0719ae309075ae4a291533883847c3f7c441dad", + "git_sha": "41dfa3f7c0ffabb96a6a813fe321c6d1cc5b6e46", "installed_by": ["modules"] } } diff --git a/modules/nf-core/multiqc/environment.yml b/modules/nf-core/multiqc/environment.yml index a27122ce1..812fc4c5e 100644 --- a/modules/nf-core/multiqc/environment.yml +++ b/modules/nf-core/multiqc/environment.yml @@ -1,5 +1,7 @@ +--- +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json channels: - conda-forge - bioconda dependencies: - - bioconda::multiqc=1.27 + - bioconda::multiqc=1.29 diff --git a/modules/nf-core/multiqc/main.nf b/modules/nf-core/multiqc/main.nf index 58d9313c6..0ac3c3699 100644 --- a/modules/nf-core/multiqc/main.nf +++ b/modules/nf-core/multiqc/main.nf @@ -3,8 +3,8 @@ process MULTIQC { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/multiqc:1.27--pyhdfd78af_0' : - 'biocontainers/multiqc:1.27--pyhdfd78af_0' }" + 'https://depot.galaxyproject.org/singularity/multiqc:1.29--pyhdfd78af_0' : + 'biocontainers/multiqc:1.29--pyhdfd78af_0' }" input: path multiqc_files, stageAs: "?/*" diff --git a/modules/nf-core/multiqc/meta.yml b/modules/nf-core/multiqc/meta.yml index b16c18792..ce30eb732 100644 --- a/modules/nf-core/multiqc/meta.yml +++ b/modules/nf-core/multiqc/meta.yml @@ -15,57 +15,71 @@ tools: licence: ["GPL-3.0-or-later"] identifier: biotools:multiqc input: - - - multiqc_files: - type: file - description: | - List of reports / files recognised by MultiQC, for example the html and zip output of FastQC - - - multiqc_config: - type: file - description: Optional config yml for MultiQC - pattern: "*.{yml,yaml}" - - - extra_multiqc_config: - type: file - description: Second optional config yml for MultiQC. Will override common sections - in multiqc_config. - pattern: "*.{yml,yaml}" - - - multiqc_logo: + - multiqc_files: + type: file + description: | + List of reports / files recognised by MultiQC, for example the html and zip output of FastQC + ontologies: [] + - multiqc_config: + type: file + description: Optional config yml for MultiQC + pattern: "*.{yml,yaml}" + ontologies: + - edam: http://edamontology.org/format_3750 # YAML + - extra_multiqc_config: + type: file + description: Second optional config yml for MultiQC. Will override common sections + in multiqc_config. + pattern: "*.{yml,yaml}" + ontologies: + - edam: http://edamontology.org/format_3750 # YAML + - multiqc_logo: + type: file + description: Optional logo file for MultiQC + pattern: "*.{png}" + ontologies: [] + - replace_names: + type: file + description: | + Optional two-column sample renaming file. First column a set of + patterns, second column a set of corresponding replacements. Passed via + MultiQC's `--replace-names` option. + pattern: "*.{tsv}" + ontologies: + - edam: http://edamontology.org/format_3475 # TSV + - sample_names: + type: file + description: | + Optional TSV file with headers, passed to the MultiQC --sample_names + argument. + pattern: "*.{tsv}" + ontologies: + - edam: http://edamontology.org/format_3475 # TSV +output: + report: + - "*multiqc_report.html": type: file - description: Optional logo file for MultiQC - pattern: "*.{png}" - - - replace_names: + description: MultiQC report file + pattern: "multiqc_report.html" + ontologies: [] + data: + - "*_data": + type: directory + description: MultiQC data dir + pattern: "multiqc_data" + plots: + - "*_plots": type: file - description: | - Optional two-column sample renaming file. First column a set of - patterns, second column a set of corresponding replacements. Passed via - MultiQC's `--replace-names` option. - pattern: "*.{tsv}" - - - sample_names: + description: Plots created by MultiQC + pattern: "*_data" + ontologies: [] + versions: + - versions.yml: type: file - description: | - Optional TSV file with headers, passed to the MultiQC --sample_names - argument. - pattern: "*.{tsv}" -output: - - report: - - "*multiqc_report.html": - type: file - description: MultiQC report file - pattern: "multiqc_report.html" - - data: - - "*_data": - type: directory - description: MultiQC data dir - pattern: "multiqc_data" - - plots: - - "*_plots": - type: file - description: Plots created by MultiQC - pattern: "*_data" - - versions: - - versions.yml: - type: file - description: File containing software versions - pattern: "versions.yml" + description: File containing software versions + pattern: "versions.yml" + ontologies: + - edam: http://edamontology.org/format_3750 # YAML authors: - "@abhi18av" - "@bunop" diff --git a/modules/nf-core/multiqc/tests/main.nf.test.snap b/modules/nf-core/multiqc/tests/main.nf.test.snap index 7b7c13220..88e90571c 100644 --- a/modules/nf-core/multiqc/tests/main.nf.test.snap +++ b/modules/nf-core/multiqc/tests/main.nf.test.snap @@ -2,14 +2,14 @@ "multiqc_versions_single": { "content": [ [ - "versions.yml:md5,8f3b8c1cec5388cf2708be948c9fa42f" + "versions.yml:md5,c1fe644a37468f6dae548d98bc72c2c1" ] ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.4" + "nextflow": "25.04.2" }, - "timestamp": "2025-01-27T09:29:57.631982377" + "timestamp": "2025-05-22T11:50:41.182332996" }, "multiqc_stub": { "content": [ @@ -17,25 +17,25 @@ "multiqc_report.html", "multiqc_data", "multiqc_plots", - "versions.yml:md5,8f3b8c1cec5388cf2708be948c9fa42f" + "versions.yml:md5,c1fe644a37468f6dae548d98bc72c2c1" ] ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.4" + "nextflow": "25.04.2" }, - "timestamp": "2025-01-27T09:30:34.743726958" + "timestamp": "2025-05-22T11:51:22.448739369" }, "multiqc_versions_config": { "content": [ [ - "versions.yml:md5,8f3b8c1cec5388cf2708be948c9fa42f" + "versions.yml:md5,c1fe644a37468f6dae548d98bc72c2c1" ] ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.4" + "nextflow": "25.04.2" }, - "timestamp": "2025-01-27T09:30:21.44383553" + "timestamp": "2025-05-22T11:51:06.198928424" } } \ No newline at end of file diff --git a/nextflow.config b/nextflow.config index 282d6d44b..42f59084d 100644 --- a/nextflow.config +++ b/nextflow.config @@ -229,7 +229,6 @@ dag { manifest { name = 'nf-core/proteinfold' - author = """Athanasios Baltzis, Jose Espinosa-Carrasco, Harshil Patel""" // The author field is deprecated from Nextflow version 24.10.0, use contributors instead contributors = [ // TODO nf-core: Update the field with the details of the contributors to your pipeline. New with Nextflow version 24.10.0 [ @@ -261,14 +260,14 @@ manifest { description = """Protein 3D structure prediction pipeline""" mainScript = 'main.nf' defaultBranch = 'master' - nextflowVersion = '!>=24.04.2' + nextflowVersion = '!>=24.10.5' version = '1.2.0dev' doi = '' } // Nextflow plugins plugins { - id 'nf-schema@2.3.0' // Validation of pipeline parameters and creation of an input channel from a sample sheet + id 'nf-schema@2.4.2' // Validation of pipeline parameters and creation of an input channel from a sample sheet } validation { diff --git a/nf-test.config b/nf-test.config index 889df7601..3a1fff59f 100644 --- a/nf-test.config +++ b/nf-test.config @@ -9,7 +9,7 @@ config { configFile "tests/nextflow.config" // ignore tests coming from the nf-core/modules repo - ignore 'modules/nf-core/**/*', 'subworkflows/nf-core/**/*' + ignore 'modules/nf-core/**/tests/*', 'subworkflows/nf-core/**/tests/*' // run all test with defined profile(s) from the main nextflow.config profile "test" diff --git a/ro-crate-metadata.json b/ro-crate-metadata.json index 852680a7f..d4e105b22 100644 --- a/ro-crate-metadata.json +++ b/ro-crate-metadata.json @@ -22,8 +22,8 @@ "@id": "./", "@type": "Dataset", "creativeWorkStatus": "InProgress", - "datePublished": "2025-06-03T11:01:48+00:00", - "description": "

\n \n \n \"nf-core/proteinfold\"\n \n

\n\n[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/ci.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/ci.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX)\n[![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.04.2-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.1-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.1)\n[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/proteinfold)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23proteinfold-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/proteinfold)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/proteinfold** is a bioinformatics pipeline that ...\n\n\n\n\n2. Present QC for raw reads ([`MultiQC`](http://multiqc.info/))\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) with `-profile test` before running the workflow on actual data.\n\n\n\nNow, you can run the pipeline using:\n\n\n\n```bash\nnextflow run nf-core/proteinfold \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \n```\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) and the [parameter documentation](https://nf-co.re/proteinfold/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/proteinfold/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/proteinfold/output).\n\n## Credits\n\nnf-core/proteinfold was originally written by Athanasios Baltzis, Jose Espinosa-Carrasco, Harshil Patel.\n\nWe thank the following people for their extensive assistance in the development of this pipeline:\n\n\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#proteinfold` channel](https://nfcore.slack.com/channels/proteinfold) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\n\n\n\n\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", + "datePublished": "2025-07-08T11:39:36+00:00", + "description": "

\n \n \n \"nf-core/proteinfold\"\n \n

\n\n[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX)\n[![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.10.5-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.2-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.2)\n[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/proteinfold)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23proteinfold-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/proteinfold)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/proteinfold** is a bioinformatics pipeline that ...\n\n\n\n\n2. Present QC for raw reads ([`MultiQC`](http://multiqc.info/))\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) with `-profile test` before running the workflow on actual data.\n\n\n\nNow, you can run the pipeline using:\n\n\n\n```bash\nnextflow run nf-core/proteinfold \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \n```\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) and the [parameter documentation](https://nf-co.re/proteinfold/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/proteinfold/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/proteinfold/output).\n\n## Credits\n\nnf-core/proteinfold was originally written by Athanasios Baltzis, Jose Espinosa-Carrasco, Harshil Patel.\n\nWe thank the following people for their extensive assistance in the development of this pipeline:\n\n\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#proteinfold` channel](https://nfcore.slack.com/channels/proteinfold) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\n\n\n\n\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", "hasPart": [ { "@id": "main.nf" @@ -99,7 +99,7 @@ }, "mentions": [ { - "@id": "#97ee32f4-c70e-40dd-972c-ef911da3cede" + "@id": "#3e40ea74-c4ab-45b1-beb5-accf31043a86" } ], "name": "nf-core/proteinfold" @@ -128,7 +128,7 @@ } ], "dateCreated": "", - "dateModified": "2025-06-03T11:01:48Z", + "dateModified": "2025-07-08T11:39:36Z", "dct:conformsTo": "https://bioschemas.org/profiles/ComputationalWorkflow/1.0-RELEASE/", "keywords": [ "nf-core", @@ -142,11 +142,6 @@ "protein-structure" ], "license": ["MIT"], - "maintainer": [ - { - "@id": "#drpatelhh@gmail.com" - } - ], "name": ["nf-core/proteinfold"], "programmingLanguage": { "@id": "https://w3id.org/workflowhub/workflow-ro-crate#nextflow" @@ -167,14 +162,14 @@ "url": { "@id": "https://www.nextflow.io/" }, - "version": "!>=24.04.2" + "version": "!>=24.10.5" }, { - "@id": "#97ee32f4-c70e-40dd-972c-ef911da3cede", + "@id": "#3e40ea74-c4ab-45b1-beb5-accf31043a86", "@type": "TestSuite", "instance": [ { - "@id": "#30e6ae55-7030-44bd-845c-db16063cb2c1" + "@id": "#401a0219-0d1e-4d19-a6af-901d59fc4e4c" } ], "mainEntity": { @@ -183,7 +178,7 @@ "name": "Test suite for nf-core/proteinfold" }, { - "@id": "#30e6ae55-7030-44bd-845c-db16063cb2c1", + "@id": "#401a0219-0d1e-4d19-a6af-901d59fc4e4c", "@type": "TestInstance", "name": "GitHub Actions workflow for testing nf-core/proteinfold", "resource": "repos/nf-core/proteinfold/actions/workflows/nf-test.yml", diff --git a/subworkflows/nf-core/utils_nfschema_plugin/tests/nextflow.config b/subworkflows/nf-core/utils_nfschema_plugin/tests/nextflow.config index 0907ac58f..09ef842ae 100644 --- a/subworkflows/nf-core/utils_nfschema_plugin/tests/nextflow.config +++ b/subworkflows/nf-core/utils_nfschema_plugin/tests/nextflow.config @@ -1,5 +1,5 @@ plugins { - id "nf-schema@2.1.0" + id "nf-schema@2.4.2" } validation { diff --git a/tests/.nftignore b/tests/.nftignore index dcdf312a7..16409f40c 100644 --- a/tests/.nftignore +++ b/tests/.nftignore @@ -1,4 +1,5 @@ .DS_Store +multiqc/multiqc_data/BETA-multiqc.parquet multiqc/multiqc_data/multiqc.log multiqc/multiqc_data/multiqc_data.json multiqc/multiqc_data/multiqc_sources.txt diff --git a/tests/nextflow.config b/tests/nextflow.config index 84568cfca..9b4ef8173 100644 --- a/tests/nextflow.config +++ b/tests/nextflow.config @@ -6,7 +6,9 @@ // TODO nf-core: Specify any additional parameters here // Or any resources requirements -params.modules_testdata_base_path = 'https://raw.githubusercontent.com/nf-core/test-datasets/modules/data/' -params.pipelines_testdata_base_path = 'https://raw.githubusercontent.com/nf-core/test-datasets/refs/heads/proteinfold' +params { + modules_testdata_base_path = 'https://raw.githubusercontent.com/nf-core/test-datasets/modules/data/' + pipelines_testdata_base_path = 'https://raw.githubusercontent.com/nf-core/test-datasets/refs/heads/proteinfold' +} aws.client.anonymous = true // fixes S3 access issues on self-hosted runners From be68201574d98c54e3ca31ada88a45578622a949 Mon Sep 17 00:00:00 2001 From: jscgh Date: Fri, 11 Jul 2025 13:49:05 +1000 Subject: [PATCH 050/150] Add dna and rna to boltz entities --- modules/local/data_convertor/boltz_fasta/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/data_convertor/boltz_fasta/main.nf b/modules/local/data_convertor/boltz_fasta/main.nf index 8c6a45236..59f99c88a 100644 --- a/modules/local/data_convertor/boltz_fasta/main.nf +++ b/modules/local/data_convertor/boltz_fasta/main.nf @@ -30,7 +30,7 @@ process BOLTZ_FASTA { all_combinations = list(string.ascii_uppercase) + list(string.ascii_lowercase) + [str(x) for x in range(0, 10)] msa_files = [${msa_files}] - ENTITY_TYPES = ["protein", "ccd", "smiles"] + ENTITY_TYPES = ["protein", "ccd", "smiles", "dna", "rna"] def infer_entity_type(header, sequence): header_lower = header.lower() From 633e586b2e15288ea4fab427b30279583cc880c7 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 15:38:55 +1000 Subject: [PATCH 051/150] Update HF3 to simplify publishdir outputs --- bin/extract_metrics.py | 62 ++++++++++++++++++++++------ conf/modules_helixfold3.config | 16 ++++--- modules/local/run_helixfold3/main.nf | 31 ++++++++------ 3 files changed, 80 insertions(+), 29 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 277866048..55df2a84e 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -85,6 +85,8 @@ def read_pkl(name, pkl_files): """ Adapted from the Galaxy AlphaFold tool (https://github.com/usegalaxy-au/tools-au/blob/de94df520c8dc7b8652aedb92e90f6ebb312f95f/tools/alphafold/scripts/outputs.py), originally authored by @neoformit and @graceahall and funded by Australian Biocommons and QCIF Australia. """ + ptm_data = {} + iptm_data = {} for pkl_file in pkl_files: print(f"Processing {pkl_file}") data = pickle.load(open(pkl_file, "rb")) @@ -107,10 +109,20 @@ def read_pkl(name, pkl_files): if 'ptm' not in data.keys(): print(f"No pTM/iPTM output in {pkl_file}, it was likely a monomer calculation") else: - with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: - f.write(f"{np.round(data['ptm'],3)}\n") - with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: - f.write(f"{np.round(data['iptm'],3)}\n") + #with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: + # f.write(f"{np.round(data['ptm'],3)}\n") + #with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: + # f.write(f"{np.round(data['iptm'],3)}\n") + ptm_data[f"{model_id}"] = f"{np.round(data['ptm'],3)}\n" + iptm_data[f"{model_id}"] = f"{np.round(data.get('iptm',0.),3)}\n" + if ptm_data: + with open(f"{name}_ptm.tsv", 'w') as f: + for k, v in ptm_data.items(): #probably better to be ordered + f.write(f"{k} {v}") + with open(f"{name}_iptm.tsv", 'w') as f: + for k, v in iptm_data.items(): #probably better to be ordered + f.write(f"{k} {v}") + def read_a3m(name, a3m_files): @@ -127,7 +139,22 @@ def read_npz(name, npz_files): model_id = os.path.basename(npz_file).split('_model_')[-1].split('.npz')[0] write_tsv(f"{name}_{model_id}_pae.tsv", format_pae_rows(data["pae"])) +def read_csv(name, csv_files): + for idx, csv_file in enumerate(csv_files): + model_id = os.path.basename(csv_file).split('_')[-1].split('.csv')[0] + msa_lines = [] + with open(csv_file) as f: + f.readline() + for line in f: + msa_lines.append(''.join(c for c in line.strip('\n').split(',')[1] if not c.islower())) + msa_rows = [[str(AA_to_int.get(residue, 20)) for residue in line] for line in msa_lines] + write_tsv(f"{name}_msa.tsv", msa_rows) + break # only 1 csv + def read_json(name, json_files): + ptm_data = {} + iptm_data = {} + print("HELLO") for idx, json_file in enumerate(json_files): with open(json_file, 'r') as f: data = json.load(f) @@ -145,9 +172,8 @@ def read_json(name, json_files): # model_id = os.path.basename(json_file) # print(model_id) if 'all_results' in json_file: # Individual predictions in HF3 - # TODO: iPTM is 0 in some HF3 files. Check that's just no the one case - model_id = os.path.dirname(json_file).split('-rank')[-1] #Use re-ranked output - if 'predictions' in json_file: # Boltz-1 confnameences in predictions/[protein]/confidence_[protein]_model_*.json + model_id = int(os.path.dirname(json_file).split('-rank')[-1]) #Use re-ranked output + if 'predictions' in json_file: # Boltz-1 confidences in predictions/[protein]/confidence_[protein]_model_*.json # TODO: haven't tested this for multiple models with --diffusion_samples model_id = os.path.basename(json_file).split('_model_')[-1].split('.json')[0] @@ -159,10 +185,19 @@ def read_json(name, json_files): if 'ptm' not in data.keys(): print(f"No pTM/iPTM output in {json_file}, it was likely a monomer calculation") else: - with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: - f.write(f"{np.round(data['ptm'],3)}\n") - with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: - f.write(f"{np.round(data['iptm'],3)}\n") + #with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: + # f.write(f"{np.round(data['ptm'],3)}\n") + #with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: + # f.write(f"{np.round(data['iptm'],3)}\n") + ptm_data[model_id] = f"{np.round(data['ptm'],3)}\n" + iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" + if ptm_data: + with open(f"{name}_ptm.tsv", 'w') as f: + for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): + f.write(f"{k} {v}") + with open(f"{name}_iptm.tsv", 'w') as f: + for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): + f.write(f"{k} {v}") def read_pt(name, pt_files): import torch # moved to a conditional import since too bulky import if not used @@ -178,7 +213,8 @@ def main(): parser = argparse.ArgumentParser() parser.add_argument("--pkls", dest="pkls", required=False, nargs="+") # For reading both HelixFold3 and AlphaFold2 MSA formats parser.add_argument("--npzs", dest="npzs", required=False, nargs="+") # For reading the Boltz-1 PAE formats. TODO: Boltz-1 MSA not implemented (go straight to .a3m file), implement - parser.add_argument("--a3ms", dest="a3ms", required=False, nargs="+") # For reading the RosettaFold-All-Atom, ColabFold, and Boltz-1 MSA formats + parser.add_argument("--a3ms", dest="a3ms", required=False, nargs="+") # For reading the RosettaFold-All-Atom, ColabFold MSA formats + parser.add_argument("--csvs", dest="csvs", required=False, nargs="+") # For reading boltz csvs parser.add_argument("--jsons", dest="jsons", required=False, nargs="+") # For reading the AF3 MSA & PAE, HF3 PAE parser.add_argument("--pts", dest="pts", required=False, nargs="+") # For read RFAA pytorch model to get PAE data parser.add_argument("--structs", dest="structs", required=False, nargs="+") @@ -189,6 +225,8 @@ def main(): read_pkl(args.name, args.pkls) if args.a3ms: read_a3m(args.name, args.a3ms) + if args.csvs: + read_csv(args.name, args.csvs) if args.npzs: read_npz(args.name, args.npzs) if args.jsons: diff --git a/conf/modules_helixfold3.config b/conf/modules_helixfold3.config index f3011a11e..bbdd8a090 100644 --- a/conf/modules_helixfold3.config +++ b/conf/modules_helixfold3.config @@ -34,11 +34,17 @@ process { ].join(' ').trim() publishDir = [ - path: { "${params.outdir}/helixfold3/" }, - mode: 'copy', - saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, - pattern: '*.*' - ] + path: { "${params.outdir}/helixfold3/${meta.id}" }, + mode: 'copy', + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, + pattern: '*.*' + ] } withName: 'NFCORE_PROTEINFOLD:HELIXFOLD3:MULTIQC' { diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 17189ecb5..2302d34ae 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -27,13 +27,13 @@ process RUN_HELIXFOLD3 { output: tuple val(meta), path ("${meta.id}_helixfold3.pdb") , emit: top_ranked_pdb tuple val(meta), path ("${meta.id}_helixfold3.cif") , emit: main_cif - tuple val(meta), path ("${meta.id}/ranked*.pdb") , emit: pdb + tuple val(meta), path ("${meta.id}-ranked*.pdb") , emit: pdb tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: multiqc tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa // If ${meta.id}-rank*/all_results.json" doesn't have PAE vales in the key, this will be empty - tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes - tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptms - tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptms + tuple val(meta), path ("${meta.id}_*_pae.tsv") , emit: paes + tuple val(meta), path ("${meta.id}_ptm.tsv") , emit: ptms + tuple val(meta), path ("${meta.id}_iptm.tsv") , emit: iptms path ("versions.yml") , emit: versions when: @@ -78,8 +78,9 @@ process RUN_HELIXFOLD3 { --jsons ${fasta.baseName}/${fasta.baseName}-rank*/all_results.json [ ! -d ${meta.id} ] && mkdir ${meta.id} - for i in 1 2 3 4 5 - do cp "${fasta.baseName}/${fasta.baseName}-rank\$i/predicted_structure.pdb" "${meta.id}/ranked_\$i.pdb" + for i in 1 2 3 4 5; do + cp "${fasta.baseName}/${fasta.baseName}-rank\$i/predicted_structure.pdb" "${meta.id}-ranked_\$i.pdb" + done cat <<-END_VERSIONS > versions.yml @@ -94,13 +95,19 @@ process RUN_HELIXFOLD3 { touch "${meta.id}_helixfold3.pdb" touch "${meta.id}_plddt.tsv" touch "${meta.id}_msa.tsv" - touch "${meta.id}_0_pae.tsv" + touch "${meta.id}_ptm.tsv" + touch "${meta.id}_iptm.tsv" + touch "${meta.id}_1_pae.tsv" + touch "${meta.id}_2_pae.tsv" + touch "${meta.id}_3_pae.tsv" + touch "${meta.id}_4_pae.tsv" + touch "${meta.id}_5_pae.tsv" mkdir "${meta.id}" - touch "${meta.id}/ranked_1.pdb" - touch "${meta.id}/ranked_2.pdb" - touch "${meta.id}/ranked_3.pdb" - touch "${meta.id}/ranked_4.pdb" - touch "${meta.id}/ranked_5.pdb" + touch "${meta.id}-ranked_1.pdb" + touch "${meta.id}-ranked_2.pdb" + touch "${meta.id}-ranked_3.pdb" + touch "${meta.id}-ranked_4.pdb" + touch "${meta.id}-ranked_5.pdb" cat <<-END_VERSIONS > versions.yml From 75919fad7e6c973cd688f12f21129cfd6454e817 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 22:20:11 +1000 Subject: [PATCH 052/150] Update AF2 to simplify publishdir outputs --- conf/modules_alphafold2.config | 22 +++++++++++++++++----- modules/local/run_alphafold2/main.nf | 12 +++++------- modules/local/run_alphafold2_pred/main.nf | 14 ++++++++------ 3 files changed, 30 insertions(+), 18 deletions(-) diff --git a/conf/modules_alphafold2.config b/conf/modules_alphafold2.config index 691d4ac8c..78e09e631 100644 --- a/conf/modules_alphafold2.config +++ b/conf/modules_alphafold2.config @@ -41,9 +41,15 @@ process { ].join(' ').trim() publishDir = [ [ - path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}" }, + path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}/${meta.id}" }, mode: 'copy', - saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, pattern: '*.*' ], [ @@ -60,7 +66,7 @@ process { withName: 'RUN_ALPHAFOLD2_MSA' { ext.args = params.max_template_date ? "--max_template_date ${params.max_template_date}" : '' publishDir = [ - path: { "${params.outdir}/alphafold2_${params.alphafold2_mode}" }, + path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}" }, mode: 'copy', saveAs: { filename -> filename.equals('versions.yml') ? null : filename } ] @@ -71,9 +77,15 @@ process { ext.args = params.use_gpu ? '--use_gpu_relax=true' : '--use_gpu_relax=false' publishDir = [ [ - path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}" }, + path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}/${meta.id}" }, mode: 'copy', - saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, pattern: '*.*' ], [ diff --git a/modules/local/run_alphafold2/main.nf b/modules/local/run_alphafold2/main.nf index 24ac3aa2b..58100bc41 100644 --- a/modules/local/run_alphafold2/main.nf +++ b/modules/local/run_alphafold2/main.nf @@ -32,11 +32,9 @@ process RUN_ALPHAFOLD2 { tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: multiqc tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa // TODO: alphafold2_model_preset == "monomer" the pae file won't exist. - // Default is monomer_ptm which does calculate metrics. Good default, metrics worth it for minor performance loss - // Nevertheless PAE has to be optional since not all alphafold2 NN models are handled to generate PAE - tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes - tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptms - tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptms + tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes + tuple val(meta), path ("${meta.id}_ptm.tsv") , optional: true, emit: ptms + tuple val(meta), path ("${meta.id}_iptm.tsv") , optional: true, emit: iptms path "versions.yml", emit: versions when: @@ -92,8 +90,8 @@ process RUN_ALPHAFOLD2 { touch "${meta.id}_plddt.tsv" touch "${meta.id}_msa.tsv" touch "${meta.id}_0_pae.tsv" - touch "${meta.id}_0_ptm.tsv" - touch "${meta.id}_0_iptm.tsv" + touch "${meta.id}_ptm.tsv" + touch "${meta.id}_iptm.tsv" mkdir "${fasta.baseName}" touch "${fasta.baseName}/ranked_0.pdb" touch "${fasta.baseName}/ranked_1.pdb" diff --git a/modules/local/run_alphafold2_pred/main.nf b/modules/local/run_alphafold2_pred/main.nf index 88b7df5d1..0d760b2f7 100644 --- a/modules/local/run_alphafold2_pred/main.nf +++ b/modules/local/run_alphafold2_pred/main.nf @@ -33,11 +33,9 @@ process RUN_ALPHAFOLD2_PRED { // TODO: re-label multiqc -> plddt so multiqc channel can take in all metrics tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: multiqc // TODO: alphafold2_model_preset == "monomer" the pae file won't exist. - // Default is monomer_ptm which does calculate metrics. Good default, metrics worth it for minor performance loss - // Nevertheless PAE has to be optional since not all alphafold2 NN models are handled to generate PAE tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes - tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptms - tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptms + tuple val(meta), path ("${meta.id}_ptm.tsv") , optional: true, emit: ptms + tuple val(meta), path ("${meta.id}_iptm.tsv") , optional: true, emit: iptms path "versions.yml" , emit: versions when: @@ -77,8 +75,12 @@ process RUN_ALPHAFOLD2_PRED { touch "${meta.id}_plddt.tsv" touch "${meta.id}_msa.tsv" touch "${meta.id}_0_pae.tsv" - touch "${meta.id}_0_ptm.tsv" - touch "${meta.id}_0_iptm.tsv" + touch "${meta.id}_1_pae.tsv" + touch "${meta.id}_2_pae.tsv" + touch "${meta.id}_3_pae.tsv" + touch "${meta.id}_4_pae.tsv" + touch "${meta.id}_ptm.tsv" + touch "${meta.id}_iptm.tsv" mkdir "${fasta.baseName}" touch "${fasta.baseName}/ranked_0.pdb" touch "${fasta.baseName}/ranked_1.pdb" From b23d256d44e470064784aca3a5c31ce5778a4622 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 22:33:05 +1000 Subject: [PATCH 053/150] Update boltz to simplify publishdir outputs --- conf/modules_boltz.config | 16 +++++++++++----- modules/local/run_boltz/main.nf | 11 ++++++----- workflows/boltz.nf | 1 - 3 files changed, 17 insertions(+), 11 deletions(-) diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index ed2fb1eab..9bc57865f 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -15,13 +15,19 @@ process { ext.args = '--write_full_pae --output_format pdb --use_msa_server' publishDir = [ [ - path: { "${params.outdir}/boltz/default" }, - mode: 'copy', - saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, - pattern: '*.*' + path: { "${params.outdir}/boltz/${meta.id}" }, + mode: 'copy', + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, + pattern: '*.*' ], [ - path: { "${params.outdir}/boltz/default/top_ranked_structures" }, + path: { "${params.outdir}/boltz/${meta.id}/top_ranked_structures" }, mode: 'copy', saveAs: { "${meta.id}.pdb" }, pattern: '*.pdb' diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index f21fb7bdf..50cf77227 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -25,11 +25,11 @@ process RUN_BOLTZ { tuple val(meta), path ("boltz_results_*/predictions/*/*.pdb") , emit: pdb tuple val(meta), path ("boltz_results_*/predictions/*/plddt_*model_0.npz") , emit: plddt tuple val(meta), path ("boltz_results_*/predictions/*/pae_*model_0.npz") , emit: pae - tuple val(meta), path ("${meta.id}_plddt.tsv") , optional: true, emit: plddt_raw - tuple val(meta), path ("${meta.id}_msa.tsv") , optional: true, emit: msa_raw + tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: plddt_raw + tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa_raw tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: pae_raw - tuple val(meta), path ("${meta.id}_*_ptm.tsv") , optional: true, emit: ptm_raw - tuple val(meta), path ("${meta.id}_*_iptm.tsv") , optional: true, emit: iptm_raw + tuple val(meta), path ("${meta.id}_ptm.tsv") , emit: ptm_raw + tuple val(meta), path ("${meta.id}_iptm.tsv") , emit: iptm_raw path "versions.yml", emit: versions @@ -56,7 +56,8 @@ process RUN_BOLTZ { extract_metrics.py --name ${meta.id} \\ --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ - --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz + --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz \\ + --csvs boltz_results_*/msa/${meta.id}_*.csv \\ cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/workflows/boltz.nf b/workflows/boltz.nf index 9b8d0a8d8..131f93db5 100644 --- a/workflows/boltz.nf +++ b/workflows/boltz.nf @@ -70,7 +70,6 @@ workflow BOLTZ { ] } ) - ) .map{ def meta = it[0].clone() meta.cnt = it[2] From 9b7362eef70548d9488af43f04d7e60f77fa589f Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 22:34:04 +1000 Subject: [PATCH 054/150] Remove debug print --- bin/extract_metrics.py | 1 - 1 file changed, 1 deletion(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 55df2a84e..f5fce329b 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -154,7 +154,6 @@ def read_csv(name, csv_files): def read_json(name, json_files): ptm_data = {} iptm_data = {} - print("HELLO") for idx, json_file in enumerate(json_files): with open(json_file, 'r') as f: data = json.load(f) From 2f2078225c7aacac9fbefa0d487be4dbcbc08409 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 22:52:23 +1000 Subject: [PATCH 055/150] Remove colabfold comment --- modules/local/colabfold_batch/main.nf | 2 -- 1 file changed, 2 deletions(-) diff --git a/modules/local/colabfold_batch/main.nf b/modules/local/colabfold_batch/main.nf index ba4264e76..7dce5f2b3 100644 --- a/modules/local/colabfold_batch/main.nf +++ b/modules/local/colabfold_batch/main.nf @@ -42,10 +42,8 @@ process COLABFOLD_BATCH { \$PWD for i in `find *.png -maxdepth 0`; do cp \$i \${i%'.png'}_mqc.png; done if [ ! -e `find *_relaxed_rank_001_*.pdb` ]; then - #for i in `find *_relaxed_rank_001*.pdb`; do cp \$i `echo \$i | sed "s|_relaxed_rank_|\t|g" | cut -f1`"_colabfold.pdb"; done cp *_relaxed_rank_001*.pdb ${meta.id}_colabfold.pdb else - #for i in `find *_unrelaxed_rank_001*.pdb`; do cp \$i `echo \$i | sed "s|_unrelaxed_rank_|\t|g" | cut -f1`"_colabfold.pdb"; done cp *_unrelaxed_rank_001*.pdb ${meta.id}_colabfold.pdb fi From a4d867fc230d4c78c20793f08fc629db049727c1 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 23:09:50 +1000 Subject: [PATCH 056/150] Fix linting --- conf/modules_helixfold3.config | 2 +- modules/local/run_helixfold3/main.nf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/conf/modules_helixfold3.config b/conf/modules_helixfold3.config index bbdd8a090..66a1fdcd1 100644 --- a/conf/modules_helixfold3.config +++ b/conf/modules_helixfold3.config @@ -36,7 +36,7 @@ process { publishDir = [ path: { "${params.outdir}/helixfold3/${meta.id}" }, mode: 'copy', - saveAs: { filename -> + saveAs: { filename -> if(filename.endsWith('_pae.tsv')){ "paes/$filename" } else if(filename.equals('versions.yml')){ diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 2302d34ae..ef148e9c7 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -80,7 +80,7 @@ process RUN_HELIXFOLD3 { [ ! -d ${meta.id} ] && mkdir ${meta.id} for i in 1 2 3 4 5; do cp "${fasta.baseName}/${fasta.baseName}-rank\$i/predicted_structure.pdb" "${meta.id}-ranked_\$i.pdb" - + done cat <<-END_VERSIONS > versions.yml From 10bae5ab31bdae2e5a20d2f7d8cfd0da4db44820 Mon Sep 17 00:00:00 2001 From: tlitfin Date: Sat, 12 Jul 2025 23:36:33 +1000 Subject: [PATCH 057/150] fix AF2 split test --- modules/local/run_alphafold2_pred/main.nf | 6 ------ 1 file changed, 6 deletions(-) diff --git a/modules/local/run_alphafold2_pred/main.nf b/modules/local/run_alphafold2_pred/main.nf index 0d760b2f7..2eea1ac4c 100644 --- a/modules/local/run_alphafold2_pred/main.nf +++ b/modules/local/run_alphafold2_pred/main.nf @@ -75,12 +75,6 @@ process RUN_ALPHAFOLD2_PRED { touch "${meta.id}_plddt.tsv" touch "${meta.id}_msa.tsv" touch "${meta.id}_0_pae.tsv" - touch "${meta.id}_1_pae.tsv" - touch "${meta.id}_2_pae.tsv" - touch "${meta.id}_3_pae.tsv" - touch "${meta.id}_4_pae.tsv" - touch "${meta.id}_ptm.tsv" - touch "${meta.id}_iptm.tsv" mkdir "${fasta.baseName}" touch "${fasta.baseName}/ranked_0.pdb" touch "${fasta.baseName}/ranked_1.pdb" From 593cc3e576e3244f1bf1a1685c2f72eaa6688a8c Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 17 Jul 2025 17:32:37 +1000 Subject: [PATCH 058/150] Removed unneeded boltz params --- conf/modules_boltz.config | 24 ------------- docs/usage.md | 40 +++++---------------- nextflow.config | 24 ------------- nextflow_schema.json | 74 --------------------------------------- 4 files changed, 8 insertions(+), 154 deletions(-) diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index fc88f8a8f..4b4660287 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -15,34 +15,10 @@ process { ext.args = [ params.boltz_model ? "--model ${params.boltz_model}" : "", params.boltz_out_dir ? "--out_dir ${params.boltz_out_dir}" : "", - params.boltz_cache ? "--cache ${params.boltz_cache}" : "", - params.boltz_checkpoint ? "--checkpoint ${params.boltz_checkpoint}" : "", - params.boltz_devices ? "--devices ${params.boltz_devices}" : "", - params.boltz_accelerator ? "--accelerator ${params.boltz_accelerator}" : "", - params.boltz_recycling_steps ? "--recycling_steps ${params.boltz_recycling_steps}" : "", - params.boltz_sampling_steps ? "--sampling_steps ${params.boltz_sampling_steps}" : "", - params.boltz_diffusion_samples ? "--diffusion_samples ${params.boltz_diffusion_samples}" : "", - params.boltz_max_parallel_samples ? "--max_parallel_samples ${params.boltz_max_parallel_samples}" : "", - params.boltz_step_scale ? "--step_scale ${params.boltz_step_scale}" : "", - params.boltz_output_format ? "--output_format ${params.boltz_output_format}" : "", - params.boltz_num_workers ? "--num_workers ${params.boltz_num_workers}" : "", - params.boltz_method ? "--method ${params.boltz_method}" : "", - params.boltz_preprocessing_threads ? "--preprocessing-threads ${params.boltz_preprocessing_threads}" : "", - params.boltz_affinity_mw_correction ? "--affinity_mw_correction" : "", - params.boltz_sampling_steps_affinity ? "--sampling_steps_affinity ${params.boltz_sampling_steps_affinity}" : "", - params.boltz_diffusion_samples_affinity ? "--diffusion_samples_affinity ${params.boltz_diffusion_samples_affinity}" : "", - params.boltz_affinity_checkpoint ? "--affinity_checkpoint ${params.boltz_affinity_checkpoint}" : "", - params.boltz_max_msa_seqs ? "--max_msa_seqs ${params.boltz_max_msa_seqs}" : "", - params.boltz_subsample_msa ? "--subsample_msa" : "", - params.boltz_num_subsampled_msa ? "--num_subsampled_msa ${params.boltz_num_subsampled_msa}" : "", - params.boltz_no_trifast ? "--no_trifast" : "", - params.boltz_override ? "--override" : "", params.boltz_use_msa_server ? "--use_msa_server" : "", params.boltz_msa_server_url ? "--msa_server_url ${params.boltz_msa_server_url}" : "", - params.boltz_msa_pairing_strategy ? "--msa_pairing_strategy ${params.boltz_msa_pairing_strategy}" : "", params.boltz_use_potentials ? "--use_potentials" : "", params.boltz_write_full_pae ? "--write_full_pae" : "", - params.boltz_write_full_pde ? "--write_full_pde" : "" ].findAll{ it }.join(' ').trim() publishDir = [ diff --git a/docs/usage.md b/docs/usage.md index c11357a86..ac0b7040b 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -591,38 +591,14 @@ nextflow run nf-core/proteinfold \ ### Boltz parameter descriptions -| Parameter | Default | Description | -| ------------------------------------ | ------- | --------------------------------------------------- | -| `--boltz_model` | `null` | The model to use for prediction. Default is Boltz-2 | -| `--boltz_out_dir` | `null` | Output directory for Boltz predictions | -| `--boltz_cache` | `./` | Boltz cache directory | -| `--boltz_checkpoint` | `null` | Optional checkpoint | -| `--boltz_devices` | `null` | Number of devices to use | -| `--boltz_accelerator` | `null` | Accelerator type (`gpu`, `cpu`, `tpu`) | -| `--boltz_recycling_steps` | `null` | Number of recycling steps | -| `--boltz_sampling_steps` | `null` | Number of sampling steps | -| `--boltz_diffusion_samples` | `null` | Number of diffusion samples | -| `--boltz_max_parallel_samples` | `null` | Maximum number of samples to predict in parallel | -| `--boltz_step_scale` | `null` | Step scale (float) | -| `--boltz_output_format` | `pdb` | Output format (`pdb` or `mmcif`) | -| `--boltz_num_workers` | `null` | Number of dataloader workers | -| `--boltz_method` | `null` | Method to use for prediction | -| `--boltz_preprocessing_threads` | `null` | Number of threads for preprocessing | -| `--boltz_affinity_mw_correction` | `null` | Add MW correction to affinity value head (flag) | -| `--boltz_sampling_steps_affinity` | `null` | Number of sampling steps for affinity prediction | -| `--boltz_diffusion_samples_affinity` | `null` | Number of diffusion samples for affinity prediction | -| `--boltz_affinity_checkpoint` | `null` | Optional checkpoint for affinity | -| `--boltz_max_msa_seqs` | `null` | Maximum number of MSA sequences | -| `--boltz_subsample_msa` | `null` | Subsample the MSA (flag) | -| `--boltz_num_subsampled_msa` | `null` | Number of MSA sequences to subsample | -| `--boltz_no_trifast` | `null` | Do not use trifast kernels (flag) | -| `--boltz_override` | `null` | Override existing predictions (flag) | -| `--boltz_use_msa_server` | `null` | Use MSA server to generate MSAs (flag) | -| `--boltz_msa_server_url` | `null` | MSA server URL | -| `--boltz_msa_pairing_strategy` | `null` | MSA pairing strategy (`greedy`, `complete`) | -| `--boltz_use_potentials` | `null` | Use inference time potentials (flag) | -| `--boltz_write_full_pae` | `true` | Save the full PAE matrix as a file (flag) | -| `--boltz_write_full_pde` | `null` | Save the full PDE matrix as a file (flag) | +| Parameter | Default | Description | +| ------------------------ | ------- | --------------------------------------------------- | +| `--boltz_model` | `null` | The model to use for prediction. Default is Boltz-2 | +| `--boltz_out_dir` | `null` | Output directory for Boltz predictions | +| `--boltz_use_msa_server` | `null` | Use MSA server to generate MSAs (flag) | +| `--boltz_msa_server_url` | `null` | MSA server URL | +| `--boltz_use_potentials` | `null` | Use inference time potentials (flag) | +| `--boltz_write_full_pae` | `true` | Save the full PAE matrix as a file (flag) | > You can override any of these parameters via the command line or a params file. diff --git a/nextflow.config b/nextflow.config index 4d15b436d..7fccb279a 100644 --- a/nextflow.config +++ b/nextflow.config @@ -75,34 +75,10 @@ params { // Boltz parameters boltz_model = null boltz_out_dir = null - boltz_cache = './' - boltz_checkpoint = null - boltz_devices = null - boltz_accelerator = null - boltz_recycling_steps = null - boltz_sampling_steps = null - boltz_diffusion_samples = null - boltz_max_parallel_samples = null - boltz_step_scale = null - boltz_output_format = 'pdb' - boltz_num_workers = null - boltz_method = null - boltz_preprocessing_threads = null - boltz_affinity_mw_correction = false - boltz_sampling_steps_affinity = null - boltz_diffusion_samples_affinity = null - boltz_affinity_checkpoint = null - boltz_max_msa_seqs = null - boltz_subsample_msa = false - boltz_num_subsampled_msa = null - boltz_no_trifast = false - boltz_override = false boltz_use_msa_server = false boltz_msa_server_url = null - boltz_msa_pairing_strategy = null boltz_use_potentials = false boltz_write_full_pae = true - boltz_write_full_pde = false // Boltz links boltz_ccd_link = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 2464cb493..01f41447e 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -250,80 +250,9 @@ "boltz_out_dir": { "type": "string" }, - "boltz_cache": { - "type": "string", - "default": "./" - }, - "boltz_checkpoint": { - "type": "string" - }, - "boltz_devices": { - "type": "string" - }, - "boltz_accelerator": { - "type": "string" - }, - "boltz_recycling_steps": { - "type": "string" - }, - "boltz_sampling_steps": { - "type": "string" - }, - "boltz_diffusion_samples": { - "type": "string" - }, - "boltz_max_parallel_samples": { - "type": "string" - }, - "boltz_step_scale": { - "type": "string" - }, - "boltz_output_format": { - "type": "string", - "default": "pdb" - }, - "boltz_num_workers": { - "type": "string" - }, - "boltz_method": { - "type": "string" - }, - "boltz_preprocessing_threads": { - "type": "string" - }, - "boltz_affinity_mw_correction": { - "type": "boolean" - }, - "boltz_sampling_steps_affinity": { - "type": "string" - }, - "boltz_diffusion_samples_affinity": { - "type": "string" - }, - "boltz_affinity_checkpoint": { - "type": "string" - }, - "boltz_max_msa_seqs": { - "type": "string" - }, - "boltz_subsample_msa": { - "type": "boolean" - }, - "boltz_num_subsampled_msa": { - "type": "string" - }, - "boltz_no_trifast": { - "type": "boolean" - }, - "boltz_override": { - "type": "boolean" - }, "boltz_msa_server_url": { "type": "string" }, - "boltz_msa_pairing_strategy": { - "type": "string" - }, "boltz_use_potentials": { "type": "boolean" }, @@ -331,9 +260,6 @@ "type": "boolean", "default": true }, - "boltz_write_full_pde": { - "type": "boolean" - }, "boltz_model": { "type": "string" } From f8f31fd253177989d38f7a4846e37d2a3b0fcc8b Mon Sep 17 00:00:00 2001 From: vagkaratzas Date: Thu, 17 Jul 2025 08:35:31 +0100 Subject: [PATCH 059/150] github snapshot diff fix --- .github/workflows/nf-test.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/nf-test.yml b/.github/workflows/nf-test.yml index f03aea0c0..325bc152f 100644 --- a/.github/workflows/nf-test.yml +++ b/.github/workflows/nf-test.yml @@ -99,8 +99,6 @@ jobs: - name: Run nf-test uses: ./.github/actions/nf-test env: - NFT_DIFF: ${{ env.NFT_DIFF }} - NFT_DIFF_ARGS: ${{ env.NFT_DIFF_ARGS }} NFT_WORKDIR: ${{ env.NFT_WORKDIR }} with: profile: ${{ matrix.profile }} From b27f09dcc359c02c3f3281b4ba1f3873eabb5af4 Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 17 Jul 2025 17:59:33 +1000 Subject: [PATCH 060/150] Added back boltz_output_format with pdb default --- conf/modules_boltz.config | 1 + nextflow.config | 1 + nextflow_schema.json | 8 +++++++- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index 4b4660287..847abc6eb 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -15,6 +15,7 @@ process { ext.args = [ params.boltz_model ? "--model ${params.boltz_model}" : "", params.boltz_out_dir ? "--out_dir ${params.boltz_out_dir}" : "", + params.boltz_output_format ? "--output_format ${params.boltz_output_format}" : "", params.boltz_use_msa_server ? "--use_msa_server" : "", params.boltz_msa_server_url ? "--msa_server_url ${params.boltz_msa_server_url}" : "", params.boltz_use_potentials ? "--use_potentials" : "", diff --git a/nextflow.config b/nextflow.config index 7fccb279a..42dd5ee70 100644 --- a/nextflow.config +++ b/nextflow.config @@ -75,6 +75,7 @@ params { // Boltz parameters boltz_model = null boltz_out_dir = null + boltz_output_format = 'pdb' boltz_use_msa_server = false boltz_msa_server_url = null boltz_use_potentials = false diff --git a/nextflow_schema.json b/nextflow_schema.json index 01f41447e..352864076 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -1190,5 +1190,11 @@ { "$ref": "#/$defs/helixfold3_dbs_and_parameters_link_options" } - ] + ], + "properties": { + "boltz_output_format": { + "type": "string", + "default": "pdb" + } + } } From c364b902301bb8dc640bdf374490baa781ffbd07 Mon Sep 17 00:00:00 2001 From: jscgh Date: Fri, 18 Jul 2025 11:20:34 +1000 Subject: [PATCH 061/150] Fixing colabfold_uniref30 name --- CHANGELOG.md | 4 ++-- main.nf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b420ee5b..a90c6cc66 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -161,8 +161,8 @@ Thank you to everyone else that has contributed by reporting bugs, enhancements | `--uniprot_sprot` | `--uniprot_sprot_link` | | `--uniprot_trembl` | `--uniprot_trembl_link` | | `--uniclust30_path` | `--uniref30_alphafold2_path` | -| `--uniref30` | `--uniref30_colabfold_link` | -| `--uniref30_path` | `--uniref30_colabfold_path` | +| `--uniref30` | `--colabfold_uniref30_link` | +| `--uniref30_path` | `--colabfold_uniref30_path` | | `--num_recycle` | `--num_recycles_colabfold` | | | `--num_recycles_esmfold` | | | `--uniref30_alphafold2_link` | diff --git a/main.nf b/main.nf index ea0618619..932430040 100644 --- a/main.nf +++ b/main.nf @@ -443,10 +443,10 @@ workflow NFCORE_PROTEINFOLD { params.colabfold_server, params.colabfold_alphafold2_params_path, params.colabfold_db_path, - params.uniref30_colabfold_path, + params.colabfold_uniref30_path, params.colabfold_alphafold2_params_link, params.colabfold_db_link, - params.uniref30_colabfold_link, + params.colabfold_uniref30_link, params.create_colabfold_index ) ch_versions = ch_versions.mix(PREPARE_COLABFOLD_DBS.out.versions) From 5e8c0102455d6893ed8968f82e43176168df69df Mon Sep 17 00:00:00 2001 From: Keiran Rowell Date: Fri, 18 Jul 2025 15:22:25 +1000 Subject: [PATCH 062/150] Update nf-test snapshots for PR #312 using local docker profile execution --- tests/alphafold2_download.nf.test.snap | 8 +-- tests/alphafold2_split.nf.test.snap | 69 ++++++++++++++------------ tests/alphafold3.nf.test.snap | 16 +++--- tests/colabfold_download.nf.test.snap | 10 ++-- tests/colabfold_local.nf.test.snap | 8 +-- tests/colabfold_webserver.nf.test.snap | 8 +-- tests/default.nf.test.snap | 66 ++++++++++++++---------- tests/esmfold.nf.test.snap | 8 +-- tests/split_fasta.nf.test.snap | 8 +-- 9 files changed, 108 insertions(+), 93 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index b15bc48e5..c8aa5a2ec 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -4,10 +4,10 @@ 21, { "ARIA2": { - "aria2": null + "aria2": "1.37.0" }, "ARIA2_PDB_SEQRES": { - "aria2": null + "aria2": "1.37.0" }, "COMBINE_UNIPROT": { "awk": null @@ -68,8 +68,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T22:40:17.147742" + "timestamp": "2025-07-18T15:19:40.464849224" } } \ No newline at end of file diff --git a/tests/alphafold2_split.nf.test.snap b/tests/alphafold2_split.nf.test.snap index abf117fa9..20b5e1301 100644 --- a/tests/alphafold2_split.nf.test.snap +++ b/tests/alphafold2_split.nf.test.snap @@ -4,14 +4,14 @@ 7, { "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "RUN_ALPHAFOLD2_MSA": { - "awk": "5.1.0" + "awk": null }, "RUN_ALPHAFOLD2_PRED": { - "python": null + "python": "3.11.10" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -20,34 +20,37 @@ [ "alphafold2", "alphafold2/split_msa_prediction", + "alphafold2/split_msa_prediction/T1024", "alphafold2/split_msa_prediction/T1024.1", - "alphafold2/split_msa_prediction/T1024.1/ranked_0.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_1.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_2.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_3.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_4.pdb", - "alphafold2/split_msa_prediction/T1024_0_pae.tsv", - "alphafold2/split_msa_prediction/T1024_alphafold2.pdb", - "alphafold2/split_msa_prediction/T1024_msa.tsv", - "alphafold2/split_msa_prediction/T1024_plddt.tsv", + "alphafold2/split_msa_prediction/T1024.1/features.pkl", + "alphafold2/split_msa_prediction/T1024/T1024.1", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_0.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_1.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_2.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_3.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_4.pdb", + "alphafold2/split_msa_prediction/T1024/T1024_alphafold2.pdb", + "alphafold2/split_msa_prediction/T1024/T1024_msa.tsv", + "alphafold2/split_msa_prediction/T1024/T1024_plddt.tsv", + "alphafold2/split_msa_prediction/T1024/paes", + "alphafold2/split_msa_prediction/T1024/paes/T1024_0_pae.tsv", + "alphafold2/split_msa_prediction/T1026", "alphafold2/split_msa_prediction/T1026.1", - "alphafold2/split_msa_prediction/T1026.1/ranked_0.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_1.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_2.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_3.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_4.pdb", - "alphafold2/split_msa_prediction/T1026_0_pae.tsv", - "alphafold2/split_msa_prediction/T1026_alphafold2.pdb", - "alphafold2/split_msa_prediction/T1026_msa.tsv", - "alphafold2/split_msa_prediction/T1026_plddt.tsv", + "alphafold2/split_msa_prediction/T1026.1/features.pkl", + "alphafold2/split_msa_prediction/T1026/T1026.1", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_0.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_1.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_2.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_3.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_4.pdb", + "alphafold2/split_msa_prediction/T1026/T1026_alphafold2.pdb", + "alphafold2/split_msa_prediction/T1026/T1026_msa.tsv", + "alphafold2/split_msa_prediction/T1026/T1026_plddt.tsv", + "alphafold2/split_msa_prediction/T1026/paes", + "alphafold2/split_msa_prediction/T1026/paes/T1026_0_pae.tsv", "alphafold2/split_msa_prediction/top_ranked_structures", "alphafold2/split_msa_prediction/top_ranked_structures/T1024.pdb", "alphafold2/split_msa_prediction/top_ranked_structures/T1026.pdb", - "alphafold2_split_msa_prediction", - "alphafold2_split_msa_prediction/T1024.1", - "alphafold2_split_msa_prediction/T1024.1/features.pkl", - "alphafold2_split_msa_prediction/T1026.1", - "alphafold2_split_msa_prediction/T1026.1/features.pkl", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -60,28 +63,28 @@ "pipeline_info/nf_core_proteinfold_software_mqc_versions.yml" ], [ + "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", - "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", "test_alphafold2_report.html:md5,d41d8cd98f00b204e9800998ecf8427e", "test_seq_coverage.png:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -90,8 +93,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T22:36:22.635126" + "timestamp": "2025-07-18T15:19:48.798327705" } } \ No newline at end of file diff --git a/tests/alphafold3.nf.test.snap b/tests/alphafold3.nf.test.snap index acbd1db24..7ee35de24 100644 --- a/tests/alphafold3.nf.test.snap +++ b/tests/alphafold3.nf.test.snap @@ -4,20 +4,20 @@ 11, { "FASTA_TO_ALPHAFOLD3_JSON": { - "python": "3.13.0" + "python": "3.11.10" }, "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "MMCIF2PDB_MODELS": { - "python": "3.12.7" + "python": "3.11.10" }, "MMCIF2PDB_TOP_RANKED": { - "python": "3.12.7" + "python": "3.11.10" }, "RUN_ALPHAFOLD3": { - "python": null + "python": "3.11.10" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -107,8 +107,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T23:02:05.225476" + "timestamp": "2025-07-18T15:19:56.968229605" } } \ No newline at end of file diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index 14bfe7a8e..a41219e2c 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -4,14 +4,14 @@ 7, { "ARIA2": { - "aria2": null + "aria2": "1.37.0" }, "COLABFOLD_BATCH": { "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -71,8 +71,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T23:16:36.210501" + "timestamp": "2025-07-18T15:20:04.92469067" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index 93e1052b4..d211eaf3c 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T23:12:47.221555" + "timestamp": "2025-07-18T15:20:12.854844081" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index 4a5e2548f..6ed924837 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -61,8 +61,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T23:18:10.011715" + "timestamp": "2025-07-18T15:20:20.435083644" } } \ No newline at end of file diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index 4808716a6..f058fa604 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -4,11 +4,11 @@ 5, { "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "RUN_ALPHAFOLD2": { - "python": null + "python": "3.11.10" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -17,26 +17,34 @@ [ "alphafold2", "alphafold2/standard", - "alphafold2/standard/T1024.1", - "alphafold2/standard/T1024.1/ranked_0.pdb", - "alphafold2/standard/T1024.1/ranked_1.pdb", - "alphafold2/standard/T1024.1/ranked_2.pdb", - "alphafold2/standard/T1024.1/ranked_3.pdb", - "alphafold2/standard/T1024.1/ranked_4.pdb", - "alphafold2/standard/T1024_0_pae.tsv", - "alphafold2/standard/T1024_alphafold2.pdb", - "alphafold2/standard/T1024_msa.tsv", - "alphafold2/standard/T1024_plddt.tsv", - "alphafold2/standard/T1026.1", - "alphafold2/standard/T1026.1/ranked_0.pdb", - "alphafold2/standard/T1026.1/ranked_1.pdb", - "alphafold2/standard/T1026.1/ranked_2.pdb", - "alphafold2/standard/T1026.1/ranked_3.pdb", - "alphafold2/standard/T1026.1/ranked_4.pdb", - "alphafold2/standard/T1026_0_pae.tsv", - "alphafold2/standard/T1026_alphafold2.pdb", - "alphafold2/standard/T1026_msa.tsv", - "alphafold2/standard/T1026_plddt.tsv", + "alphafold2/standard/T1024", + "alphafold2/standard/T1024/T1024.1", + "alphafold2/standard/T1024/T1024.1/ranked_0.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_1.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_2.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_3.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_4.pdb", + "alphafold2/standard/T1024/T1024_alphafold2.pdb", + "alphafold2/standard/T1024/T1024_iptm.tsv", + "alphafold2/standard/T1024/T1024_msa.tsv", + "alphafold2/standard/T1024/T1024_plddt.tsv", + "alphafold2/standard/T1024/T1024_ptm.tsv", + "alphafold2/standard/T1024/paes", + "alphafold2/standard/T1024/paes/T1024_0_pae.tsv", + "alphafold2/standard/T1026", + "alphafold2/standard/T1026/T1026.1", + "alphafold2/standard/T1026/T1026.1/ranked_0.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_1.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_2.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_3.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_4.pdb", + "alphafold2/standard/T1026/T1026_alphafold2.pdb", + "alphafold2/standard/T1026/T1026_iptm.tsv", + "alphafold2/standard/T1026/T1026_msa.tsv", + "alphafold2/standard/T1026/T1026_plddt.tsv", + "alphafold2/standard/T1026/T1026_ptm.tsv", + "alphafold2/standard/T1026/paes", + "alphafold2/standard/T1026/paes/T1026_0_pae.tsv", "alphafold2/standard/top_ranked_structures", "alphafold2/standard/top_ranked_structures/T1024.pdb", "alphafold2/standard/top_ranked_structures/T1026.pdb", @@ -57,19 +65,23 @@ "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -80,8 +92,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T21:48:12.396129" + "timestamp": "2025-07-18T15:20:28.528321926" } } \ No newline at end of file diff --git a/tests/esmfold.nf.test.snap b/tests/esmfold.nf.test.snap index 8e36e840a..163c916c2 100644 --- a/tests/esmfold.nf.test.snap +++ b/tests/esmfold.nf.test.snap @@ -4,8 +4,8 @@ 5, { "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "RUN_ESMFOLD": { "esm-fold": "1.0.3" @@ -49,8 +49,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T23:19:34.656166" + "timestamp": "2025-07-18T15:20:36.013702202" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index bd71c415f..2d6169c16 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.7", - "generate_report.py": "Python 3.12.7" + "python": "3.11.10", + "generate_report.py": "Python 3.11.10" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.4" }, - "timestamp": "2025-07-01T23:20:10.322018" + "timestamp": "2025-07-18T15:20:44.308864281" } } \ No newline at end of file From 7a122d8ea08060b5cdb47fb9b94998978e260db8 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 22 Jul 2025 18:37:01 +1000 Subject: [PATCH 063/150] Updated snapshots now nf-test config has been altered --- tests/alphafold2_download.nf.test.snap | 8 ++++---- tests/alphafold2_split.nf.test.snap | 12 ++++++------ tests/alphafold3.nf.test.snap | 16 ++++++++-------- tests/colabfold_download.nf.test.snap | 8 ++++---- tests/colabfold_local.nf.test.snap | 8 ++++---- tests/colabfold_webserver.nf.test.snap | 8 ++++---- tests/default.nf.test.snap | 10 +++++----- tests/esmfold.nf.test.snap | 8 ++++---- tests/split_fasta.nf.test.snap | 8 ++++---- 9 files changed, 43 insertions(+), 43 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index c8aa5a2ec..da304d197 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -10,10 +10,10 @@ "aria2": "1.37.0" }, "COMBINE_UNIPROT": { - "awk": null + "awk": "5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)" }, "DOWNLOAD_PDBMMCIF": { - "awk": null + "awk": "5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -68,8 +68,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:19:40.464849224" + "timestamp": "2025-07-22T18:31:47.575262" } } \ No newline at end of file diff --git a/tests/alphafold2_split.nf.test.snap b/tests/alphafold2_split.nf.test.snap index 20b5e1301..1976ad2e8 100644 --- a/tests/alphafold2_split.nf.test.snap +++ b/tests/alphafold2_split.nf.test.snap @@ -4,14 +4,14 @@ 7, { "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "RUN_ALPHAFOLD2_MSA": { - "awk": null + "awk": "5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)" }, "RUN_ALPHAFOLD2_PRED": { - "python": "3.11.10" + "python": "3.10.16" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -93,8 +93,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:19:48.798327705" + "timestamp": "2025-07-22T18:34:30.445769" } } \ No newline at end of file diff --git a/tests/alphafold3.nf.test.snap b/tests/alphafold3.nf.test.snap index 7ee35de24..e3baa618c 100644 --- a/tests/alphafold3.nf.test.snap +++ b/tests/alphafold3.nf.test.snap @@ -4,20 +4,20 @@ 11, { "FASTA_TO_ALPHAFOLD3_JSON": { - "python": "3.11.10" + "python": "3.10.16" }, "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "MMCIF2PDB_MODELS": { - "python": "3.11.10" + "python": "3.10.16" }, "MMCIF2PDB_TOP_RANKED": { - "python": "3.11.10" + "python": "3.10.16" }, "RUN_ALPHAFOLD3": { - "python": "3.11.10" + "python": "3.10.16" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -107,8 +107,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:19:56.968229605" + "timestamp": "2025-07-22T18:34:43.744043" } } \ No newline at end of file diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index a41219e2c..f3c210c0d 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -10,8 +10,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -71,8 +71,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:20:04.92469067" + "timestamp": "2025-07-22T18:34:55.477351" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index d211eaf3c..8146c8c38 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:20:12.854844081" + "timestamp": "2025-07-22T18:35:07.4495" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index 6ed924837..31e846b79 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -61,8 +61,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:20:20.435083644" + "timestamp": "2025-07-22T18:35:19.268583" } } \ No newline at end of file diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index f058fa604..1878fa35b 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -4,11 +4,11 @@ 5, { "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "RUN_ALPHAFOLD2": { - "python": "3.11.10" + "python": "3.10.16" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -92,8 +92,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:20:28.528321926" + "timestamp": "2025-07-22T18:35:30.474012" } } \ No newline at end of file diff --git a/tests/esmfold.nf.test.snap b/tests/esmfold.nf.test.snap index 163c916c2..0925f852e 100644 --- a/tests/esmfold.nf.test.snap +++ b/tests/esmfold.nf.test.snap @@ -4,8 +4,8 @@ 5, { "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "RUN_ESMFOLD": { "esm-fold": "1.0.3" @@ -49,8 +49,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:20:36.013702202" + "timestamp": "2025-07-22T18:35:41.097649" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index 2d6169c16..e56d734dd 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.11.10", - "generate_report.py": "Python 3.11.10" + "python": "3.10.16", + "generate_report.py": "Python 3.10.16" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.4" + "nextflow": "24.10.6" }, - "timestamp": "2025-07-18T15:20:44.308864281" + "timestamp": "2025-07-22T18:35:52.290907" } } \ No newline at end of file From f2cdc6e4089a5edf0c3ef8d22f8164f8e757adb7 Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 23 Jul 2025 14:14:10 +1000 Subject: [PATCH 064/150] Updated snapshots and .gitignore --- .gitignore | 1 + tests/alphafold2_download.nf.test.snap | 8 ++++---- tests/alphafold2_split.nf.test.snap | 12 ++++++------ tests/alphafold3.nf.test.snap | 16 ++++++++-------- tests/colabfold_download.nf.test.snap | 8 ++++---- tests/colabfold_local.nf.test.snap | 8 ++++---- tests/colabfold_webserver.nf.test.snap | 8 ++++---- tests/default.nf.test.snap | 10 +++++----- tests/esmfold.nf.test.snap | 8 ++++---- tests/split_fasta.nf.test.snap | 8 ++++---- 10 files changed, 44 insertions(+), 43 deletions(-) diff --git a/.gitignore b/.gitignore index a42ce0162..c162b2451 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,4 @@ testing/ testing* *.pyc null/ +.nf* diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index da304d197..77f00fcf1 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -10,10 +10,10 @@ "aria2": "1.37.0" }, "COMBINE_UNIPROT": { - "awk": "5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)" + "awk": null }, "DOWNLOAD_PDBMMCIF": { - "awk": "5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)" + "awk": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -68,8 +68,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:31:47.575262" + "timestamp": "2025-07-23T14:02:47.301023472" } } \ No newline at end of file diff --git a/tests/alphafold2_split.nf.test.snap b/tests/alphafold2_split.nf.test.snap index 1976ad2e8..0c137801c 100644 --- a/tests/alphafold2_split.nf.test.snap +++ b/tests/alphafold2_split.nf.test.snap @@ -4,14 +4,14 @@ 7, { "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "RUN_ALPHAFOLD2_MSA": { - "awk": "5.3.1, API 4.0, PMA Avon 8-g1, (GNU MPFR 4.2.1, GNU MP 6.3.0)" + "awk": null }, "RUN_ALPHAFOLD2_PRED": { - "python": "3.10.16" + "python": "3.12.3" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -93,8 +93,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:34:30.445769" + "timestamp": "2025-07-23T14:02:55.747699491" } } \ No newline at end of file diff --git a/tests/alphafold3.nf.test.snap b/tests/alphafold3.nf.test.snap index e3baa618c..729bdb2c6 100644 --- a/tests/alphafold3.nf.test.snap +++ b/tests/alphafold3.nf.test.snap @@ -4,20 +4,20 @@ 11, { "FASTA_TO_ALPHAFOLD3_JSON": { - "python": "3.10.16" + "python": "3.12.3" }, "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "MMCIF2PDB_MODELS": { - "python": "3.10.16" + "python": "3.12.3" }, "MMCIF2PDB_TOP_RANKED": { - "python": "3.10.16" + "python": "3.12.3" }, "RUN_ALPHAFOLD3": { - "python": "3.10.16" + "python": "3.12.3" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -107,8 +107,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:34:43.744043" + "timestamp": "2025-07-23T14:03:04.18611438" } } \ No newline at end of file diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index f3c210c0d..d73785c65 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -10,8 +10,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -71,8 +71,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:34:55.477351" + "timestamp": "2025-07-23T14:03:12.176590312" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index 8146c8c38..b226be1c1 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:35:07.4495" + "timestamp": "2025-07-23T14:13:18.76882921" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index 31e846b79..eede40939 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -61,8 +61,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:35:19.268583" + "timestamp": "2025-07-23T14:03:28.216927732" } } \ No newline at end of file diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index 1878fa35b..d2b118dd6 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -4,11 +4,11 @@ 5, { "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "RUN_ALPHAFOLD2": { - "python": "3.10.16" + "python": "3.12.3" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -92,8 +92,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:35:30.474012" + "timestamp": "2025-07-23T14:03:36.49723326" } } \ No newline at end of file diff --git a/tests/esmfold.nf.test.snap b/tests/esmfold.nf.test.snap index 0925f852e..cdc5d39d8 100644 --- a/tests/esmfold.nf.test.snap +++ b/tests/esmfold.nf.test.snap @@ -4,8 +4,8 @@ 5, { "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "RUN_ESMFOLD": { "esm-fold": "1.0.3" @@ -49,8 +49,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:35:41.097649" + "timestamp": "2025-07-23T14:03:43.905592194" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index e56d734dd..bc6fb1097 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.10.16", - "generate_report.py": "Python 3.10.16" + "python": "3.12.3", + "generate_report.py": "Python 3.12.3" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.6" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-22T18:35:52.290907" + "timestamp": "2025-07-23T14:03:52.431213304" } } \ No newline at end of file From bd26484dc2b2bdf6abbb9ae89b6f31b73f27cb1e Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 23 Jul 2025 17:00:00 +1000 Subject: [PATCH 065/150] Changed snapshots to the ones from dev --- tests/alphafold2_download.nf.test.snap | 8 +-- tests/alphafold2_split.nf.test.snap | 69 ++++++++++++-------------- tests/alphafold3.nf.test.snap | 16 +++--- tests/colabfold_download.nf.test.snap | 10 ++-- tests/colabfold_local.nf.test.snap | 8 +-- tests/colabfold_webserver.nf.test.snap | 8 +-- tests/default.nf.test.snap | 66 ++++++++++-------------- tests/esmfold.nf.test.snap | 8 +-- tests/split_fasta.nf.test.snap | 8 +-- 9 files changed, 93 insertions(+), 108 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index 77f00fcf1..b15bc48e5 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -4,10 +4,10 @@ 21, { "ARIA2": { - "aria2": "1.37.0" + "aria2": null }, "ARIA2_PDB_SEQRES": { - "aria2": "1.37.0" + "aria2": null }, "COMBINE_UNIPROT": { "awk": null @@ -68,8 +68,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:02:47.301023472" + "timestamp": "2025-07-01T22:40:17.147742" } } \ No newline at end of file diff --git a/tests/alphafold2_split.nf.test.snap b/tests/alphafold2_split.nf.test.snap index 0c137801c..abf117fa9 100644 --- a/tests/alphafold2_split.nf.test.snap +++ b/tests/alphafold2_split.nf.test.snap @@ -4,14 +4,14 @@ 7, { "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "RUN_ALPHAFOLD2_MSA": { - "awk": null + "awk": "5.1.0" }, "RUN_ALPHAFOLD2_PRED": { - "python": "3.12.3" + "python": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -20,37 +20,34 @@ [ "alphafold2", "alphafold2/split_msa_prediction", - "alphafold2/split_msa_prediction/T1024", "alphafold2/split_msa_prediction/T1024.1", - "alphafold2/split_msa_prediction/T1024.1/features.pkl", - "alphafold2/split_msa_prediction/T1024/T1024.1", - "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_0.pdb", - "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_1.pdb", - "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_2.pdb", - "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_3.pdb", - "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_4.pdb", - "alphafold2/split_msa_prediction/T1024/T1024_alphafold2.pdb", - "alphafold2/split_msa_prediction/T1024/T1024_msa.tsv", - "alphafold2/split_msa_prediction/T1024/T1024_plddt.tsv", - "alphafold2/split_msa_prediction/T1024/paes", - "alphafold2/split_msa_prediction/T1024/paes/T1024_0_pae.tsv", - "alphafold2/split_msa_prediction/T1026", + "alphafold2/split_msa_prediction/T1024.1/ranked_0.pdb", + "alphafold2/split_msa_prediction/T1024.1/ranked_1.pdb", + "alphafold2/split_msa_prediction/T1024.1/ranked_2.pdb", + "alphafold2/split_msa_prediction/T1024.1/ranked_3.pdb", + "alphafold2/split_msa_prediction/T1024.1/ranked_4.pdb", + "alphafold2/split_msa_prediction/T1024_0_pae.tsv", + "alphafold2/split_msa_prediction/T1024_alphafold2.pdb", + "alphafold2/split_msa_prediction/T1024_msa.tsv", + "alphafold2/split_msa_prediction/T1024_plddt.tsv", "alphafold2/split_msa_prediction/T1026.1", - "alphafold2/split_msa_prediction/T1026.1/features.pkl", - "alphafold2/split_msa_prediction/T1026/T1026.1", - "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_0.pdb", - "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_1.pdb", - "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_2.pdb", - "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_3.pdb", - "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_4.pdb", - "alphafold2/split_msa_prediction/T1026/T1026_alphafold2.pdb", - "alphafold2/split_msa_prediction/T1026/T1026_msa.tsv", - "alphafold2/split_msa_prediction/T1026/T1026_plddt.tsv", - "alphafold2/split_msa_prediction/T1026/paes", - "alphafold2/split_msa_prediction/T1026/paes/T1026_0_pae.tsv", + "alphafold2/split_msa_prediction/T1026.1/ranked_0.pdb", + "alphafold2/split_msa_prediction/T1026.1/ranked_1.pdb", + "alphafold2/split_msa_prediction/T1026.1/ranked_2.pdb", + "alphafold2/split_msa_prediction/T1026.1/ranked_3.pdb", + "alphafold2/split_msa_prediction/T1026.1/ranked_4.pdb", + "alphafold2/split_msa_prediction/T1026_0_pae.tsv", + "alphafold2/split_msa_prediction/T1026_alphafold2.pdb", + "alphafold2/split_msa_prediction/T1026_msa.tsv", + "alphafold2/split_msa_prediction/T1026_plddt.tsv", "alphafold2/split_msa_prediction/top_ranked_structures", "alphafold2/split_msa_prediction/top_ranked_structures/T1024.pdb", "alphafold2/split_msa_prediction/top_ranked_structures/T1026.pdb", + "alphafold2_split_msa_prediction", + "alphafold2_split_msa_prediction/T1024.1", + "alphafold2_split_msa_prediction/T1024.1/features.pkl", + "alphafold2_split_msa_prediction/T1026.1", + "alphafold2_split_msa_prediction/T1026.1/features.pkl", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -63,28 +60,28 @@ "pipeline_info/nf_core_proteinfold_software_mqc_versions.yml" ], [ - "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", + "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", "test_alphafold2_report.html:md5,d41d8cd98f00b204e9800998ecf8427e", "test_seq_coverage.png:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -93,8 +90,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:02:55.747699491" + "timestamp": "2025-07-01T22:36:22.635126" } } \ No newline at end of file diff --git a/tests/alphafold3.nf.test.snap b/tests/alphafold3.nf.test.snap index 729bdb2c6..acbd1db24 100644 --- a/tests/alphafold3.nf.test.snap +++ b/tests/alphafold3.nf.test.snap @@ -4,20 +4,20 @@ 11, { "FASTA_TO_ALPHAFOLD3_JSON": { - "python": "3.12.3" + "python": "3.13.0" }, "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "MMCIF2PDB_MODELS": { - "python": "3.12.3" + "python": "3.12.7" }, "MMCIF2PDB_TOP_RANKED": { - "python": "3.12.3" + "python": "3.12.7" }, "RUN_ALPHAFOLD3": { - "python": "3.12.3" + "python": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -107,8 +107,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:03:04.18611438" + "timestamp": "2025-07-01T23:02:05.225476" } } \ No newline at end of file diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index d73785c65..14bfe7a8e 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -4,14 +4,14 @@ 7, { "ARIA2": { - "aria2": "1.37.0" + "aria2": null }, "COLABFOLD_BATCH": { "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -71,8 +71,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:03:12.176590312" + "timestamp": "2025-07-01T23:16:36.210501" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index b226be1c1..93e1052b4 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:13:18.76882921" + "timestamp": "2025-07-01T23:12:47.221555" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index eede40939..4a5e2548f 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -61,8 +61,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:03:28.216927732" + "timestamp": "2025-07-01T23:18:10.011715" } } \ No newline at end of file diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index d2b118dd6..4808716a6 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -4,11 +4,11 @@ 5, { "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "RUN_ALPHAFOLD2": { - "python": "3.12.3" + "python": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -17,34 +17,26 @@ [ "alphafold2", "alphafold2/standard", - "alphafold2/standard/T1024", - "alphafold2/standard/T1024/T1024.1", - "alphafold2/standard/T1024/T1024.1/ranked_0.pdb", - "alphafold2/standard/T1024/T1024.1/ranked_1.pdb", - "alphafold2/standard/T1024/T1024.1/ranked_2.pdb", - "alphafold2/standard/T1024/T1024.1/ranked_3.pdb", - "alphafold2/standard/T1024/T1024.1/ranked_4.pdb", - "alphafold2/standard/T1024/T1024_alphafold2.pdb", - "alphafold2/standard/T1024/T1024_iptm.tsv", - "alphafold2/standard/T1024/T1024_msa.tsv", - "alphafold2/standard/T1024/T1024_plddt.tsv", - "alphafold2/standard/T1024/T1024_ptm.tsv", - "alphafold2/standard/T1024/paes", - "alphafold2/standard/T1024/paes/T1024_0_pae.tsv", - "alphafold2/standard/T1026", - "alphafold2/standard/T1026/T1026.1", - "alphafold2/standard/T1026/T1026.1/ranked_0.pdb", - "alphafold2/standard/T1026/T1026.1/ranked_1.pdb", - "alphafold2/standard/T1026/T1026.1/ranked_2.pdb", - "alphafold2/standard/T1026/T1026.1/ranked_3.pdb", - "alphafold2/standard/T1026/T1026.1/ranked_4.pdb", - "alphafold2/standard/T1026/T1026_alphafold2.pdb", - "alphafold2/standard/T1026/T1026_iptm.tsv", - "alphafold2/standard/T1026/T1026_msa.tsv", - "alphafold2/standard/T1026/T1026_plddt.tsv", - "alphafold2/standard/T1026/T1026_ptm.tsv", - "alphafold2/standard/T1026/paes", - "alphafold2/standard/T1026/paes/T1026_0_pae.tsv", + "alphafold2/standard/T1024.1", + "alphafold2/standard/T1024.1/ranked_0.pdb", + "alphafold2/standard/T1024.1/ranked_1.pdb", + "alphafold2/standard/T1024.1/ranked_2.pdb", + "alphafold2/standard/T1024.1/ranked_3.pdb", + "alphafold2/standard/T1024.1/ranked_4.pdb", + "alphafold2/standard/T1024_0_pae.tsv", + "alphafold2/standard/T1024_alphafold2.pdb", + "alphafold2/standard/T1024_msa.tsv", + "alphafold2/standard/T1024_plddt.tsv", + "alphafold2/standard/T1026.1", + "alphafold2/standard/T1026.1/ranked_0.pdb", + "alphafold2/standard/T1026.1/ranked_1.pdb", + "alphafold2/standard/T1026.1/ranked_2.pdb", + "alphafold2/standard/T1026.1/ranked_3.pdb", + "alphafold2/standard/T1026.1/ranked_4.pdb", + "alphafold2/standard/T1026_0_pae.tsv", + "alphafold2/standard/T1026_alphafold2.pdb", + "alphafold2/standard/T1026_msa.tsv", + "alphafold2/standard/T1026_plddt.tsv", "alphafold2/standard/top_ranked_structures", "alphafold2/standard/top_ranked_structures/T1024.pdb", "alphafold2/standard/top_ranked_structures/T1026.pdb", @@ -65,23 +57,19 @@ "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -92,8 +80,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:03:36.49723326" + "timestamp": "2025-07-01T21:48:12.396129" } } \ No newline at end of file diff --git a/tests/esmfold.nf.test.snap b/tests/esmfold.nf.test.snap index cdc5d39d8..8e36e840a 100644 --- a/tests/esmfold.nf.test.snap +++ b/tests/esmfold.nf.test.snap @@ -4,8 +4,8 @@ 5, { "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "RUN_ESMFOLD": { "esm-fold": "1.0.3" @@ -49,8 +49,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:03:43.905592194" + "timestamp": "2025-07-01T23:19:34.656166" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index bc6fb1097..bd71c415f 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -7,8 +7,8 @@ "colabfold_batch": "1.5.2" }, "GENERATE_REPORT": { - "python": "3.12.3", - "generate_report.py": "Python 3.12.3" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "MMSEQS_COLABFOLDSEARCH": { "colabfold_search": "1.5.2" @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-07-23T14:03:52.431213304" + "timestamp": "2025-07-01T23:20:10.322018" } } \ No newline at end of file From 7d47a324777f94f4e169643f7d9d8509e38a29a9 Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 24 Jul 2025 17:05:40 +1000 Subject: [PATCH 066/150] Updated snapshots manually --- tests/alphafold2_download.nf.test.snap | 2 +- tests/alphafold2_split.nf.test.snap | 59 ++++++++++++++------------ tests/alphafold3.nf.test.snap | 2 +- tests/colabfold_download.nf.test.snap | 2 +- tests/colabfold_local.nf.test.snap | 2 +- tests/colabfold_webserver.nf.test.snap | 2 +- tests/default.nf.test.snap | 58 +++++++++++++++---------- tests/esmfold.nf.test.snap | 2 +- tests/split_fasta.nf.test.snap | 2 +- 9 files changed, 73 insertions(+), 58 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index b15bc48e5..6cebbda24 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -70,6 +70,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T22:40:17.147742" + "timestamp": "2025-07-24T16:54:22.238418565" } } \ No newline at end of file diff --git a/tests/alphafold2_split.nf.test.snap b/tests/alphafold2_split.nf.test.snap index abf117fa9..dee05380e 100644 --- a/tests/alphafold2_split.nf.test.snap +++ b/tests/alphafold2_split.nf.test.snap @@ -20,34 +20,37 @@ [ "alphafold2", "alphafold2/split_msa_prediction", + "alphafold2/split_msa_prediction/T1024", "alphafold2/split_msa_prediction/T1024.1", - "alphafold2/split_msa_prediction/T1024.1/ranked_0.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_1.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_2.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_3.pdb", - "alphafold2/split_msa_prediction/T1024.1/ranked_4.pdb", - "alphafold2/split_msa_prediction/T1024_0_pae.tsv", - "alphafold2/split_msa_prediction/T1024_alphafold2.pdb", - "alphafold2/split_msa_prediction/T1024_msa.tsv", - "alphafold2/split_msa_prediction/T1024_plddt.tsv", + "alphafold2/split_msa_prediction/T1024.1/features.pkl", + "alphafold2/split_msa_prediction/T1024/T1024.1", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_0.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_1.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_2.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_3.pdb", + "alphafold2/split_msa_prediction/T1024/T1024.1/ranked_4.pdb", + "alphafold2/split_msa_prediction/T1024/T1024_alphafold2.pdb", + "alphafold2/split_msa_prediction/T1024/T1024_msa.tsv", + "alphafold2/split_msa_prediction/T1024/T1024_plddt.tsv", + "alphafold2/split_msa_prediction/T1024/paes", + "alphafold2/split_msa_prediction/T1024/paes/T1024_0_pae.tsv", + "alphafold2/split_msa_prediction/T1026", "alphafold2/split_msa_prediction/T1026.1", - "alphafold2/split_msa_prediction/T1026.1/ranked_0.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_1.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_2.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_3.pdb", - "alphafold2/split_msa_prediction/T1026.1/ranked_4.pdb", - "alphafold2/split_msa_prediction/T1026_0_pae.tsv", - "alphafold2/split_msa_prediction/T1026_alphafold2.pdb", - "alphafold2/split_msa_prediction/T1026_msa.tsv", - "alphafold2/split_msa_prediction/T1026_plddt.tsv", + "alphafold2/split_msa_prediction/T1026.1/features.pkl", + "alphafold2/split_msa_prediction/T1026/T1026.1", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_0.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_1.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_2.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_3.pdb", + "alphafold2/split_msa_prediction/T1026/T1026.1/ranked_4.pdb", + "alphafold2/split_msa_prediction/T1026/T1026_alphafold2.pdb", + "alphafold2/split_msa_prediction/T1026/T1026_msa.tsv", + "alphafold2/split_msa_prediction/T1026/T1026_plddt.tsv", + "alphafold2/split_msa_prediction/T1026/paes", + "alphafold2/split_msa_prediction/T1026/paes/T1026_0_pae.tsv", "alphafold2/split_msa_prediction/top_ranked_structures", "alphafold2/split_msa_prediction/top_ranked_structures/T1024.pdb", "alphafold2/split_msa_prediction/top_ranked_structures/T1026.pdb", - "alphafold2_split_msa_prediction", - "alphafold2_split_msa_prediction/T1024.1", - "alphafold2_split_msa_prediction/T1024.1/features.pkl", - "alphafold2_split_msa_prediction/T1026.1", - "alphafold2_split_msa_prediction/T1026.1/features.pkl", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -60,28 +63,28 @@ "pipeline_info/nf_core_proteinfold_software_mqc_versions.yml" ], [ + "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", - "features.pkl:md5,d41d8cd98f00b204e9800998ecf8427e", "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", "test_alphafold2_report.html:md5,d41d8cd98f00b204e9800998ecf8427e", "test_seq_coverage.png:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -92,6 +95,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T22:36:22.635126" + "timestamp": "2025-07-24T16:54:30.453984448" } } \ No newline at end of file diff --git a/tests/alphafold3.nf.test.snap b/tests/alphafold3.nf.test.snap index acbd1db24..7a6fcc263 100644 --- a/tests/alphafold3.nf.test.snap +++ b/tests/alphafold3.nf.test.snap @@ -109,6 +109,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T23:02:05.225476" + "timestamp": "2025-07-24T16:54:38.626994903" } } \ No newline at end of file diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index 14bfe7a8e..2d2f303ce 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -73,6 +73,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T23:16:36.210501" + "timestamp": "2025-07-24T16:54:46.721482885" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index 93e1052b4..244e729a9 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -66,6 +66,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T23:12:47.221555" + "timestamp": "2025-07-24T16:54:54.686425178" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index 4a5e2548f..e80a04359 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -63,6 +63,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T23:18:10.011715" + "timestamp": "2025-07-24T16:55:02.279523773" } } \ No newline at end of file diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index 4808716a6..7dfd6b659 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -17,26 +17,34 @@ [ "alphafold2", "alphafold2/standard", - "alphafold2/standard/T1024.1", - "alphafold2/standard/T1024.1/ranked_0.pdb", - "alphafold2/standard/T1024.1/ranked_1.pdb", - "alphafold2/standard/T1024.1/ranked_2.pdb", - "alphafold2/standard/T1024.1/ranked_3.pdb", - "alphafold2/standard/T1024.1/ranked_4.pdb", - "alphafold2/standard/T1024_0_pae.tsv", - "alphafold2/standard/T1024_alphafold2.pdb", - "alphafold2/standard/T1024_msa.tsv", - "alphafold2/standard/T1024_plddt.tsv", - "alphafold2/standard/T1026.1", - "alphafold2/standard/T1026.1/ranked_0.pdb", - "alphafold2/standard/T1026.1/ranked_1.pdb", - "alphafold2/standard/T1026.1/ranked_2.pdb", - "alphafold2/standard/T1026.1/ranked_3.pdb", - "alphafold2/standard/T1026.1/ranked_4.pdb", - "alphafold2/standard/T1026_0_pae.tsv", - "alphafold2/standard/T1026_alphafold2.pdb", - "alphafold2/standard/T1026_msa.tsv", - "alphafold2/standard/T1026_plddt.tsv", + "alphafold2/standard/T1024", + "alphafold2/standard/T1024/T1024.1", + "alphafold2/standard/T1024/T1024.1/ranked_0.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_1.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_2.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_3.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_4.pdb", + "alphafold2/standard/T1024/T1024_alphafold2.pdb", + "alphafold2/standard/T1024/T1024_iptm.tsv", + "alphafold2/standard/T1024/T1024_msa.tsv", + "alphafold2/standard/T1024/T1024_plddt.tsv", + "alphafold2/standard/T1024/T1024_ptm.tsv", + "alphafold2/standard/T1024/paes", + "alphafold2/standard/T1024/paes/T1024_0_pae.tsv", + "alphafold2/standard/T1026", + "alphafold2/standard/T1026/T1026.1", + "alphafold2/standard/T1026/T1026.1/ranked_0.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_1.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_2.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_3.pdb", + "alphafold2/standard/T1026/T1026.1/ranked_4.pdb", + "alphafold2/standard/T1026/T1026_alphafold2.pdb", + "alphafold2/standard/T1026/T1026_iptm.tsv", + "alphafold2/standard/T1026/T1026_msa.tsv", + "alphafold2/standard/T1026/T1026_plddt.tsv", + "alphafold2/standard/T1026/T1026_ptm.tsv", + "alphafold2/standard/T1026/paes", + "alphafold2/standard/T1026/paes/T1026_0_pae.tsv", "alphafold2/standard/top_ranked_structures", "alphafold2/standard/top_ranked_structures/T1024.pdb", "alphafold2/standard/top_ranked_structures/T1026.pdb", @@ -57,19 +65,23 @@ "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", - "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1026_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "T1026.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", @@ -82,6 +94,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T21:48:12.396129" + "timestamp": "2025-07-24T16:55:10.198238805" } } \ No newline at end of file diff --git a/tests/esmfold.nf.test.snap b/tests/esmfold.nf.test.snap index 8e36e840a..8a17769bd 100644 --- a/tests/esmfold.nf.test.snap +++ b/tests/esmfold.nf.test.snap @@ -51,6 +51,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T23:19:34.656166" + "timestamp": "2025-07-24T16:55:17.861762289" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index bd71c415f..036a189aa 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -66,6 +66,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-07-01T23:20:10.322018" + "timestamp": "2025-07-24T16:55:26.47855323" } } \ No newline at end of file From 72642e4b82fff0f02b76d459b3fa8c09d3e2b697 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 28 Jul 2025 11:33:25 +1000 Subject: [PATCH 067/150] Tabs to spaces --- conf/modules_alphafold2.config | 32 +++++++++---------- conf/modules_boltz.config | 20 ++++++------ conf/modules_helixfold3.config | 20 ++++++------ .../Dockerfile_nfcore-proteinfold_esmfold | 10 +++--- 4 files changed, 41 insertions(+), 41 deletions(-) diff --git a/conf/modules_alphafold2.config b/conf/modules_alphafold2.config index 78e09e631..cf2060497 100644 --- a/conf/modules_alphafold2.config +++ b/conf/modules_alphafold2.config @@ -41,15 +41,15 @@ process { ].join(' ').trim() publishDir = [ [ - path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}/${meta.id}" }, + path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}/${meta.id}" }, mode: 'copy', - saveAs: { filename -> - if(filename.endsWith('_pae.tsv')){ - "paes/$filename" - } else if(filename.equals('versions.yml')){ - null - } else { filename } - }, + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, pattern: '*.*' ], [ @@ -77,15 +77,15 @@ process { ext.args = params.use_gpu ? '--use_gpu_relax=true' : '--use_gpu_relax=false' publishDir = [ [ - path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}/${meta.id}" }, + path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}/${meta.id}" }, mode: 'copy', - saveAs: { filename -> - if(filename.endsWith('_pae.tsv')){ - "paes/$filename" - } else if(filename.equals('versions.yml')){ - null - } else { filename } - }, + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, pattern: '*.*' ], [ diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index 9bc57865f..e31459c68 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -15,16 +15,16 @@ process { ext.args = '--write_full_pae --output_format pdb --use_msa_server' publishDir = [ [ - path: { "${params.outdir}/boltz/${meta.id}" }, - mode: 'copy', - saveAs: { filename -> - if(filename.endsWith('_pae.tsv')){ - "paes/$filename" - } else if(filename.equals('versions.yml')){ - null - } else { filename } - }, - pattern: '*.*' + path: { "${params.outdir}/boltz/${meta.id}" }, + mode: 'copy', + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, + pattern: '*.*' ], [ path: { "${params.outdir}/boltz/${meta.id}/top_ranked_structures" }, diff --git a/conf/modules_helixfold3.config b/conf/modules_helixfold3.config index 66a1fdcd1..903955044 100644 --- a/conf/modules_helixfold3.config +++ b/conf/modules_helixfold3.config @@ -34,16 +34,16 @@ process { ].join(' ').trim() publishDir = [ - path: { "${params.outdir}/helixfold3/${meta.id}" }, - mode: 'copy', - saveAs: { filename -> - if(filename.endsWith('_pae.tsv')){ - "paes/$filename" - } else if(filename.equals('versions.yml')){ - null - } else { filename } - }, - pattern: '*.*' + path: { "${params.outdir}/helixfold3/${meta.id}" }, + mode: 'copy', + saveAs: { filename -> + if(filename.endsWith('_pae.tsv')){ + "paes/$filename" + } else if(filename.equals('versions.yml')){ + null + } else { filename } + }, + pattern: '*.*' ] } diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_esmfold b/dockerfiles/Dockerfile_nfcore-proteinfold_esmfold index b775faeaa..80b2261d5 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_esmfold +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_esmfold @@ -30,13 +30,13 @@ RUN wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/latest/do RUN /conda/bin/conda install --quiet -y conda==24.11.1 pip python=3.9 \ && conda clean --all --force-pkgs-dirs --yes -RUN cd / && /conda/bin/conda update -qy conda \ +RUN cd / && /conda/bin/conda update -qy conda \ && /conda/bin/conda install -y -c conda-forge pip python -RUN /conda/bin/pip install --no-cache-dir git+https://github.com/facebookresearch/esm.git -RUN /conda/bin/pip install --no-cache-dir "fair-esm[esmfold]" +RUN /conda/bin/pip install --no-cache-dir git+https://github.com/facebookresearch/esm.git +RUN /conda/bin/pip install --no-cache-dir "fair-esm[esmfold]" RUN /conda/bin/pip install --no-cache-dir torch==2.0.0 torchvision==0.15.0 --upgrade --force-reinstall --index-url https://download.pytorch.org/whl/cu118 -RUN /conda/bin/pip install --no-cache-dir \ +RUN /conda/bin/pip install --no-cache-dir \ pytorch_lightning==1.9.5 \ biopython==1.85 \ ## https://github.com/facebookresearch/esm/issues/621#issuecomment-1741684707 @@ -51,7 +51,7 @@ RUN /conda/bin/pip install --no-cache-dir \ typing-extensions==4.12.2 \ wandb==0.12.21 -RUN /conda/bin/pip install --no-cache-dir 'dllogger @ git+https://github.com/NVIDIA/dllogger.git' +RUN /conda/bin/pip install --no-cache-dir 'dllogger @ git+https://github.com/NVIDIA/dllogger.git' ## https://github.com/aqlaboratory/insilico_design_pipeline/blob/main/README.md#additional-notes RUN git clone https://github.com/aqlaboratory/openfold.git && \ From 4304fcbaad40e49b881d8fed1a9c1817e8888c15 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 28 Jul 2025 22:57:02 +0200 Subject: [PATCH 068/150] Update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b420ee5b..b0793e2b1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -48,6 +48,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #332](https://github.com/nf-core/proteinfold/pull/332)] - Fix rare superposition bug in reports. - [[PR #333](https://github.com/nf-core/proteinfold/pull/333)] - Updates the RFAA dockerfile for better versioning and smaller image size. - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). +- [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). ### Parameters From 96c0600dbb8d7ef0bde5180ba6385b5ca7e77761 Mon Sep 17 00:00:00 2001 From: Keiran Rowell <54380465+keiran-rowell-unsw@users.noreply.github.com> Date: Tue, 29 Jul 2025 08:55:48 +1000 Subject: [PATCH 069/150] Update modules/local/run_alphafold2/main.nf Co-authored-by: Jose Espinosa-Carrasco --- modules/local/run_alphafold2/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/run_alphafold2/main.nf b/modules/local/run_alphafold2/main.nf index 58100bc41..4c453d088 100644 --- a/modules/local/run_alphafold2/main.nf +++ b/modules/local/run_alphafold2/main.nf @@ -35,7 +35,7 @@ process RUN_ALPHAFOLD2 { tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: paes tuple val(meta), path ("${meta.id}_ptm.tsv") , optional: true, emit: ptms tuple val(meta), path ("${meta.id}_iptm.tsv") , optional: true, emit: iptms - path "versions.yml", emit: versions + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when From 30e20327e1320c8b4d48cc0d8f062ff7ad89b8ab Mon Sep 17 00:00:00 2001 From: jscgh <75345304+jscgh@users.noreply.github.com> Date: Tue, 29 Jul 2025 10:57:06 +1000 Subject: [PATCH 070/150] Apply suggestions from code review Adds consistency to boltz variable names Co-authored-by: Jose Espinosa-Carrasco --- conf/dbs.config | 4 ++-- main.nf | 6 +++--- nextflow.config | 4 ++-- nextflow_schema.json | 4 ++-- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 039573cd4..46f2c91b7 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -62,14 +62,14 @@ params { boltz_model_link = 'https://huggingface.co/boltz-community/boltz-1/resolve/main/boltz1_conf.ckpt' boltz2_aff_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt' boltz2_conf_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt' - mols_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar' + boltz2_mols_link = 'https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar' // Boltz paths boltz_ccd_path = "${params.boltz_db}/params/ccd.pkl" boltz_model_path = "${params.boltz_db}/params/boltz1_conf.ckpt" boltz2_aff_path = "${params.boltz_db}/params/boltz2_aff.ckpt" boltz2_conf_path = "${params.boltz_db}/params/boltz2_conf.ckpt" - mols_path = "${params.boltz_db}/params/mols/" + boltz2_mols_path = "${params.boltz_db}/params/mols/" // Colabfold links colabfold_db_link = 'http://wwwuser.gwdg.de/~compbiol/colabfold/colabfold_envdb_202108.tar.gz' diff --git a/main.nf b/main.nf index efe8baaab..996a94e48 100644 --- a/main.nf +++ b/main.nf @@ -435,12 +435,12 @@ workflow NFCORE_PROTEINFOLD { params.boltz_model_path, params.boltz2_aff_path, params.boltz2_conf_path, - params.mols_path, + params.boltz2_mols_path, params.boltz_ccd_link, params.boltz_model_link, params.boltz2_aff_link, params.boltz2_conf_link, - params.mols_link + params.boltz2_mols_link ) ch_versions = ch_versions.mix(PREPARE_BOLTZ_DBS.out.versions) @@ -464,7 +464,7 @@ workflow NFCORE_PROTEINFOLD { PREPARE_BOLTZ_DBS.out.boltz_model, PREPARE_BOLTZ_DBS.out.boltz2_aff, PREPARE_BOLTZ_DBS.out.boltz2_conf, - PREPARE_BOLTZ_DBS.out.mols, + PREPARE_BOLTZ_DBS.out.boltz2_mols, PREPARE_COLABFOLD_DBS.out.colabfold_db, PREPARE_COLABFOLD_DBS.out.uniref30, params.boltz_use_msa_server diff --git a/nextflow.config b/nextflow.config index 42dd5ee70..5356799bd 100644 --- a/nextflow.config +++ b/nextflow.config @@ -86,7 +86,7 @@ params { boltz_model_link = null boltz2_aff_link = null boltz2_conf_link = null - mols_link = null + boltz2_mols_link = null // Boltz paths boltz_db = null @@ -94,7 +94,7 @@ params { boltz_model_path = null boltz2_aff_path = null boltz2_conf_path = null - mols_path = null + boltz2_mols_path = null // Colabfold parameters colabfold_server = "webserver" diff --git a/nextflow_schema.json b/nextflow_schema.json index 352864076..512969ef0 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -785,7 +785,7 @@ "type": "string", "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt" }, - "mols_link": { + "boltz2_mols_link": { "type": "string", "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar" } @@ -822,7 +822,7 @@ "type": "string", "default": "null/params/boltz2_conf.ckpt" }, - "mols_path": { + "boltz2_mols_path": { "type": "string", "default": "null/params/mols/" } From 4887c7fde9ee7949b73d767ba960f4805b5ddc6e Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 29 Jul 2025 16:04:52 +1000 Subject: [PATCH 071/150] Updated changelog with parameters --- CHANGELOG.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4ebad47fc..fd7765ed1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -80,6 +80,24 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 | | `--alphafold3_uniref90_path` | | | `--alphafold3_pdb_seqres_path` | | | `--alphafold3_uniprot_path` | +| | `--boltz_model` | +| | `--boltz_out_dir` | +| | `--boltz_output_format` | +| | `--boltz_use_msa_server` | +| | `--boltz_msa_server_url` | +| | `--boltz_use_potentials` | +| | `--boltz_write_full_pae` | +| | `--boltz2_aff_path` | +| | `--boltz2_conf_path` | +| | `--boltz2_mols_path` | +| | `--boltz_model_path` | +| | `--boltz_ccd_path` | +| | `--boltz_db` | +| | `--boltz2_aff_link` | +| | `--boltz2_conf_link` | +| | `--boltz2_mols_link` | +| | `--boltz_model_link` | +| | `--boltz_ccd_link` | > **NB:** Parameter has been **updated** if both old and new parameter information is present. > **NB:** Parameter has been **added** if just the new parameter information is present. From eb043741e00a0b6cbd9452c1968d3c06742a1005 Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 29 Jul 2025 16:12:09 +1000 Subject: [PATCH 072/150] Updated prepare_boltz_dbs --- subworkflows/local/prepare_boltz_dbs.nf | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/subworkflows/local/prepare_boltz_dbs.nf b/subworkflows/local/prepare_boltz_dbs.nf index 20ee2c813..e571c8ae4 100644 --- a/subworkflows/local/prepare_boltz_dbs.nf +++ b/subworkflows/local/prepare_boltz_dbs.nf @@ -12,26 +12,27 @@ include { workflow PREPARE_BOLTZ_DBS { take: + boltz_db boltz_ccd boltz_model boltz2_aff boltz2_conf - mols + boltz2_mols boltz_ccd_link boltz_model_link boltz2_aff_link boltz2_conf_link - mols_link + boltz2_mols_link main: ch_versions = Channel.empty() - if (boltz_ccd && boltz_model && boltz2_aff && boltz2_conf && mols) { + if (boltz_db) { ch_boltz_ccd = Channel.value(file(boltz_ccd)) ch_boltz_model = Channel.value(file(boltz_model)) ch_boltz2_aff = Channel.value(file(boltz2_aff)) ch_boltz2_conf = Channel.value(file(boltz2_conf)) - ch_mols = Channel.value(file(mols)) + ch_boltz2_mols = Channel.value(file(boltz2_mols)) } else { ARIA2_BOLTZ_CCD( [ @@ -72,10 +73,10 @@ workflow PREPARE_BOLTZ_DBS { ARIA2_MOLS( [ [:], - mols_link + boltz2_mols_link ] ) - ch_mols = ARIA2_MOLS.out.downloaded_file.map{ it[1] } + ch_boltz2_mols = ARIA2_MOLS.out.downloaded_file.map{ it[1] } ch_versions = ch_versions.mix(ARIA2_MOLS.out.versions) } @@ -84,6 +85,6 @@ workflow PREPARE_BOLTZ_DBS { boltz_model = ch_boltz_model boltz2_aff = ch_boltz2_aff boltz2_conf = ch_boltz2_conf - mols = ch_mols + boltz2_mols = ch_boltz2_mols versions = ch_versions } From 8912385657f49728168e0bb312aaceeb43a66f07 Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 29 Jul 2025 16:44:46 +1000 Subject: [PATCH 073/150] Added boltz_db to prepare_boltz_dbs --- main.nf | 1 + 1 file changed, 1 insertion(+) diff --git a/main.nf b/main.nf index 996a94e48..04e7dffc7 100644 --- a/main.nf +++ b/main.nf @@ -431,6 +431,7 @@ workflow NFCORE_PROTEINFOLD { // if (params.mode.toLowerCase().split(",").contains("boltz")) { PREPARE_BOLTZ_DBS( + params.boltz_db, params.boltz_ccd_path, params.boltz_model_path, params.boltz2_aff_path, From 5687897e2ef1121831ac90e49ddfa3fa576c616d Mon Sep 17 00:00:00 2001 From: Jose Espinosa-Carrasco Date: Tue, 29 Jul 2025 09:59:11 +0000 Subject: [PATCH 074/150] Fix ro-crate --- ro-crate-metadata.json | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/ro-crate-metadata.json b/ro-crate-metadata.json index 11ed5830e..92fbf5df1 100644 --- a/ro-crate-metadata.json +++ b/ro-crate-metadata.json @@ -23,7 +23,7 @@ "@type": "Dataset", "creativeWorkStatus": "InProgress", "datePublished": "2025-07-08T11:39:36+00:00", - "description": "

\n \n \n \"nf-core/proteinfold\"\n \n

\n\n[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX)\n[![nf-test](https://img.shields.io/badge/unit_tests-nf--test-337ab7.svg)](https://www.nf-test.com)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.10.5-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.2-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.2)\n[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/proteinfold)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23proteinfold-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/proteinfold)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/proteinfold** is a bioinformatics pipeline that ...\n\n\n\n\n2. Present QC for raw reads ([`MultiQC`](http://multiqc.info/))\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) with `-profile test` before running the workflow on actual data.\n\n\n\nNow, you can run the pipeline using:\n\n\n\n```bash\nnextflow run nf-core/proteinfold \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \n```\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) and the [parameter documentation](https://nf-co.re/proteinfold/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/proteinfold/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/proteinfold/output).\n\n## Credits\n\nnf-core/proteinfold was originally written by Athanasios Baltzis, Jose Espinosa-Carrasco, Harshil Patel.\n\nWe thank the following people for their extensive assistance in the development of this pipeline:\n\n\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#proteinfold` channel](https://nfcore.slack.com/channels/proteinfold) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\n\n\n\n\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", + "description": "

\n \n \n \"nf-core/proteinfold\"\n \n

\n\n[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.13135393-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.13135393)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.10.5-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.2-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.2)\n[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/proteinfold)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23proteinfold-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/proteinfold)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/proteinfold** is a bioinformatics best-practice analysis pipeline for Protein 3D structure prediction.\n\nThe pipeline is built using [Nextflow](https://www.nextflow.io), a workflow tool to run tasks across multiple compute infrastructures in a very portable manner. It uses Docker/Singularity containers making installation trivial and results highly reproducible. The [Nextflow DSL2](https://www.nextflow.io/docs/latest/dsl2.html) implementation of this pipeline uses one container per process which makes it much easier to maintain and update software dependencies. Where possible, these processes have been submitted to and installed from [nf-core/modules](https://github.com/nf-core/modules) in order to make them available to all nf-core pipelines, and to everyone within the Nextflow community!\n\nOn release, automated continuous integration tests run the pipeline on a full-sized dataset on the AWS cloud infrastructure. This ensures that the pipeline runs on AWS, has sensible resource allocation defaults set to run on real-world datasets, and permits the persistent storage of results to benchmark between pipeline releases and other analysis sources. The results obtained from the full-sized test can be viewed on the [nf-core website](https://nf-co.re/proteinfold/results).\n\n## Pipeline summary\n\n![Alt text](docs/images/nf-core-proteinfold_metro_map_1.1.0.png?raw=true \"nf-core-proteinfold 1.1.0 metro map\")\n\n1. Choice of protein structure prediction method:\n\n i. [AlphaFold2](https://github.com/deepmind/alphafold) - Regular AlphaFold2 (MSA computation and model inference in the same process)\n\n ii. [AlphaFold2 split](https://github.com/luisas/alphafold_split) - AlphaFold2 MSA computation and model inference in separate processes\n\n iii. [AlphaFold3](https://github.com/deepmind/alphafold) - Regular AlphaFold3 (MSA computation and model inference in the same process)\n\n iv. [ColabFold](https://github.com/sokrypton/ColabFold) - MMseqs2 API server followed by ColabFold\n\n v. [ColabFold](https://github.com/sokrypton/ColabFold) - MMseqs2 local search followed by ColabFold\n\n vi. [ESMFold](https://github.com/facebookresearch/esm) - Regular ESM\n\n vii. [RoseTTAFold-All-Atom](https://github.com/baker-laboratory/RoseTTAFold-All-Atom/) - Regular RFAA\n\n viii. [HelixFold3](https://github.com/PaddlePaddle/PaddleHelix/tree/dev/apps/protein_folding/helixfold3) - Regular HF3\n\n ix. [Boltz](https://github.com/jwohlwend/boltz/) - Regular Boltz-1\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) with `-profile test` before running the workflow on actual data.\n\nNow, you can run the pipeline using:\n\n```bash\nnextflow run nf-core/proteinfold \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \n```\n\nThe pipeline takes care of downloading the databases and parameters required by AlphaFold2, Colabfold, ESMFold or RoseTTAFold-All-Atom. In case you have already downloaded the required files, you can skip this step by providing the path to the databases using the corresponding parameter [`--alphafold2_db`], [`--colabfold_db`], [`--esmfold_db`] or ['--rosettafold_all_atom_db']. Please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) to check the directory structure you must provide for each database.\n\n- The typical command to run AlphaFold2 mode is shown below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold2 \\\n --alphafold2_db \\\n --full_dbs \\\n --alphafold2_model_preset monomer \\\n --use_gpu \\\n -profile \n ```\n\n- Here is the command to run AlphaFold2 splitting the MSA from the prediction execution:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold2 \\\n --alphafold2_mode split_msa_prediction \\\n --alphafold2_db \\\n --full_dbs \\\n --alphafold2_model_preset monomer \\\n --use_gpu \\\n -profile \n ```\n\n- The AlphaFold3 mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold3 \\\n --alphafold3_db \\\n --use_gpu \\\n -profile \n ```\n\n > [!WARNING]\n > The AlphaFold3 weights are not provided by this pipeline. Users must obtain the weights directly from DeepMind according to their [terms of use](https://github.com/deepmind/alphafold/blob/main/WEIGHTS_TERMS_OF_USE.md) and [prohibited use policy](https://github.com/deepmind/alphafold/blob/main/WEIGHTS_PROHIBITED_USE_POLICY.md). Please ensure you comply with all terms and conditions before using AlphaFold3. For more information about AlphaFold3 usage and requirements, please refer to the [official AlphaFold3 repository](https://github.com/deepmind/alphafold).\n\n- Below, the command to run colabfold_local mode:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode colabfold \\\n --colabfold_server local \\\n --colabfold_db \\\n --num_recycles_colabfold 3 \\\n --use_amber \\\n --colabfold_model_preset \"alphafold2_ptm\" \\\n --use_gpu \\\n --db_load_mode 0\n -profile \n ```\n\n- The typical command to run colabfold_webserver mode would be:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode colabfold \\\n --colabfold_server webserver \\\n --host_url \\\n --colabfold_db \\\n --num_recycles_colabfold 3 \\\n --use_amber \\\n --colabfold_model_preset \"alphafold2_ptm\" \\\n --use_gpu \\\n -profile \n ```\n\n [!WARNING]\n\n > If you aim to carry out a large amount of predictions using the colabfold_webserver mode, please setup and use your own custom MMSeqs2 API Server. You can find instructions [here](https://github.com/sokrypton/ColabFold/tree/main/MsaServer).\n\n- The esmfold mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode esmfold \\\n --esmfold_model_preset \\\n --esmfold_db \\\n --num_recycles_esmfold 4 \\\n --use_gpu \\\n -profile \n ```\n\n- The rosettafold_all_atom mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode rosettafold_all_atom \\\n --rosettafold_all_atom_db \\\n --use_gpu \\\n -profile \n ```\n\n- The helixfold3 mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode helixfold3 \\\n --helixfold3_db \\\n --use_gpu \\\n -profile \n ```\n\n- The boltz mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode boltz \\\n --boltz_ccd_path \\\n --boltz_model_path \\\n --use_gpu \\\n -profile \n ```\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) and the [parameter documentation](https://nf-co.re/proteinfold/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/proteinfold/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/proteinfold/output).\n\n## Credits\n\nnf-core/proteinfold was originally written by Athanasios Baltzis ([@athbaltzis](https://github.com/athbaltzis)), Jose Espinosa-Carrasco ([@JoseEspinosa](https://github.com/JoseEspinosa)), Luisa Santus ([@luisas](https://github.com/luisas)) and Leila Mansouri ([@l-mansouri](https://github.com/l-mansouri)) from [The Comparative Bioinformatics Group](https://www.crg.eu/en/cedric_notredame) at [The Centre for Genomic Regulation, Spain](https://www.crg.eu/) under the umbrella of the [BovReg project](https://www.bovreg.eu/) and Harshil Patel ([@drpatelh](https://github.com/drpatelh)) from [Seqera Labs, Spain](https://seqera.io/).\n\nMany thanks to others who have helped out and contributed along the way too, including (but not limited to): Norman Goodacre and Waleed Osman from Interline Therapeutics ([@interlinetx](https://github.com/interlinetx)), Martin Steinegger ([@martin-steinegger](https://github.com/martin-steinegger)) and Raoul J.P. Bonnal ([@rjpbonnal](https://github.com/rjpbonnal))\n\nWe would also like to thanks to the AWS Open Data Sponsorship Program for generously providing the resources necessary to host the data utilized in the testing, development, and deployment of nf-core proteinfold.\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#proteinfold` channel](https://nfcore.slack.com/channels/proteinfold) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\nIf you use nf-core/proteinfold for your analysis, please cite it using the following doi: [10.5281/zenodo.7437038](https://doi.org/10.5281/zenodo.7437038)\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", "hasPart": [ { "@id": "main.nf" @@ -145,8 +145,12 @@ "protein-sequences", "protein-structure" ], - "license": ["MIT"], - "name": ["nf-core/proteinfold"], + "license": [ + "MIT" + ], + "name": [ + "nf-core/proteinfold" + ], "programmingLanguage": { "@id": "https://w3id.org/workflowhub/workflow-ro-crate#nextflow" }, From ab5f935e1323be703f41dd1dcf5b03a7ea360c3d Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 30 Jul 2025 16:18:12 +1000 Subject: [PATCH 075/150] Colabfold module pathing improvements --- modules/local/colabfold_batch/main.nf | 4 +++- modules/local/mmseqs_colabfoldsearch/main.nf | 10 +++------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/modules/local/colabfold_batch/main.nf b/modules/local/colabfold_batch/main.nf index ba4264e76..ea2bcc14c 100644 --- a/modules/local/colabfold_batch/main.nf +++ b/modules/local/colabfold_batch/main.nf @@ -32,7 +32,9 @@ process COLABFOLD_BATCH { def VERSION = '1.5.2' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ - ln -r -s params/alphafold_params_*/* params/ + ln -s \$(realpath params/alphafold_params_*/*) params/ + touch params/download_finished.txt + colabfold_batch \\ $args \\ --num-recycle ${numRec} \\ diff --git a/modules/local/mmseqs_colabfoldsearch/main.nf b/modules/local/mmseqs_colabfoldsearch/main.nf index 2df5bf852..711da1880 100644 --- a/modules/local/mmseqs_colabfoldsearch/main.nf +++ b/modules/local/mmseqs_colabfoldsearch/main.nf @@ -6,8 +6,8 @@ process MMSEQS_COLABFOLDSEARCH { input: tuple val(meta), path(fasta) - path colabfold_db - path uniref30 + path ('db/*') + path ('db/*') output: tuple val(meta), path("**.a3m"), emit: a3m @@ -25,11 +25,7 @@ process MMSEQS_COLABFOLDSEARCH { def VERSION = '1.5.2' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ - mkdir ./db - ln -r -s $uniref30/uniref30_* ./db - ln -r -s $colabfold_db/colabfold_envdb* ./db - - /localcolabfold/colabfold-conda/bin/colabfold_search \\ + colabfold_search \\ $args \\ --threads $task.cpus ${fasta} \\ ./db \\ From 88f5cc304d102561f26c7e25fdaaa8e452460754 Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 30 Jul 2025 16:18:24 +1000 Subject: [PATCH 076/150] Updated Colabfold image --- .../Dockerfile_nfcore-proteinfold_colabfold | 44 +++---------------- 1 file changed, 5 insertions(+), 39 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold b/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold index c45ad4ecc..be7098026 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold @@ -1,40 +1,6 @@ -FROM nvidia/cuda:12.6.2-cudnn-runtime-ubuntu24.04 +FROM ghcr.io/sokrypton/colabfold:1.5.5-cuda12.2.2 -LABEL authors="Athanasios Baltzis, Jose Espinosa-Carrasco, Leila Mansouri" \ - title="nfcore/proteinfold_colabfold" \ - Version="1.2.0dev" \ - description="Docker image containing all software requirements to run the COLABFOLD_BATCH module using the nf-core/proteinfold pipeline" - -ENV PATH="/localcolabfold/colabfold-conda/bin:$PATH" -ENV LD_LIBRARY_PATH="/localcolabfold/colabfold-conda/lib:/usr/local/cuda/lib64" -ENV PYTHONPATH="/localcolabfold/colabfold-conda/lib" -ENV PATH="/MMseqs2/build/bin:$PATH" - -# Use bash to support string substitution. -RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A4B469963BF863CC -RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y \ - build-essential \ - cuda-command-line-tools-12-6 \ - git \ - hmmer \ - kalign \ - tzdata \ - wget \ - curl \ - cmake \ - && rm -rf /var/lib/apt/lists/* - -RUN cd / \ - && wget https://raw.githubusercontent.com/YoshitakaMo/localcolabfold/07e87ed/install_colabbatch_linux.sh \ - && sed -i "/colabfold.download/d" install_colabbatch_linux.sh \ - # Avoid error running on cpus - # https://github.com/YoshitakaMo/localcolabfold/issues/238#issuecomment-2203777538 - && sed -i "/==0.4.28/d" install_colabbatch_linux.sh \ - && bash install_colabbatch_linux.sh - -## Updated -RUN /localcolabfold/colabfold-conda/bin/python3.10 -m pip install tensorflow-cpu==2.17.0 - -# #Silence download of the AlphaFold2 params -RUN sed -i "s|download_alphafold_params(|#download_alphafold_params(|g" /localcolabfold/colabfold-conda/lib/python3.10/site-packages/colabfold/batch.py -RUN sed -i "s|if args\.num_models|#if args\.num_models|g" /localcolabfold/colabfold-conda/lib/python3.10/site-packages/colabfold/batch.py +RUN wget https://mmseqs.com/latest/mmseqs-linux-gpu.tar.gz && \ + tar xvfz mmseqs-linux-gpu.tar.gz && \ + mv mmseqs/bin/* /usr/local/bin/ && \ + rm -rf mmseqs-linux-*.tar.gz mmseqs From 2c451ceb973cea1f1281647ea6ef979d5d2f0db4 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 30 Jul 2025 08:56:14 +0200 Subject: [PATCH 077/150] Add unzip module --- modules/nf-core/unzip/environment.yml | 7 ++ modules/nf-core/unzip/main.nf | 49 ++++++++++++ modules/nf-core/unzip/meta.yml | 50 ++++++++++++ modules/nf-core/unzip/tests/main.nf.test | 54 +++++++++++++ modules/nf-core/unzip/tests/main.nf.test.snap | 76 +++++++++++++++++++ 5 files changed, 236 insertions(+) create mode 100644 modules/nf-core/unzip/environment.yml create mode 100644 modules/nf-core/unzip/main.nf create mode 100644 modules/nf-core/unzip/meta.yml create mode 100644 modules/nf-core/unzip/tests/main.nf.test create mode 100644 modules/nf-core/unzip/tests/main.nf.test.snap diff --git a/modules/nf-core/unzip/environment.yml b/modules/nf-core/unzip/environment.yml new file mode 100644 index 000000000..246158953 --- /dev/null +++ b/modules/nf-core/unzip/environment.yml @@ -0,0 +1,7 @@ +--- +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json +channels: + - conda-forge + - bioconda +dependencies: + - conda-forge::p7zip=16.02 diff --git a/modules/nf-core/unzip/main.nf b/modules/nf-core/unzip/main.nf new file mode 100644 index 000000000..a0c02109c --- /dev/null +++ b/modules/nf-core/unzip/main.nf @@ -0,0 +1,49 @@ +process UNZIP { + tag "$archive" + label 'process_single' + + conda "${moduleDir}/environment.yml" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/p7zip:16.02' : + 'biocontainers/p7zip:16.02' }" + + input: + tuple val(meta), path(archive) + + output: + tuple val(meta), path("${prefix}/"), emit: unzipped_archive + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + if ( archive instanceof List && archive.name.size > 1 ) { error "[UNZIP] error: 7za only accepts a single archive as input. Please check module input." } + prefix = task.ext.prefix ?: ( meta.id ? "${meta.id}" : archive.baseName) + """ + 7za \\ + x \\ + -o"${prefix}"/ \\ + $args \\ + $archive + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + 7za: \$(echo \$(7za --help) | sed 's/.*p7zip Version //; s/(.*//') + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: '' + if ( archive instanceof List && archive.name.size > 1 ) { error "[UNZIP] error: 7za only accepts a single archive as input. Please check module input." } + prefix = task.ext.prefix ?: ( meta.id ? "${meta.id}" : archive.baseName) + """ + mkdir "${prefix}" + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + 7za: \$(echo \$(7za --help) | sed 's/.*p7zip Version //; s/(.*//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/unzip/meta.yml b/modules/nf-core/unzip/meta.yml new file mode 100644 index 000000000..ba1eb9129 --- /dev/null +++ b/modules/nf-core/unzip/meta.yml @@ -0,0 +1,50 @@ +name: unzip +description: Unzip ZIP archive files +keywords: + - unzip + - decompression + - zip + - archiving +tools: + - unzip: + description: p7zip is a quick port of 7z.exe and 7za.exe (command line version + of 7zip, see www.7-zip.org) for Unix. + homepage: https://sourceforge.net/projects/p7zip/ + documentation: https://sourceforge.net/projects/p7zip/ + tool_dev_url: https://sourceforge.net/projects/p7zip" + licence: ["LGPL-2.1-or-later"] + identifier: "" +input: + - - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - archive: + type: file + description: ZIP file + pattern: "*.zip" + ontologies: + - edam: http://edamontology.org/format_3987 # ZIP format +output: + unzipped_archive: + - - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - ${prefix}/: + type: directory + description: Directory contents of the unzipped archive + pattern: "${archive.baseName}/" + versions: + - versions.yml: + type: file + description: File containing software versions + pattern: "versions.yml" + ontologies: + - edam: http://edamontology.org/format_3750 # YAML +authors: + - "@jfy133" +maintainers: + - "@jfy133" diff --git a/modules/nf-core/unzip/tests/main.nf.test b/modules/nf-core/unzip/tests/main.nf.test new file mode 100644 index 000000000..238b68d8b --- /dev/null +++ b/modules/nf-core/unzip/tests/main.nf.test @@ -0,0 +1,54 @@ +nextflow_process { + + name "Test Process UNZIP" + script "../main.nf" + process "UNZIP" + + tag "modules" + tag "modules_nfcore" + tag "unzip" + + test("generic [tar] [tar_gz]") { + + when { + process { + """ + input[0] = [ + [ id: 'hello' ], + file(params.modules_testdata_base_path + 'generic/tar/hello.tar.gz', checkIfExists: true) + ] + """ + } + } + + then { + assertAll( + { assert process.success }, + { assert snapshot(process.out).match() } + ) + } + } + + test("generic [tar] [tar_gz] stub") { + + options "-stub" + + when { + process { + """ + input[0] = [ + [ id: 'hello' ], + file(params.modules_testdata_base_path + 'generic/tar/hello.tar.gz', checkIfExists: true) + ] + """ + } + } + + then { + assertAll( + { assert process.success }, + { assert snapshot(process.out).match() } + ) + } + } +} diff --git a/modules/nf-core/unzip/tests/main.nf.test.snap b/modules/nf-core/unzip/tests/main.nf.test.snap new file mode 100644 index 000000000..cdd2ab164 --- /dev/null +++ b/modules/nf-core/unzip/tests/main.nf.test.snap @@ -0,0 +1,76 @@ +{ + "generic [tar] [tar_gz] stub": { + "content": [ + { + "0": [ + [ + { + "id": "hello" + }, + [ + + ] + ] + ], + "1": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ], + "unzipped_archive": [ + [ + { + "id": "hello" + }, + [ + + ] + ] + ], + "versions": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ] + } + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.2" + }, + "timestamp": "2024-06-30T19:16:37.11550986" + }, + "generic [tar] [tar_gz]": { + "content": [ + { + "0": [ + [ + { + "id": "hello" + }, + [ + "hello.tar:md5,80c66db79a773bc87b3346035ff9593e" + ] + ] + ], + "1": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ], + "unzipped_archive": [ + [ + { + "id": "hello" + }, + [ + "hello.tar:md5,80c66db79a773bc87b3346035ff9593e" + ] + ] + ], + "versions": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ] + } + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.2" + }, + "timestamp": "2024-06-30T19:16:25.120242571" + } +} \ No newline at end of file From 8b9810cb65622e7cbac1aadf6bf11cefb174b0fc Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Fri, 1 Aug 2025 10:56:33 +1000 Subject: [PATCH 078/150] Signal intent to extend iPTM to chain-wise format for v2 --- bin/extract_metrics.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index f5fce329b..c62b3feae 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -23,6 +23,10 @@ #... # ^ overwrought with duplication, but can catch program specific weirdness, and lower barrier to adding new programs in the future. +# TODO: Chain-wise iPTM since the relevant interface might not always be the average of all. +# Would complete Issue #308 +# Proposed format is pair-interfaces in rows, structure inference number in cols: https://github.com/nf-core/proteinfold/pull/312#issuecomment-2917709432 + # Mapping of characters to integers for MSA parsing. # 20 is for unknown characters, and 21 is for gaps. AA_to_int = { From 217745afa6430a808edb2009eb82f1a32fdc9c75 Mon Sep 17 00:00:00 2001 From: jscgh Date: Fri, 1 Aug 2025 12:45:53 +1000 Subject: [PATCH 079/150] Updated Dockerfile for colabfold image --- dockerfiles/Dockerfile_nfcore-proteinfold_colabfold | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold b/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold index be7098026..243784833 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold @@ -1,6 +1,5 @@ FROM ghcr.io/sokrypton/colabfold:1.5.5-cuda12.2.2 -RUN wget https://mmseqs.com/latest/mmseqs-linux-gpu.tar.gz && \ - tar xvfz mmseqs-linux-gpu.tar.gz && \ - mv mmseqs/bin/* /usr/local/bin/ && \ - rm -rf mmseqs-linux-*.tar.gz mmseqs +RUN mamba install -y -n colabfold -c conda-forge -c bioconda mmseqs2=18.8cc5c && \ + mamba clean -afy && \ + mmseqs version From fa9d1c899bedb93886f82c0d1e3d660c06660236 Mon Sep 17 00:00:00 2001 From: jscgh Date: Fri, 1 Aug 2025 12:46:26 +1000 Subject: [PATCH 080/150] Retrieve colabfold versions instead of hardcoded --- modules/local/colabfold_batch/main.nf | 6 ++---- modules/local/mmseqs_colabfoldsearch/main.nf | 10 ++++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/local/colabfold_batch/main.nf b/modules/local/colabfold_batch/main.nf index ea2bcc14c..d50f12f80 100644 --- a/modules/local/colabfold_batch/main.nf +++ b/modules/local/colabfold_batch/main.nf @@ -29,7 +29,6 @@ process COLABFOLD_BATCH { error("Local COLABFOLD_BATCH module does not support Conda. Please use Docker / Singularity / Podman instead.") } def args = task.ext.args ?: '' - def VERSION = '1.5.2' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ ln -s \$(realpath params/alphafold_params_*/*) params/ @@ -53,12 +52,11 @@ process COLABFOLD_BATCH { cat <<-END_VERSIONS > versions.yml "${task.process}": - colabfold_batch: $VERSION + colabfold_batch: \$(conda run -n colabfold pip list | grep "^colabfold" | awk '{print \$2}') END_VERSIONS """ stub: - def VERSION = '1.5.2' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ touch ./"${meta.id}"_colabfold.pdb touch ./"${meta.id}"_mqc.png @@ -70,7 +68,7 @@ process COLABFOLD_BATCH { cat <<-END_VERSIONS > versions.yml "${task.process}": - colabfold_batch: $VERSION + colabfold_batch: \$(conda run -n colabfold pip list | grep "^colabfold" | awk '{print \$2}') END_VERSIONS """ } diff --git a/modules/local/mmseqs_colabfoldsearch/main.nf b/modules/local/mmseqs_colabfoldsearch/main.nf index 711da1880..0cc123ab1 100644 --- a/modules/local/mmseqs_colabfoldsearch/main.nf +++ b/modules/local/mmseqs_colabfoldsearch/main.nf @@ -22,7 +22,6 @@ process MMSEQS_COLABFOLDSEARCH { error("Local MMSEQS_COLABFOLDSEARCH module does not support Conda. Please use Docker / Singularity / Podman instead.") } def args = task.ext.args ?: '' - def VERSION = '1.5.2' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ colabfold_search \\ @@ -33,19 +32,22 @@ process MMSEQS_COLABFOLDSEARCH { cat <<-END_VERSIONS > versions.yml "${task.process}": - colabfold_search: $VERSION + colabfold_search: \$(conda run -n colabfold pip list | grep "^colabfold" | awk '{print \$2}') + alphafold_colabfold: \$(conda run -n colabfold pip list | grep "^alphafold-colabfold" | awk '{print \$2}') + mmseqs: \$(mmseqs version) END_VERSIONS """ stub: - def VERSION = '1.5.2' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ mkdir results touch results/${meta.id}.a3m cat <<-END_VERSIONS > versions.yml "${task.process}": - colabfold_search: $VERSION + colabfold_search: \$(conda run -n colabfold pip list | grep "^colabfold" | awk '{print \$2}') + alphafold_colabfold: \$(conda run -n colabfold pip list | grep "^alphafold-colabfold" | awk '{print \$2}') + mmseqs: \$(mmseqs version) END_VERSIONS """ } From 5c267e5fa7e80c6d248f1b7e92b2ab7deeb8c764 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Fri, 1 Aug 2025 17:27:04 +1000 Subject: [PATCH 081/150] scaffold chain-pair iPTM extraction code --- bin/extract_metrics.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index c62b3feae..7ba317a8e 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -62,6 +62,26 @@ def format_msa_rows(msa_data): def format_pae_rows(pae_data): return [[f"{num:.4f}" for num in row] for row in pae_data] +def chain_iptm_matrix_to_pairs(chain_iptm_data): + """ + Convert a chain-wise iPTM matrix to pair values by taking off-diagonal elements. + """ + # From AlphaFold3 output docs: + # 'chain_pair_iptm': An [num_chains, num_chains] array. + # Off-diagonal element (i, j) of the array contains the ipTM restricted to tokens from chains i and j. + # Diagonal element (i, i) contains the pTM restricted to chain i. + + # TODO: load the chain-wise iPTM matrix from a file into np matrix + + # TODO: turn the matrix into a list of pairs by taking off-diagonal elements + + # TODO: discard duplicates due to symmetry, e.g. (A,B) and (B,A) are the same pair + + # TODO: append the chain names in front of value, e.g. "A:B 0.85, A:C 0.90, A:D 0.80, B:C 0.75, B:D 0.70, C:D 0.65" + + # TODO: return the list of pairs as a string rows to be passed to write_tsv() to write to a metrics file + raise NotImplementedError("Chain-wise iPTM matrix to pairs conversion is not implemented yet.") + def write_tsv(file_path, rows): with open(file_path, 'w') as out_f: writer = csv.writer(out_f, delimiter='\t') From 3c759bf9c56027ccf3cb4987e9cd48cb95691d50 Mon Sep 17 00:00:00 2001 From: Tom Litfin Date: Sat, 2 Aug 2025 16:10:15 +1000 Subject: [PATCH 082/150] Harmonize msa arguments in colabfold and boltz --- README.md | 5 ++--- conf/modules_boltz.config | 6 +++--- conf/modules_colabfold.config | 7 ++++--- conf/test_boltz.config | 2 -- conf/test_colabfold_download.config | 2 +- conf/test_colabfold_local.config | 1 - conf/test_colabfold_webserver.config | 4 ++-- conf/test_full_boltz.config | 2 -- conf/test_full_colabfold_local.config | 1 - conf/test_full_colabfold_webserver.config | 4 ++-- ...t_full_colabfold_webserver_multimer.config | 2 +- conf/test_split_fasta.config | 1 - docs/usage.md | 11 +++++----- main.nf | 6 +++--- nextflow.config | 6 ++---- nextflow_schema.json | 20 +++++-------------- subworkflows/local/prepare_colabfold_dbs.nf | 6 +++--- workflows/colabfold.nf | 8 +++++--- 18 files changed, 38 insertions(+), 56 deletions(-) diff --git a/README.md b/README.md index 47141e81e..f6f90ce91 100644 --- a/README.md +++ b/README.md @@ -116,7 +116,6 @@ The pipeline takes care of downloading the databases and parameters required by --input samplesheet.csv \ --outdir \ --mode colabfold \ - --colabfold_server local \ --colabfold_db \ --num_recycles_colabfold 3 \ --use_amber \ @@ -133,8 +132,8 @@ The pipeline takes care of downloading the databases and parameters required by --input samplesheet.csv \ --outdir \ --mode colabfold \ - --colabfold_server webserver \ - --host_url \ + --use_msa_server \ + --msa_server_url \ --colabfold_db \ --num_recycles_colabfold 3 \ --use_amber \ diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index 58ea2208f..ea2a7172e 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -13,11 +13,11 @@ process { withName: 'RUN_BOLTZ' { ext.args = [ - params.boltz_model ? "--model ${params.boltz_model}" : "", + params.boltz_model ? "--model ${params.boltz_model}" : "", params.boltz_out_dir ? "--out_dir ${params.boltz_out_dir}" : "", params.boltz_output_format ? "--output_format ${params.boltz_output_format}" : "", - params.boltz_use_msa_server ? "--use_msa_server" : "", - params.boltz_msa_server_url ? "--msa_server_url ${params.boltz_msa_server_url}" : "", + params.use_msa_server ? "--use_msa_server" : "", + params.msa_server_url ? "--msa_server_url ${params.msa_server_url}" : "", params.boltz_use_potentials ? "--use_potentials" : "", params.boltz_write_full_pae ? "--write_full_pae" : "", ].findAll{ it }.join(' ').trim() diff --git a/conf/modules_colabfold.config b/conf/modules_colabfold.config index 92deaf093..a7ece8721 100644 --- a/conf/modules_colabfold.config +++ b/conf/modules_colabfold.config @@ -20,23 +20,24 @@ process { } } +// TODO: Differentiate between local and server MSA? process { withName: 'COLABFOLD_BATCH' { ext.args = [ params.use_gpu ? '--use-gpu-relax' : '', params.use_amber ? '--amber' : '', params.use_templates ? '--templates' : '', - params.colabfold_server == 'webserver' && params.host_url ? "--host-url ${params.host_url}" : '' + params.use_msa_server && params.msa_server_url ? "--host-url ${params.msa_server_url}" : '' ].join(' ').trim() publishDir = [ [ - path: { "${params.outdir}/colabfold/${params.colabfold_server}" }, + path: { "${params.outdir}/colabfold/" }, mode: 'copy', saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, pattern: '*.*' ], [ - path: { "${params.outdir}/colabfold/${params.colabfold_server}/top_ranked_structures" }, + path: { "${params.outdir}/colabfold/top_ranked_structures" }, mode: 'copy', saveAs: { "${meta.id}.pdb" }, pattern: '*_relaxed_rank_001*.pdb' diff --git a/conf/test_boltz.config b/conf/test_boltz.config index f4978df3c..682419f50 100644 --- a/conf/test_boltz.config +++ b/conf/test_boltz.config @@ -26,9 +26,7 @@ params { // Input data for full test of boltz mode = 'boltz' - colabfold_server = 'local' colabfold_model_preset = 'alphafold2_ptm' input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' colabfold_db = 's3://proteinfold-dataset/test-data/db/colabfold_mini' - boltz_use_msa_server = false } diff --git a/conf/test_colabfold_download.config b/conf/test_colabfold_download.config index 8d2f9547b..f3b527b5f 100644 --- a/conf/test_colabfold_download.config +++ b/conf/test_colabfold_download.config @@ -27,7 +27,7 @@ params { // Input data to test colabfold analysis mode = 'colabfold' - colabfold_server = 'webserver' + use_msa_server = true input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' } diff --git a/conf/test_colabfold_local.config b/conf/test_colabfold_local.config index 7186ccd5b..3019f1963 100644 --- a/conf/test_colabfold_local.config +++ b/conf/test_colabfold_local.config @@ -25,7 +25,6 @@ params { // Input data to test colabfold with the colabfold webserver analysis mode = 'colabfold' - colabfold_server = 'local' colabfold_db = "${projectDir}/assets/dummy_db_dir" input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' } diff --git a/conf/test_colabfold_webserver.config b/conf/test_colabfold_webserver.config index 29faf98f0..e2273b359 100644 --- a/conf/test_colabfold_webserver.config +++ b/conf/test_colabfold_webserver.config @@ -23,9 +23,9 @@ params { config_profile_name = 'Test profile' config_profile_description = 'Minimal test dataset to check pipeline function' - // Input data to test colabfold with a local server analysis + // Input data to test colabfold with a webserver analysis mode = 'colabfold' - colabfold_server = 'webserver' + use_msa_server = true colabfold_db = "${projectDir}/assets/dummy_db_dir" input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' } diff --git a/conf/test_full_boltz.config b/conf/test_full_boltz.config index 999454f04..d3710bc84 100644 --- a/conf/test_full_boltz.config +++ b/conf/test_full_boltz.config @@ -16,9 +16,7 @@ params { // Input data for full test of boltz mode = 'boltz' - colabfold_server = 'local' colabfold_model_preset = 'alphafold2_ptm' input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' colabfold_db = 's3://proteinfold-dataset/test-data/db/colabfold_mini' - boltz_use_msa_server = false } diff --git a/conf/test_full_colabfold_local.config b/conf/test_full_colabfold_local.config index 9d146bfe6..7f1a41e16 100644 --- a/conf/test_full_colabfold_local.config +++ b/conf/test_full_colabfold_local.config @@ -17,7 +17,6 @@ params { // Input data to test colabfold with a local server analysis mode = 'colabfold' - colabfold_server = 'local' colabfold_model_preset = 'alphafold2_ptm' input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' colabfold_db = 's3://proteinfold-dataset/test-data/db/colabfold_mini' diff --git a/conf/test_full_colabfold_webserver.config b/conf/test_full_colabfold_webserver.config index ca54564db..949adbf65 100644 --- a/conf/test_full_colabfold_webserver.config +++ b/conf/test_full_colabfold_webserver.config @@ -16,8 +16,8 @@ params { // Input data for full test of colabfold with Colabfold server mode = 'colabfold' - colabfold_server = 'webserver' + use_msa_server = true colabfold_model_preset = 'alphafold2_ptm' input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet.csv' - colabfold_db = 's3://proteinfold-dataset/test-data/db/colabfold_mini' + colabfold_db = 's3://proteinfold-dataset/test-data/db/colabfold_mini' } diff --git a/conf/test_full_colabfold_webserver_multimer.config b/conf/test_full_colabfold_webserver_multimer.config index b539faf52..d6d41bb4d 100644 --- a/conf/test_full_colabfold_webserver_multimer.config +++ b/conf/test_full_colabfold_webserver_multimer.config @@ -16,7 +16,7 @@ params { // Input data for full test of colabfold with Colabfold server mode = 'colabfold' - colabfold_server = 'webserver' + use_msa_server = true colabfold_model_preset = 'alphafold2_multimer_v3' input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet_multimer.csv' colabfold_db = 's3://proteinfold-dataset/test-data/db/colabfold_mini' diff --git a/conf/test_split_fasta.config b/conf/test_split_fasta.config index 4d2bd9ae9..f9463eb68 100644 --- a/conf/test_split_fasta.config +++ b/conf/test_split_fasta.config @@ -25,7 +25,6 @@ params { // Input data to test colabfold with the colabfold webserver analysis mode = 'colabfold' - colabfold_server = 'local' split_fasta = true colabfold_db = "${projectDir}/assets/dummy_db_dir" input = params.pipelines_testdata_base_path + 'proteinfold/testdata/samplesheet/v1.2/samplesheet_multimer.csv' diff --git a/docs/usage.md b/docs/usage.md index ac0b7040b..18983b631 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -179,14 +179,13 @@ To provide the predownloaded AlphaFold3 databases and parameters you can specify ``` -Colabfold mode using use your own custom MMSeqs2 API server (`--colabfold_server local`) can be run using the following command: +Colabfold mode can be used with local database search using the following command: ```bash nextflow run nf-core/proteinfold \ --input samplesheet.csv \ --outdir \ --mode colabfold \ - --colabfold_server local \ --colabfold_db \ --num_recycles_colabfold 3 \ --use_amber \ @@ -203,8 +202,8 @@ nextflow run nf-core/proteinfold \ --input samplesheet.csv \ --outdir \ --mode colabfold - --colabfold_server webserver \ - --host_url \ + --use_msa_server \ + --msa_server_url \ --colabfold_db \ --num_recycles_colabfold 3 \ --use_amber \ @@ -595,8 +594,8 @@ nextflow run nf-core/proteinfold \ | ------------------------ | ------- | --------------------------------------------------- | | `--boltz_model` | `null` | The model to use for prediction. Default is Boltz-2 | | `--boltz_out_dir` | `null` | Output directory for Boltz predictions | -| `--boltz_use_msa_server` | `null` | Use MSA server to generate MSAs (flag) | -| `--boltz_msa_server_url` | `null` | MSA server URL | +| `--use_msa_server` | `null` | Use MSA server to generate MSAs (flag) | +| `--msa_server_url` | `null` | MSA server URL | | `--boltz_use_potentials` | `null` | Use inference time potentials (flag) | | `--boltz_write_full_pae` | `true` | Save the full PAE matrix as a file (flag) | diff --git a/main.nf b/main.nf index 04e7dffc7..b821dfa63 100644 --- a/main.nf +++ b/main.nf @@ -239,7 +239,7 @@ workflow NFCORE_PROTEINFOLD { // PREPARE_COLABFOLD_DBS ( params.colabfold_db, - params.colabfold_server, + params.use_msa_server, params.colabfold_alphafold2_params_path, params.colabfold_db_path, params.colabfold_uniref30_path, @@ -447,7 +447,7 @@ workflow NFCORE_PROTEINFOLD { PREPARE_COLABFOLD_DBS ( params.colabfold_db, - params.colabfold_server, + params.use_msa_server, params.colabfold_alphafold2_params_path, params.colabfold_db_path, params.colabfold_uniref30_path, @@ -468,7 +468,7 @@ workflow NFCORE_PROTEINFOLD { PREPARE_BOLTZ_DBS.out.boltz2_mols, PREPARE_COLABFOLD_DBS.out.colabfold_db, PREPARE_COLABFOLD_DBS.out.uniref30, - params.boltz_use_msa_server + params.use_msa_server ) ch_multiqc = ch_multiqc.mix(BOLTZ.out.multiqc_report) ch_versions = ch_versions.mix(BOLTZ.out.versions) diff --git a/nextflow.config b/nextflow.config index 7cae73120..5bd492c62 100644 --- a/nextflow.config +++ b/nextflow.config @@ -76,8 +76,6 @@ params { boltz_model = null boltz_out_dir = null boltz_output_format = 'pdb' - boltz_use_msa_server = false - boltz_msa_server_url = null boltz_use_potentials = false boltz_write_full_pae = true @@ -97,13 +95,13 @@ params { boltz2_mols_path = null // Colabfold parameters - colabfold_server = "webserver" + use_msa_server = false colabfold_model_preset = "alphafold2_ptm" // {'alphafold2_ptm', 'alphafold2_multimer_v1', 'alphafold2_multimer_v2', 'alphafold2_multimer_v3'} num_recycles_colabfold = 3 use_amber = true colabfold_db = null db_load_mode = 0 - host_url = null + msa_server_url = null use_templates = true create_colabfold_index = false diff --git a/nextflow_schema.json b/nextflow_schema.json index 512969ef0..abcd8081f 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -151,12 +151,10 @@ "fa_icon": "fas fa-coins", "description": "ColabFold options.", "properties": { - "colabfold_server": { - "type": "string", - "default": "webserver", - "description": "Specifies the MSA server used by ColabFold", - "enum": ["webserver", "local"], - "fa_icon": "fas fa-server" + "use_msa_server": { + "type": "boolean", + "description": "Use the cloud MSA server", + "icon": "fas folder-open" }, "colabfold_model_preset": { "type": "string", @@ -192,7 +190,7 @@ "enum": [0, 1, 2, 3], "errorMessage": "DB load mode must be 0, 1, 2, or 3" }, - "host_url": { + "msa_server_url": { "type": "string", "description": "Specify your custom MMSeqs2 API server url", "fa_icon": "fas fa-link", @@ -242,17 +240,9 @@ "fa_icon": "fas fa-database", "description": "Boltz options.", "properties": { - "boltz_use_msa_server": { - "type": "boolean", - "description": "Use the cloud MSA server", - "icon": "fas folder-open" - }, "boltz_out_dir": { "type": "string" }, - "boltz_msa_server_url": { - "type": "string" - }, "boltz_use_potentials": { "type": "boolean" }, diff --git a/subworkflows/local/prepare_colabfold_dbs.nf b/subworkflows/local/prepare_colabfold_dbs.nf index 8d6ecf1d8..370a7080c 100644 --- a/subworkflows/local/prepare_colabfold_dbs.nf +++ b/subworkflows/local/prepare_colabfold_dbs.nf @@ -14,7 +14,7 @@ workflow PREPARE_COLABFOLD_DBS { take: colabfold_db // directory: path/to/colabfold/DBs and params - colabfold_server // string: Specifies the server to use for colabfold + use_msa_server // bool: Specifies whether to use web msa server colabfold_alphafold2_params_path // directory: /path/to/colabfold/alphafold2/params/ colabfold_db_path // directory: /path/to/colabfold/db/ colabfold_uniref30_path // directory: /path/to/uniref30/colabfold/ @@ -31,7 +31,7 @@ workflow PREPARE_COLABFOLD_DBS { if (colabfold_db) { ch_params = Channel.value(file(colabfold_alphafold2_params_path, type: 'any')) - if (colabfold_server == 'local') { + if (!use_msa_server) { ch_colabfold_db = Channel.value(file(colabfold_db_path, type: 'any')) ch_uniref30 = Channel.value(file(colabfold_uniref30_path, type: 'any')) } @@ -43,7 +43,7 @@ workflow PREPARE_COLABFOLD_DBS { ch_params = ARIA2_COLABFOLD_PARAMS.out.db ch_versions = ch_versions.mix(ARIA2_COLABFOLD_PARAMS.out.versions) - if (params.colabfold_server == 'local') { + if (!use_msa_server) { ARIA2_COLABFOLD_DB ( colabfold_db_link ) diff --git a/workflows/colabfold.nf b/workflows/colabfold.nf index 2b751e66d..c356984f9 100644 --- a/workflows/colabfold.nf +++ b/workflows/colabfold.nf @@ -37,11 +37,12 @@ workflow COLABFOLD { main: ch_multiqc_report = Channel.empty() - if (params.colabfold_server == 'webserver') { + if (params.use_msa_server) { // // MODULE: Run colabfold // - if (params.colabfold_model_preset != 'alphafold2_ptm' && params.colabfold_model_preset != 'alphafold2') { + if (colabfold_model_preset != 'alphafold2_ptm' && colabfold_model_preset != 'alphafold2') { + //Multimer mode MULTIFASTA_TO_CSV( ch_samplesheet ) @@ -67,11 +68,12 @@ workflow COLABFOLD { ch_versions = ch_versions.mix(COLABFOLD_BATCH.out.versions) } - } else if (params.colabfold_server == 'local') { + } else { // // MODULE: Run mmseqs // if (params.colabfold_model_preset != 'alphafold2_ptm' && params.colabfold_model_preset != 'alphafold2') { + //Multimer mode MULTIFASTA_TO_CSV( ch_samplesheet ) From e614086c3a18ee4edc303bba1eda221fc5f61cc0 Mon Sep 17 00:00:00 2001 From: Tom Litfin Date: Sun, 3 Aug 2025 23:39:23 +1000 Subject: [PATCH 083/150] Update AF2 defaults --- nextflow.config | 8 ++++---- nextflow_schema.json | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/nextflow.config b/nextflow.config index 7cae73120..8fc4f62c8 100644 --- a/nextflow.config +++ b/nextflow.config @@ -11,16 +11,16 @@ params { // Input options input = null - mode = 'alphafold2' // {alphafold2, colabfold, esmfold, rosettafold_all_atom, helixfold3, boltz} + mode = 'alphafold2' // {alphafold2, colabfold, esmfold, rosettafold_all_atom, alphafold3, helixfold3, boltz} use_gpu = false split_fasta = false db = null // Alphafold2 parameters - alphafold2_mode = "standard" - max_template_date = "2038-01-19" + alphafold2_mode = 'split_msa_prediction' // {standard, split_msa_prediction} + max_template_date = '2038-01-19' full_dbs = false // true full_dbs, false reduced_dbs - alphafold2_model_preset = "monomer" // for AF2 {monomer (default), monomer_casp14, monomer_ptm, multimer} + alphafold2_model_preset = 'monomer_ptm' // for AF2 {monomer, monomer_casp14, monomer_ptm, multimer} alphafold2_db = null random_seed = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 512969ef0..3ed8e5a4d 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -100,14 +100,14 @@ }, "alphafold2_mode": { "type": "string", - "default": "standard", + "default": "split_msa_prediction", "description": "Specifies the mode in which AlphaFold2 will be run", "enum": ["standard", "split_msa_prediction"], "fa_icon": "fas fa-exchange-alt" }, "alphafold2_model_preset": { "type": "string", - "default": "monomer", + "default": "monomer_ptm", "description": "Model preset for 'AlphaFold2' mode", "enum": ["monomer", "monomer_casp14", "monomer_ptm", "multimer"], "fa_icon": "fas fa-stream" From 7ce532087890d1416120284db3e40fc25d16e2b2 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 4 Aug 2025 12:23:40 +1000 Subject: [PATCH 084/150] Updated CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4681657bb..5021e7c6a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -51,6 +51,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #333](https://github.com/nf-core/proteinfold/pull/333)] - Updates the RFAA dockerfile for better versioning and smaller image size. - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). - [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). +- [[PR #356](https://github.com/nf-core/proteinfold/pull/356)] - Update AF2 defaults to use split mode and monomer_ptm model. ### Parameters From f4497be67c29caeffa044d7c04be149d9c919a1e Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 12:41:58 +1000 Subject: [PATCH 085/150] Disambiguate HelixFold3 param names --- conf/modules_helixfold3.config | 12 ++++++------ nextflow.config | 6 +++--- nextflow_schema.json | 21 ++++++++++++++------- 3 files changed, 23 insertions(+), 16 deletions(-) diff --git a/conf/modules_helixfold3.config b/conf/modules_helixfold3.config index 903955044..6349a321a 100644 --- a/conf/modules_helixfold3.config +++ b/conf/modules_helixfold3.config @@ -25,12 +25,12 @@ process { ext.args = [ params.helixfold3_max_template_date ? "--max_template_date=${params.helixfold3_max_template_date}" : "--max_template_date=2038-01-19", - params.model_name ? "--model_name ${params.model_name}" : "--model_name allatom_demo", - params.preset ? "--preset ${params.preset}" : "--preset 'reduced_dbs'", - params.init_model ? "--init_model ${params.init_model}" : "--init_model './init_models/HelixFold3-240814.pdparams'", - params.logging_level ? "--logging_level ${params.logging_level}" : "--logging_level 'ERROR'", - params.precision ? "--precision ${params.precision}" : "--precision 'bf16'", - params.infer_times ? "--infer_times ${params.infer_times}" : "--infer_times 4" + params.model_name ? "--model_name ${params.model_name}" : "--model_name allatom_demo", + params.helixfold3_full_dbs ? "--preset 'full_dbs'" : "--preset 'reduced_dbs'", + params.init_model ? "--init_model ${params.init_model}" : "--init_model './init_models/HelixFold3-240814.pdparams'", + params.logging_level ? "--logging_level ${params.logging_level}" : "--logging_level 'ERROR'", + params.helixfold3_precision ? "--precision ${params.helixfold3_precision}" : "--precision 'bf16'", + params.helixfold3_infer_times ? "--infer_times ${params.helixfold3_infer_times}" : "--infer_times 4" ].join(' ').trim() publishDir = [ diff --git a/nextflow.config b/nextflow.config index 5bd492c62..231217268 100644 --- a/nextflow.config +++ b/nextflow.config @@ -144,11 +144,11 @@ params { // Helixfold3 parameters helixfold3_db = null model_name = null - preset = null + helixfold3_full_dbs = false init_model = null logging_level = null - precision = null - infer_times = null + helixfold3_precision = "bf16" + helixfold3_infer_times = 4 helixfold3_max_template_date = "2038-01-19" // Helixfold3 links diff --git a/nextflow_schema.json b/nextflow_schema.json index abcd8081f..9ab11bf04 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -295,8 +295,9 @@ "model_name": { "type": "string" }, - "preset": { - "type": "string" + "helixfold3_full_dbs": { + "type": "boolean", + "description": "If true uses the full version of the BFD database otherwise, otherwise it uses its reduced version, small bfd" }, "init_model": { "type": "string" @@ -304,15 +305,21 @@ "logging_level": { "type": "string" }, - "precision": { - "type": "string" + "helixfold3_precision": { + "type": "string", + "enum": ["bf16", "fp32"], + "description": "The numerical precision used by the HelixFold3 model." }, - "infer_times": { - "type": "string" + "helixfold3_infer_times": { + "type": "integer", + "default": 4, + "minimum": 1, + "description": "Number of independent predictions made with the HelixFold3 model" }, "helixfold3_max_template_date": { "type": "string", - "default": "2038-01-19" + "default": "2038-01-19", + "description": "No PDB template released after this date will be used to guide predictions." } } }, From 4a54108dc6c4639659d5452d8cf3ba7f0ef62eb2 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 13:02:38 +1000 Subject: [PATCH 086/150] Harmonize rfaa param names --- conf/dbs.config | 16 +++++----- main.nf | 16 +++++----- nextflow.config | 16 +++++----- nextflow_schema.json | 16 +++++----- .../local/prepare_rosettafold_all_atom_dbs.nf | 32 +++++++++---------- 5 files changed, 48 insertions(+), 48 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 46f2c91b7..5ccfc914b 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -87,16 +87,16 @@ params { ] // RoseTTAFold_All_Atom links - uniref30_rosettafold_all_atom_link = 'http://wwwuser.gwdg.de/~compbiol/uniclust/2020_06/UniRef30_2020_06_hhsuite.tar.gz' - pdb100_rosettafold_all_atom_link = 'https://files.ipd.uw.edu/pub/RoseTTAFold/pdb100_2021Mar03.tar.gz' - bfd_rosettafold_all_atom_link = 'https://bfd.mmseqs.com/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz' - rfaa_paper_weights_link = 'http://files.ipd.uw.edu/pub/RF-All-Atom/weights/RFAA_paper_weights.pt' + rosettafold_all_atom_uniref30_link = 'http://wwwuser.gwdg.de/~compbiol/uniclust/2020_06/UniRef30_2020_06_hhsuite.tar.gz' + rosettafold_all_atom_pdb100_link = 'https://files.ipd.uw.edu/pub/RoseTTAFold/pdb100_2021Mar03.tar.gz' + rosettafold_all_atom_bfd_link = 'https://bfd.mmseqs.com/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz' + rosettafold_all_atom_paper_weights_link = 'http://files.ipd.uw.edu/pub/RF-All-Atom/weights/RFAA_paper_weights.pt' // RoseTTAFold_All_Atom paths - uniref30_rosettafold_all_atom_path = "${params.rosettafold_all_atom_db}/uniref30/*" - pdb100_rosettafold_all_atom_path = "${params.rosettafold_all_atom_db}/pdb100/*" - bfd_rosettafold_all_atom_path = "${params.rosettafold_all_atom_db}/bfd/*" - rfaa_paper_weights_path = "${params.rosettafold_all_atom_db}/params/RFAA_paper_weights.pt" + rosettafold_all_atom_uniref30_path = "${params.rosettafold_all_atom_db}/uniref30/*" + rosettafold_all_atom_pdb100_path = "${params.rosettafold_all_atom_db}/pdb100/*" + rosettafold_all_atom_bfd_path = "${params.rosettafold_all_atom_db}/bfd/*" + rosettafold_all_atom_paper_weights_path = "${params.rosettafold_all_atom_db}/params/RFAA_paper_weights.pt" // Helixfold3 links helixfold3_uniclust30_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/uniclust30_2018_08_hhsuite.tar.gz' diff --git a/main.nf b/main.nf index b821dfa63..aa67a4936 100644 --- a/main.nf +++ b/main.nf @@ -323,14 +323,14 @@ workflow NFCORE_PROTEINFOLD { // PREPARE_ROSETTAFOLD_ALL_ATOM_DBS ( params.rosettafold_all_atom_db, - params.bfd_rosettafold_all_atom_path, - params.uniref30_rosettafold_all_atom_path, - params.pdb100_rosettafold_all_atom_path, - params.rfaa_paper_weights_path, - params.bfd_rosettafold_all_atom_link, - params.uniref30_rosettafold_all_atom_link, - params.pdb100_rosettafold_all_atom_link, - params.rfaa_paper_weights_link + params.rosettafold_all_atom_bfd_path, + params.rosettafold_all_atom_uniref30_path, + params.rosettafold_all_atom_pdb100_path, + params.rosettafold_all_atom_paper_weights_path, + params.rosettafold_all_atom_bfd_link, + params.rosettafold_all_atom_uniref30_link, + params.rosettafold_all_atom_pdb100_link, + params.rosettafold_all_atom_paper_weights_link ) ch_versions = ch_versions.mix(PREPARE_ROSETTAFOLD_ALL_ATOM_DBS.out.versions) diff --git a/nextflow.config b/nextflow.config index 231217268..6e0122b21 100644 --- a/nextflow.config +++ b/nextflow.config @@ -130,16 +130,16 @@ params { rosettafold_all_atom_db = null // RoseTTAFold_All_Atom links - uniref30_rosettafold_all_atom_link = null - pdb100_rosettafold_all_atom_link = null - bfd_rosettafold_all_atom_link = null - rfaa_paper_weights_link = null + rosettafold_all_atom_uniref30_link = null + rosettafold_all_atom_pdb100_link = null + rosettafold_all_atom_bfd_link = null + rosettafold_all_atom_paper_weights_link = null // RoseTTAFold_All_Atom paths - uniref30_rosettafold_all_atom_path = null - pdb100_rosettafold_all_atom_path = null - bfd_rosettafold_all_atom_path = null - rfaa_paper_weights_path = null + rosettafold_all_atom_uniref30_path = null + rosettafold_all_atom_pdb100_path = null + rosettafold_all_atom_bfd_path = null + rosettafold_all_atom_paper_weights_path = null // Helixfold3 parameters helixfold3_db = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 9ab11bf04..f7b61522d 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -939,19 +939,19 @@ "description": "Parameters used to provide the paths to the DBs and parameters for RoseTTAFold All Atom.", "default": "", "properties": { - "uniref30_rosettafold_all_atom_link": { + "rosettafold_all_atom_uniref30_link": { "type": "string", "default": "http://wwwuser.gwdg.de/~compbiol/uniclust/2020_06/UniRef30_2020_06_hhsuite.tar.gz" }, - "bfd_rosettafold_all_atom_link": { + "rosettafold_all_atom_bfd_link": { "type": "string", "default": "https://bfd.mmseqs.com/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz" }, - "pdb100_rosettafold_all_atom_link": { + "rosettafold_all_atom_pdb100_link": { "type": "string", "default": "https://files.ipd.uw.edu/pub/RoseTTAFold/pdb100_2021Mar03.tar.gz" }, - "rfaa_paper_weights_link": { + "rosettafold_all_atom_paper_weights_link": { "type": "string", "default": "http://files.ipd.uw.edu/pub/RF-All-Atom/weights/RFAA_paper_weights.pt" } @@ -966,19 +966,19 @@ "rosettafold_all_atom_db": { "type": "string" }, - "uniref30_rosettafold_all_atom_path": { + "rosettafold_all_atom_uniref30_path": { "type": "string", "default": "null/uniref30/*" }, - "bfd_rosettafold_all_atom_path": { + "rosettafold_all_atom_bfd_path": { "type": "string", "default": "null/bfd/*" }, - "pdb100_rosettafold_all_atom_path": { + "rosettafold_all_atom_pdb100_path": { "type": "string", "default": "null/pdb100/*" }, - "rfaa_paper_weights_path": { + "rosettafold_all_atom_paper_weights_path": { "type": "string", "default": "null/params/RFAA_paper_weights.pt" } diff --git a/subworkflows/local/prepare_rosettafold_all_atom_dbs.nf b/subworkflows/local/prepare_rosettafold_all_atom_dbs.nf index 341204ea2..77bfd11ec 100644 --- a/subworkflows/local/prepare_rosettafold_all_atom_dbs.nf +++ b/subworkflows/local/prepare_rosettafold_all_atom_dbs.nf @@ -16,38 +16,38 @@ workflow PREPARE_ROSETTAFOLD_ALL_ATOM_DBS { take: rosettafold_all_atom_db - bfd_rosettafold_all_atom_path // directory: /path/to/bfd/ - uniref30_rosettafold_all_atom_path // directory: /path/to/uniref30/rosettafold_all_atom/ - pdb100_rosettafold_all_atom_path - rfaa_paper_weights_path - bfd_rosettafold_all_atom_link - uniref30_rosettafold_all_atom_link - pdb100_rosettafold_all_atom_link - rfaa_paper_weights_link + rosettafold_all_atom_bfd_path // directory: /path/to/bfd/ + rosettafold_all_atom_uniref30_path // directory: /path/to/uniref30/rosettafold_all_atom/ + rosettafold_all_atom_pdb100_path + rosettafold_all_atom_paper_weights_path + rosettafold_all_atom_bfd_link + rosettafold_all_atom_uniref30_link + rosettafold_all_atom_pdb100_link + rosettafold_all_atom_paper_weights_link main: ch_versions = Channel.empty() if (rosettafold_all_atom_db) { - ch_bfd = Channel.value(file(bfd_rosettafold_all_atom_path)) - ch_uniref30 = Channel.value(file(uniref30_rosettafold_all_atom_path)) - ch_pdb100 = Channel.value(file(pdb100_rosettafold_all_atom_path)) - ch_rfaa_paper_weights = Channel.value(file(rfaa_paper_weights_path)) + ch_bfd = Channel.value(file(rosettafold_all_atom_bfd_path)) + ch_uniref30 = Channel.value(file(rosettafold_all_atom_uniref30_path)) + ch_pdb100 = Channel.value(file(rosettafold_all_atom_pdb100_path)) + ch_rfaa_paper_weights = Channel.value(file(rosettafold_all_atom_paper_weights_path)) } else { - ARIA2_BFD(bfd_rosettafold_all_atom_link) + ARIA2_BFD(rosettafold_all_atom_bfd_link) ch_bfd = ARIA2_BFD.out.db ch_versions = ch_versions.mix(ARIA2_BFD.out.versions) - ARIA2_UNIREF30(uniref30_rosettafold_all_atom_link) + ARIA2_UNIREF30(rosettafold_all_atom_uniref30_link) ch_uniref30 = ARIA2_UNIREF30.out.db ch_versions = ch_versions.mix(ARIA2_UNIREF30.out.versions) - ARIA2_PDB100(pdb100_rosettafold_all_atom_link) + ARIA2_PDB100(rosettafold_all_atom_pdb100_link) ch_pdb100 = ARIA2_PDB100.out.db ch_versions = ch_versions.mix(ARIA2_PDB100.out.versions) - ARIA2_WEIGHTS(rfaa_paper_weights_link) + ARIA2_WEIGHTS(rosettafold_all_atom_paper_weights_link) ch_rfaa_paper_weights = ARIA2_WEIGHTS.out.db ch_versions = ch_versions.mix(ARIA2_WEIGHTS.out.versions) } From 74bc301617a6a7acbc59b23d59b37ec626aa7fdf Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 4 Aug 2025 13:28:26 +1000 Subject: [PATCH 087/150] Removed alphafold2_mode from DBs download paths --- conf/modules.config | 2 +- conf/modules_alphafold2.config | 2 +- tests/alphafold2_download.nf.test.snap | 29 +++++++++++++------------- tests/colabfold_download.nf.test.snap | 7 +++---- tests/split_fasta.nf.test.snap | 4 ++-- 5 files changed, 21 insertions(+), 23 deletions(-) diff --git a/conf/modules.config b/conf/modules.config index c6b1078eb..05fad7044 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -30,7 +30,7 @@ process { withName: 'UNTAR' { ext.args2 = '--no-same-owner' publishDir = [ - path: {"${params.outdir}/DBs/${params.mode}/${params.alphafold2_mode}"}, + path: {"${params.outdir}/DBs/${params.mode}"}, mode: 'symlink', saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, ] diff --git a/conf/modules_alphafold2.config b/conf/modules_alphafold2.config index cf2060497..d69cbec67 100644 --- a/conf/modules_alphafold2.config +++ b/conf/modules_alphafold2.config @@ -17,7 +17,7 @@ process { withName: 'GUNZIP|COMBINE_UNIPROT|DOWNLOAD_PDBMMCIF|ARIA2_PDB_SEQRES' { publishDir = [ - path: {"${params.outdir}/DBs/alphafold2/${params.alphafold2_mode}"}, + path: {"${params.outdir}/DBs/alphafold2"}, mode: 'symlink', saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, ] diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index 6cebbda24..d816fedeb 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -22,19 +22,18 @@ [ "DBs", "DBs/alphafold2", - "DBs/alphafold2/standard", - "DBs/alphafold2/standard/UniRef30_2021_03", - "DBs/alphafold2/standard/alphafold_params_2022-12-06", - "DBs/alphafold2/standard/bfd-first_non_consensus_sequences.fasta", - "DBs/alphafold2/standard/mgy_clusters_2022_05.fa", - "DBs/alphafold2/standard/mmcif_files", - "DBs/alphafold2/standard/obsolete.dat", - "DBs/alphafold2/standard/pdb70_from_mmcif_200916", - "DBs/alphafold2/standard/pdb_seqres.txt", - "DBs/alphafold2/standard/uniprot.fasta", - "DBs/alphafold2/standard/uniprot_sprot.fasta", - "DBs/alphafold2/standard/uniprot_trembl.fasta", - "DBs/alphafold2/standard/uniref90.fasta", + "DBs/alphafold2/UniRef30_2021_03", + "DBs/alphafold2/alphafold_params_2022-12-06", + "DBs/alphafold2/bfd-first_non_consensus_sequences.fasta", + "DBs/alphafold2/mgy_clusters_2022_05.fa", + "DBs/alphafold2/mmcif_files", + "DBs/alphafold2/obsolete.dat", + "DBs/alphafold2/pdb70_from_mmcif_200916", + "DBs/alphafold2/pdb_seqres.txt", + "DBs/alphafold2/uniprot.fasta", + "DBs/alphafold2/uniprot_sprot.fasta", + "DBs/alphafold2/uniprot_trembl.fasta", + "DBs/alphafold2/uniref90.fasta", "multiqc", "multiqc/alphafold2_multiqc_data", "multiqc/alphafold2_multiqc_plots", @@ -68,8 +67,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:54:22.238418565" + "timestamp": "2025-08-04T13:20:28.422801993" } } \ No newline at end of file diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index 2d2f303ce..7d20ac9a7 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -20,8 +20,7 @@ [ "DBs", "DBs/colabfold", - "DBs/colabfold/standard", - "DBs/colabfold/standard/alphafold_params_2021-07-14", + "DBs/colabfold/alphafold_params_2021-07-14", "colabfold", "colabfold/webserver", "colabfold/webserver/T1024_colabfold.pdb", @@ -71,8 +70,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:54:46.721482885" + "timestamp": "2025-08-04T13:16:31.355330962" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index 036a189aa..21a1670b0 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -64,8 +64,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:55:26.47855323" + "timestamp": "2025-08-04T13:24:37.804124192" } } \ No newline at end of file From fd7fd9590ac0cd28f5ff73efc82a2bdbc33c01cf Mon Sep 17 00:00:00 2001 From: Tom Litfin Date: Sun, 3 Aug 2025 23:06:36 +1000 Subject: [PATCH 088/150] Remove un-needed boltz params --- conf/modules_boltz.config | 6 ++---- docs/usage.md | 2 -- nextflow.config | 3 --- nextflow_schema.json | 15 +-------------- 4 files changed, 3 insertions(+), 23 deletions(-) diff --git a/conf/modules_boltz.config b/conf/modules_boltz.config index 58ea2208f..4c2c6535e 100644 --- a/conf/modules_boltz.config +++ b/conf/modules_boltz.config @@ -13,13 +13,11 @@ process { withName: 'RUN_BOLTZ' { ext.args = [ - params.boltz_model ? "--model ${params.boltz_model}" : "", - params.boltz_out_dir ? "--out_dir ${params.boltz_out_dir}" : "", - params.boltz_output_format ? "--output_format ${params.boltz_output_format}" : "", + params.boltz_model ? "--model ${params.boltz_model}" : "", params.boltz_use_msa_server ? "--use_msa_server" : "", params.boltz_msa_server_url ? "--msa_server_url ${params.boltz_msa_server_url}" : "", params.boltz_use_potentials ? "--use_potentials" : "", - params.boltz_write_full_pae ? "--write_full_pae" : "", + "--write_full_pae", ].findAll{ it }.join(' ').trim() publishDir = [ diff --git a/docs/usage.md b/docs/usage.md index ac0b7040b..6ed761633 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -594,11 +594,9 @@ nextflow run nf-core/proteinfold \ | Parameter | Default | Description | | ------------------------ | ------- | --------------------------------------------------- | | `--boltz_model` | `null` | The model to use for prediction. Default is Boltz-2 | -| `--boltz_out_dir` | `null` | Output directory for Boltz predictions | | `--boltz_use_msa_server` | `null` | Use MSA server to generate MSAs (flag) | | `--boltz_msa_server_url` | `null` | MSA server URL | | `--boltz_use_potentials` | `null` | Use inference time potentials (flag) | -| `--boltz_write_full_pae` | `true` | Save the full PAE matrix as a file (flag) | > You can override any of these parameters via the command line or a params file. diff --git a/nextflow.config b/nextflow.config index 7cae73120..9f262596f 100644 --- a/nextflow.config +++ b/nextflow.config @@ -74,12 +74,9 @@ params { // Boltz parameters boltz_model = null - boltz_out_dir = null - boltz_output_format = 'pdb' boltz_use_msa_server = false boltz_msa_server_url = null boltz_use_potentials = false - boltz_write_full_pae = true // Boltz links boltz_ccd_link = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 512969ef0..66980da73 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -247,19 +247,12 @@ "description": "Use the cloud MSA server", "icon": "fas folder-open" }, - "boltz_out_dir": { - "type": "string" - }, "boltz_msa_server_url": { "type": "string" }, "boltz_use_potentials": { "type": "boolean" }, - "boltz_write_full_pae": { - "type": "boolean", - "default": true - }, "boltz_model": { "type": "string" } @@ -1190,11 +1183,5 @@ { "$ref": "#/$defs/helixfold3_dbs_and_parameters_link_options" } - ], - "properties": { - "boltz_output_format": { - "type": "string", - "default": "pdb" - } - } + ] } From e13a0fd74e783799307aaae6fbcda410a89f1796 Mon Sep 17 00:00:00 2001 From: Tom Litfin Date: Sun, 3 Aug 2025 23:19:08 +1000 Subject: [PATCH 089/150] Remove un-needed helixfold3 params --- conf/modules_helixfold3.config | 4 ++-- docs/usage.md | 2 -- nextflow.config | 2 -- nextflow_schema.json | 6 ------ 4 files changed, 2 insertions(+), 12 deletions(-) diff --git a/conf/modules_helixfold3.config b/conf/modules_helixfold3.config index 903955044..9ca6c2ac4 100644 --- a/conf/modules_helixfold3.config +++ b/conf/modules_helixfold3.config @@ -25,10 +25,10 @@ process { ext.args = [ params.helixfold3_max_template_date ? "--max_template_date=${params.helixfold3_max_template_date}" : "--max_template_date=2038-01-19", - params.model_name ? "--model_name ${params.model_name}" : "--model_name allatom_demo", + "--model_name allatom_demo", params.preset ? "--preset ${params.preset}" : "--preset 'reduced_dbs'", params.init_model ? "--init_model ${params.init_model}" : "--init_model './init_models/HelixFold3-240814.pdparams'", - params.logging_level ? "--logging_level ${params.logging_level}" : "--logging_level 'ERROR'", + "--logging_level 'ERROR'", params.precision ? "--precision ${params.precision}" : "--precision 'bf16'", params.infer_times ? "--infer_times ${params.infer_times}" : "--infer_times 4" ].join(' ').trim() diff --git a/docs/usage.md b/docs/usage.md index 6ed761633..aa4979ddb 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -391,10 +391,8 @@ nextflow run nf-core/proteinfold \ ```console ## Optional parameters with default values: --helixfold3_max_template_date=2038-01-19 - --model_name allatom_demo --preset 'reduced_dbs' --init_model './init_models/HelixFold3-240814.pdparams' - --logging_level 'ERROR' --precision 'bf16' --infer_times 4 ``` diff --git a/nextflow.config b/nextflow.config index 9f262596f..54bc7a805 100644 --- a/nextflow.config +++ b/nextflow.config @@ -142,10 +142,8 @@ params { // Helixfold3 parameters helixfold3_db = null - model_name = null preset = null init_model = null - logging_level = null precision = null infer_times = null helixfold3_max_template_date = "2038-01-19" diff --git a/nextflow_schema.json b/nextflow_schema.json index 66980da73..70067173d 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -295,18 +295,12 @@ "description": "HelixFold3 options", "default": "", "properties": { - "model_name": { - "type": "string" - }, "preset": { "type": "string" }, "init_model": { "type": "string" }, - "logging_level": { - "type": "string" - }, "precision": { "type": "string" }, From 1d278fd9ca91f22345aa7636811a30e2da0087f2 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 4 Aug 2025 11:48:53 +1000 Subject: [PATCH 090/150] HF3 init_model from init_model_path --- CHANGELOG.md | 1 + conf/modules_helixfold3.config | 1 - docs/usage.md | 1 - modules/local/run_helixfold3/main.nf | 6 +++++- nextflow.config | 1 - nextflow_schema.json | 3 --- 6 files changed, 6 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4681657bb..cf6bfc5db 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -51,6 +51,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #333](https://github.com/nf-core/proteinfold/pull/333)] - Updates the RFAA dockerfile for better versioning and smaller image size. - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). - [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). +- [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. ### Parameters diff --git a/conf/modules_helixfold3.config b/conf/modules_helixfold3.config index 9ca6c2ac4..13ddc8e71 100644 --- a/conf/modules_helixfold3.config +++ b/conf/modules_helixfold3.config @@ -27,7 +27,6 @@ process { params.helixfold3_max_template_date ? "--max_template_date=${params.helixfold3_max_template_date}" : "--max_template_date=2038-01-19", "--model_name allatom_demo", params.preset ? "--preset ${params.preset}" : "--preset 'reduced_dbs'", - params.init_model ? "--init_model ${params.init_model}" : "--init_model './init_models/HelixFold3-240814.pdparams'", "--logging_level 'ERROR'", params.precision ? "--precision ${params.precision}" : "--precision 'bf16'", params.infer_times ? "--infer_times ${params.infer_times}" : "--infer_times 4" diff --git a/docs/usage.md b/docs/usage.md index aa4979ddb..31a61818b 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -392,7 +392,6 @@ nextflow run nf-core/proteinfold \ ## Optional parameters with default values: --helixfold3_max_template_date=2038-01-19 --preset 'reduced_dbs' - --init_model './init_models/HelixFold3-240814.pdparams' --precision 'bf16' --infer_times 4 ``` diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index ef148e9c7..d0e7bb2fa 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -46,6 +46,8 @@ process RUN_HELIXFOLD3 { } def args = task.ext.args ?: '' """ + init_model_path=\$(ls ./init_models/*.pdparams | head -n 1) + mamba run --name helixfold python3.9 /app/helixfold3/inference.py \\ --maxit_binary "./maxit_src/bin/maxit" \\ --jackhmmer_binary_path "jackhmmer" \\ @@ -67,7 +69,9 @@ process RUN_HELIXFOLD3 { --uniref90_database_path "./uniref90/uniref90.fasta" \\ --mgnify_database_path "./mgnify/mgy_clusters.fa" \\ --input_json="${fasta}" \\ - --output_dir="\$PWD" $args + --output_dir="\$PWD" \\ + --init_model "\$init_model_path" \\ + $args cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.pdb" "./${meta.id}_helixfold3.pdb" cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.cif" "./${meta.id}_helixfold3.cif" diff --git a/nextflow.config b/nextflow.config index 54bc7a805..a2ad75fad 100644 --- a/nextflow.config +++ b/nextflow.config @@ -143,7 +143,6 @@ params { // Helixfold3 parameters helixfold3_db = null preset = null - init_model = null precision = null infer_times = null helixfold3_max_template_date = "2038-01-19" diff --git a/nextflow_schema.json b/nextflow_schema.json index 70067173d..dcbef8278 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -298,9 +298,6 @@ "preset": { "type": "string" }, - "init_model": { - "type": "string" - }, "precision": { "type": "string" }, From c8b0c97dd10817c20a9d346ff9d7bb1289ac03e2 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 4 Aug 2025 14:56:55 +1000 Subject: [PATCH 091/150] Updated CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index cf6bfc5db..d1cfba076 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -52,6 +52,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). - [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. +- [[PR #357](https://github.com/nf-core/proteinfold/pull/357)] - Update ColabFold module and image. ### Parameters From b8bdb1fcab184fc8efe14d14e8233400adddaac7 Mon Sep 17 00:00:00 2001 From: jscgh Date: Mon, 4 Aug 2025 15:11:01 +1000 Subject: [PATCH 092/150] Updated snapshots --- tests/colabfold_download.nf.test.snap | 6 +++--- tests/colabfold_local.nf.test.snap | 10 ++++++---- tests/colabfold_webserver.nf.test.snap | 6 +++--- tests/default.nf.test.snap | 4 ++-- tests/split_fasta.nf.test.snap | 10 ++++++---- 5 files changed, 20 insertions(+), 16 deletions(-) diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index 2d2f303ce..bd989ad62 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -7,7 +7,7 @@ "aria2": null }, "COLABFOLD_BATCH": { - "colabfold_batch": "1.5.2" + "colabfold_batch": null }, "GENERATE_REPORT": { "python": "3.12.7", @@ -71,8 +71,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:54:46.721482885" + "timestamp": "2025-08-04T15:03:02.615959389" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index 244e729a9..69ae284a0 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -4,14 +4,16 @@ 7, { "COLABFOLD_BATCH": { - "colabfold_batch": "1.5.2" + "colabfold_batch": null }, "GENERATE_REPORT": { "python": "3.12.7", "generate_report.py": "Python 3.12.7" }, "MMSEQS_COLABFOLDSEARCH": { - "colabfold_search": "1.5.2" + "colabfold_search": null, + "alphafold_colabfold": null, + "mmseqs": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -64,8 +66,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:54:54.686425178" + "timestamp": "2025-08-04T15:03:13.281594692" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index e80a04359..52f3e7310 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -4,7 +4,7 @@ 5, { "COLABFOLD_BATCH": { - "colabfold_batch": "1.5.2" + "colabfold_batch": null }, "GENERATE_REPORT": { "python": "3.12.7", @@ -61,8 +61,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:55:02.279523773" + "timestamp": "2025-08-04T15:03:22.469274618" } } \ No newline at end of file diff --git a/tests/default.nf.test.snap b/tests/default.nf.test.snap index 7dfd6b659..315be886e 100644 --- a/tests/default.nf.test.snap +++ b/tests/default.nf.test.snap @@ -92,8 +92,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:55:10.198238805" + "timestamp": "2025-08-04T15:08:38.134028321" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index 036a189aa..e3086af8b 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -4,14 +4,16 @@ 7, { "COLABFOLD_BATCH": { - "colabfold_batch": "1.5.2" + "colabfold_batch": null }, "GENERATE_REPORT": { "python": "3.12.7", "generate_report.py": "Python 3.12.7" }, "MMSEQS_COLABFOLDSEARCH": { - "colabfold_search": "1.5.2" + "colabfold_search": null, + "alphafold_colabfold": null, + "mmseqs": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -64,8 +66,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:55:26.47855323" + "timestamp": "2025-08-04T15:03:51.792622381" } } \ No newline at end of file From 8f2b6ceef46591d1903ac16627631f0bb9936ebd Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 13:30:47 +1000 Subject: [PATCH 093/150] Harmonize colabfold param names --- conf/dbs.config | 2 +- conf/modules_colabfold.config | 8 ++--- main.nf | 8 ++--- nextflow.config | 20 ++++++------ nextflow_schema.json | 36 ++++++++++----------- subworkflows/local/prepare_colabfold_dbs.nf | 8 ++--- 6 files changed, 41 insertions(+), 41 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 5ccfc914b..ae54029b4 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -76,7 +76,7 @@ params { colabfold_uniref30_link = 'https://wwwuser.gwdg.de/~compbiol/colabfold/uniref30_2302.tar.gz' // Colabfold paths - colabfold_db_path = "${params.colabfold_db}/colabfold_envdb/*" + colabfold_envdb_path = "${params.colabfold_db}/colabfold_envdb/*" colabfold_uniref30_path = "${params.colabfold_db}/colabfold_uniref30/*" // Are all these params options needed? colabfold_alphafold2_params_tags = [ diff --git a/conf/modules_colabfold.config b/conf/modules_colabfold.config index a7ece8721..f0bbda83f 100644 --- a/conf/modules_colabfold.config +++ b/conf/modules_colabfold.config @@ -24,9 +24,9 @@ process { process { withName: 'COLABFOLD_BATCH' { ext.args = [ - params.use_gpu ? '--use-gpu-relax' : '', - params.use_amber ? '--amber' : '', - params.use_templates ? '--templates' : '', + params.use_gpu ? '--use-gpu-relax' : '', + params.colabfold_use_amber ? '--amber' : '', + params.colabfold_use_templates ? '--templates' : '', params.use_msa_server && params.msa_server_url ? "--host-url ${params.msa_server_url}" : '' ].join(' ').trim() publishDir = [ @@ -60,7 +60,7 @@ process { ] } withName: 'MMSEQS_COLABFOLDSEARCH' { - ext.args = { params.db_load_mode ? "--db-load-mode ${params.db_load_mode}" : '' } + ext.args = { params.colabfold_db_load_mode ? "--db-load-mode ${params.colabfold_db_load_mode}" : '' } publishDir = [ enabled: false ] diff --git a/main.nf b/main.nf index aa67a4936..739e108f0 100644 --- a/main.nf +++ b/main.nf @@ -241,12 +241,12 @@ workflow NFCORE_PROTEINFOLD { params.colabfold_db, params.use_msa_server, params.colabfold_alphafold2_params_path, - params.colabfold_db_path, + params.colabfold_envdb_path, params.colabfold_uniref30_path, params.colabfold_alphafold2_params_link, params.colabfold_db_link, params.colabfold_uniref30_link, - params.create_colabfold_index + params.colabfold_create_index ) ch_versions = ch_versions.mix(PREPARE_COLABFOLD_DBS.out.versions) @@ -260,7 +260,7 @@ workflow NFCORE_PROTEINFOLD { PREPARE_COLABFOLD_DBS.out.params, PREPARE_COLABFOLD_DBS.out.colabfold_db, PREPARE_COLABFOLD_DBS.out.uniref30, - params.num_recycles_colabfold + params.colabfold_num_recycles ) ch_multiqc = ch_multiqc.mix(COLABFOLD.out.multiqc_report) @@ -449,7 +449,7 @@ workflow NFCORE_PROTEINFOLD { params.colabfold_db, params.use_msa_server, params.colabfold_alphafold2_params_path, - params.colabfold_db_path, + params.colabfold_envdb_path, params.colabfold_uniref30_path, params.colabfold_alphafold2_params_link, params.colabfold_db_link, diff --git a/nextflow.config b/nextflow.config index 6e0122b21..9b1a25599 100644 --- a/nextflow.config +++ b/nextflow.config @@ -15,6 +15,8 @@ params { use_gpu = false split_fasta = false db = null + use_msa_server = false + msa_server_url = null // Alphafold2 parameters alphafold2_mode = "standard" @@ -95,22 +97,20 @@ params { boltz2_mols_path = null // Colabfold parameters - use_msa_server = false - colabfold_model_preset = "alphafold2_ptm" // {'alphafold2_ptm', 'alphafold2_multimer_v1', 'alphafold2_multimer_v2', 'alphafold2_multimer_v3'} - num_recycles_colabfold = 3 - use_amber = true - colabfold_db = null - db_load_mode = 0 - msa_server_url = null - use_templates = true - create_colabfold_index = false + colabfold_model_preset = "alphafold2_ptm" // {'alphafold2_ptm', 'alphafold2_multimer_v1', 'alphafold2_multimer_v2', 'alphafold2_multimer_v3'} + colabfold_num_recycles = 3 + colabfold_use_amber = true + colabfold_db = null + colabfold_db_load_mode = 0 + colabfold_use_templates = true + colabfold_create_index = false // Colabfold links colabfold_db_link = null colabfold_uniref30_link = null // Colabfold paths - colabfold_db_path = null + colabfold_envdb_path = null colabfold_uniref30_path = null // Esmfold parameters diff --git a/nextflow_schema.json b/nextflow_schema.json index f7b61522d..41d732f6d 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -76,6 +76,18 @@ "description": "UniRef major release", "enum": ["UniRef30_2023_02", "UniRef30_2022_02", "UniRef30_2021_03"], "fa_icon": "fas fa-database" + }, + "use_msa_server": { + "type": "boolean", + "description": "Use the cloud MSA server", + "icon": "fas folder-open" + }, + "msa_server_url": { + "type": "string", + "description": "Specify your custom MMSeqs2 API server url", + "fa_icon": "fas fa-link", + "format": "uri", + "errorMessage": "Please provide a valid URL for the MMSeqs2 API server" } } }, @@ -151,11 +163,6 @@ "fa_icon": "fas fa-coins", "description": "ColabFold options.", "properties": { - "use_msa_server": { - "type": "boolean", - "description": "Use the cloud MSA server", - "icon": "fas folder-open" - }, "colabfold_model_preset": { "type": "string", "default": "alphafold2_ptm", @@ -168,7 +175,7 @@ ], "fa_icon": "fas fa-stream" }, - "num_recycles_colabfold": { + "colabfold_num_recycles": { "type": "integer", "default": 3, "description": "Number of recycles for ColabFold", @@ -177,33 +184,26 @@ "maximum": 20, "errorMessage": "Number of recycles must be a whole number between 1 and 20" }, - "use_amber": { + "colabfold_use_amber": { "type": "boolean", "default": true, "description": "Use Amber minimization to refine the predicted structures", "fa_icon": "fas fa-compress-alt" }, - "db_load_mode": { + "colabfold_db_load_mode": { "type": "integer", "description": "Specify the way that MMSeqs2 will load the required databases in memory", "fa_icon": "fas fa-download", "enum": [0, 1, 2, 3], "errorMessage": "DB load mode must be 0, 1, 2, or 3" }, - "msa_server_url": { - "type": "string", - "description": "Specify your custom MMSeqs2 API server url", - "fa_icon": "fas fa-link", - "format": "uri", - "errorMessage": "Please provide a valid URL for the MMSeqs2 API server" - }, - "use_templates": { + "colabfold_use_templates": { "type": "boolean", "default": true, "description": "Use PDB templates", "fa_icon": "fas fa-paste" }, - "create_colabfold_index": { + "colabfold_create_index": { "type": "boolean", "description": "Create databases indexes when running colabfold_local mode", "fa_icon": "fas fa-bezier-curve" @@ -684,7 +684,7 @@ "fa_icon": "fas fa-folder-open", "errorMessage": "Please provide a valid path to ColabFold database" }, - "colabfold_db_path": { + "colabfold_envdb_path": { "type": "string", "description": "Link to the ColabFold database", "fa_icon": "fas fa-folder-open", diff --git a/subworkflows/local/prepare_colabfold_dbs.nf b/subworkflows/local/prepare_colabfold_dbs.nf index 370a7080c..7e01e94c5 100644 --- a/subworkflows/local/prepare_colabfold_dbs.nf +++ b/subworkflows/local/prepare_colabfold_dbs.nf @@ -16,12 +16,12 @@ workflow PREPARE_COLABFOLD_DBS { colabfold_db // directory: path/to/colabfold/DBs and params use_msa_server // bool: Specifies whether to use web msa server colabfold_alphafold2_params_path // directory: /path/to/colabfold/alphafold2/params/ - colabfold_db_path // directory: /path/to/colabfold/db/ + colabfold_envdb_path // directory: /path/to/colabfold/db/ colabfold_uniref30_path // directory: /path/to/uniref30/colabfold/ colabfold_alphafold2_params_link // string: Specifies the link to download colabfold alphafold2 params colabfold_db_link // string: Specifies the link to download colabfold db colabfold_uniref30_link // string: Specifies the link to download uniref30 - create_colabfold_index // boolean: Create index for colabfold db + colabfold_create_index // boolean: Create index for colabfold db main: ch_params = Channel.empty() @@ -32,7 +32,7 @@ workflow PREPARE_COLABFOLD_DBS { if (colabfold_db) { ch_params = Channel.value(file(colabfold_alphafold2_params_path, type: 'any')) if (!use_msa_server) { - ch_colabfold_db = Channel.value(file(colabfold_db_path, type: 'any')) + ch_colabfold_db = Channel.value(file(colabfold_envdb_path, type: 'any')) ch_uniref30 = Channel.value(file(colabfold_uniref30_path, type: 'any')) } } @@ -74,7 +74,7 @@ workflow PREPARE_COLABFOLD_DBS { ch_uniref30 = MMSEQS_TSV2EXPROFILEDB_UNIPROT30.out.db_exprofile ch_versions = ch_versions.mix(MMSEQS_TSV2EXPROFILEDB_UNIPROT30.out.versions) - if (create_colabfold_index) { + if (colabfold_create_index) { MMSEQS_CREATEINDEX_UNIPROT30 ( MMSEQS_TSV2EXPROFILEDB_UNIPROT30.out.db_exprofile ) From 341bec66ecc7ada3714a120666f4d4c256f213b3 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 13:37:37 +1000 Subject: [PATCH 094/150] Harmonize esmfold param names --- main.nf | 2 +- nextflow.config | 2 +- nextflow_schema.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/main.nf b/main.nf index 739e108f0..3ca0faf27 100644 --- a/main.nf +++ b/main.nf @@ -305,7 +305,7 @@ workflow NFCORE_PROTEINFOLD { ch_samplesheet, ch_versions, PREPARE_ESMFOLD_DBS.out.params, - params.num_recycles_esmfold + params.esmfold_num_recycles ) ch_multiqc = ch_multiqc.mix(ESMFOLD.out.multiqc_report.collect()) diff --git a/nextflow.config b/nextflow.config index 9b1a25599..7baaee746 100644 --- a/nextflow.config +++ b/nextflow.config @@ -116,7 +116,7 @@ params { // Esmfold parameters esmfold_db = null esmfold_model_preset = "monomer" - num_recycles_esmfold = 4 + esmfold_num_recycles = 4 // Esmfold links esmfold_3B_v1 = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 41d732f6d..9b62b790e 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -216,7 +216,7 @@ "fa_icon": "fas fa-coins", "description": "ESMFold options.", "properties": { - "num_recycles_esmfold": { + "esmfold_num_recycles": { "type": "integer", "default": 4, "description": "Specifies the number of recycles used by ESMFold", From 676108445d5b94961c1c01f24dac11a6d7507ef7 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 15:06:53 +1000 Subject: [PATCH 095/150] Harmonize alphafold2 param names --- conf/modules_alphafold2.config | 6 +++--- main.nf | 4 ++-- nextflow.config | 12 ++++++------ nextflow_schema.json | 9 +++++---- subworkflows/local/prepare_alphafold2_dbs.nf | 6 +++--- workflows/alphafold2.nf | 6 +++--- 6 files changed, 22 insertions(+), 21 deletions(-) diff --git a/conf/modules_alphafold2.config b/conf/modules_alphafold2.config index cf2060497..146bcd7eb 100644 --- a/conf/modules_alphafold2.config +++ b/conf/modules_alphafold2.config @@ -36,8 +36,8 @@ process { accelerator = params.use_gpu? 1 : 0 ext.args = [ params.use_gpu ? '--use_gpu_relax=true' : '--use_gpu_relax=false', - params.max_template_date ? "--max_template_date ${params.max_template_date}" : '', - params.random_seed ? "--random_seed=${params.random_seed}" : '' + params.alphafold2_max_template_date ? "--max_template_date ${params.alphafold2_max_template_date}" : '', + params.alphafold2_random_seed ? "--random_seed=${params.alphafold2_random_seed}" : '' ].join(' ').trim() publishDir = [ [ @@ -64,7 +64,7 @@ process { process { withName: 'RUN_ALPHAFOLD2_MSA' { - ext.args = params.max_template_date ? "--max_template_date ${params.max_template_date}" : '' + ext.args = params.alphafold2_max_template_date ? "--max_template_date ${params.alphafold2_max_template_date}" : '' publishDir = [ path: { "${params.outdir}/alphafold2/${params.alphafold2_mode}" }, mode: 'copy', diff --git a/main.nf b/main.nf index 3ca0faf27..63b3cc2ce 100644 --- a/main.nf +++ b/main.nf @@ -97,7 +97,7 @@ workflow NFCORE_PROTEINFOLD { // PREPARE_ALPHAFOLD2_DBS ( params.alphafold2_db, - params.full_dbs, + params.alphafold2_full_dbs, params.bfd_path, params.alphafold2_small_bfd_path, params.alphafold2_params_path, @@ -130,7 +130,7 @@ workflow NFCORE_PROTEINFOLD { ALPHAFOLD2 ( ch_samplesheet, ch_versions, - params.full_dbs, + params.alphafold2_full_dbs, params.alphafold2_mode, params.alphafold2_model_preset, PREPARE_ALPHAFOLD2_DBS.out.params, diff --git a/nextflow.config b/nextflow.config index 7baaee746..8771b9370 100644 --- a/nextflow.config +++ b/nextflow.config @@ -19,12 +19,12 @@ params { msa_server_url = null // Alphafold2 parameters - alphafold2_mode = "standard" - max_template_date = "2038-01-19" - full_dbs = false // true full_dbs, false reduced_dbs - alphafold2_model_preset = "monomer" // for AF2 {monomer (default), monomer_casp14, monomer_ptm, multimer} - alphafold2_db = null - random_seed = null + alphafold2_mode = "standard" + alphafold2_max_template_date = "2038-01-19" + alphafold2_full_dbs = false // true full_dbs, false reduced_dbs + alphafold2_model_preset = "monomer" // for AF2 {monomer (default), monomer_casp14, monomer_ptm, multimer} + alphafold2_db = null + alphafold2_random_seed = null // Alphafold2 links bfd_link = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 9b62b790e..b41d89427 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -97,7 +97,7 @@ "fa_icon": "fas fa-dna", "description": "AlphaFold2 options.", "properties": { - "max_template_date": { + "alphafold2_max_template_date": { "type": "string", "default": "2038-01-19", "description": "Maximum date of the PDB templates used by 'AlphaFold2' mode", @@ -105,7 +105,7 @@ "pattern": "^\\d{4}-\\d{2}-\\d{2}$", "errorMessage": "Date must be in YYYY-MM-DD format" }, - "full_dbs": { + "alphafold2_full_dbs": { "type": "boolean", "description": "If true uses the full version of the BFD database otherwise, otherwise it uses its reduced version, small bfd", "fa_icon": "fas fa-battery-full" @@ -124,8 +124,9 @@ "enum": ["monomer", "monomer_casp14", "monomer_ptm", "multimer"], "fa_icon": "fas fa-stream" }, - "random_seed": { - "type": "string" + "alphafold2_random_seed": { + "type": "string", + "description": "Random seed to control stochastic alphafold inference." }, "alphafold2_params_prefix": { "type": "string", diff --git a/subworkflows/local/prepare_alphafold2_dbs.nf b/subworkflows/local/prepare_alphafold2_dbs.nf index f28cb1268..cf4ebbbce 100644 --- a/subworkflows/local/prepare_alphafold2_dbs.nf +++ b/subworkflows/local/prepare_alphafold2_dbs.nf @@ -23,7 +23,7 @@ workflow PREPARE_ALPHAFOLD2_DBS { take: alphafold2_db // directory: path to alphafold2 DBs - full_dbs // boolean: Use full databases (otherwise reduced version) + alphafold2_full_dbs // boolean: Use full databases (otherwise reduced version) bfd_path // directory: /path/to/bfd/ small_bfd_path // directory: /path/to/small_bfd/ alphafold2_params_path // directory: /path/to/alphafold2/params/ @@ -55,7 +55,7 @@ workflow PREPARE_ALPHAFOLD2_DBS { if (alphafold2_db) { - if (full_dbs) { + if (alphafold2_full_dbs) { ch_bfd = Channel.value(file(bfd_path)) ch_small_bfd = Channel.value(file("${projectDir}/assets/dummy_db")) } @@ -75,7 +75,7 @@ workflow PREPARE_ALPHAFOLD2_DBS { ch_uniprot = Channel.value(file(uniprot_path)) } else { - if (full_dbs) { + if (alphafold2_full_dbs) { ARIA2_BFD( bfd_link ) diff --git a/workflows/alphafold2.nf b/workflows/alphafold2.nf index d070b6581..74f163ac1 100644 --- a/workflows/alphafold2.nf +++ b/workflows/alphafold2.nf @@ -28,7 +28,7 @@ workflow ALPHAFOLD2 { take: ch_samplesheet // channel: samplesheet read in from --input ch_versions // channel: [ path(versions.yml) ] - full_dbs // boolean: Use full databases (otherwise reduced version) + alphafold2_full_dbs // boolean: Use full databases (otherwise reduced version) alphafold2_mode // string: Mode to run Alphafold2 in alphafold2_model_preset // string: Specifies the model preset to use for Alphafold2 ch_alphafold2_params // channel: path(alphafold2_params) @@ -66,7 +66,7 @@ workflow ALPHAFOLD2 { // RUN_ALPHAFOLD2 ( ch_samplesheet, - full_dbs, + alphafold2_full_dbs, alphafold2_model_preset, ch_alphafold2_params, ch_bfd, @@ -100,7 +100,7 @@ workflow ALPHAFOLD2 { // RUN_ALPHAFOLD2_MSA ( ch_samplesheet, - full_dbs, + alphafold2_full_dbs, alphafold2_model_preset, ch_alphafold2_params, ch_bfd, From 10083ba94dd42afca6ddcebd6d4efd5171f64bd7 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 15:13:13 +1000 Subject: [PATCH 096/150] Harmonize alphafold3 param names --- nextflow_schema.json | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index b41d89427..a516f647d 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -142,22 +142,6 @@ } } }, - "alphafold3_options": { - "title": "Alphafold3 options", - "type": "object", - "fa_icon": "fas fa-dna", - "description": "Alphafold3 options.", - "properties": { - "alphafold3_db": { - "type": "string", - "format": "path", - "exists": true, - "description": "Specifies the DB and PARAMS path used by 'AlphaFold3' mode", - "fa_icon": "fas fa-database", - "errorMessage": "Please provide a valid path to AlphaFold3 database" - } - } - }, "colabfold_options": { "title": "ColabFold options", "type": "object", @@ -558,6 +542,14 @@ "fa_icon": "fas fa-database", "description": "Parameters used to provide the links to the DBs and parameters public resources to Alphafold3.", "properties": { + "alphafold3_db": { + "type": "string", + "format": "path", + "exists": true, + "description": "Specifies the DB and PARAMS path used by 'AlphaFold3' mode", + "fa_icon": "fas fa-database", + "errorMessage": "Please provide a valid path to AlphaFold3 database" + }, "alphafold3_small_bfd_link": { "type": "string", "default": "https://storage.googleapis.com/alphafold-databases/v3.0/bfd-first_non_consensus_sequences.fasta.zst", @@ -1119,9 +1111,6 @@ { "$ref": "#/$defs/alphafold2_options" }, - { - "$ref": "#/$defs/alphafold3_options" - }, { "$ref": "#/$defs/colabfold_options" }, From 4139449557aae8e0bad4ad12a450d4d0224b6392 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Mon, 4 Aug 2025 16:22:10 +1000 Subject: [PATCH 097/150] fix linting --- ro-crate-metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ro-crate-metadata.json b/ro-crate-metadata.json index 92fbf5df1..9980ec684 100644 --- a/ro-crate-metadata.json +++ b/ro-crate-metadata.json @@ -23,7 +23,7 @@ "@type": "Dataset", "creativeWorkStatus": "InProgress", "datePublished": "2025-07-08T11:39:36+00:00", - "description": "

\n \n \n \"nf-core/proteinfold\"\n \n

\n\n[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.13135393-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.13135393)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.10.5-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.2-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.2)\n[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/proteinfold)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23proteinfold-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/proteinfold)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/proteinfold** is a bioinformatics best-practice analysis pipeline for Protein 3D structure prediction.\n\nThe pipeline is built using [Nextflow](https://www.nextflow.io), a workflow tool to run tasks across multiple compute infrastructures in a very portable manner. It uses Docker/Singularity containers making installation trivial and results highly reproducible. The [Nextflow DSL2](https://www.nextflow.io/docs/latest/dsl2.html) implementation of this pipeline uses one container per process which makes it much easier to maintain and update software dependencies. Where possible, these processes have been submitted to and installed from [nf-core/modules](https://github.com/nf-core/modules) in order to make them available to all nf-core pipelines, and to everyone within the Nextflow community!\n\nOn release, automated continuous integration tests run the pipeline on a full-sized dataset on the AWS cloud infrastructure. This ensures that the pipeline runs on AWS, has sensible resource allocation defaults set to run on real-world datasets, and permits the persistent storage of results to benchmark between pipeline releases and other analysis sources. The results obtained from the full-sized test can be viewed on the [nf-core website](https://nf-co.re/proteinfold/results).\n\n## Pipeline summary\n\n![Alt text](docs/images/nf-core-proteinfold_metro_map_1.1.0.png?raw=true \"nf-core-proteinfold 1.1.0 metro map\")\n\n1. Choice of protein structure prediction method:\n\n i. [AlphaFold2](https://github.com/deepmind/alphafold) - Regular AlphaFold2 (MSA computation and model inference in the same process)\n\n ii. [AlphaFold2 split](https://github.com/luisas/alphafold_split) - AlphaFold2 MSA computation and model inference in separate processes\n\n iii. [AlphaFold3](https://github.com/deepmind/alphafold) - Regular AlphaFold3 (MSA computation and model inference in the same process)\n\n iv. [ColabFold](https://github.com/sokrypton/ColabFold) - MMseqs2 API server followed by ColabFold\n\n v. [ColabFold](https://github.com/sokrypton/ColabFold) - MMseqs2 local search followed by ColabFold\n\n vi. [ESMFold](https://github.com/facebookresearch/esm) - Regular ESM\n\n vii. [RoseTTAFold-All-Atom](https://github.com/baker-laboratory/RoseTTAFold-All-Atom/) - Regular RFAA\n\n viii. [HelixFold3](https://github.com/PaddlePaddle/PaddleHelix/tree/dev/apps/protein_folding/helixfold3) - Regular HF3\n\n ix. [Boltz](https://github.com/jwohlwend/boltz/) - Regular Boltz-1\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) with `-profile test` before running the workflow on actual data.\n\nNow, you can run the pipeline using:\n\n```bash\nnextflow run nf-core/proteinfold \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \n```\n\nThe pipeline takes care of downloading the databases and parameters required by AlphaFold2, Colabfold, ESMFold or RoseTTAFold-All-Atom. In case you have already downloaded the required files, you can skip this step by providing the path to the databases using the corresponding parameter [`--alphafold2_db`], [`--colabfold_db`], [`--esmfold_db`] or ['--rosettafold_all_atom_db']. Please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) to check the directory structure you must provide for each database.\n\n- The typical command to run AlphaFold2 mode is shown below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold2 \\\n --alphafold2_db \\\n --full_dbs \\\n --alphafold2_model_preset monomer \\\n --use_gpu \\\n -profile \n ```\n\n- Here is the command to run AlphaFold2 splitting the MSA from the prediction execution:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold2 \\\n --alphafold2_mode split_msa_prediction \\\n --alphafold2_db \\\n --full_dbs \\\n --alphafold2_model_preset monomer \\\n --use_gpu \\\n -profile \n ```\n\n- The AlphaFold3 mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold3 \\\n --alphafold3_db \\\n --use_gpu \\\n -profile \n ```\n\n > [!WARNING]\n > The AlphaFold3 weights are not provided by this pipeline. Users must obtain the weights directly from DeepMind according to their [terms of use](https://github.com/deepmind/alphafold/blob/main/WEIGHTS_TERMS_OF_USE.md) and [prohibited use policy](https://github.com/deepmind/alphafold/blob/main/WEIGHTS_PROHIBITED_USE_POLICY.md). Please ensure you comply with all terms and conditions before using AlphaFold3. For more information about AlphaFold3 usage and requirements, please refer to the [official AlphaFold3 repository](https://github.com/deepmind/alphafold).\n\n- Below, the command to run colabfold_local mode:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode colabfold \\\n --colabfold_server local \\\n --colabfold_db \\\n --num_recycles_colabfold 3 \\\n --use_amber \\\n --colabfold_model_preset \"alphafold2_ptm\" \\\n --use_gpu \\\n --db_load_mode 0\n -profile \n ```\n\n- The typical command to run colabfold_webserver mode would be:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode colabfold \\\n --colabfold_server webserver \\\n --host_url \\\n --colabfold_db \\\n --num_recycles_colabfold 3 \\\n --use_amber \\\n --colabfold_model_preset \"alphafold2_ptm\" \\\n --use_gpu \\\n -profile \n ```\n\n [!WARNING]\n\n > If you aim to carry out a large amount of predictions using the colabfold_webserver mode, please setup and use your own custom MMSeqs2 API Server. You can find instructions [here](https://github.com/sokrypton/ColabFold/tree/main/MsaServer).\n\n- The esmfold mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode esmfold \\\n --esmfold_model_preset \\\n --esmfold_db \\\n --num_recycles_esmfold 4 \\\n --use_gpu \\\n -profile \n ```\n\n- The rosettafold_all_atom mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode rosettafold_all_atom \\\n --rosettafold_all_atom_db \\\n --use_gpu \\\n -profile \n ```\n\n- The helixfold3 mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode helixfold3 \\\n --helixfold3_db \\\n --use_gpu \\\n -profile \n ```\n\n- The boltz mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode boltz \\\n --boltz_ccd_path \\\n --boltz_model_path \\\n --use_gpu \\\n -profile \n ```\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) and the [parameter documentation](https://nf-co.re/proteinfold/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/proteinfold/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/proteinfold/output).\n\n## Credits\n\nnf-core/proteinfold was originally written by Athanasios Baltzis ([@athbaltzis](https://github.com/athbaltzis)), Jose Espinosa-Carrasco ([@JoseEspinosa](https://github.com/JoseEspinosa)), Luisa Santus ([@luisas](https://github.com/luisas)) and Leila Mansouri ([@l-mansouri](https://github.com/l-mansouri)) from [The Comparative Bioinformatics Group](https://www.crg.eu/en/cedric_notredame) at [The Centre for Genomic Regulation, Spain](https://www.crg.eu/) under the umbrella of the [BovReg project](https://www.bovreg.eu/) and Harshil Patel ([@drpatelh](https://github.com/drpatelh)) from [Seqera Labs, Spain](https://seqera.io/).\n\nMany thanks to others who have helped out and contributed along the way too, including (but not limited to): Norman Goodacre and Waleed Osman from Interline Therapeutics ([@interlinetx](https://github.com/interlinetx)), Martin Steinegger ([@martin-steinegger](https://github.com/martin-steinegger)) and Raoul J.P. Bonnal ([@rjpbonnal](https://github.com/rjpbonnal))\n\nWe would also like to thanks to the AWS Open Data Sponsorship Program for generously providing the resources necessary to host the data utilized in the testing, development, and deployment of nf-core proteinfold.\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#proteinfold` channel](https://nfcore.slack.com/channels/proteinfold) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\nIf you use nf-core/proteinfold for your analysis, please cite it using the following doi: [10.5281/zenodo.7437038](https://doi.org/10.5281/zenodo.7437038)\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", + "description": "

\n \n \n \"nf-core/proteinfold\"\n \n

\n\n[![GitHub Actions CI Status](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/nf-test.yml)\n[![GitHub Actions Linting Status](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml/badge.svg)](https://github.com/nf-core/proteinfold/actions/workflows/linting.yml)[![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/proteinfold/results)[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.13135393-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.13135393)\n\n[![Nextflow](https://img.shields.io/badge/version-%E2%89%A524.10.5-green?style=flat&logo=nextflow&logoColor=white&color=%230DC09D&link=https%3A%2F%2Fnextflow.io)](https://www.nextflow.io/)\n[![nf-core template version](https://img.shields.io/badge/nf--core_template-3.3.2-green?style=flat&logo=nfcore&logoColor=white&color=%2324B064&link=https%3A%2F%2Fnf-co.re)](https://github.com/nf-core/tools/releases/tag/3.3.2)\n[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/)\n[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/)\n[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/)\n[![Launch on Seqera Platform](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Seqera%20Platform-%234256e7)](https://cloud.seqera.io/launch?pipeline=https://github.com/nf-core/proteinfold)\n\n[![Get help on Slack](http://img.shields.io/badge/slack-nf--core%20%23proteinfold-4A154B?labelColor=000000&logo=slack)](https://nfcore.slack.com/channels/proteinfold)[![Follow on Bluesky](https://img.shields.io/badge/bluesky-%40nf__core-1185fe?labelColor=000000&logo=bluesky)](https://bsky.app/profile/nf-co.re)[![Follow on Mastodon](https://img.shields.io/badge/mastodon-nf__core-6364ff?labelColor=FFFFFF&logo=mastodon)](https://mstdn.science/@nf_core)[![Watch on YouTube](http://img.shields.io/badge/youtube-nf--core-FF0000?labelColor=000000&logo=youtube)](https://www.youtube.com/c/nf-core)\n\n## Introduction\n\n**nf-core/proteinfold** is a bioinformatics best-practice analysis pipeline for Protein 3D structure prediction.\n\nThe pipeline is built using [Nextflow](https://www.nextflow.io), a workflow tool to run tasks across multiple compute infrastructures in a very portable manner. It uses Docker/Singularity containers making installation trivial and results highly reproducible. The [Nextflow DSL2](https://www.nextflow.io/docs/latest/dsl2.html) implementation of this pipeline uses one container per process which makes it much easier to maintain and update software dependencies. Where possible, these processes have been submitted to and installed from [nf-core/modules](https://github.com/nf-core/modules) in order to make them available to all nf-core pipelines, and to everyone within the Nextflow community!\n\nOn release, automated continuous integration tests run the pipeline on a full-sized dataset on the AWS cloud infrastructure. This ensures that the pipeline runs on AWS, has sensible resource allocation defaults set to run on real-world datasets, and permits the persistent storage of results to benchmark between pipeline releases and other analysis sources. The results obtained from the full-sized test can be viewed on the [nf-core website](https://nf-co.re/proteinfold/results).\n\n## Pipeline summary\n\n![Alt text](docs/images/nf-core-proteinfold_metro_map_1.1.0.png?raw=true \"nf-core-proteinfold 1.1.0 metro map\")\n\n1. Choice of protein structure prediction method:\n\n i. [AlphaFold2](https://github.com/deepmind/alphafold) - Regular AlphaFold2 (MSA computation and model inference in the same process)\n\n ii. [AlphaFold2 split](https://github.com/luisas/alphafold_split) - AlphaFold2 MSA computation and model inference in separate processes\n\n iii. [AlphaFold3](https://github.com/deepmind/alphafold) - Regular AlphaFold3 (MSA computation and model inference in the same process)\n\n iv. [ColabFold](https://github.com/sokrypton/ColabFold) - MMseqs2 API server followed by ColabFold\n\n v. [ColabFold](https://github.com/sokrypton/ColabFold) - MMseqs2 local search followed by ColabFold\n\n vi. [ESMFold](https://github.com/facebookresearch/esm) - Regular ESM\n\n vii. [RoseTTAFold-All-Atom](https://github.com/baker-laboratory/RoseTTAFold-All-Atom/) - Regular RFAA\n\n viii. [HelixFold3](https://github.com/PaddlePaddle/PaddleHelix/tree/dev/apps/protein_folding/helixfold3) - Regular HF3\n\n ix. [Boltz](https://github.com/jwohlwend/boltz/) - Regular Boltz-1\n\n## Usage\n\n> [!NOTE]\n> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) with `-profile test` before running the workflow on actual data.\n\nNow, you can run the pipeline using:\n\n```bash\nnextflow run nf-core/proteinfold \\\n -profile \\\n --input samplesheet.csv \\\n --outdir \n```\n\nThe pipeline takes care of downloading the databases and parameters required by AlphaFold2, Colabfold, ESMFold or RoseTTAFold-All-Atom. In case you have already downloaded the required files, you can skip this step by providing the path to the databases using the corresponding parameter [`--alphafold2_db`], [`--colabfold_db`], [`--esmfold_db`] or ['--rosettafold_all_atom_db']. Please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) to check the directory structure you must provide for each database.\n\n- The typical command to run AlphaFold2 mode is shown below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold2 \\\n --alphafold2_db \\\n --full_dbs \\\n --alphafold2_model_preset monomer \\\n --use_gpu \\\n -profile \n ```\n\n- Here is the command to run AlphaFold2 splitting the MSA from the prediction execution:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold2 \\\n --alphafold2_mode split_msa_prediction \\\n --alphafold2_db \\\n --full_dbs \\\n --alphafold2_model_preset monomer \\\n --use_gpu \\\n -profile \n ```\n\n- The AlphaFold3 mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode alphafold3 \\\n --alphafold3_db \\\n --use_gpu \\\n -profile \n ```\n\n > [!WARNING]\n > The AlphaFold3 weights are not provided by this pipeline. Users must obtain the weights directly from DeepMind according to their [terms of use](https://github.com/deepmind/alphafold/blob/main/WEIGHTS_TERMS_OF_USE.md) and [prohibited use policy](https://github.com/deepmind/alphafold/blob/main/WEIGHTS_PROHIBITED_USE_POLICY.md). Please ensure you comply with all terms and conditions before using AlphaFold3. For more information about AlphaFold3 usage and requirements, please refer to the [official AlphaFold3 repository](https://github.com/deepmind/alphafold).\n\n- Below, the command to run colabfold_local mode:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode colabfold \\\n --colabfold_db \\\n --num_recycles_colabfold 3 \\\n --use_amber \\\n --colabfold_model_preset \"alphafold2_ptm\" \\\n --use_gpu \\\n --db_load_mode 0\n -profile \n ```\n\n- The typical command to run colabfold_webserver mode would be:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode colabfold \\\n --use_msa_server \\\n --msa_server_url \\\n --colabfold_db \\\n --num_recycles_colabfold 3 \\\n --use_amber \\\n --colabfold_model_preset \"alphafold2_ptm\" \\\n --use_gpu \\\n -profile \n ```\n\n [!WARNING]\n\n > If you aim to carry out a large amount of predictions using the colabfold_webserver mode, please setup and use your own custom MMSeqs2 API Server. You can find instructions [here](https://github.com/sokrypton/ColabFold/tree/main/MsaServer).\n\n- The esmfold mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode esmfold \\\n --esmfold_model_preset \\\n --esmfold_db \\\n --num_recycles_esmfold 4 \\\n --use_gpu \\\n -profile \n ```\n\n- The rosettafold_all_atom mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode rosettafold_all_atom \\\n --rosettafold_all_atom_db \\\n --use_gpu \\\n -profile \n ```\n\n- The helixfold3 mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode helixfold3 \\\n --helixfold3_db \\\n --use_gpu \\\n -profile \n ```\n\n- The boltz mode can be run using the command below:\n\n ```console\n nextflow run nf-core/proteinfold \\\n --input samplesheet.csv \\\n --outdir \\\n --mode boltz \\\n --boltz_ccd_path \\\n --boltz_model_path \\\n --use_gpu \\\n -profile \n ```\n\n> [!WARNING]\n> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; see [docs](https://nf-co.re/docs/usage/getting_started/configuration#custom-configuration-files).\n\nFor more details and further functionality, please refer to the [usage documentation](https://nf-co.re/proteinfold/usage) and the [parameter documentation](https://nf-co.re/proteinfold/parameters).\n\n## Pipeline output\n\nTo see the results of an example test run with a full size dataset refer to the [results](https://nf-co.re/proteinfold/results) tab on the nf-core website pipeline page.\nFor more details about the output files and reports, please refer to the\n[output documentation](https://nf-co.re/proteinfold/output).\n\n## Credits\n\nnf-core/proteinfold was originally written by Athanasios Baltzis ([@athbaltzis](https://github.com/athbaltzis)), Jose Espinosa-Carrasco ([@JoseEspinosa](https://github.com/JoseEspinosa)), Luisa Santus ([@luisas](https://github.com/luisas)) and Leila Mansouri ([@l-mansouri](https://github.com/l-mansouri)) from [The Comparative Bioinformatics Group](https://www.crg.eu/en/cedric_notredame) at [The Centre for Genomic Regulation, Spain](https://www.crg.eu/) under the umbrella of the [BovReg project](https://www.bovreg.eu/) and Harshil Patel ([@drpatelh](https://github.com/drpatelh)) from [Seqera Labs, Spain](https://seqera.io/).\n\nMany thanks to others who have helped out and contributed along the way too, including (but not limited to): Norman Goodacre and Waleed Osman from Interline Therapeutics ([@interlinetx](https://github.com/interlinetx)), Martin Steinegger ([@martin-steinegger](https://github.com/martin-steinegger)) and Raoul J.P. Bonnal ([@rjpbonnal](https://github.com/rjpbonnal))\n\nWe would also like to thanks to the AWS Open Data Sponsorship Program for generously providing the resources necessary to host the data utilized in the testing, development, and deployment of nf-core proteinfold.\n\n## Contributions and Support\n\nIf you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md).\n\nFor further information or help, don't hesitate to get in touch on the [Slack `#proteinfold` channel](https://nfcore.slack.com/channels/proteinfold) (you can join with [this invite](https://nf-co.re/join/slack)).\n\n## Citations\n\nIf you use nf-core/proteinfold for your analysis, please cite it using the following doi: [10.5281/zenodo.7437038](https://doi.org/10.5281/zenodo.7437038)\n\nAn extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file.\n\nYou can cite the `nf-core` publication as follows:\n\n> **The nf-core framework for community-curated bioinformatics pipelines.**\n>\n> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.\n>\n> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).\n", "hasPart": [ { "@id": "main.nf" From 0112492c2792f07ebf52a0106cc8c3af7f812322 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 18:36:30 +0200 Subject: [PATCH 098/150] Add maxit binary link --- conf/dbs.config | 2 ++ 1 file changed, 2 insertions(+) diff --git a/conf/dbs.config b/conf/dbs.config index 46f2c91b7..cb9ad3259 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -109,9 +109,11 @@ params { helixfold3_uniprot_trembl_link = 'ftp://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_trembl.fasta.gz' helixfold3_pdb_seqres_link = 'https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt' helixfold3_uniref90_link = 'ftp://ftp.uniprot.org/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz' + // TODO should be updated to 2022_05 as in alphafold2? helixfold3_mgnify_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/mgy_clusters_2018_12.fa.gz' helixfold3_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' helixfold3_obsolete_link = 'https://files.rcsb.org/pub/pdb/data/status/obsolete.dat' + helixfold3_maxit_src_link = 'https://proteinfold-dataset.s3.amazonaws.com/test-data/db/helixfold3/maxit-v11.200-prod-src.tar.gz' // Helixfold3 paths helixfold3_uniclust30_path = "${params.helixfold3_db}/uniref30/*" From 494901eaecc1f739536f6898ff383b4422e4330f Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 18:37:14 +0200 Subject: [PATCH 099/150] Update paths so that modules run when data is downloaded using "PREPARE" subworkflows --- modules/local/run_alphafold2/main.nf | 2 +- modules/local/run_helixfold3/main.nf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/local/run_alphafold2/main.nf b/modules/local/run_alphafold2/main.nf index 4c453d088..7137d6117 100644 --- a/modules/local/run_alphafold2/main.nf +++ b/modules/local/run_alphafold2/main.nf @@ -67,7 +67,7 @@ process RUN_ALPHAFOLD2 { --output_dir=\$PWD \ --data_dir=\$PWD \ --uniref90_database_path=./uniref90/uniref90.fasta \ - --mgnify_database_path=./mgnify/mgy_clusters.fa \ + --mgnify_database_path=./mgnify/mgy_clusters_2022_05.fa \ --template_mmcif_dir=./mmcif_files \ --obsolete_pdbs_path=./obsolete_pdb/obsolete.dat \ $args diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index d0e7bb2fa..b79a4f09f 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -67,7 +67,7 @@ process RUN_HELIXFOLD3 { --obsolete_pdbs_path="./obsolete.dat" \\ --ccd_preprocessed_path="./ccd_preprocessed_etkdg.pkl.gz" \\ --uniref90_database_path "./uniref90/uniref90.fasta" \\ - --mgnify_database_path "./mgnify/mgy_clusters.fa" \\ + --mgnify_database_path "./mgnify/mgy_clusters_2018_12.fa" \\ --input_json="${fasta}" \\ --output_dir="\$PWD" \\ --init_model "\$init_model_path" \\ From 0b44231e427167c737d46f24a7216111adb59744 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 18:42:06 +0200 Subject: [PATCH 100/150] Add alphafold3 to logic to set the same parent path for all dbs --- nextflow.config | 2 ++ 1 file changed, 2 insertions(+) diff --git a/nextflow.config b/nextflow.config index a2ad75fad..c8374286a 100644 --- a/nextflow.config +++ b/nextflow.config @@ -501,6 +501,8 @@ validation { if (params.mode.toLowerCase().split(",").contains("alphafold2")) { params.alphafold2_db = params.alphafold2_db ?: params.db } +if (params.mode.toLowerCase().split(",").contains("alphafold3")) + { params.alphafold3_db = params.alphafold3_db ?: params.db } if (params.mode.toLowerCase().split(",").contains("colabfold")) { params.colabfold_db = params.colabfold_db ?: params.db } if (params.mode.toLowerCase().split(",").contains("esmfold")) From 5e3ba47edcb19a810ce715b2b0b355fa8b143901 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 18:47:35 +0200 Subject: [PATCH 101/150] Make possible to both read "pdb70" and "pdb70/pdb70_from_mmcif_200916" (if path not modified after downloading) --- conf/dbs.config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/dbs.config b/conf/dbs.config index cb9ad3259..e18c3ea44 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -32,7 +32,7 @@ params { alphafold2_small_bfd_path = "${params.alphafold2_db}/small_bfd/*" alphafold2_params_path = "${params.alphafold2_db}/params/${params.alphafold2_params_prefix}/*" alphafold2_mgnify_path = "${params.alphafold2_db}/mgnify/*" - pdb70_path = "${params.alphafold2_db}/pdb70/*" + pdb70_path = "${params.alphafold2_db}/pdb70/**" alphafold2_pdb_mmcif_path = "${params.alphafold2_db}/pdb_mmcif/mmcif_files" pdb_obsolete_path = "${params.alphafold2_db}/pdb_mmcif/obsolete.dat" alphafold2_uniref30_path = "${params.alphafold2_db}/uniref30/*" From 7a9f36303eaab23ebc8126dd21a0a2483d3ce6b4 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 22:31:27 +0200 Subject: [PATCH 102/150] Revert change, will commit with helixfold3 changes --- conf/dbs.config | 1 - 1 file changed, 1 deletion(-) diff --git a/conf/dbs.config b/conf/dbs.config index e18c3ea44..3938a6963 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -113,7 +113,6 @@ params { helixfold3_mgnify_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/mgy_clusters_2018_12.fa.gz' helixfold3_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' helixfold3_obsolete_link = 'https://files.rcsb.org/pub/pdb/data/status/obsolete.dat' - helixfold3_maxit_src_link = 'https://proteinfold-dataset.s3.amazonaws.com/test-data/db/helixfold3/maxit-v11.200-prod-src.tar.gz' // Helixfold3 paths helixfold3_uniclust30_path = "${params.helixfold3_db}/uniref30/*" From 5ea83ef4f4ed5d0d6c5be5433f18ed57943fd800 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 22:36:25 +0200 Subject: [PATCH 103/150] Update changelog --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index cf6bfc5db..19df379e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -52,6 +52,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). - [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. +- [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. +- [[PR #360](https://github.com/nf-core/proteinfold/pull/360)] - Rename some DBs paths in the run modules so they are equal to those when DBs are downloaded. + ### Parameters From 9d6e74d464d0bac709edaa9bb0c4744575366465 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 22:50:27 +0200 Subject: [PATCH 104/150] Also left for helixfold3 changes --- modules/nf-core/unzip/environment.yml | 7 -- modules/nf-core/unzip/main.nf | 49 ------------ modules/nf-core/unzip/meta.yml | 50 ------------ modules/nf-core/unzip/tests/main.nf.test | 54 ------------- modules/nf-core/unzip/tests/main.nf.test.snap | 76 ------------------- 5 files changed, 236 deletions(-) delete mode 100644 modules/nf-core/unzip/environment.yml delete mode 100644 modules/nf-core/unzip/main.nf delete mode 100644 modules/nf-core/unzip/meta.yml delete mode 100644 modules/nf-core/unzip/tests/main.nf.test delete mode 100644 modules/nf-core/unzip/tests/main.nf.test.snap diff --git a/modules/nf-core/unzip/environment.yml b/modules/nf-core/unzip/environment.yml deleted file mode 100644 index 246158953..000000000 --- a/modules/nf-core/unzip/environment.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json -channels: - - conda-forge - - bioconda -dependencies: - - conda-forge::p7zip=16.02 diff --git a/modules/nf-core/unzip/main.nf b/modules/nf-core/unzip/main.nf deleted file mode 100644 index a0c02109c..000000000 --- a/modules/nf-core/unzip/main.nf +++ /dev/null @@ -1,49 +0,0 @@ -process UNZIP { - tag "$archive" - label 'process_single' - - conda "${moduleDir}/environment.yml" - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/p7zip:16.02' : - 'biocontainers/p7zip:16.02' }" - - input: - tuple val(meta), path(archive) - - output: - tuple val(meta), path("${prefix}/"), emit: unzipped_archive - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - if ( archive instanceof List && archive.name.size > 1 ) { error "[UNZIP] error: 7za only accepts a single archive as input. Please check module input." } - prefix = task.ext.prefix ?: ( meta.id ? "${meta.id}" : archive.baseName) - """ - 7za \\ - x \\ - -o"${prefix}"/ \\ - $args \\ - $archive - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - 7za: \$(echo \$(7za --help) | sed 's/.*p7zip Version //; s/(.*//') - END_VERSIONS - """ - - stub: - def args = task.ext.args ?: '' - if ( archive instanceof List && archive.name.size > 1 ) { error "[UNZIP] error: 7za only accepts a single archive as input. Please check module input." } - prefix = task.ext.prefix ?: ( meta.id ? "${meta.id}" : archive.baseName) - """ - mkdir "${prefix}" - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - 7za: \$(echo \$(7za --help) | sed 's/.*p7zip Version //; s/(.*//') - END_VERSIONS - """ -} diff --git a/modules/nf-core/unzip/meta.yml b/modules/nf-core/unzip/meta.yml deleted file mode 100644 index ba1eb9129..000000000 --- a/modules/nf-core/unzip/meta.yml +++ /dev/null @@ -1,50 +0,0 @@ -name: unzip -description: Unzip ZIP archive files -keywords: - - unzip - - decompression - - zip - - archiving -tools: - - unzip: - description: p7zip is a quick port of 7z.exe and 7za.exe (command line version - of 7zip, see www.7-zip.org) for Unix. - homepage: https://sourceforge.net/projects/p7zip/ - documentation: https://sourceforge.net/projects/p7zip/ - tool_dev_url: https://sourceforge.net/projects/p7zip" - licence: ["LGPL-2.1-or-later"] - identifier: "" -input: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - archive: - type: file - description: ZIP file - pattern: "*.zip" - ontologies: - - edam: http://edamontology.org/format_3987 # ZIP format -output: - unzipped_archive: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - ${prefix}/: - type: directory - description: Directory contents of the unzipped archive - pattern: "${archive.baseName}/" - versions: - - versions.yml: - type: file - description: File containing software versions - pattern: "versions.yml" - ontologies: - - edam: http://edamontology.org/format_3750 # YAML -authors: - - "@jfy133" -maintainers: - - "@jfy133" diff --git a/modules/nf-core/unzip/tests/main.nf.test b/modules/nf-core/unzip/tests/main.nf.test deleted file mode 100644 index 238b68d8b..000000000 --- a/modules/nf-core/unzip/tests/main.nf.test +++ /dev/null @@ -1,54 +0,0 @@ -nextflow_process { - - name "Test Process UNZIP" - script "../main.nf" - process "UNZIP" - - tag "modules" - tag "modules_nfcore" - tag "unzip" - - test("generic [tar] [tar_gz]") { - - when { - process { - """ - input[0] = [ - [ id: 'hello' ], - file(params.modules_testdata_base_path + 'generic/tar/hello.tar.gz', checkIfExists: true) - ] - """ - } - } - - then { - assertAll( - { assert process.success }, - { assert snapshot(process.out).match() } - ) - } - } - - test("generic [tar] [tar_gz] stub") { - - options "-stub" - - when { - process { - """ - input[0] = [ - [ id: 'hello' ], - file(params.modules_testdata_base_path + 'generic/tar/hello.tar.gz', checkIfExists: true) - ] - """ - } - } - - then { - assertAll( - { assert process.success }, - { assert snapshot(process.out).match() } - ) - } - } -} diff --git a/modules/nf-core/unzip/tests/main.nf.test.snap b/modules/nf-core/unzip/tests/main.nf.test.snap deleted file mode 100644 index cdd2ab164..000000000 --- a/modules/nf-core/unzip/tests/main.nf.test.snap +++ /dev/null @@ -1,76 +0,0 @@ -{ - "generic [tar] [tar_gz] stub": { - "content": [ - { - "0": [ - [ - { - "id": "hello" - }, - [ - - ] - ] - ], - "1": [ - "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" - ], - "unzipped_archive": [ - [ - { - "id": "hello" - }, - [ - - ] - ] - ], - "versions": [ - "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" - ] - } - ], - "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" - }, - "timestamp": "2024-06-30T19:16:37.11550986" - }, - "generic [tar] [tar_gz]": { - "content": [ - { - "0": [ - [ - { - "id": "hello" - }, - [ - "hello.tar:md5,80c66db79a773bc87b3346035ff9593e" - ] - ] - ], - "1": [ - "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" - ], - "unzipped_archive": [ - [ - { - "id": "hello" - }, - [ - "hello.tar:md5,80c66db79a773bc87b3346035ff9593e" - ] - ] - ], - "versions": [ - "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" - ] - } - ], - "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" - }, - "timestamp": "2024-06-30T19:16:25.120242571" - } -} \ No newline at end of file From d0f5faa94816175f32c34f24762641a9777337a5 Mon Sep 17 00:00:00 2001 From: Jose Espinosa-Carrasco Date: Mon, 4 Aug 2025 20:55:18 +0000 Subject: [PATCH 105/150] Make lint happy --- CHANGELOG.md | 1 - 1 file changed, 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 19df379e9..529ad8d2c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,7 +55,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. - [[PR #360](https://github.com/nf-core/proteinfold/pull/360)] - Rename some DBs paths in the run modules so they are equal to those when DBs are downloaded. - ### Parameters | Old parameter | New parameter | From ee0db8930123a77ff486c7ee2a8c422172adc299 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 23:01:28 +0200 Subject: [PATCH 106/150] Make nf-core lint happy --- nextflow_schema.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index dcbef8278..3fd114a19 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -498,7 +498,7 @@ "type": "string", "description": "Path to the PDB70 database", "fa_icon": "fas fa-folder-open", - "default": "null/pdb70/*" + "default": "null/pdb70/**" }, "alphafold2_pdb_mmcif_path": { "type": "string", From 6cd48682265cab4c6751788f9f4643070f1fd1ba Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 23:16:06 +0200 Subject: [PATCH 107/150] Add unzip modules --- modules.json | 5 ++ modules/nf-core/unzip/environment.yml | 7 ++ modules/nf-core/unzip/main.nf | 49 ++++++++++++ modules/nf-core/unzip/meta.yml | 50 ++++++++++++ modules/nf-core/unzip/tests/main.nf.test | 54 +++++++++++++ modules/nf-core/unzip/tests/main.nf.test.snap | 76 +++++++++++++++++++ 6 files changed, 241 insertions(+) create mode 100644 modules/nf-core/unzip/environment.yml create mode 100644 modules/nf-core/unzip/main.nf create mode 100644 modules/nf-core/unzip/meta.yml create mode 100644 modules/nf-core/unzip/tests/main.nf.test create mode 100644 modules/nf-core/unzip/tests/main.nf.test.snap diff --git a/modules.json b/modules.json index e9f8e89a3..326168768 100644 --- a/modules.json +++ b/modules.json @@ -43,6 +43,11 @@ "git_sha": "5caf7640a9ef1d18d765d55339be751bb0969dfa", "installed_by": ["modules"], "patch": "modules/nf-core/untar/untar.diff" + }, + "unzip": { + "branch": "master", + "git_sha": "41dfa3f7c0ffabb96a6a813fe321c6d1cc5b6e46", + "installed_by": ["modules"] } } }, diff --git a/modules/nf-core/unzip/environment.yml b/modules/nf-core/unzip/environment.yml new file mode 100644 index 000000000..246158953 --- /dev/null +++ b/modules/nf-core/unzip/environment.yml @@ -0,0 +1,7 @@ +--- +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json +channels: + - conda-forge + - bioconda +dependencies: + - conda-forge::p7zip=16.02 diff --git a/modules/nf-core/unzip/main.nf b/modules/nf-core/unzip/main.nf new file mode 100644 index 000000000..a0c02109c --- /dev/null +++ b/modules/nf-core/unzip/main.nf @@ -0,0 +1,49 @@ +process UNZIP { + tag "$archive" + label 'process_single' + + conda "${moduleDir}/environment.yml" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/p7zip:16.02' : + 'biocontainers/p7zip:16.02' }" + + input: + tuple val(meta), path(archive) + + output: + tuple val(meta), path("${prefix}/"), emit: unzipped_archive + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + if ( archive instanceof List && archive.name.size > 1 ) { error "[UNZIP] error: 7za only accepts a single archive as input. Please check module input." } + prefix = task.ext.prefix ?: ( meta.id ? "${meta.id}" : archive.baseName) + """ + 7za \\ + x \\ + -o"${prefix}"/ \\ + $args \\ + $archive + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + 7za: \$(echo \$(7za --help) | sed 's/.*p7zip Version //; s/(.*//') + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: '' + if ( archive instanceof List && archive.name.size > 1 ) { error "[UNZIP] error: 7za only accepts a single archive as input. Please check module input." } + prefix = task.ext.prefix ?: ( meta.id ? "${meta.id}" : archive.baseName) + """ + mkdir "${prefix}" + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + 7za: \$(echo \$(7za --help) | sed 's/.*p7zip Version //; s/(.*//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/unzip/meta.yml b/modules/nf-core/unzip/meta.yml new file mode 100644 index 000000000..ba1eb9129 --- /dev/null +++ b/modules/nf-core/unzip/meta.yml @@ -0,0 +1,50 @@ +name: unzip +description: Unzip ZIP archive files +keywords: + - unzip + - decompression + - zip + - archiving +tools: + - unzip: + description: p7zip is a quick port of 7z.exe and 7za.exe (command line version + of 7zip, see www.7-zip.org) for Unix. + homepage: https://sourceforge.net/projects/p7zip/ + documentation: https://sourceforge.net/projects/p7zip/ + tool_dev_url: https://sourceforge.net/projects/p7zip" + licence: ["LGPL-2.1-or-later"] + identifier: "" +input: + - - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - archive: + type: file + description: ZIP file + pattern: "*.zip" + ontologies: + - edam: http://edamontology.org/format_3987 # ZIP format +output: + unzipped_archive: + - - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - ${prefix}/: + type: directory + description: Directory contents of the unzipped archive + pattern: "${archive.baseName}/" + versions: + - versions.yml: + type: file + description: File containing software versions + pattern: "versions.yml" + ontologies: + - edam: http://edamontology.org/format_3750 # YAML +authors: + - "@jfy133" +maintainers: + - "@jfy133" diff --git a/modules/nf-core/unzip/tests/main.nf.test b/modules/nf-core/unzip/tests/main.nf.test new file mode 100644 index 000000000..238b68d8b --- /dev/null +++ b/modules/nf-core/unzip/tests/main.nf.test @@ -0,0 +1,54 @@ +nextflow_process { + + name "Test Process UNZIP" + script "../main.nf" + process "UNZIP" + + tag "modules" + tag "modules_nfcore" + tag "unzip" + + test("generic [tar] [tar_gz]") { + + when { + process { + """ + input[0] = [ + [ id: 'hello' ], + file(params.modules_testdata_base_path + 'generic/tar/hello.tar.gz', checkIfExists: true) + ] + """ + } + } + + then { + assertAll( + { assert process.success }, + { assert snapshot(process.out).match() } + ) + } + } + + test("generic [tar] [tar_gz] stub") { + + options "-stub" + + when { + process { + """ + input[0] = [ + [ id: 'hello' ], + file(params.modules_testdata_base_path + 'generic/tar/hello.tar.gz', checkIfExists: true) + ] + """ + } + } + + then { + assertAll( + { assert process.success }, + { assert snapshot(process.out).match() } + ) + } + } +} diff --git a/modules/nf-core/unzip/tests/main.nf.test.snap b/modules/nf-core/unzip/tests/main.nf.test.snap new file mode 100644 index 000000000..cdd2ab164 --- /dev/null +++ b/modules/nf-core/unzip/tests/main.nf.test.snap @@ -0,0 +1,76 @@ +{ + "generic [tar] [tar_gz] stub": { + "content": [ + { + "0": [ + [ + { + "id": "hello" + }, + [ + + ] + ] + ], + "1": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ], + "unzipped_archive": [ + [ + { + "id": "hello" + }, + [ + + ] + ] + ], + "versions": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ] + } + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.2" + }, + "timestamp": "2024-06-30T19:16:37.11550986" + }, + "generic [tar] [tar_gz]": { + "content": [ + { + "0": [ + [ + { + "id": "hello" + }, + [ + "hello.tar:md5,80c66db79a773bc87b3346035ff9593e" + ] + ] + ], + "1": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ], + "unzipped_archive": [ + [ + { + "id": "hello" + }, + [ + "hello.tar:md5,80c66db79a773bc87b3346035ff9593e" + ] + ] + ], + "versions": [ + "versions.yml:md5,52c55ce814e8bc9edc5a6c625ed794b8" + ] + } + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.2" + }, + "timestamp": "2024-06-30T19:16:25.120242571" + } +} \ No newline at end of file From 57d8dc58de62881602114407d2d0c471b5dee12d Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Mon, 4 Aug 2025 23:23:06 +0200 Subject: [PATCH 108/150] Add maxit binary for PREPARE_HELIXFOLD3 subworkflow --- conf/dbs.config | 1 + subworkflows/local/aria2_uncompress.nf | 19 ++++++++++++++++++- subworkflows/local/prepare_helixfold3_dbs.nf | 13 +++++++++---- 3 files changed, 28 insertions(+), 5 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 46f2c91b7..a61fe801f 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -112,6 +112,7 @@ params { helixfold3_mgnify_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/mgy_clusters_2018_12.fa.gz' helixfold3_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' helixfold3_obsolete_link = 'https://files.rcsb.org/pub/pdb/data/status/obsolete.dat' + helixfold3_maxit_src_link = 'https://proteinfold-dataset.s3.amazonaws.com/test-data/db/helixfold3/maxit-v11.200-prod-src.tar.gz' // Helixfold3 paths helixfold3_uniclust30_path = "${params.helixfold3_db}/uniref30/*" diff --git a/subworkflows/local/aria2_uncompress.nf b/subworkflows/local/aria2_uncompress.nf index 77eb8dea5..a2fc63c1d 100644 --- a/subworkflows/local/aria2_uncompress.nf +++ b/subworkflows/local/aria2_uncompress.nf @@ -4,6 +4,7 @@ include { UNTAR } from '../../modules/nf-core/untar/main' include { GUNZIP } from '../../modules/nf-core/gunzip/main' include { ARIA2 } from '../../modules/nf-core/aria2/main' +include { UNZIP } from '../../modules/nf-core/unzip/main' include { ZSTD_DECOMPRESS } from '../../modules/local/zstd_decompress/main.nf' workflow ARIA2_UNCOMPRESS { @@ -19,12 +20,28 @@ workflow ARIA2_UNCOMPRESS { ) ch_db = Channel.empty() - if (source_url.toString().endsWith('.tar') || source_url.toString().endsWith('.tar.gz') || source_url.toString().endsWith('.tar.zst')) { + if (source_url.toString().endsWith('.pkl.gz')) { + ch_db = ARIA2.out.downloaded_file.map { it[1] } + } else if (source_url.toString().endsWith('.tar') || source_url.toString().endsWith('.tar.gz') || source_url.toString().endsWith('.tar.zst')) { ch_db = UNTAR (ARIA2.out.downloaded_file).untar.map{ it[1] } } else if (source_url.toString().endsWith('.gz')) { ch_db = GUNZIP (ARIA2.out.downloaded_file).gunzip.map { it[1] } } else if (source_url.toString().endsWith('.zst')) { ch_db = ZSTD_DECOMPRESS (ARIA2.out.downloaded_file).decompressed.map { it[1] } + } else if (source_url.toString().endsWith('.zip')) { + ch_db = UNZIP (ARIA2.out.downloaded_file) + .unzipped_archive + //.map { it[1] } + .map { meta, dir -> + // Get the nested directory + def nestedDir = dir.listFiles()[0] + // Find the .pdparams file + def pdparamsFile = nestedDir.listFiles().find { it.getName().endsWith('.pdparams') } + [ pdparamsFile ] + } + ch_db.view() + } else { + ch_db = ARIA2.out.downloaded_file.map { it[1] } } emit: diff --git a/subworkflows/local/prepare_helixfold3_dbs.nf b/subworkflows/local/prepare_helixfold3_dbs.nf index b61fbb365..0179a7c4e 100644 --- a/subworkflows/local/prepare_helixfold3_dbs.nf +++ b/subworkflows/local/prepare_helixfold3_dbs.nf @@ -14,11 +14,12 @@ include { ARIA2_UNCOMPRESS as ARIA2_UNIREF90 ARIA2_UNCOMPRESS as ARIA2_MGNIFY ARIA2_UNCOMPRESS as ARIA2_INIT_MODELS + ARIA2_UNCOMPRESS as ARIA2_MAXIT } from './aria2_uncompress' include { ARIA2 as ARIA2_PDB_SEQRES } from '../../modules/nf-core/aria2/main' -include { COMBINE_UNIPROT } from '../../modules/local/combine_uniprot' -include { DOWNLOAD_PDBMMCIF } from '../../modules/local/download_pdbmmcif' +include { COMBINE_UNIPROT } from '../../modules/local/combine_uniprot' +include { DOWNLOAD_PDBMMCIF } from '../../modules/local/download_pdbmmcif' workflow PREPARE_HELIXFOLD3_DBS { @@ -37,6 +38,7 @@ workflow PREPARE_HELIXFOLD3_DBS { helixfold3_mgnify_link helixfold3_pdb_mmcif_link helixfold3_obsolete_link + helixfold3_maxit_src_link helixfold3_uniclust30_path helixfold3_ccd_preprocessed_path helixfold3_rfam_path @@ -100,7 +102,7 @@ workflow PREPARE_HELIXFOLD3_DBS { DOWNLOAD_PDBMMCIF( helixfold3_pdb_mmcif_link - ) + ) ch_helixfold3_mmcif_files = DOWNLOAD_PDBMMCIF.out.ch_db ch_versions = ch_versions.mix(DOWNLOAD_PDBMMCIF.out.versions) @@ -123,7 +125,6 @@ workflow PREPARE_HELIXFOLD3_DBS { ch_helixfold3_pdb_seqres = ARIA2_PDB_SEQRES.out.downloaded_file.map{ it[1] } ch_versions = ch_versions.mix(ARIA2_PDB_SEQRES.out.versions) - ARIA2_UNIPROT_SPROT( helixfold3_uniprot_sprot_link ) @@ -138,6 +139,10 @@ workflow PREPARE_HELIXFOLD3_DBS { ) ch_helixfold3_uniprot = COMBINE_UNIPROT.out.ch_db ch_versions = ch_versions.mix(COMBINE_UNIPROT.out.versions) + + ARIA2_MAXIT(helixfold3_maxit_src_link) + ch_helixfold3_maxit_src = ARIA2_MAXIT.out.db + ch_versions = ch_versions.mix(ARIA2_MAXIT.out.versions) } emit: From 8a3fb9be595390b755bb242c4aaebc3f5654741a Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 5 Aug 2025 11:19:48 +1000 Subject: [PATCH 109/150] Updated DB links with harmonised latest versions --- conf/dbs.config | 12 ++++++------ nextflow_schema.json | 12 ++++++------ tests/alphafold2_download.nf.test.snap | 12 ++++++------ 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/conf/dbs.config b/conf/dbs.config index 3938a6963..200008c1b 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -17,11 +17,11 @@ params { bfd_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz' alphafold2_small_bfd_link = 'https://storage.googleapis.com/alphafold-databases/reduced_dbs/bfd-first_non_consensus_sequences.fasta.gz' alphafold2_params_link = 'https://storage.googleapis.com/alphafold/alphafold_params_2022-12-06.tar' - alphafold2_mgnify_link = 'https://storage.googleapis.com/alphafold-databases/v2.3/mgy_clusters_2022_05.fa.gz' - pdb70_link = 'http://wwwuser.gwdg.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/old-releases/pdb70_from_mmcif_200916.tar.gz' + alphafold2_mgnify_link = 'https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz' + pdb70_link = 'https://wwwuser.gwdguser.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/pdb70_from_mmcif_220313.tar.gz' alphafold2_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' //Other sources available: 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' ftp.pdbj.org::ftp_data/structures/divided/mmCIF/ rsync.ebi.ac.uk::pub/databases/pdb/data/structures/divided/mmCIF/ pdb_obsolete_link = 'https://files.wwpdb.org/pub/pdb/data/status/obsolete.dat' - alphafold2_uniref30_link = 'https://storage.googleapis.com/alphafold-databases/v2.3/UniRef30_2021_03.tar.gz' + alphafold2_uniref30_link = 'https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz' alphafold2_uniref90_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz' alphafold2_pdb_seqres_link = 'https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt' uniprot_sprot_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz' @@ -87,7 +87,7 @@ params { ] // RoseTTAFold_All_Atom links - uniref30_rosettafold_all_atom_link = 'http://wwwuser.gwdg.de/~compbiol/uniclust/2020_06/UniRef30_2020_06_hhsuite.tar.gz' + uniref30_rosettafold_all_atom_link = 'https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz' pdb100_rosettafold_all_atom_link = 'https://files.ipd.uw.edu/pub/RoseTTAFold/pdb100_2021Mar03.tar.gz' bfd_rosettafold_all_atom_link = 'https://bfd.mmseqs.com/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz' rfaa_paper_weights_link = 'http://files.ipd.uw.edu/pub/RF-All-Atom/weights/RFAA_paper_weights.pt' @@ -99,7 +99,7 @@ params { rfaa_paper_weights_path = "${params.rosettafold_all_atom_db}/params/RFAA_paper_weights.pt" // Helixfold3 links - helixfold3_uniclust30_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/uniclust30_2018_08_hhsuite.tar.gz' + helixfold3_uniclust30_link = 'https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz' helixfold3_ccd_preprocessed_link = 'https://paddlehelix.bd.bcebos.com/HelixFold3/CCD/ccd_preprocessed_etkdg.pkl.gz' helixfold3_rfam_link = 'https://paddlehelix.bd.bcebos.com/HelixFold3/MSA/Rfam-14.9_rep_seq.fasta' helixfold3_init_models_link = 'https://paddlehelix.bd.bcebos.com/HelixFold3/params/HelixFold3-params-240814.zip' @@ -110,7 +110,7 @@ params { helixfold3_pdb_seqres_link = 'https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt' helixfold3_uniref90_link = 'ftp://ftp.uniprot.org/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz' // TODO should be updated to 2022_05 as in alphafold2? - helixfold3_mgnify_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/mgy_clusters_2018_12.fa.gz' + helixfold3_mgnify_link = 'https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz' helixfold3_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' helixfold3_obsolete_link = 'https://files.rcsb.org/pub/pdb/data/status/obsolete.dat' diff --git a/nextflow_schema.json b/nextflow_schema.json index 3fd114a19..3fe1c9ee2 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -402,13 +402,13 @@ }, "alphafold2_mgnify_link": { "type": "string", - "default": "https://storage.googleapis.com/alphafold-databases/v2.3/mgy_clusters_2022_05.fa.gz", + "default": "https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz", "description": "Link to the MGnify database", "fa_icon": "fas fa-link" }, "pdb70_link": { "type": "string", - "default": "http://wwwuser.gwdg.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/old-releases/pdb70_from_mmcif_200916.tar.gz", + "default": "https://wwwuser.gwdguser.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/pdb70_from_mmcif_220313.tar.gz", "description": "Link to the PDB70 database", "fa_icon": "fas fa-link" }, @@ -426,7 +426,7 @@ }, "alphafold2_uniref30_link": { "type": "string", - "default": "https://storage.googleapis.com/alphafold-databases/v2.3/UniRef30_2021_03.tar.gz", + "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz", "description": "Link to the Uniclust30 database", "fa_icon": "fas fa-link" }, @@ -928,7 +928,7 @@ "properties": { "uniref30_rosettafold_all_atom_link": { "type": "string", - "default": "http://wwwuser.gwdg.de/~compbiol/uniclust/2020_06/UniRef30_2020_06_hhsuite.tar.gz" + "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz" }, "bfd_rosettafold_all_atom_link": { "type": "string", @@ -1046,7 +1046,7 @@ }, "helixfold3_uniclust30_link": { "type": "string", - "default": "https://storage.googleapis.com/alphafold-databases/casp14_versions/uniclust30_2018_08_hhsuite.tar.gz" + "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz" }, "helixfold3_ccd_preprocessed_link": { "type": "string", @@ -1074,7 +1074,7 @@ }, "helixfold3_mgnify_link": { "type": "string", - "default": "https://storage.googleapis.com/alphafold-databases/casp14_versions/mgy_clusters_2018_12.fa.gz" + "default": "https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz" }, "helixfold3_pdb_mmcif_link": { "type": "string", diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index 6cebbda24..e9a4fad26 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -23,13 +23,13 @@ "DBs", "DBs/alphafold2", "DBs/alphafold2/standard", - "DBs/alphafold2/standard/UniRef30_2021_03", + "DBs/alphafold2/standard/UniRef30_2023_02_hhsuite", "DBs/alphafold2/standard/alphafold_params_2022-12-06", "DBs/alphafold2/standard/bfd-first_non_consensus_sequences.fasta", - "DBs/alphafold2/standard/mgy_clusters_2022_05.fa", + "DBs/alphafold2/standard/mgy_clusters.fa", "DBs/alphafold2/standard/mmcif_files", "DBs/alphafold2/standard/obsolete.dat", - "DBs/alphafold2/standard/pdb70_from_mmcif_200916", + "DBs/alphafold2/standard/pdb70_from_mmcif_220313", "DBs/alphafold2/standard/pdb_seqres.txt", "DBs/alphafold2/standard/uniprot.fasta", "DBs/alphafold2/standard/uniprot_sprot.fasta", @@ -50,7 +50,7 @@ "file.txt:md5,d41d8cd98f00b204e9800998ecf8427e" ], "bfd-first_non_consensus_sequences.fasta:md5,d41d8cd98f00b204e9800998ecf8427e", - "mgy_clusters_2022_05.fa:md5,d41d8cd98f00b204e9800998ecf8427e", + "mgy_clusters.fa:md5,d41d8cd98f00b204e9800998ecf8427e", [ ], @@ -68,8 +68,8 @@ ], "meta": { "nf-test": "0.9.2", - "nextflow": "24.10.5" + "nextflow": "25.04.6" }, - "timestamp": "2025-07-24T16:54:22.238418565" + "timestamp": "2025-08-05T11:15:15.449397416" } } \ No newline at end of file From d67a8aba47bd1afdc05eca6ffa41a32b7a30f49a Mon Sep 17 00:00:00 2001 From: jscgh Date: Tue, 5 Aug 2025 12:16:41 +1000 Subject: [PATCH 110/150] Handle mgnify_database_path dynamically by the input DB --- CHANGELOG.md | 1 - modules/local/run_alphafold2/main.nf | 3 ++- modules/local/run_helixfold3/main.nf | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 529ad8d2c..fe4430f15 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -52,7 +52,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). - [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. -- [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. - [[PR #360](https://github.com/nf-core/proteinfold/pull/360)] - Rename some DBs paths in the run modules so they are equal to those when DBs are downloaded. ### Parameters diff --git a/modules/local/run_alphafold2/main.nf b/modules/local/run_alphafold2/main.nf index 7137d6117..7c9ea2aef 100644 --- a/modules/local/run_alphafold2/main.nf +++ b/modules/local/run_alphafold2/main.nf @@ -60,6 +60,7 @@ process RUN_ALPHAFOLD2 { then sed -i "/^\\w*0/d" pdb_seqres/pdb_seqres.txt fi if [ -d params/alphafold_params_* ]; then ln -r -s params/alphafold_params_*/* params/; fi + mgnify_db_path=\$(ls -v ./mgnify/mgy_clusters*.fa | tail -n 1) python3 /app/alphafold/run_alphafold.py \ --fasta_paths=${fasta} \ --model_preset=${alphafold2_model_preset} \ @@ -67,7 +68,7 @@ process RUN_ALPHAFOLD2 { --output_dir=\$PWD \ --data_dir=\$PWD \ --uniref90_database_path=./uniref90/uniref90.fasta \ - --mgnify_database_path=./mgnify/mgy_clusters_2022_05.fa \ + --mgnify_database_path=\$mgnify_db_path \ --template_mmcif_dir=./mmcif_files \ --obsolete_pdbs_path=./obsolete_pdb/obsolete.dat \ $args diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index b79a4f09f..227cd7443 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -47,6 +47,7 @@ process RUN_HELIXFOLD3 { def args = task.ext.args ?: '' """ init_model_path=\$(ls ./init_models/*.pdparams | head -n 1) + mgnify_db_path=\$(ls -v ./mgnify/mgy_clusters*.fa | tail -n 1) mamba run --name helixfold python3.9 /app/helixfold3/inference.py \\ --maxit_binary "./maxit_src/bin/maxit" \\ @@ -67,7 +68,7 @@ process RUN_HELIXFOLD3 { --obsolete_pdbs_path="./obsolete.dat" \\ --ccd_preprocessed_path="./ccd_preprocessed_etkdg.pkl.gz" \\ --uniref90_database_path "./uniref90/uniref90.fasta" \\ - --mgnify_database_path "./mgnify/mgy_clusters_2018_12.fa" \\ + --mgnify_database_path "\$mgnify_db_path" \\ --input_json="${fasta}" \\ --output_dir="\$PWD" \\ --init_model "\$init_model_path" \\ From 6937e11db83ebdfb74bde5446265b8ded7b5b934 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 5 Aug 2025 14:47:13 +1000 Subject: [PATCH 111/150] Generates name_model_chain-wise_iptm.tsv for a single model for Boltz --- bin/extract_metrics.py | 67 ++++++++++++++++++++++++++++++------------ 1 file changed, 48 insertions(+), 19 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 7ba317a8e..88ad47026 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -6,6 +6,7 @@ #import torch moved to a conditional import since too bulky import if not used import numpy as np import csv +import string from utils import plddt_from_struct_b_factor # TODO: Issue #309, make into a poper separate process, it its own module so that dependencies can be managed better @@ -26,6 +27,7 @@ # TODO: Chain-wise iPTM since the relevant interface might not always be the average of all. # Would complete Issue #308 # Proposed format is pair-interfaces in rows, structure inference number in cols: https://github.com/nf-core/proteinfold/pull/312#issuecomment-2917709432 +# KR - changed to have both sides of the matrix, because it's not symmetrical (see comment in Issue #306) # Mapping of characters to integers for MSA parsing. # 20 is for unknown characters, and 21 is for gaps. @@ -62,7 +64,27 @@ def format_msa_rows(msa_data): def format_pae_rows(pae_data): return [[f"{num:.4f}" for num in row] for row in pae_data] -def chain_iptm_matrix_to_pairs(chain_iptm_data): +def format_iptm_rows(chain_pair_entries): + """ + Format iPTM data into a list of rows for writing to a TSV file. + Each row contains: the chain-pair in uppercase, e.g. "A:B", "B:A", A:C", etc. and then the iPTM value formatted to 4 decimal places. + """ + def idx_to_letter(idx): + """ Convert the index integer of the matrix to a letter representation that wraps to double representation, e.g. 0 -> A, 1 -> B, ..., 25 -> Z, 26 -> AA, 27 -> AB, etc. + This is somewhat compatible with how protein structure chain names are numbered by biochemists. + But we should move away from fixed-format PDB files -- we have nothing to lose but our chains.""" + result = "" + while idx >= 0: + result = string.ascii_uppercase[idx % 26] + result + idx = idx // 26 - 1 + if idx < 0: + break + return result + + return [[f"{idx_to_letter(idx[0])}:{idx_to_letter(idx[1])}", f"{val:.4f}"] for idx, val in chain_pair_entries] + + +def chain_iptm_matrix_to_pairs(iptm_matrix): """ Convert a chain-wise iPTM matrix to pair values by taking off-diagonal elements. """ @@ -70,17 +92,7 @@ def chain_iptm_matrix_to_pairs(chain_iptm_data): # 'chain_pair_iptm': An [num_chains, num_chains] array. # Off-diagonal element (i, j) of the array contains the ipTM restricted to tokens from chains i and j. # Diagonal element (i, i) contains the pTM restricted to chain i. - - # TODO: load the chain-wise iPTM matrix from a file into np matrix - - # TODO: turn the matrix into a list of pairs by taking off-diagonal elements - - # TODO: discard duplicates due to symmetry, e.g. (A,B) and (B,A) are the same pair - - # TODO: append the chain names in front of value, e.g. "A:B 0.85, A:C 0.90, A:D 0.80, B:C 0.75, B:D 0.70, C:D 0.65" - - # TODO: return the list of pairs as a string rows to be passed to write_tsv() to write to a metrics file - raise NotImplementedError("Chain-wise iPTM matrix to pairs conversion is not implemented yet.") + return [(idx, val) for idx, val in np.ndenumerate(iptm_matrix) if idx[0] != idx[1]] def write_tsv(file_path, rows): with open(file_path, 'w') as out_f: @@ -178,6 +190,7 @@ def read_csv(name, csv_files): def read_json(name, json_files): ptm_data = {} iptm_data = {} + chain_pair_iptm_data = {} # For iPTM data to be converted into formatted pairs with non-self elements for idx, json_file in enumerate(json_files): with open(json_file, 'r') as f: data = json.load(f) @@ -214,13 +227,29 @@ def read_json(name, json_files): # f.write(f"{np.round(data['iptm'],3)}\n") ptm_data[model_id] = f"{np.round(data['ptm'],3)}\n" iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" - if ptm_data: - with open(f"{name}_ptm.tsv", 'w') as f: - for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): - f.write(f"{k} {v}") - with open(f"{name}_iptm.tsv", 'w') as f: - for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): - f.write(f"{k} {v}") + + if ptm_data: + with open(f"{name}_ptm.tsv", 'w') as f: + for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): + f.write(f"{k} {v}") + if iptm_data: + with open(f"{name}_iptm.tsv", 'w') as f: + for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): + f.write(f"{k} {v}") + + if 'chain_pair_iptm' not in data.keys() and 'pair_chains_iptm' not in data.keys(): + print(f"No chain-wise iPTM output in {json_file}, it was likely a monomer calculation") + else: + if 'chain_pair_iptm' in data.keys(): #HelixFold3 key, coincidentally also AF3 + chain_pair_iptm_data = data['chain_pair_iptm'] + elif 'pair_chains_iptm' in data.keys(): #Boltz key + chain_pair_iptm_data = data['pair_chains_iptm'] + else: + raise ValueError("No chain-wise iPTM data found in the JSON file.") + chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row])] for row in sorted(chain_pair_iptm_data)]) + chain_pair_entries = chain_iptm_matrix_to_pairs(chain_iptm_matrix) + write_tsv(f"{name}_{model_id}_chain-wise_iptm.tsv", format_iptm_rows(chain_pair_entries)) + def read_pt(name, pt_files): import torch # moved to a conditional import since too bulky import if not used From 2ef2359aa84416ebbb5d7d0d7b0345047dab74cd Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 5 Aug 2025 15:50:46 +1000 Subject: [PATCH 112/150] Dump a self-chain pTM score for each model ID --- bin/extract_metrics.py | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 88ad47026..aa74140b0 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -94,6 +94,9 @@ def chain_iptm_matrix_to_pairs(iptm_matrix): # Diagonal element (i, i) contains the pTM restricted to chain i. return [(idx, val) for idx, val in np.ndenumerate(iptm_matrix) if idx[0] != idx[1]] +def chainwise_iptm_matrix_to_ptms(iptm_matrix): + return [(idx, val) for idx, val in np.ndenumerate(iptm_matrix) if idx[0] == idx[1]] + def write_tsv(file_path, rows): with open(file_path, 'w') as out_f: writer = csv.writer(out_f, delimiter='\t') @@ -202,7 +205,7 @@ def read_json(name, json_files): write_tsv(f"{name}_msa.tsv", msa_rows) #AF3 output with PAE info, or HF3 PAE data. TODO: Need to make sure the workflow points to [protein]/[protein]_rank1/all_results.json - # TODO: I think I need to capture model_id and inference_id + # TODO: I think I need to capture model_id and inference_id -- MUST FIX since this is so fragile and will be different for different programs. #if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer ## Might want to cut more if I just want ${meta.id}_[metric].tsv # model_id = os.path.basename(json_file) @@ -212,7 +215,9 @@ def read_json(name, json_files): if 'predictions' in json_file: # Boltz-1 confidences in predictions/[protein]/confidence_[protein]_model_*.json # TODO: haven't tested this for multiple models with --diffusion_samples model_id = os.path.basename(json_file).split('_model_')[-1].split('.json')[0] - + if 'summary_confidences' in json_file: #Prevent crash when model_id is not defined + model_id = os.path.basename(json_file).split('summary_confidences_')[-1].split('.json')[0] + if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") else: @@ -225,18 +230,17 @@ def read_json(name, json_files): # f.write(f"{np.round(data['ptm'],3)}\n") #with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: # f.write(f"{np.round(data['iptm'],3)}\n") - ptm_data[model_id] = f"{np.round(data['ptm'],3)}\n" - iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" - - if ptm_data: + if data['ptm']: + ptm_data[model_id] = f"{np.round(data['ptm'],3)}\n" with open(f"{name}_ptm.tsv", 'w') as f: for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): f.write(f"{k} {v}") - if iptm_data: + if data['iptm']: + iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" with open(f"{name}_iptm.tsv", 'w') as f: for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): f.write(f"{k} {v}") - + if 'chain_pair_iptm' not in data.keys() and 'pair_chains_iptm' not in data.keys(): print(f"No chain-wise iPTM output in {json_file}, it was likely a monomer calculation") else: @@ -246,9 +250,16 @@ def read_json(name, json_files): chain_pair_iptm_data = data['pair_chains_iptm'] else: raise ValueError("No chain-wise iPTM data found in the JSON file.") - chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row])] for row in sorted(chain_pair_iptm_data)]) + + if isinstance(chain_pair_iptm_data, dict): + chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row])] for row in sorted(chain_pair_iptm_data)]) + elif isinstance(chain_pair_iptm_data, list): + chain_iptm_matrix = np.array(chain_pair_iptm_data) + chain_pair_entries = chain_iptm_matrix_to_pairs(chain_iptm_matrix) - write_tsv(f"{name}_{model_id}_chain-wise_iptm.tsv", format_iptm_rows(chain_pair_entries)) + write_tsv(f"{name}_{model_id}_chainwise_iptm.tsv", format_iptm_rows(chain_pair_entries)) + chainwise_ptms = chainwise_iptm_matrix_to_ptms(chain_iptm_matrix) + write_tsv(f"{name}_{model_id}_chainwise_ptm.tsv", format_iptm_rows(chainwise_ptms)) def read_pt(name, pt_files): From fe5c3213d4bb4861ab2626bae8b4a9a56a1bd828 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 5 Aug 2025 16:22:21 +1000 Subject: [PATCH 113/150] cut/paste the chain-wise (i)pTM for each model up to 5, if it exists, into a summary file --- modules/local/run_boltz/main.nf | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 31ac092a8..1c46b962d 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -46,6 +46,9 @@ process RUN_BOLTZ { // TODO: MSA processing for Boltz is not solid yet. They can come from webserver, local mmseq, or a custom paired .csv (see docs below) // https://github.com/jwohlwend/boltz/blob/main/docs/prediction.md#yaml-format // TODO: what I really need to do is add a function to read /processed/msa/*.npz and convert it to a .tsv file + + // TODO: Boltz is the example to do chain-wise summary files. This will be better if model_id was properly written per prog and EXTRACT_METRICs was a process + // paste will fail gracefully if a blank file is passed, so don't worry about overwriting summary_chainwise...tsv. model_0 has the labels, the rest are cut to col 2. if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_BOLTZ module does not support Conda. Please use Docker / Singularity / Podman instead.") } @@ -65,6 +68,17 @@ process RUN_BOLTZ { --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz \\ --csvs boltz_results_*/msa/${meta.id}_*.csv \\ + cp ${meta.id}_0_chainwise_ptm.tsv ${meta.id}_summary_chainwise_ptm.tsv + for i in {1..4}; do + paste ${meta.id}_summary_chainwise_ptm.tsv <(cut -f2 ${meta.id}_${i}_chainwise_ptm.tsv) > temp && mv temp ${meta.id}_summary_chainwise_ptm.tsv + done + + cp ${meta.id}_0_chainwise_iptm.tsv ${meta.id}_summary_chainwise_iptm.tsv + for i in {1..4}; do + paste ${meta.id}_summary_chainwise_iptm.tsv <(cut -f2 ${meta.id}_${i}_chainwise_iptm.tsv) > temp && mv temp ${meta.id}_summary_chainwise_iptm.tsv + done + + cat <<-END_VERSIONS > versions.yml "${task.process}": boltz: $version From 5215c10cbf825f15ef99f5e01f95784bc87e8f13 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 5 Aug 2025 16:29:09 +1000 Subject: [PATCH 114/150] Add chainwise pTM files to emits and stub-run touches --- modules/local/run_boltz/main.nf | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 1c46b962d..85d91d232 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -33,6 +33,9 @@ process RUN_BOLTZ { tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: pae_raw tuple val(meta), path ("${meta.id}_ptm.tsv") , emit: ptm_raw tuple val(meta), path ("${meta.id}_iptm.tsv") , emit: iptm_raw + tuple val(meta), path ("${meta.id}_summary_chainwise_ptm.tsv") , optional: true, emit: summary_chainwise_ptm_raw + tuple val(meta), path ("${meta.id}_*_chainwise_iptm.tsv") , optional: true, emit: chainwise_iptm_raw + tuple val(meta), path ("${meta.id}_summary_chainwise_iptm.tsv") , optional: true, emit: summary_chainwise_iptm_raw path "versions.yml", emit: versions @@ -105,6 +108,10 @@ process RUN_BOLTZ { touch "${meta.id}_0_pae.tsv" touch "${meta.id}_0_ptm.tsv" touch "${meta.id}_0_iptm.tsv" + touch "${meta.id}_0_chainwise_ptm.tsv" + touch "${meta.id}_summary_chainwise_ptm.tsv" + touch "${meta.id}_0_chainwise_iptm.tsv" + touch "${meta.id}_summary_chainwise_iptm.tsv" cat <<-END_VERSIONS > versions.yml "${task.process}": From aa8d135b3bbfb5fd81575586d178b7f634543a87 Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 5 Aug 2025 16:39:36 +1000 Subject: [PATCH 115/150] fix trailing whitespace --- bin/extract_metrics.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index aa74140b0..51e85e1af 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -70,8 +70,8 @@ def format_iptm_rows(chain_pair_entries): Each row contains: the chain-pair in uppercase, e.g. "A:B", "B:A", A:C", etc. and then the iPTM value formatted to 4 decimal places. """ def idx_to_letter(idx): - """ Convert the index integer of the matrix to a letter representation that wraps to double representation, e.g. 0 -> A, 1 -> B, ..., 25 -> Z, 26 -> AA, 27 -> AB, etc. - This is somewhat compatible with how protein structure chain names are numbered by biochemists. + """ Convert the index integer of the matrix to a letter representation that wraps to double representation, e.g. 0 -> A, 1 -> B, ..., 25 -> Z, 26 -> AA, 27 -> AB, etc. + This is somewhat compatible with how protein structure chain names are numbered by biochemists. But we should move away from fixed-format PDB files -- we have nothing to lose but our chains.""" result = "" while idx >= 0: @@ -89,9 +89,9 @@ def chain_iptm_matrix_to_pairs(iptm_matrix): Convert a chain-wise iPTM matrix to pair values by taking off-diagonal elements. """ # From AlphaFold3 output docs: - # 'chain_pair_iptm': An [num_chains, num_chains] array. - # Off-diagonal element (i, j) of the array contains the ipTM restricted to tokens from chains i and j. - # Diagonal element (i, i) contains the pTM restricted to chain i. + # 'chain_pair_iptm': An [num_chains, num_chains] array. + # Off-diagonal element (i, j) of the array contains the ipTM restricted to tokens from chains i and j. + # Diagonal element (i, i) contains the pTM restricted to chain i. return [(idx, val) for idx, val in np.ndenumerate(iptm_matrix) if idx[0] != idx[1]] def chainwise_iptm_matrix_to_ptms(iptm_matrix): @@ -217,7 +217,7 @@ def read_json(name, json_files): model_id = os.path.basename(json_file).split('_model_')[-1].split('.json')[0] if 'summary_confidences' in json_file: #Prevent crash when model_id is not defined model_id = os.path.basename(json_file).split('summary_confidences_')[-1].split('.json')[0] - + if "pae" not in data.keys(): print(f"No PAE output in {json_file}, it was likely a monomer calculation") else: @@ -240,7 +240,7 @@ def read_json(name, json_files): with open(f"{name}_iptm.tsv", 'w') as f: for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): f.write(f"{k} {v}") - + if 'chain_pair_iptm' not in data.keys() and 'pair_chains_iptm' not in data.keys(): print(f"No chain-wise iPTM output in {json_file}, it was likely a monomer calculation") else: @@ -250,17 +250,17 @@ def read_json(name, json_files): chain_pair_iptm_data = data['pair_chains_iptm'] else: raise ValueError("No chain-wise iPTM data found in the JSON file.") - + if isinstance(chain_pair_iptm_data, dict): chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row])] for row in sorted(chain_pair_iptm_data)]) elif isinstance(chain_pair_iptm_data, list): chain_iptm_matrix = np.array(chain_pair_iptm_data) - + chain_pair_entries = chain_iptm_matrix_to_pairs(chain_iptm_matrix) write_tsv(f"{name}_{model_id}_chainwise_iptm.tsv", format_iptm_rows(chain_pair_entries)) chainwise_ptms = chainwise_iptm_matrix_to_ptms(chain_iptm_matrix) write_tsv(f"{name}_{model_id}_chainwise_ptm.tsv", format_iptm_rows(chainwise_ptms)) - + def read_pt(name, pt_files): import torch # moved to a conditional import since too bulky import if not used From 4cf2156bb85470b2347057c4922d3e9a8a92737f Mon Sep 17 00:00:00 2001 From: "keiran.rowell" Date: Tue, 5 Aug 2025 16:48:04 +1000 Subject: [PATCH 116/150] PR351 chainwise CHANGELOG entry --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4681657bb..6446932d0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -51,6 +51,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #333](https://github.com/nf-core/proteinfold/pull/333)] - Updates the RFAA dockerfile for better versioning and smaller image size. - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). - [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). +- [[PR #351](https://github.com/nf-core/proteinfold/pull/351)] - add chain-wise (i)pTM values and summary file for AF3-generation codes. ### Parameters From 1bae081ae5b75cd5747292f8e3cccdd512b09596 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 10:41:23 +0200 Subject: [PATCH 117/150] Clean code --- subworkflows/local/aria2_uncompress.nf | 3 --- 1 file changed, 3 deletions(-) diff --git a/subworkflows/local/aria2_uncompress.nf b/subworkflows/local/aria2_uncompress.nf index a2fc63c1d..51ff9019e 100644 --- a/subworkflows/local/aria2_uncompress.nf +++ b/subworkflows/local/aria2_uncompress.nf @@ -31,15 +31,12 @@ workflow ARIA2_UNCOMPRESS { } else if (source_url.toString().endsWith('.zip')) { ch_db = UNZIP (ARIA2.out.downloaded_file) .unzipped_archive - //.map { it[1] } .map { meta, dir -> - // Get the nested directory def nestedDir = dir.listFiles()[0] // Find the .pdparams file def pdparamsFile = nestedDir.listFiles().find { it.getName().endsWith('.pdparams') } [ pdparamsFile ] } - ch_db.view() } else { ch_db = ARIA2.out.downloaded_file.map { it[1] } } From 2f88b5acb20846b30dbb645d58c59adedb4e89a2 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 10:43:22 +0200 Subject: [PATCH 118/150] Add params.helixfold3_maxit_src_link --- main.nf | 1 + 1 file changed, 1 insertion(+) diff --git a/main.nf b/main.nf index 04e7dffc7..32d549584 100644 --- a/main.nf +++ b/main.nf @@ -373,6 +373,7 @@ workflow NFCORE_PROTEINFOLD { params.helixfold3_mgnify_link, params.helixfold3_pdb_mmcif_link, params.helixfold3_obsolete_link, + params.helixfold3_maxit_src_link, params.helixfold3_uniclust30_path, params.helixfold3_ccd_preprocessed_path, params.helixfold3_rfam_path, From f0179f601b97b90470d4dcf08016007b1b2ba31f Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 11:13:55 +0200 Subject: [PATCH 119/150] Update boltz image to ping specific version --- dockerfiles/Dockerfile_nfcore-proteinfold_boltz | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz index 38ac9e111..0ef3a4fb4 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_boltz @@ -12,6 +12,14 @@ RUN apt-get update && \ && apt-get autoremove -y \ && rm -rf /var/lib/apt/lists/* -RUN pip install --no-cache-dir boltz +RUN pip install --no-cache-dir boltz==2.0.3 + +## To update to version 2.2.0, uncomment the following lines, though still was complaining +## about triton version, thought the error msg state to be sure of using 3.3.0 +# RUN pip install --no-cache-dir \ +# cuequivariance_ops_cu12==0.5.1\ +# cuequivariance_ops_torch_cu12==0.5.1 \ +# cuequivariance_torch==0.5.1 \ +# triton==3.3.0 CMD ["boltz"] From a056e02b88dc18bc5363df47427df63061fb17a2 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 11:14:36 +0200 Subject: [PATCH 120/150] Update version in boltz module --- modules/local/run_boltz/main.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 31ac092a8..e2d175687 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -72,7 +72,7 @@ process RUN_BOLTZ { """ stub: - def version = "0.4.1" + def version = "2.0.3" """ mkdir -p boltz_results_${meta.id}/processed/msa/ mkdir -p boltz_results_${meta.id}/processed/structures/ From 81f2e836fa63ccac5f79a10fb889babc09e351c2 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 11:21:18 +0200 Subject: [PATCH 121/150] Update run_helixfold3 to use newer version --- modules/local/run_helixfold3/main.nf | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index d0e7bb2fa..c334f4bf5 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -46,10 +46,7 @@ process RUN_HELIXFOLD3 { } def args = task.ext.args ?: '' """ - init_model_path=\$(ls ./init_models/*.pdparams | head -n 1) - - mamba run --name helixfold python3.9 /app/helixfold3/inference.py \\ - --maxit_binary "./maxit_src/bin/maxit" \\ + mamba run --name helixfold python3.10 /app/helixfold3/inference.py \\ --jackhmmer_binary_path "jackhmmer" \\ --hhblits_binary_path "hhblits" \\ --hhsearch_binary_path "hhsearch" \\ @@ -58,7 +55,7 @@ process RUN_HELIXFOLD3 { --hmmbuild_binary_path "hmmbuild" \\ --nhmmer_binary_path "nhmmer" \\ --bfd_database_path="./bfd/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt" \\ - --small_bfd_database_path="./small_bfd/bfd-first_non_consensus_sequences.fasta" \\ + --reduced_bfd_database_path="./small_bfd/bfd-first_non_consensus_sequences.fasta" \\ --uniclust30_database_path="./uniref30/${params.uniref30_prefix}" \\ --uniprot_database_path="./uniprot/uniprot.fasta" \\ --pdb_seqres_database_path="./pdb_seqres/pdb_seqres.txt" \\ @@ -67,10 +64,9 @@ process RUN_HELIXFOLD3 { --obsolete_pdbs_path="./obsolete.dat" \\ --ccd_preprocessed_path="./ccd_preprocessed_etkdg.pkl.gz" \\ --uniref90_database_path "./uniref90/uniref90.fasta" \\ - --mgnify_database_path "./mgnify/mgy_clusters.fa" \\ + --mgnify_database_path "./mgnify/mgy_clusters_2018_12.fa" \\ --input_json="${fasta}" \\ --output_dir="\$PWD" \\ - --init_model "\$init_model_path" \\ $args cp "${fasta.baseName}/${fasta.baseName}-rank1/predicted_structure.pdb" "./${meta.id}_helixfold3.pdb" From bf84e1524cdcdf826d6dc85b0faac5d4d265475e Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 11:29:32 +0200 Subject: [PATCH 122/150] Set pdb as the boltz output --- modules/local/run_boltz/main.nf | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index e2d175687..dcebf1434 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -60,6 +60,7 @@ process RUN_BOLTZ { cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb extract_metrics.py --name ${meta.id} \\ + --output_format "pdb" \\ --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz \\ From 19d34e69f4e2ad9b08fce53162d7d00ae2d0e697 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 13:42:01 +0200 Subject: [PATCH 123/150] Fix output_format argument --- modules/local/run_boltz/main.nf | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index dcebf1434..3fd922d74 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -56,11 +56,10 @@ process RUN_BOLTZ { export NUMBA_CACHE_DIR=/tmp export HOME=/tmp - boltz predict "${fasta}" ${args} + boltz predict "${fasta}" --output_format "pdb" ${args} cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb extract_metrics.py --name ${meta.id} \\ - --output_format "pdb" \\ --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz \\ From df8865e1183299cc83b6260337380d2fb5d5bfff Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Tue, 5 Aug 2025 15:47:14 +0200 Subject: [PATCH 124/150] Update changelog --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cf6bfc5db..f2040d9f1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -50,8 +50,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #332](https://github.com/nf-core/proteinfold/pull/332)] - Fix rare superposition bug in reports. - [[PR #333](https://github.com/nf-core/proteinfold/pull/333)] - Updates the RFAA dockerfile for better versioning and smaller image size. - [[PR #335](https://github.com/nf-core/proteinfold/pull/335)] - Update pipeline template to [nf-core/tools 3.3.1](https://github.com/nf-core/tools/releases/tag/3.3.1). -- [[PR #346](https://github.com/nf-core/proteinfold/pull/346)] - Update pipeline template to [nf-core/tools 3.3.2](https://github.com/nf-core/tools/releases/tag/3.3.2). - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. +- [[PR #362](https://github.com/nf-core/proteinfold/pull/355)] - Update boltz Dockerfile and image pinging specific version (2.0.3). ### Parameters From b39378578e94c10d03d36593ee60ce157ad1d85e Mon Sep 17 00:00:00 2001 From: jscgh Date: Wed, 6 Aug 2025 17:18:48 +1000 Subject: [PATCH 125/150] Update snapshots --- tests/alphafold2_download.nf.test.snap | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index ca7f8d2c4..bf315d48f 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -22,13 +22,13 @@ [ "DBs", "DBs/alphafold2", - "DBs/alphafold2/UniRef30_2021_03", + "DBs/alphafold2/UniRef30_2023_02_hhsuite", "DBs/alphafold2/alphafold_params_2022-12-06", "DBs/alphafold2/bfd-first_non_consensus_sequences.fasta", - "DBs/alphafold2/mgy_clusters_2022_05.fa", + "DBs/alphafold2/mgy_clusters.fa", "DBs/alphafold2/mmcif_files", "DBs/alphafold2/obsolete.dat", - "DBs/alphafold2/pdb70_from_mmcif_200916", + "DBs/alphafold2/pdb70_from_mmcif_220313", "DBs/alphafold2/pdb_seqres.txt", "DBs/alphafold2/uniprot.fasta", "DBs/alphafold2/uniprot_sprot.fasta", @@ -69,6 +69,6 @@ "nf-test": "0.9.2", "nextflow": "25.04.6" }, - "timestamp": "2025-08-04T13:20:28.422801993" + "timestamp": "2025-08-06T17:07:06.871556244" } } \ No newline at end of file From 50e18430ff9fba3cc4da261b3a72e817d5c41265 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:00:57 +0200 Subject: [PATCH 126/150] Move alphafold2_msa dockerfile to its module --- .../local/run_alphafold2_msa/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_msa => modules/local/run_alphafold2_msa/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_msa b/modules/local/run_alphafold2_msa/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_msa rename to modules/local/run_alphafold2_msa/Dockerfile From 49c51b508f26d59ef33b497380e9efd831ac714d Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:01:18 +0200 Subject: [PATCH 127/150] Move alphafold2_pred dockerfile to its module --- .../local/run_alphafold2_pred/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_pred => modules/local/run_alphafold2_pred/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_pred b/modules/local/run_alphafold2_pred/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_pred rename to modules/local/run_alphafold2_pred/Dockerfile From c178141fee28529b5c82f68c407c2a55fe8d9fff Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:01:49 +0200 Subject: [PATCH 128/150] Move alphafold2_standard dockerfile to its module --- .../local/run_alphafold2/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_standard => modules/local/run_alphafold2/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_standard b/modules/local/run_alphafold2/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_alphafold2_standard rename to modules/local/run_alphafold2/Dockerfile From 9af2f71bf81e904da77eb4e7de62a23b80b11902 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:02:12 +0200 Subject: [PATCH 129/150] Move alphafold3 dockerfile to its module --- .../local/run_alphafold3/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_alphafold3_standard => modules/local/run_alphafold3/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_alphafold3_standard b/modules/local/run_alphafold3/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_alphafold3_standard rename to modules/local/run_alphafold3/Dockerfile From 7b3203ff8dda12a7ab0993544493fde6425c6223 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:02:28 +0200 Subject: [PATCH 130/150] Move boltz dockerfile to its module --- .../local/run_boltz/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_boltz => modules/local/run_boltz/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_boltz b/modules/local/run_boltz/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_boltz rename to modules/local/run_boltz/Dockerfile From 01fc847e85d390d188430793312adc9a2f28008a Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:02:51 +0200 Subject: [PATCH 131/150] Move colabfold_batch dockerfile to its module --- .../local/colabfold_batch/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_colabfold => modules/local/colabfold_batch/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_colabfold b/modules/local/colabfold_batch/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_colabfold rename to modules/local/colabfold_batch/Dockerfile From b79e2fc093e58d746663a4f5566498fd0ae62a36 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:03:04 +0200 Subject: [PATCH 132/150] Move esmfold dockerfile to its module --- .../local/run_esmfold/Dockerfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dockerfiles/Dockerfile_nfcore-proteinfold_esmfold => modules/local/run_esmfold/Dockerfile (100%) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_esmfold b/modules/local/run_esmfold/Dockerfile similarity index 100% rename from dockerfiles/Dockerfile_nfcore-proteinfold_esmfold rename to modules/local/run_esmfold/Dockerfile From 63a6c292a75ff8b0b8d7324f183504acca6af706 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:03:58 +0200 Subject: [PATCH 133/150] Move helixfold3 dockerfile and environment file to its module --- .../Dockerfile_nfcore-proteinfold_helixfold3 | 47 ------------------- .../local/run_helixfold3/environment.yaml | 0 ...ronment_nfcore-proteinfold_helixfold3.yaml | 35 -------------- 3 files changed, 82 deletions(-) delete mode 100644 dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 rename dockerfiles/environment_nfcore-proteinfold_helixfold3.yaml => modules/local/run_helixfold3/environment.yaml (100%) delete mode 100644 modules/local/run_helixfold3/environment_nfcore-proteinfold_helixfold3.yaml diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 b/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 deleted file mode 100644 index 6e8f2ddbe..000000000 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 +++ /dev/null @@ -1,47 +0,0 @@ -ARG CUDA=12.8.1 -FROM nvidia/cuda:${CUDA}-cudnn-devel-ubuntu22.04 AS builder -# FROM directive resets ARGS, so we specify again (the value is retained if -# previously set). -ARG CUDA - -LABEL Author="j.caley@unsw.edu.au, Jose Espinosa-Carrasco" \ - title="nfcore/proteinfold_helixfold3" \ - Version="1.2.0dev" \ - description="Docker image containing all software requirements to run the RUN_HELIXFOLD3 module using the nf-core/proteinfold pipeline" - -RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y wget git && \ - wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" && \ - bash /tmp/Miniforge3-$(uname)-$(uname -m).sh -b -p /conda && \ - git clone --single-branch --branch dev --depth 1 --no-checkout https://github.com/PaddlePaddle/PaddleHelix.git /app/helixfold3 && \ - cd /app/helixfold3 && \ - git sparse-checkout init --cone && \ - git sparse-checkout set apps/protein_folding/helixfold3 && \ - git checkout dev && \ - mv apps/protein_folding/helixfold3/* . && \ - rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* /root/.cache apps && \ - apt-get remove --purge -y wget git && apt-get autoremove -y && apt-get clean -y - -COPY environment_nfcore-proteinfold_helixfold3.yaml /app/helixfold3/environment.yaml - -ENV PATH="/conda/bin:$PATH" - -RUN mamba env create --file=/app/helixfold3/environment.yaml && \ - mamba install -y -c bioconda aria2 hmmer==3.3.2 kalign2==2.04 hhsuite==3.3.0 -n helixfold && \ - mamba install -y -c conda-forge openbabel -n helixfold && \ - mamba clean --all --force-pkgs-dirs -y && \ - rm -rf /root/.cache - -FROM nvidia/cuda:${CUDA}-cudnn-devel-ubuntu22.04 -# FROM directive resets ARGS, so we specify again (the value is retained if -# previously set). -ARG CUDA - -COPY --from=builder /app /app -COPY --from=builder /conda /conda - -ENV PATH="/conda/bin:/app/helixfold3:./maxit_src/bin:/conda/envs/helixfold/bin:$PATH" \ - RCSBROOT="./maxit_src" \ - MAXIT_SRC="./maxit_src" \ - PYTHON_BIN="/conda/envs/helixfold/bin/python3.9" \ - ENV_BIN="/conda/envs/helixfold/bin" \ - OBABEL_BIN="/conda/envs/helixfold/bin" diff --git a/dockerfiles/environment_nfcore-proteinfold_helixfold3.yaml b/modules/local/run_helixfold3/environment.yaml similarity index 100% rename from dockerfiles/environment_nfcore-proteinfold_helixfold3.yaml rename to modules/local/run_helixfold3/environment.yaml diff --git a/modules/local/run_helixfold3/environment_nfcore-proteinfold_helixfold3.yaml b/modules/local/run_helixfold3/environment_nfcore-proteinfold_helixfold3.yaml deleted file mode 100644 index e277fcef3..000000000 --- a/modules/local/run_helixfold3/environment_nfcore-proteinfold_helixfold3.yaml +++ /dev/null @@ -1,35 +0,0 @@ -name: helixfold -channels: - - conda-forge - - bioconda - - nvidia - - biocore - -dependencies: - - python=3.9 - - cuda-toolkit=12.0 - - cudnn=8.4.0 - - nccl=2.14 - - libgcc - - libgomp - - pip - - aria2 - - hmmer==3.4 - - kalign2==2.04 - - hhsuite==3.3.0 - - openbabel - - pip: - - paddlepaddle-gpu==2.6.1 -f https://www.paddlepaddle.org.cn/whl/linux/mkl/avx/stable.html - - absl-py==0.13.0 - - biopython==1.79 - - chex==0.0.7 - - dm-haiku==0.0.4 - - dm-tree==0.1.6 - - docker==5.0.0 - - immutabledict==2.0.0 - - jax==0.2.14 - - ml-collections==0.1.0 - - pandas==1.3.4 - - scipy==1.9.0 - - rdkit-pypi==2022.9.5 - - posebusters From 7cd4a433f0f98a6de0f546875153f4fe320aa71a Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:04:19 +0200 Subject: [PATCH 134/150] Move rosettafold_all_atom dockerfile to its module --- ...le_nfcore-proteinfold_rosettafold_all_atom | 51 ------------------- .../local/run_rosettafold_all_atom/Dockerfile | 40 ++++++++++----- 2 files changed, 28 insertions(+), 63 deletions(-) delete mode 100644 dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom b/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom deleted file mode 100644 index 649b66155..000000000 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_rosettafold_all_atom +++ /dev/null @@ -1,51 +0,0 @@ -ARG CUDA=12.6.0 -FROM nvidia/cuda:${CUDA}-runtime-ubuntu24.04 AS builder -# FROM directive resets ARGS, so we specify again (the value is retained if -# previously set). -ARG CUDA - -LABEL Author="j.caley@unsw.edu.au" \ - title="nfcore/proteinfold_rosettafold_all_atom" \ - Version="1.2.0dev" \ - description="Docker image containing all software requirements to run the RUN_ROSETTAFOLD_ALL_ATOM module using the nf-core/proteinfold pipeline" - -ENV PYTHONPATH="/app/RoseTTAFold-All-Atom" \ - PATH="/conda/bin:/app/RoseTTAFold-All-Atom:$PATH" \ - DGLBACKEND="pytorch" \ - LD_LIBRARY_PATH="/conda/lib:/usr/local/cuda-$(cut -f1,2 -d. <<< ${CUDA})/lib64:$LD_LIBRARY_PATH" - -RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y wget git && \ - wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/download/24.11.0-0/Miniforge3-$(uname)-$(uname -m).sh" && \ - bash /tmp/Miniforge3-$(uname)-$(uname -m).sh -b -p /conda && \ - rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* /root/.cache && \ - git clone --single-branch --depth 1 https://github.com/Australian-Structural-Biology-Computing/RoseTTAFold-All-Atom.git /app/RoseTTAFold-All-Atom && \ - cd /app/RoseTTAFold-All-Atom && \ - git fetch --depth 1 origin e8f94d6d6ddfb07da2119bcfa94359bc6912fd29 && \ - git checkout e8f94d6d6ddfb07da2119bcfa94359bc6912fd29 && \ - /conda/bin/mamba env create --file=environment.yaml && \ - /conda/bin/mamba run -n RFAA bash -c \ - "python /app/RoseTTAFold-All-Atom/rf2aa/SE3Transformer/setup.py install && \ - bash /app/RoseTTAFold-All-Atom/install_dependencies.sh" && \ - /conda/bin/mamba clean --all --force-pkgs-dirs -y && \ - cd /app/RoseTTAFold-All-Atom && \ - wget https://ftp.ncbi.nlm.nih.gov/blast/executables/legacy.NOTSUPPORTED/2.2.26/blast-2.2.26-x64-linux.tar.gz && \ - mkdir -p blast-2.2.26 && \ - tar -xf blast-2.2.26-x64-linux.tar.gz -C blast-2.2.26 && \ - cp -r blast-2.2.26/blast-2.2.26/ blast-2.2.26_bk && \ - rm -r blast-2.2.26 && \ - mv blast-2.2.26_bk/ blast-2.2.26 && \ - rm -rf /root/.cache *.tar.gz && \ - apt-get remove --purge -y wget git && apt-get autoremove -y && apt-get clean -y - -FROM nvidia/cuda:${CUDA}-base-ubuntu24.04 -# FROM directive resets ARGS, so we specify again (the value is retained if -# previously set). -ARG CUDA - -COPY --from=builder /app /app -COPY --from=builder /conda /conda - -ENV PYTHONPATH="/app/RoseTTAFold-All-Atom" \ - PATH="/conda/bin:/app/RoseTTAFold-All-Atom:$PATH" \ - DGLBACKEND="pytorch" \ - LD_LIBRARY_PATH="/conda/lib:/usr/local/cuda-$(cut -f1,2 -d. <<< ${CUDA})/lib64:$LD_LIBRARY_PATH" diff --git a/modules/local/run_rosettafold_all_atom/Dockerfile b/modules/local/run_rosettafold_all_atom/Dockerfile index 42c0c90f7..649b66155 100644 --- a/modules/local/run_rosettafold_all_atom/Dockerfile +++ b/modules/local/run_rosettafold_all_atom/Dockerfile @@ -1,30 +1,33 @@ -FROM nvidia/cuda:12.6.0-cudnn-devel-ubuntu24.04 +ARG CUDA=12.6.0 +FROM nvidia/cuda:${CUDA}-runtime-ubuntu24.04 AS builder +# FROM directive resets ARGS, so we specify again (the value is retained if +# previously set). +ARG CUDA LABEL Author="j.caley@unsw.edu.au" \ title="nfcore/proteinfold_rosettafold_all_atom" \ - Version="0.9.0" \ + Version="1.2.0dev" \ description="Docker image containing all software requirements to run the RUN_ROSETTAFOLD_ALL_ATOM module using the nf-core/proteinfold pipeline" ENV PYTHONPATH="/app/RoseTTAFold-All-Atom" \ PATH="/conda/bin:/app/RoseTTAFold-All-Atom:$PATH" \ DGLBACKEND="pytorch" \ - LD_LIBRARY_PATH="/conda/lib:/usr/local/cuda-12.6/lib64:$LD_LIBRARY_PATH" + LD_LIBRARY_PATH="/conda/lib:/usr/local/cuda-$(cut -f1,2 -d. <<< ${CUDA})/lib64:$LD_LIBRARY_PATH" RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y wget git && \ - wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" && \ + wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/download/24.11.0-0/Miniforge3-$(uname)-$(uname -m).sh" && \ bash /tmp/Miniforge3-$(uname)-$(uname -m).sh -b -p /conda && \ - rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* && \ - apt-get autoremove -y && apt-get clean -y - -RUN git clone --single-branch --depth 1 https://github.com/Australian-Structural-Biology-Computing/RoseTTAFold-All-Atom.git /app/RoseTTAFold-All-Atom && \ + rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* /root/.cache && \ + git clone --single-branch --depth 1 https://github.com/Australian-Structural-Biology-Computing/RoseTTAFold-All-Atom.git /app/RoseTTAFold-All-Atom && \ cd /app/RoseTTAFold-All-Atom && \ + git fetch --depth 1 origin e8f94d6d6ddfb07da2119bcfa94359bc6912fd29 && \ + git checkout e8f94d6d6ddfb07da2119bcfa94359bc6912fd29 && \ /conda/bin/mamba env create --file=environment.yaml && \ /conda/bin/mamba run -n RFAA bash -c \ "python /app/RoseTTAFold-All-Atom/rf2aa/SE3Transformer/setup.py install && \ bash /app/RoseTTAFold-All-Atom/install_dependencies.sh" && \ - /conda/bin/mamba clean --all --force-pkgs-dirs -y - -RUN cd /app/RoseTTAFold-All-Atom && \ + /conda/bin/mamba clean --all --force-pkgs-dirs -y && \ + cd /app/RoseTTAFold-All-Atom && \ wget https://ftp.ncbi.nlm.nih.gov/blast/executables/legacy.NOTSUPPORTED/2.2.26/blast-2.2.26-x64-linux.tar.gz && \ mkdir -p blast-2.2.26 && \ tar -xf blast-2.2.26-x64-linux.tar.gz -C blast-2.2.26 && \ @@ -32,4 +35,17 @@ RUN cd /app/RoseTTAFold-All-Atom && \ rm -r blast-2.2.26 && \ mv blast-2.2.26_bk/ blast-2.2.26 && \ rm -rf /root/.cache *.tar.gz && \ - apt-get autoremove -y && apt-get remove --purge -y wget git && apt-get clean -y + apt-get remove --purge -y wget git && apt-get autoremove -y && apt-get clean -y + +FROM nvidia/cuda:${CUDA}-base-ubuntu24.04 +# FROM directive resets ARGS, so we specify again (the value is retained if +# previously set). +ARG CUDA + +COPY --from=builder /app /app +COPY --from=builder /conda /conda + +ENV PYTHONPATH="/app/RoseTTAFold-All-Atom" \ + PATH="/conda/bin:/app/RoseTTAFold-All-Atom:$PATH" \ + DGLBACKEND="pytorch" \ + LD_LIBRARY_PATH="/conda/lib:/usr/local/cuda-$(cut -f1,2 -d. <<< ${CUDA})/lib64:$LD_LIBRARY_PATH" From fcdb2599f88329d26dfe3db9eac750f907c3493d Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 15:18:37 +0200 Subject: [PATCH 135/150] Update changelog --- CHANGELOG.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ccc0a64e8..2c09e8960 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,7 +55,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. - [[PR #356](https://github.com/nf-core/proteinfold/pull/356)] - Update AF2 defaults to use split mode and monomer_ptm model. - [[PR #360](https://github.com/nf-core/proteinfold/pull/360)] - Rename some DBs paths in the run modules so they are equal to those when DBs are downloaded. -- [[PR #362](https://github.com/nf-core/proteinfold/pull/355)] - Update boltz Dockerfile and image pinging specific version (2.0.3). +- [[PR #362](https://github.com/nf-core/proteinfold/pull/355)] - Update boltz Dockerfile and image pinning specific version (2.0.3). +- [[#364](https://github.com/nf-core/proteinfold/issues/364)] - Move Dockerfiles to its corresponding module. ### Parameters From c42768acf9731c71610c850ac0a40fed12a696b3 Mon Sep 17 00:00:00 2001 From: Jose Espinosa-Carrasco Date: Wed, 6 Aug 2025 13:56:41 +0000 Subject: [PATCH 136/150] Add helixfold3_maxit_src_link to nextflow schema --- nextflow_schema.json | 4 ++++ subworkflows/local/prepare_helixfold3_dbs.nf | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/nextflow_schema.json b/nextflow_schema.json index a05b708fe..a852e3475 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -1094,6 +1094,10 @@ "helixfold3_obsolete_link": { "type": "string", "default": "https://files.rcsb.org/pub/pdb/data/status/obsolete.dat" + }, + "helixfold3_maxit_src_link": { + "type": "string", + "default": "https://proteinfold-dataset.s3.amazonaws.com/test-data/db/helixfold3/maxit-v11.200-prod-src.tar.gz" } } } diff --git a/subworkflows/local/prepare_helixfold3_dbs.nf b/subworkflows/local/prepare_helixfold3_dbs.nf index 0179a7c4e..156b2da1f 100644 --- a/subworkflows/local/prepare_helixfold3_dbs.nf +++ b/subworkflows/local/prepare_helixfold3_dbs.nf @@ -139,7 +139,7 @@ workflow PREPARE_HELIXFOLD3_DBS { ) ch_helixfold3_uniprot = COMBINE_UNIPROT.out.ch_db ch_versions = ch_versions.mix(COMBINE_UNIPROT.out.versions) - + ARIA2_MAXIT(helixfold3_maxit_src_link) ch_helixfold3_maxit_src = ARIA2_MAXIT.out.db ch_versions = ch_versions.mix(ARIA2_MAXIT.out.versions) From 489b38feeba834b7a2bed2ee7c9f62b30cea8331 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 16:13:02 +0200 Subject: [PATCH 137/150] Update snapshot --- tests/alphafold2_download.nf.test.snap | 50 ++++++++++++++++++++++++-- 1 file changed, 47 insertions(+), 3 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index bf315d48f..a51d5af30 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -1,7 +1,7 @@ { "-profile test_alphafold2_download": { "content": [ - 21, + 23, { "ARIA2": { "aria2": null @@ -15,6 +15,13 @@ "DOWNLOAD_PDBMMCIF": { "awk": null }, + "GENERATE_REPORT": { + "python": "3.12.2", + "generate_report.py": "Python 3.12.2" + }, + "RUN_ALPHAFOLD2": { + "python": "3.12.2" + }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" } @@ -34,6 +41,28 @@ "DBs/alphafold2/uniprot_sprot.fasta", "DBs/alphafold2/uniprot_trembl.fasta", "DBs/alphafold2/uniref90.fasta", + "alphafold2", + "alphafold2/standard", + "alphafold2/standard/T1024", + "alphafold2/standard/T1024/T1024.1", + "alphafold2/standard/T1024/T1024.1/ranked_0.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_1.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_2.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_3.pdb", + "alphafold2/standard/T1024/T1024.1/ranked_4.pdb", + "alphafold2/standard/T1024/T1024_alphafold2.pdb", + "alphafold2/standard/T1024/T1024_iptm.tsv", + "alphafold2/standard/T1024/T1024_msa.tsv", + "alphafold2/standard/T1024/T1024_plddt.tsv", + "alphafold2/standard/T1024/T1024_ptm.tsv", + "alphafold2/standard/T1024/paes", + "alphafold2/standard/T1024/paes/T1024_0_pae.tsv", + "alphafold2/standard/top_ranked_structures", + "alphafold2/standard/top_ranked_structures/T1024.pdb", + "generate", + "generate/test_LDDT.html", + "generate/test_alphafold2_report.html", + "generate/test_seq_coverage.png", "multiqc", "multiqc/alphafold2_multiqc_data", "multiqc/alphafold2_multiqc_plots", @@ -62,13 +91,28 @@ "uniprot_sprot.fasta:md5,d41d8cd98f00b204e9800998ecf8427e", "uniprot_trembl.fasta:md5,d41d8cd98f00b204e9800998ecf8427e", "uniref90.fasta:md5,d41d8cd98f00b204e9800998ecf8427e", + "ranked_0.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "ranked_1.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "ranked_2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "ranked_3.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "ranked_4.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_alphafold2.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_iptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_msa.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_plddt.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_ptm.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024_0_pae.tsv:md5,d41d8cd98f00b204e9800998ecf8427e", + "T1024.pdb:md5,d41d8cd98f00b204e9800998ecf8427e", + "test_LDDT.html:md5,d41d8cd98f00b204e9800998ecf8427e", + "test_alphafold2_report.html:md5,d41d8cd98f00b204e9800998ecf8427e", + "test_seq_coverage.png:md5,d41d8cd98f00b204e9800998ecf8427e", "alphafold2_multiqc_report.html:md5,d41d8cd98f00b204e9800998ecf8427e" ] ], "meta": { "nf-test": "0.9.2", - "nextflow": "25.04.6" + "nextflow": "24.10.5" }, - "timestamp": "2025-08-06T17:07:06.871556244" + "timestamp": "2025-08-06T16:10:27.405125" } } \ No newline at end of file From 571af608b02874cc90a91393488f039e0abe6e1f Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 17:25:49 +0200 Subject: [PATCH 138/150] Update snapshot --- tests/alphafold2_download.nf.test.snap | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/alphafold2_download.nf.test.snap b/tests/alphafold2_download.nf.test.snap index a51d5af30..e4afb1871 100644 --- a/tests/alphafold2_download.nf.test.snap +++ b/tests/alphafold2_download.nf.test.snap @@ -16,11 +16,11 @@ "awk": null }, "GENERATE_REPORT": { - "python": "3.12.2", - "generate_report.py": "Python 3.12.2" + "python": "3.12.7", + "generate_report.py": "Python 3.12.7" }, "RUN_ALPHAFOLD2": { - "python": "3.12.2" + "python": null }, "Workflow": { "nf-core/proteinfold": "v1.2.0dev" @@ -113,6 +113,6 @@ "nf-test": "0.9.2", "nextflow": "24.10.5" }, - "timestamp": "2025-08-06T16:10:27.405125" + "timestamp": "2025-08-06T17:23:19.626138" } } \ No newline at end of file From 889a75b50b242413f71441d3dacb28f4d860f2b6 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 18:31:58 +0200 Subject: [PATCH 139/150] revert changes in helixfold3 as the newest version doesn't convert to pdb (no maxit option) --- modules/local/run_helixfold3/main.nf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index b4eda109d..227cd7443 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -49,7 +49,7 @@ process RUN_HELIXFOLD3 { init_model_path=\$(ls ./init_models/*.pdparams | head -n 1) mgnify_db_path=\$(ls -v ./mgnify/mgy_clusters*.fa | tail -n 1) - mamba run --name helixfold python3.10 /app/helixfold3/inference.py \\ + mamba run --name helixfold python3.9 /app/helixfold3/inference.py \\ --maxit_binary "./maxit_src/bin/maxit" \\ --jackhmmer_binary_path "jackhmmer" \\ --hhblits_binary_path "hhblits" \\ @@ -59,7 +59,7 @@ process RUN_HELIXFOLD3 { --hmmbuild_binary_path "hmmbuild" \\ --nhmmer_binary_path "nhmmer" \\ --bfd_database_path="./bfd/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt" \\ - --reduced_bfd_database_path="./small_bfd/bfd-first_non_consensus_sequences.fasta" \\ + --small_bfd_database_path="./small_bfd/bfd-first_non_consensus_sequences.fasta" \\ --uniclust30_database_path="./uniref30/${params.uniref30_prefix}" \\ --uniprot_database_path="./uniprot/uniprot.fasta" \\ --pdb_seqres_database_path="./pdb_seqres/pdb_seqres.txt" \\ From 244eba95137412be70446e6e56555e9a9dabc5d4 Mon Sep 17 00:00:00 2001 From: JoseEspinosa Date: Wed, 6 Aug 2025 18:47:38 +0200 Subject: [PATCH 140/150] Ping specific version of helixfold3 --- dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 b/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 index 6e8f2ddbe..16c19c3b3 100644 --- a/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 +++ b/dockerfiles/Dockerfile_nfcore-proteinfold_helixfold3 @@ -12,11 +12,11 @@ LABEL Author="j.caley@unsw.edu.au, Jose Espinosa-Carrasco" \ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y wget git && \ wget -q -P /tmp "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" && \ bash /tmp/Miniforge3-$(uname)-$(uname -m).sh -b -p /conda && \ - git clone --single-branch --branch dev --depth 1 --no-checkout https://github.com/PaddlePaddle/PaddleHelix.git /app/helixfold3 && \ + git clone --filter=blob:none --no-checkout https://github.com/PaddlePaddle/PaddleHelix.git /app/helixfold3 && \ cd /app/helixfold3 && \ git sparse-checkout init --cone && \ git sparse-checkout set apps/protein_folding/helixfold3 && \ - git checkout dev && \ + git checkout 705c2974a833cdc3a4420f4e3379da596091c97f && \ mv apps/protein_folding/helixfold3/* . && \ rm -rf /tmp/Miniforge3-$(uname)-$(uname -m).sh /var/lib/apt/lists/* /root/.cache apps && \ apt-get remove --purge -y wget git && apt-get autoremove -y && apt-get clean -y From 7e0e2961151d242f8b5606318011adada784dfe9 Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 7 Aug 2025 10:43:29 +1000 Subject: [PATCH 141/150] Add schema descriptions --- nextflow.config | 5 +- nextflow_schema.json | 141 ++++++++++++++++++++++++++++--------------- 2 files changed, 95 insertions(+), 51 deletions(-) diff --git a/nextflow.config b/nextflow.config index 448639a7d..fdb60944c 100644 --- a/nextflow.config +++ b/nextflow.config @@ -140,7 +140,7 @@ params { // Helixfold3 parameters helixfold3_db = null - helixfold3_full_dbs = false + helixfold3_full_dbs = false // true full_dbs, false reduced_dbs helixfold3_precision = "bf16" helixfold3_infer_times = 4 helixfold3_max_template_date = "2038-01-19" @@ -158,7 +158,8 @@ params { helixfold3_uniref90_link = null helixfold3_mgnify_link = null helixfold3_pdb_mmcif_link = null - helixfold3_pdb_obsolete_link = null + helixfold3_obsolete_link = null + helixfold3_maxit_src_link = null // Helixfold3 paths helixfold3_uniclust30_path = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 3d8e8a567..0e79e4e1e 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -226,10 +226,12 @@ "description": "Boltz options.", "properties": { "boltz_use_potentials": { - "type": "boolean" + "type": "boolean", + "description": "run Boltz-2 using inference time potentials" }, "boltz_model": { - "type": "string" + "type": "string", + "description": "Sets the model to use for prediction. Default is boltz2" } } }, @@ -277,7 +279,8 @@ "helixfold3_precision": { "type": "string", "enum": ["bf16", "fp32"], - "description": "The numerical precision used by the HelixFold3 model." + "description": "The numerical precision used by the HelixFold3 model.", + "default": "bf16" }, "helixfold3_infer_times": { "type": "integer", @@ -753,15 +756,18 @@ }, "boltz2_aff_link": { "type": "string", - "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt" + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_aff.ckpt", + "description": "Link to download boltz affinity file" }, "boltz2_conf_link": { "type": "string", - "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt" + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/boltz2_conf.ckpt", + "description": "Link to download boltz-2 conf file" }, "boltz2_mols_link": { "type": "string", - "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar" + "default": "https://huggingface.co/boltz-community/boltz-2/resolve/main/mols.tar", + "description": "Link to download boltz-2 mols" } } }, @@ -790,15 +796,18 @@ }, "boltz2_aff_path": { "type": "string", - "default": "null/params/boltz2_aff.ckpt" + "default": "null/params/boltz2_aff.ckpt", + "description": "Path to boltz affinity file" }, "boltz2_conf_path": { "type": "string", - "default": "null/params/boltz2_conf.ckpt" + "default": "null/params/boltz2_conf.ckpt", + "description": "Path to boltz-2 conf file" }, "boltz2_mols_path": { "type": "string", - "default": "null/params/mols/" + "default": "null/params/mols/", + "description": "Path to boltz-2 mols" } } }, @@ -918,19 +927,23 @@ "properties": { "rosettafold_all_atom_uniref30_link": { "type": "string", - "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz" + "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz", + "description": "Link to the UniRef30 database for RoseTTAFold All Atom" }, "rosettafold_all_atom_bfd_link": { "type": "string", - "default": "https://bfd.mmseqs.com/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz" + "default": "https://bfd.mmseqs.com/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz", + "description": "Link to the BFD database for RoseTTAFold All Atom" }, "rosettafold_all_atom_pdb100_link": { "type": "string", - "default": "https://files.ipd.uw.edu/pub/RoseTTAFold/pdb100_2021Mar03.tar.gz" + "default": "https://files.ipd.uw.edu/pub/RoseTTAFold/pdb100_2021Mar03.tar.gz", + "description": "Link to the PDB100 database for RoseTTAFold All Atom" }, "rosettafold_all_atom_paper_weights_link": { "type": "string", - "default": "http://files.ipd.uw.edu/pub/RF-All-Atom/weights/RFAA_paper_weights.pt" + "default": "http://files.ipd.uw.edu/pub/RF-All-Atom/weights/RFAA_paper_weights.pt", + "description": "Link to the RoseTTAFold All Atom paper weights" } } }, @@ -941,23 +954,28 @@ "default": "", "properties": { "rosettafold_all_atom_db": { - "type": "string" + "type": "string", + "description": "Path to RoseTTAFold All Atom database" }, "rosettafold_all_atom_uniref30_path": { "type": "string", - "default": "null/uniref30/*" + "default": "null/uniref30/*", + "description": "Path to UniRef30 database for RoseTTAFold All Atom" }, "rosettafold_all_atom_bfd_path": { "type": "string", - "default": "null/bfd/*" + "default": "null/bfd/*", + "description": "Path to BFD database for RoseTTAFold All Atom" }, "rosettafold_all_atom_pdb100_path": { "type": "string", - "default": "null/pdb100/*" + "default": "null/pdb100/*", + "description": "Path to PDB100 database for RoseTTAFold All Atom" }, "rosettafold_all_atom_paper_weights_path": { "type": "string", - "default": "null/params/RFAA_paper_weights.pt" + "default": "null/params/RFAA_paper_weights.pt", + "description": "Path to RoseTTAFold All Atom paper weights" } } }, @@ -968,59 +986,73 @@ "default": "", "properties": { "helixfold3_db": { - "type": "string" + "type": "string", + "description": "Path to HelixFold3 database" }, "helixfold3_init_models_path": { "type": "string", - "default": "null/params/HelixFold3-240814.pdparams" + "default": "null/params/HelixFold3-240814.pdparams", + "description": "Path to HelixFold3 init models" }, "helixfold3_uniclust30_path": { "type": "string", - "default": "null/uniref30/*" + "default": "null/uniref30/*", + "description": "Path to UniRef30 database for HelixFold3" }, "helixfold3_ccd_preprocessed_path": { "type": "string", - "default": "null/params/ccd_preprocessed_etkdg.pkl.gz" + "default": "null/params/ccd_preprocessed_etkdg.pkl.gz", + "description": "Path to CCD preprocessed file for HelixFold3" }, "helixfold3_rfam_path": { "type": "string", - "default": "null/rfam/Rfam-14.9_rep_seq.fasta" + "default": "null/rfam/Rfam-14.9_rep_seq.fasta", + "description": "Path to Rfam database for HelixFold3" }, "helixfold3_bfd_path": { "type": "string", - "default": "null/bfd/*" + "default": "null/bfd/*", + "description": "Path to BFD database for HelixFold3" }, "helixfold3_small_bfd_path": { "type": "string", - "default": "null/small_bfd/*" + "default": "null/small_bfd/*", + "description": "Path to reduced BFD database for HelixFold3" }, "helixfold3_uniprot_path": { "type": "string", - "default": "null/uniprot/*" + "default": "null/uniprot/*", + "description": "Path to UniProt database for HelixFold3" }, "helixfold3_pdb_seqres_path": { "type": "string", - "default": "null/pdb_seqres/*" + "default": "null/pdb_seqres/*", + "description": "Path to PDB SEQRES database for HelixFold3" }, "helixfold3_uniref90_path": { "type": "string", - "default": "null/uniref90/*" + "default": "null/uniref90/*", + "description": "Path to UniRef90 database for HelixFold3" }, "helixfold3_mgnify_path": { "type": "string", - "default": "null/mgnify/*" + "default": "null/mgnify/*", + "description": "Path to MGnify database for HelixFold3" }, "helixfold3_pdb_mmcif_path": { "type": "string", - "default": "null/pdb_mmcif/mmcif_files" + "default": "null/pdb_mmcif/mmcif_files", + "description": "Path to PDB mmCIF database for HelixFold3" }, "helixfold3_maxit_src_path": { "type": "string", - "default": "null/maxit-v11.200-prod-src" + "default": "null/maxit-v11.200-prod-src", + "description": "Path to Maxit Suite for HelixFold3" }, "helixfold3_obsolete_path": { "type": "string", - "default": "null/pdb_mmcif/obsolete.dat" + "default": "null/pdb_mmcif/obsolete.dat", + "description": "Path to obsolete PDB file for HelixFold3" } } }, @@ -1032,62 +1064,73 @@ "properties": { "helixfold3_init_models_link": { "type": "string", - "default": "https://paddlehelix.bd.bcebos.com/HelixFold3/params/HelixFold3-params-240814.zip" + "default": "https://paddlehelix.bd.bcebos.com/HelixFold3/params/HelixFold3-params-240814.zip", + "description": "Link to HelixFold3 init models" }, "helixfold3_uniclust30_link": { "type": "string", - "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz" + "default": "https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz", + "description": "Link to UniRef30 database for HelixFold3" }, "helixfold3_ccd_preprocessed_link": { "type": "string", - "default": "https://paddlehelix.bd.bcebos.com/HelixFold3/CCD/ccd_preprocessed_etkdg.pkl.gz" + "default": "https://paddlehelix.bd.bcebos.com/HelixFold3/CCD/ccd_preprocessed_etkdg.pkl.gz", + "description": "Link to CCD preprocessed file for HelixFold3" }, "helixfold3_rfam_link": { "type": "string", - "default": "https://paddlehelix.bd.bcebos.com/HelixFold3/MSA/Rfam-14.9_rep_seq.fasta" + "default": "https://paddlehelix.bd.bcebos.com/HelixFold3/MSA/Rfam-14.9_rep_seq.fasta", + "description": "Link to Rfam database for HelixFold3" }, "helixfold3_bfd_link": { "type": "string", - "default": "https://storage.googleapis.com/alphafold-databases/casp14_versions/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz" + "default": "https://storage.googleapis.com/alphafold-databases/casp14_versions/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz", + "description": "Link to BFD database for HelixFold3" }, "helixfold3_small_bfd_link": { "type": "string", - "default": "https://storage.googleapis.com/alphafold-databases/reduced_dbs/bfd-first_non_consensus_sequences.fasta.gz" + "default": "https://storage.googleapis.com/alphafold-databases/reduced_dbs/bfd-first_non_consensus_sequences.fasta.gz", + "description": "Link to reduced BFD database for HelixFold3" }, "helixfold3_pdb_seqres_link": { "type": "string", - "default": "https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt" + "default": "https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt", + "description": "Link to PDB SEQRES database for HelixFold3" }, "helixfold3_uniref90_link": { "type": "string", - "default": "ftp://ftp.uniprot.org/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz" + "default": "ftp://ftp.uniprot.org/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz", + "description": "Link to UniRef90 database for HelixFold3" }, "helixfold3_mgnify_link": { "type": "string", - "default": "https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz" + "default": "https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz", + "description": "Link to MGnify database for HelixFold3" }, "helixfold3_pdb_mmcif_link": { "type": "string", - "default": "rsync.rcsb.org::ftp_data/structures/divided/mmCIF/" + "default": "rsync.rcsb.org::ftp_data/structures/divided/mmCIF/", + "description": "Link to PDB mmCIF database for HelixFold3" }, "helixfold3_uniprot_sprot_link": { "type": "string", - "default": "ftp://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz" + "default": "ftp://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz", + "description": "Link to UniProt SwissProt database for HelixFold3" }, "helixfold3_uniprot_trembl_link": { "type": "string", - "default": "ftp://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_trembl.fasta.gz" - }, - "helixfold3_pdb_obsolete_link": { - "type": "string" + "default": "ftp://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_trembl.fasta.gz", + "description": "Link to UniProt TrEMBL database for HelixFold3" }, "helixfold3_obsolete_link": { "type": "string", - "default": "https://files.rcsb.org/pub/pdb/data/status/obsolete.dat" + "default": "https://files.rcsb.org/pub/pdb/data/status/obsolete.dat", + "description": "Link to obsolete PDB file for HelixFold3" }, "helixfold3_maxit_src_link": { "type": "string", - "default": "https://proteinfold-dataset.s3.amazonaws.com/test-data/db/helixfold3/maxit-v11.200-prod-src.tar.gz" + "default": "https://proteinfold-dataset.s3.amazonaws.com/test-data/db/helixfold3/maxit-v11.200-prod-src.tar.gz", + "description": "Link to Maxit Suite for HelixFold3" } } } From b449bf1ee51ce7a1836c27b61ce6e9bfdbd42249 Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 7 Aug 2025 11:06:22 +1000 Subject: [PATCH 142/150] Update snapshots --- tests/colabfold_download.nf.test.snap | 29 +++++++++++++------------- tests/colabfold_local.nf.test.snap | 29 +++++++++++++------------- tests/colabfold_webserver.nf.test.snap | 29 +++++++++++++------------- tests/split_fasta.nf.test.snap | 29 +++++++++++++------------- 4 files changed, 56 insertions(+), 60 deletions(-) diff --git a/tests/colabfold_download.nf.test.snap b/tests/colabfold_download.nf.test.snap index d5281a31c..72885e708 100644 --- a/tests/colabfold_download.nf.test.snap +++ b/tests/colabfold_download.nf.test.snap @@ -22,20 +22,19 @@ "DBs/colabfold", "DBs/colabfold/alphafold_params_2021-07-14", "colabfold", - "colabfold/webserver", - "colabfold/webserver/T1024_colabfold.pdb", - "colabfold/webserver/T1024_coverage.png", - "colabfold/webserver/T1024_mqc.png", - "colabfold/webserver/T1024_relaxed_rank_01.pdb", - "colabfold/webserver/T1024_relaxed_rank_02.pdb", - "colabfold/webserver/T1024_relaxed_rank_03.pdb", - "colabfold/webserver/T1026_colabfold.pdb", - "colabfold/webserver/T1026_coverage.png", - "colabfold/webserver/T1026_mqc.png", - "colabfold/webserver/T1026_relaxed_rank_01.pdb", - "colabfold/webserver/T1026_relaxed_rank_02.pdb", - "colabfold/webserver/T1026_relaxed_rank_03.pdb", - "colabfold/webserver/top_ranked_structures", + "colabfold/T1024_colabfold.pdb", + "colabfold/T1024_coverage.png", + "colabfold/T1024_mqc.png", + "colabfold/T1024_relaxed_rank_01.pdb", + "colabfold/T1024_relaxed_rank_02.pdb", + "colabfold/T1024_relaxed_rank_03.pdb", + "colabfold/T1026_colabfold.pdb", + "colabfold/T1026_coverage.png", + "colabfold/T1026_mqc.png", + "colabfold/T1026_relaxed_rank_01.pdb", + "colabfold/T1026_relaxed_rank_02.pdb", + "colabfold/T1026_relaxed_rank_03.pdb", + "colabfold/top_ranked_structures", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -72,6 +71,6 @@ "nf-test": "0.9.2", "nextflow": "25.04.6" }, - "timestamp": "2025-08-04T15:03:02.615959389" + "timestamp": "2025-08-07T11:02:16.287892882" } } \ No newline at end of file diff --git a/tests/colabfold_local.nf.test.snap b/tests/colabfold_local.nf.test.snap index 69ae284a0..df7853ebb 100644 --- a/tests/colabfold_local.nf.test.snap +++ b/tests/colabfold_local.nf.test.snap @@ -21,20 +21,19 @@ }, [ "colabfold", - "colabfold/local", - "colabfold/local/T1024_colabfold.pdb", - "colabfold/local/T1024_coverage.png", - "colabfold/local/T1024_mqc.png", - "colabfold/local/T1024_relaxed_rank_01.pdb", - "colabfold/local/T1024_relaxed_rank_02.pdb", - "colabfold/local/T1024_relaxed_rank_03.pdb", - "colabfold/local/T1026_colabfold.pdb", - "colabfold/local/T1026_coverage.png", - "colabfold/local/T1026_mqc.png", - "colabfold/local/T1026_relaxed_rank_01.pdb", - "colabfold/local/T1026_relaxed_rank_02.pdb", - "colabfold/local/T1026_relaxed_rank_03.pdb", - "colabfold/local/top_ranked_structures", + "colabfold/T1024_colabfold.pdb", + "colabfold/T1024_coverage.png", + "colabfold/T1024_mqc.png", + "colabfold/T1024_relaxed_rank_01.pdb", + "colabfold/T1024_relaxed_rank_02.pdb", + "colabfold/T1024_relaxed_rank_03.pdb", + "colabfold/T1026_colabfold.pdb", + "colabfold/T1026_coverage.png", + "colabfold/T1026_mqc.png", + "colabfold/T1026_relaxed_rank_01.pdb", + "colabfold/T1026_relaxed_rank_02.pdb", + "colabfold/T1026_relaxed_rank_03.pdb", + "colabfold/top_ranked_structures", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -68,6 +67,6 @@ "nf-test": "0.9.2", "nextflow": "25.04.6" }, - "timestamp": "2025-08-04T15:03:13.281594692" + "timestamp": "2025-08-07T11:02:26.46180193" } } \ No newline at end of file diff --git a/tests/colabfold_webserver.nf.test.snap b/tests/colabfold_webserver.nf.test.snap index 52f3e7310..a0d492f9c 100644 --- a/tests/colabfold_webserver.nf.test.snap +++ b/tests/colabfold_webserver.nf.test.snap @@ -16,20 +16,19 @@ }, [ "colabfold", - "colabfold/webserver", - "colabfold/webserver/T1024_colabfold.pdb", - "colabfold/webserver/T1024_coverage.png", - "colabfold/webserver/T1024_mqc.png", - "colabfold/webserver/T1024_relaxed_rank_01.pdb", - "colabfold/webserver/T1024_relaxed_rank_02.pdb", - "colabfold/webserver/T1024_relaxed_rank_03.pdb", - "colabfold/webserver/T1026_colabfold.pdb", - "colabfold/webserver/T1026_coverage.png", - "colabfold/webserver/T1026_mqc.png", - "colabfold/webserver/T1026_relaxed_rank_01.pdb", - "colabfold/webserver/T1026_relaxed_rank_02.pdb", - "colabfold/webserver/T1026_relaxed_rank_03.pdb", - "colabfold/webserver/top_ranked_structures", + "colabfold/T1024_colabfold.pdb", + "colabfold/T1024_coverage.png", + "colabfold/T1024_mqc.png", + "colabfold/T1024_relaxed_rank_01.pdb", + "colabfold/T1024_relaxed_rank_02.pdb", + "colabfold/T1024_relaxed_rank_03.pdb", + "colabfold/T1026_colabfold.pdb", + "colabfold/T1026_coverage.png", + "colabfold/T1026_mqc.png", + "colabfold/T1026_relaxed_rank_01.pdb", + "colabfold/T1026_relaxed_rank_02.pdb", + "colabfold/T1026_relaxed_rank_03.pdb", + "colabfold/top_ranked_structures", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -63,6 +62,6 @@ "nf-test": "0.9.2", "nextflow": "25.04.6" }, - "timestamp": "2025-08-04T15:03:22.469274618" + "timestamp": "2025-08-07T11:02:35.349046908" } } \ No newline at end of file diff --git a/tests/split_fasta.nf.test.snap b/tests/split_fasta.nf.test.snap index e3086af8b..72efbb9d3 100644 --- a/tests/split_fasta.nf.test.snap +++ b/tests/split_fasta.nf.test.snap @@ -21,20 +21,19 @@ }, [ "colabfold", - "colabfold/local", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_colabfold.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_coverage.png", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_mqc.png", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_relaxed_rank_01.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_relaxed_rank_02.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_relaxed_rank_03.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_colabfold.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_coverage.png", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_mqc.png", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_relaxed_rank_01.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_relaxed_rank_02.pdb", - "colabfold/local/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_relaxed_rank_03.pdb", - "colabfold/local/top_ranked_structures", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_colabfold.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_coverage.png", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_mqc.png", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_relaxed_rank_01.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_relaxed_rank_02.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_1_127_residues_relaxed_rank_03.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_colabfold.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_coverage.png", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_mqc.png", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_relaxed_rank_01.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_relaxed_rank_02.pdb", + "colabfold/H1065_N4-Cytosine_Methyltransferase_Serratia_marcescens_subunit_2_98_residues_relaxed_rank_03.pdb", + "colabfold/top_ranked_structures", "generate", "generate/test_LDDT.html", "generate/test_alphafold2_report.html", @@ -68,6 +67,6 @@ "nf-test": "0.9.2", "nextflow": "25.04.6" }, - "timestamp": "2025-08-04T15:03:51.792622381" + "timestamp": "2025-08-07T11:03:04.097369625" } } \ No newline at end of file From 0e7cc1de39a777869ffc817add2a82ff363e60dc Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 7 Aug 2025 11:55:09 +1000 Subject: [PATCH 143/150] Harmonise naming of AF2 params --- CHANGELOG.md | 92 ++++++++++++++++++++++---------------------- conf/dbs.config | 48 +++++++++++------------ main.nf | 18 ++++----- nextflow.config | 50 ++++++++++++------------ nextflow_schema.json | 18 ++++----- 5 files changed, 113 insertions(+), 113 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b0327519..0c0262674 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -61,52 +61,52 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Parameters -| Old parameter | New parameter | -| ---------------------------- | ------------------------------ | -| | `--pdb_obsolete_path` | -| `--small_bfd_link` | `--alphafold2_small_bfd_link` | -| `--mgnify_link` | `--alphafold2_mgnify_link` | -| `--pdb_mmcif_link` | `--alphafold2_pdb_mmcif_link` | -| `--uniref30_alphafold2_link` | `--alphafold2_uniref30_link` | -| `--uniref90_link` | `--alphafold2_uniref90_link` | -| `--pdb_seqres_link` | `--alphafold2_pdb_seqres_link` | -| `--small_bfd_path` | `--alphafold2_small_bfd_path` | -| `--mgnify_path_alphafold2` | `--alphafold2_mgnify_path` | -| `--pdb_mmcif_path` | `--alphafold2_pdb_mmcif_path` | -| `--uniref30_alphafold2_path` | `--alphafold2_uniref30_path` | -| `--uniref90_path` | `--alphafold2_uniref90_path` | -| `--pdb_seqres_path` | `--alphafold2_pdb_seqres_path` | -| `--uniprot_path` | `--alphafold2_uniprot_path` | -| | `--alphafold3_small_bfd_link` | -| | `--alphafold3_mgnify_link` | -| | `--alphafold3_uniref90_link` | -| | `--alphafold3_pdb_seqres_link` | -| | `--uniprot_link` | -| | `--alphafold3_small_bfd_path` | -| | `--alphafold3_params_path` | -| | `--alphafold3_mgnify_path` | -| | `--alphafold3_pdb_mmcif_path` | -| | `--alphafold3_uniref90_path` | -| | `--alphafold3_pdb_seqres_path` | -| | `--alphafold3_uniprot_path` | -| | `--boltz_model` | -| | `--boltz_out_dir` | -| | `--boltz_output_format` | -| | `--boltz_use_msa_server` | -| | `--boltz_msa_server_url` | -| | `--boltz_use_potentials` | -| | `--boltz_write_full_pae` | -| | `--boltz2_aff_path` | -| | `--boltz2_conf_path` | -| | `--boltz2_mols_path` | -| | `--boltz_model_path` | -| | `--boltz_ccd_path` | -| | `--boltz_db` | -| | `--boltz2_aff_link` | -| | `--boltz2_conf_link` | -| | `--boltz2_mols_link` | -| | `--boltz_model_link` | -| | `--boltz_ccd_link` | +| Old parameter | New parameter | +| ---------------------------- | -------------------------------- | +| | `--alphafold2_pdb_obsolete_path` | +| `--small_bfd_link` | `--alphafold2_small_bfd_link` | +| `--mgnify_link` | `--alphafold2_mgnify_link` | +| `--pdb_mmcif_link` | `--alphafold2_pdb_mmcif_link` | +| `--uniref30_alphafold2_link` | `--alphafold2_uniref30_link` | +| `--uniref90_link` | `--alphafold2_uniref90_link` | +| `--pdb_seqres_link` | `--alphafold2_pdb_seqres_link` | +| `--small_bfd_path` | `--alphafold2_small_bfd_path` | +| `--mgnify_path_alphafold2` | `--alphafold2_mgnify_path` | +| `--pdb_mmcif_path` | `--alphafold2_pdb_mmcif_path` | +| `--uniref30_alphafold2_path` | `--alphafold2_uniref30_path` | +| `--uniref90_path` | `--alphafold2_uniref90_path` | +| `--pdb_seqres_path` | `--alphafold2_pdb_seqres_path` | +| `--uniprot_path` | `--alphafold2_uniprot_path` | +| | `--alphafold3_small_bfd_link` | +| | `--alphafold3_mgnify_link` | +| | `--alphafold3_uniref90_link` | +| | `--alphafold3_pdb_seqres_link` | +| | `--alphafold3_uniprot_link` | +| | `--alphafold3_small_bfd_path` | +| | `--alphafold3_params_path` | +| | `--alphafold3_mgnify_path` | +| | `--alphafold3_pdb_mmcif_path` | +| | `--alphafold3_uniref90_path` | +| | `--alphafold3_pdb_seqres_path` | +| | `--alphafold3_uniprot_path` | +| | `--boltz_model` | +| | `--boltz_out_dir` | +| | `--boltz_output_format` | +| | `--boltz_use_msa_server` | +| | `--boltz_msa_server_url` | +| | `--boltz_use_potentials` | +| | `--boltz_write_full_pae` | +| | `--boltz2_aff_path` | +| | `--boltz2_conf_path` | +| | `--boltz2_mols_path` | +| | `--boltz_model_path` | +| | `--boltz_ccd_path` | +| | `--boltz_db` | +| | `--boltz2_aff_link` | +| | `--boltz2_conf_link` | +| | `--boltz2_mols_link` | +| | `--boltz_model_link` | +| | `--boltz_ccd_link` | > **NB:** Parameter has been **updated** if both old and new parameter information is present. > **NB:** Parameter has been **added** if just the new parameter information is present. diff --git a/conf/dbs.config b/conf/dbs.config index 355aef983..ed595beec 100644 --- a/conf/dbs.config +++ b/conf/dbs.config @@ -14,31 +14,31 @@ params { uniref30_prefix = "UniRef30_2023_02" // AlphaFold2 links - bfd_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz' - alphafold2_small_bfd_link = 'https://storage.googleapis.com/alphafold-databases/reduced_dbs/bfd-first_non_consensus_sequences.fasta.gz' - alphafold2_params_link = 'https://storage.googleapis.com/alphafold/alphafold_params_2022-12-06.tar' - alphafold2_mgnify_link = 'https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz' - pdb70_link = 'https://wwwuser.gwdguser.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/pdb70_from_mmcif_220313.tar.gz' - alphafold2_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' //Other sources available: 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' ftp.pdbj.org::ftp_data/structures/divided/mmCIF/ rsync.ebi.ac.uk::pub/databases/pdb/data/structures/divided/mmCIF/ - pdb_obsolete_link = 'https://files.wwpdb.org/pub/pdb/data/status/obsolete.dat' - alphafold2_uniref30_link = 'https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz' - alphafold2_uniref90_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz' - alphafold2_pdb_seqres_link = 'https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt' - uniprot_sprot_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz' - uniprot_trembl_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_trembl.fasta.gz' + alphafold2_bfd_link = 'https://storage.googleapis.com/alphafold-databases/casp14_versions/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz' + alphafold2_small_bfd_link = 'https://storage.googleapis.com/alphafold-databases/reduced_dbs/bfd-first_non_consensus_sequences.fasta.gz' + alphafold2_params_link = 'https://storage.googleapis.com/alphafold/alphafold_params_2022-12-06.tar' + alphafold2_mgnify_link = 'https://ftp.ebi.ac.uk/pub/databases/metagenomics/peptide_database/2024_04/mgy_clusters.fa.gz' + alphafold2_pdb70_link = 'https://wwwuser.gwdguser.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/pdb70_from_mmcif_220313.tar.gz' + alphafold2_pdb_mmcif_link = 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' //Other sources available: 'rsync.rcsb.org::ftp_data/structures/divided/mmCIF/' ftp.pdbj.org::ftp_data/structures/divided/mmCIF/ rsync.ebi.ac.uk::pub/databases/pdb/data/structures/divided/mmCIF/ + alphafold2_pdb_obsolete_link = 'https://files.wwpdb.org/pub/pdb/data/status/obsolete.dat' + alphafold2_uniref30_link = 'https://wwwuser.gwdguser.de/~compbiol/uniclust/2023_02/UniRef30_2023_02_hhsuite.tar.gz' + alphafold2_uniref90_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/uniref/uniref90/uniref90.fasta.gz' + alphafold2_pdb_seqres_link = 'https://files.wwpdb.org/pub/pdb/derived_data/pdb_seqres.txt' + alphafold2_uniprot_sprot_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz' + alphafold2_uniprot_trembl_link = 'https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_trembl.fasta.gz' // Alphafold2 paths - bfd_path = "${params.alphafold2_db}/bfd/*" - alphafold2_small_bfd_path = "${params.alphafold2_db}/small_bfd/*" - alphafold2_params_path = "${params.alphafold2_db}/params/${params.alphafold2_params_prefix}/*" - alphafold2_mgnify_path = "${params.alphafold2_db}/mgnify/*" - pdb70_path = "${params.alphafold2_db}/pdb70/**" - alphafold2_pdb_mmcif_path = "${params.alphafold2_db}/pdb_mmcif/mmcif_files" - pdb_obsolete_path = "${params.alphafold2_db}/pdb_mmcif/obsolete.dat" - alphafold2_uniref30_path = "${params.alphafold2_db}/uniref30/*" - alphafold2_uniref90_path = "${params.alphafold2_db}/uniref90/*" - alphafold2_pdb_seqres_path = "${params.alphafold2_db}/pdb_seqres/*" - alphafold2_uniprot_path = "${params.alphafold2_db}/uniprot/*" + alphafold2_bfd_path = "${params.alphafold2_db}/bfd/*" + alphafold2_small_bfd_path = "${params.alphafold2_db}/small_bfd/*" + alphafold2_params_path = "${params.alphafold2_db}/params/${params.alphafold2_params_prefix}/*" + alphafold2_mgnify_path = "${params.alphafold2_db}/mgnify/*" + alphafold2_pdb70_path = "${params.alphafold2_db}/pdb70/**" + alphafold2_pdb_mmcif_path = "${params.alphafold2_db}/pdb_mmcif/mmcif_files" + alphafold2_pdb_obsolete_path = "${params.alphafold2_db}/pdb_mmcif/obsolete.dat" + alphafold2_uniref30_path = "${params.alphafold2_db}/uniref30/*" + alphafold2_uniref90_path = "${params.alphafold2_db}/uniref90/*" + alphafold2_pdb_seqres_path = "${params.alphafold2_db}/pdb_seqres/*" + alphafold2_uniprot_path = "${params.alphafold2_db}/uniprot/*" // Alphafold3 links alphafold3_small_bfd_link = 'https://storage.googleapis.com/alphafold-databases/v3.0/bfd-first_non_consensus_sequences.fasta.zst' @@ -46,7 +46,7 @@ params { alphafold3_pdb_mmcif_link = 'https://storage.googleapis.com/alphafold-databases/v3.0/pdb_2022_09_28_mmcif_files.tar.zst' alphafold3_uniref90_link = 'https://storage.googleapis.com/alphafold-databases/v3.0/uniref90_2022_05.fa.zst' alphafold3_pdb_seqres_link = 'https://storage.googleapis.com/alphafold-databases/v3.0/pdb_seqres_2022_09_28.fasta.zst' - uniprot_link = 'https://storage.googleapis.com/alphafold-databases/v3.0/uniprot_all_2021_04.fa.zst' + alphafold3_uniprot_link = 'https://storage.googleapis.com/alphafold-databases/v3.0/uniprot_all_2021_04.fa.zst' // Alphafold3 paths alphafold3_small_bfd_path = "${params.alphafold3_db}/small_bfd/*" diff --git a/main.nf b/main.nf index 4d76f9c85..f7902947a 100644 --- a/main.nf +++ b/main.nf @@ -98,29 +98,29 @@ workflow NFCORE_PROTEINFOLD { PREPARE_ALPHAFOLD2_DBS ( params.alphafold2_db, params.alphafold2_full_dbs, - params.bfd_path, + params.alphafold2_bfd_path, params.alphafold2_small_bfd_path, params.alphafold2_params_path, params.alphafold2_mgnify_path, - params.pdb70_path, + params.alphafold2_pdb70_path, params.alphafold2_pdb_mmcif_path, - params.pdb_obsolete_path, + params.alphafold2_pdb_obsolete_path, params.alphafold2_uniref30_path, params.alphafold2_uniref90_path, params.alphafold2_pdb_seqres_path, params.alphafold2_uniprot_path, - params.bfd_link, + params.alphafold2_bfd_link, params.alphafold2_small_bfd_link, params.alphafold2_params_link, params.alphafold2_mgnify_link, - params.pdb70_link, + params.alphafold2_pdb70_link, params.alphafold2_pdb_mmcif_link, - params.pdb_obsolete_link, + params.alphafold2_pdb_obsolete_link, params.alphafold2_uniref30_link, params.alphafold2_uniref90_link, params.alphafold2_pdb_seqres_link, - params.uniprot_sprot_link, - params.uniprot_trembl_link + params.alphafold2_uniprot_sprot_link, + params.alphafold2_uniprot_trembl_link ) ch_versions = ch_versions.mix(PREPARE_ALPHAFOLD2_DBS.out.versions) @@ -185,7 +185,7 @@ workflow NFCORE_PROTEINFOLD { params.alphafold3_pdb_mmcif_link, params.alphafold3_uniref90_link, params.alphafold3_pdb_seqres_link, - params.uniprot_link + params.alphafold3_uniprot_link ) ch_versions = ch_versions.mix(PREPARE_ALPHAFOLD3_DBS.out.versions) diff --git a/nextflow.config b/nextflow.config index fdb60944c..643c39a17 100644 --- a/nextflow.config +++ b/nextflow.config @@ -17,6 +17,7 @@ params { db = null use_msa_server = false msa_server_url = null + uniref30_prefix = null // Alphafold2 parameters alphafold2_mode = 'split_msa_prediction' // {standard, split_msa_prediction} @@ -27,32 +28,31 @@ params { alphafold2_random_seed = null // Alphafold2 links - bfd_link = null - alphafold2_small_bfd_link = null - alphafold2_params_link = null - alphafold2_mgnify_link = null - pdb70_link = null - alphafold2_pdb_mmcif_link = null - pdb_obsolete_link = null - alphafold2_uniref30_link = null - alphafold2_uniref90_link = null - alphafold2_pdb_seqres_link = null - uniprot_sprot_link = null - uniprot_trembl_link = null - uniref30_prefix = null + alphafold2_bfd_link = null + alphafold2_small_bfd_link = null + alphafold2_params_link = null + alphafold2_mgnify_link = null + alphafold2_pdb70_link = null + alphafold2_pdb_mmcif_link = null + alphafold2_pdb_obsolete_link = null + alphafold2_uniref30_link = null + alphafold2_uniref90_link = null + alphafold2_pdb_seqres_link = null + alphafold2_uniprot_sprot_link = null + alphafold2_uniprot_trembl_link = null // Alphafold2 paths - bfd_path = null - alphafold2_small_bfd_path = null - alphafold2_params_path = null - alphafold2_mgnify_path = null - pdb70_path = null - alphafold2_pdb_mmcif_path = null - pdb_obsolete_path = null - alphafold2_uniref30_path = null - alphafold2_uniref90_path = null - alphafold2_pdb_seqres_path = null - alphafold2_uniprot_path = null + alphafold2_bfd_path = null + alphafold2_small_bfd_path = null + alphafold2_params_path = null + alphafold2_mgnify_path = null + alphafold2_pdb70_path = null + alphafold2_pdb_mmcif_path = null + alphafold2_pdb_obsolete_path = null + alphafold2_uniref30_path = null + alphafold2_uniref90_path = null + alphafold2_pdb_seqres_path = null + alphafold2_uniprot_path = null // Alphafold3 parameters alphafold3_db = null @@ -63,7 +63,7 @@ params { alphafold3_pdb_mmcif_link = null alphafold3_uniref90_link = null alphafold3_pdb_seqres_link = null - uniprot_link = null + alphafold3_uniprot_link = null // Alphafold3 paths alphafold3_small_bfd_path = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 0e79e4e1e..6b7b1dd48 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -367,7 +367,7 @@ "fa_icon": "fas fa-database", "description": "Parameters used to provide the links to the DBs and parameters public resources to AlphaFold2.", "properties": { - "bfd_link": { + "alphafold2_bfd_link": { "type": "string", "default": "https://storage.googleapis.com/alphafold-databases/casp14_versions/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt.tar.gz", "description": "Link to BFD dababase", @@ -391,7 +391,7 @@ "description": "Link to the MGnify database", "fa_icon": "fas fa-link" }, - "pdb70_link": { + "alphafold2_pdb70_link": { "type": "string", "default": "https://wwwuser.gwdguser.de/~compbiol/data/hhsuite/databases/hhsuite_dbs/pdb70_from_mmcif_220313.tar.gz", "description": "Link to the PDB70 database", @@ -403,7 +403,7 @@ "description": "Link to the PDB mmCIF database", "fa_icon": "fas fa-link" }, - "pdb_obsolete_link": { + "alphafold2_pdb_obsolete_link": { "type": "string", "default": "https://files.wwpdb.org/pub/pdb/data/status/obsolete.dat", "description": "Link to the PDB obsolete database", @@ -427,13 +427,13 @@ "description": "Link to the PDB SEQRES database", "fa_icon": "fas fa-link" }, - "uniprot_sprot_link": { + "alphafold2_uniprot_sprot_link": { "type": "string", "default": "https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_sprot.fasta.gz", "description": "Link to the SwissProt UniProt database", "fa_icon": "fas fa-link" }, - "uniprot_trembl_link": { + "alphafold2_uniprot_trembl_link": { "type": "string", "default": "https://ftp.ebi.ac.uk/pub/databases/uniprot/current_release/knowledgebase/complete/uniprot_trembl.fasta.gz", "description": "Link to the TrEMBL UniProt database", @@ -455,7 +455,7 @@ "fa_icon": "fas fa-database", "errorMessage": "Please provide a valid path to AlphaFold2 database" }, - "bfd_path": { + "alphafold2_bfd_path": { "type": "string", "description": "Path to BFD dababase", "fa_icon": "fas fa-folder-open", @@ -479,7 +479,7 @@ "fa_icon": "fas fa-folder-open", "default": "null/mgnify/*" }, - "pdb70_path": { + "alphafold2_pdb70_path": { "type": "string", "description": "Path to the PDB70 database", "fa_icon": "fas fa-folder-open", @@ -491,7 +491,7 @@ "fa_icon": "fas fa-folder-open", "default": "null/pdb_mmcif/mmcif_files" }, - "pdb_obsolete_path": { + "alphafold2_pdb_obsolete_path": { "type": "string", "description": "Path to the PDB obsolete file", "fa_icon": "fas fa-folder-open", @@ -567,7 +567,7 @@ "description": "Link to the PDB SEQRES database", "fa_icon": "fas fa-link" }, - "uniprot_link": { + "alphafold3_uniprot_link": { "type": "string", "default": "https://storage.googleapis.com/alphafold-databases/v3.0/uniprot_all_2021_04.fa.zst", "description": "Link to the UniProt database", From 448494f92db76845ba570aea9db04d3698a6de80 Mon Sep 17 00:00:00 2001 From: jscgh Date: Thu, 7 Aug 2025 16:32:06 +1000 Subject: [PATCH 144/150] Added to changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0c0262674..08ec261a3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,6 +55,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #355](https://github.com/nf-core/proteinfold/pull/355)] - Remove unneccesary params from Boltz and Helixfold3 modes. - [[PR #356](https://github.com/nf-core/proteinfold/pull/356)] - Update AF2 defaults to use split mode and monomer_ptm model. - [[PR #357](https://github.com/nf-core/proteinfold/pull/357)] - Update ColabFold module and image. +- [[PR #359](https://github.com/nf-core/proteinfold/pull/359)] - Harmonize parameters across modes. - [[PR #360](https://github.com/nf-core/proteinfold/pull/360)] - Rename some DBs paths in the run modules so they are equal to those when DBs are downloaded. - [[PR #362](https://github.com/nf-core/proteinfold/pull/355)] - Update boltz Dockerfile and image pinning specific version (2.0.3). - [[#364](https://github.com/nf-core/proteinfold/issues/364)] - Move Dockerfiles to its corresponding module. From 9f72b0a324a1778c402e3a7e38d3dc7b2816b18c Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Fri, 8 Aug 2025 11:59:49 +1000 Subject: [PATCH 145/150] Fix chainwise extract metrics --- bin/extract_metrics.py | 95 ++++++++++++++++++++------------- bin/utils.py | 15 +++++- modules/local/run_boltz/main.nf | 33 ++++-------- 3 files changed, 82 insertions(+), 61 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 51e85e1af..28359e303 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -7,7 +7,7 @@ import numpy as np import csv import string -from utils import plddt_from_struct_b_factor +from utils import plddt_from_struct_b_factor, get_chain_ids # TODO: Issue #309, make into a poper separate process, it its own module so that dependencies can be managed better # TODO: Need a sense of ranking, so that metrics can be traced back to correct model structure, even if they're not in sequential order. The enumerates() here are not sufficient. @@ -64,7 +64,7 @@ def format_msa_rows(msa_data): def format_pae_rows(pae_data): return [[f"{num:.4f}" for num in row] for row in pae_data] -def format_iptm_rows(chain_pair_entries): +def format_iptm_rows(chain_pair_entries, chain_ids=None): """ Format iPTM data into a list of rows for writing to a TSV file. Each row contains: the chain-pair in uppercase, e.g. "A:B", "B:A", A:C", etc. and then the iPTM value formatted to 4 decimal places. @@ -81,7 +81,16 @@ def idx_to_letter(idx): break return result - return [[f"{idx_to_letter(idx[0])}:{idx_to_letter(idx[1])}", f"{val:.4f}"] for idx, val in chain_pair_entries] + if chain_ids: + #would be better with some model_id sorting + iptm_rows = [[""]+[f"{chain_ids[idx[0]]}:{chain_ids[idx[1]]}" for idx, val in next(iter(chain_pair_entries.values()))]] + else: + iptm_rows = [[""]+[f"{idx_to_letter(idx[0])}:{idx_to_letter(idx[1])}" for idx, val in next(iter(chain_pair_entries.values()))]] + + for model_idx, chain_pair_entries_values in chain_pair_entries.items(): + iptm_rows.append([model_idx]+[f"{val:.4f}" for idx, val in chain_pair_entries_values]) + + return [list(row) for row in zip(*iptm_rows)] def chain_iptm_matrix_to_pairs(iptm_matrix): @@ -154,13 +163,13 @@ def read_pkl(name, pkl_files): # f.write(f"{np.round(data['iptm'],3)}\n") ptm_data[f"{model_id}"] = f"{np.round(data['ptm'],3)}\n" iptm_data[f"{model_id}"] = f"{np.round(data.get('iptm',0.),3)}\n" - if ptm_data: - with open(f"{name}_ptm.tsv", 'w') as f: - for k, v in ptm_data.items(): #probably better to be ordered - f.write(f"{k} {v}") - with open(f"{name}_iptm.tsv", 'w') as f: - for k, v in iptm_data.items(): #probably better to be ordered - f.write(f"{k} {v}") + if ptm_data: + with open(f"{name}_ptm.tsv", 'w') as f: + for k, v in ptm_data.items(): #probably better to be ordered + f.write(f"{k} {v}") + with open(f"{name}_iptm.tsv", 'w') as f: + for k, v in iptm_data.items(): #probably better to be ordered + f.write(f"{k} {v}") @@ -180,6 +189,7 @@ def read_npz(name, npz_files): def read_csv(name, csv_files): for idx, csv_file in enumerate(csv_files): + if not os.path.isfile(csv_file): return #TODO: Fix temporary workaround model_id = os.path.basename(csv_file).split('_')[-1].split('.csv')[0] msa_lines = [] with open(csv_file) as f: @@ -194,6 +204,10 @@ def read_json(name, json_files): ptm_data = {} iptm_data = {} chain_pair_iptm_data = {} # For iPTM data to be converted into formatted pairs with non-self elements + chain_pair_entries = {} + chainwise_ptms = {} + chain_ids = [] + for idx, json_file in enumerate(json_files): with open(json_file, 'r') as f: data = json.load(f) @@ -205,7 +219,7 @@ def read_json(name, json_files): write_tsv(f"{name}_msa.tsv", msa_rows) #AF3 output with PAE info, or HF3 PAE data. TODO: Need to make sure the workflow points to [protein]/[protein]_rank1/all_results.json - # TODO: I think I need to capture model_id and inference_id -- MUST FIX since this is so fragile and will be different for different programs. + # TODO: I think I need to capture model_id and inference_id -- MUST FIX since this is so fragile and will be different for different programs. #if '_alphafold2_ptm_model_' in json_file: # ColabFold, multimer or monomer ## Might want to cut more if I just want ${meta.id}_[metric].tsv # model_id = os.path.basename(json_file) @@ -225,41 +239,50 @@ def read_json(name, json_files): if 'ptm' not in data.keys(): print(f"No pTM/iPTM output in {json_file}, it was likely a monomer calculation") + #This message should change - currently called on boltz files not expected to contain ptm else: - #with open(f"{name}_{model_id}_ptm.tsv", 'w') as f: - # f.write(f"{np.round(data['ptm'],3)}\n") - #with open(f"{name}_{model_id}_iptm.tsv", 'w') as f: - # f.write(f"{np.round(data['iptm'],3)}\n") - if data['ptm']: - ptm_data[model_id] = f"{np.round(data['ptm'],3)}\n" - with open(f"{name}_ptm.tsv", 'w') as f: - for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): - f.write(f"{k} {v}") - if data['iptm']: - iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" - with open(f"{name}_iptm.tsv", 'w') as f: - for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): - f.write(f"{k} {v}") + ptm_data[model_id] = f"{np.round(data['ptm'],3)}\n" + if 'iptm' not in data.keys(): + print(f"No pTM/iPTM output in {json_file}, it was likely a monomer calculation") + else: + iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" + if 'chain_pair_iptm' not in data.keys() and 'pair_chains_iptm' not in data.keys(): print(f"No chain-wise iPTM output in {json_file}, it was likely a monomer calculation") else: - if 'chain_pair_iptm' in data.keys(): #HelixFold3 key, coincidentally also AF3 + if 'chain_pair_iptm' in data.keys(): chain_pair_iptm_data = data['chain_pair_iptm'] + chain_iptm_matrix = np.array(chain_pair_iptm_data) elif 'pair_chains_iptm' in data.keys(): #Boltz key chain_pair_iptm_data = data['pair_chains_iptm'] + # casting to int works for sorting boltz - need to carefully check other modes + chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row], key=int)] for row in sorted(chain_pair_iptm_data, key=int)]) + basename = os.path.basename(json_file) + dirname = os.path.dirname(json_file) + pdb_name = ".".join(basename[11:].split('.')[:-1])+'.pdb' #TODO: Fix magic number + chain_ids = get_chain_ids(os.path.join(dirname,pdb_name)) else: raise ValueError("No chain-wise iPTM data found in the JSON file.") - - if isinstance(chain_pair_iptm_data, dict): - chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row])] for row in sorted(chain_pair_iptm_data)]) - elif isinstance(chain_pair_iptm_data, list): - chain_iptm_matrix = np.array(chain_pair_iptm_data) - - chain_pair_entries = chain_iptm_matrix_to_pairs(chain_iptm_matrix) - write_tsv(f"{name}_{model_id}_chainwise_iptm.tsv", format_iptm_rows(chain_pair_entries)) - chainwise_ptms = chainwise_iptm_matrix_to_ptms(chain_iptm_matrix) - write_tsv(f"{name}_{model_id}_chainwise_ptm.tsv", format_iptm_rows(chainwise_ptms)) + + chain_pair_entries[model_id] = chain_iptm_matrix_to_pairs(chain_iptm_matrix) + chainwise_ptms[model_id] = chainwise_iptm_matrix_to_ptms(chain_iptm_matrix) + + if chainwise_ptms: + write_tsv(f"{name}_chainwise_ptm.tsv", format_iptm_rows(chainwise_ptms, chain_ids=chain_ids)) + + if chain_pair_entries: + write_tsv(f"{name}_chainwise_iptm.tsv", format_iptm_rows(chain_pair_entries, chain_ids=chain_ids)) + + if ptm_data: + with open(f"{name}_ptm.tsv", 'w') as f: + for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): + f.write(f"{k} {v}") + + if iptm_data: + with open(f"{name}_iptm.tsv", 'w') as f: + for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): + f.write(f"{k} {v}") def read_pt(name, pt_files): diff --git a/bin/utils.py b/bin/utils.py index 8540fd4ca..4c66444de 100755 --- a/bin/utils.py +++ b/bin/utils.py @@ -49,6 +49,19 @@ def plddt_from_struct_b_factor_adhoc(struct_file): return res_plddts +def get_chain_ids(struct_file): + from Bio import PDB + if str(struct_file).endswith(".pdb"): + parser = PDB.PDBParser(QUIET=True) + structure = parser.get_structure(id=id, file=struct_file) + elif str(struct_file).endswith(".cif"): + parser = PDB.MMCIFParser(QUIET=True) + structure = parser.get_structure(structure_id=id, filename=struct_file) + else: + raise ValueError(f"{struct_file} is neither a PDB or mmCIF file!") + + return [chain.id for chain in structure.get_chains()] + def plddt_from_struct_b_factor_biopython(struct_file): """ @@ -96,4 +109,4 @@ def plddt_from_struct_b_factor_biopython(struct_file): if bio_is_installed: plddt_from_struct_b_factor = plddt_from_struct_b_factor_biopython else: - plddt_from_struct_b_factor = plddt_from_struct_b_factor_adhoc + plddt_from_struct_b_factor = plddt_from_struct_b_factor_adhoc \ No newline at end of file diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 194546458..34f69449f 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -29,13 +29,12 @@ process RUN_BOLTZ { tuple val(meta), path ("boltz_results_*/predictions/*/plddt_*model_0.npz") , emit: plddt tuple val(meta), path ("boltz_results_*/predictions/*/pae_*model_0.npz") , emit: pae tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: plddt_raw - tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa_raw - tuple val(meta), path ("${meta.id}_*_pae.tsv") , optional: true, emit: pae_raw + tuple val(meta), path ("${meta.id}_msa.tsv") , optional: true, emit: msa_raw + tuple val(meta), path ("${meta.id}_*_pae.tsv") , emit: pae_raw tuple val(meta), path ("${meta.id}_ptm.tsv") , emit: ptm_raw tuple val(meta), path ("${meta.id}_iptm.tsv") , emit: iptm_raw - tuple val(meta), path ("${meta.id}_summary_chainwise_ptm.tsv") , optional: true, emit: summary_chainwise_ptm_raw - tuple val(meta), path ("${meta.id}_*_chainwise_iptm.tsv") , optional: true, emit: chainwise_iptm_raw - tuple val(meta), path ("${meta.id}_summary_chainwise_iptm.tsv") , optional: true, emit: summary_chainwise_iptm_raw + tuple val(meta), path ("${meta.id}_chainwise_ptm.tsv") , emit: summary_chainwise_ptm_raw + tuple val(meta), path ("${meta.id}_chainwise_iptm.tsv") , emit: chainwise_iptm_raw path "versions.yml", emit: versions @@ -51,7 +50,6 @@ process RUN_BOLTZ { // TODO: what I really need to do is add a function to read /processed/msa/*.npz and convert it to a .tsv file // TODO: Boltz is the example to do chain-wise summary files. This will be better if model_id was properly written per prog and EXTRACT_METRICs was a process - // paste will fail gracefully if a blank file is passed, so don't worry about overwriting summary_chainwise...tsv. model_0 has the labels, the rest are cut to col 2. if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { error("Local RUN_BOLTZ module does not support Conda. Please use Docker / Singularity / Podman instead.") } @@ -62,25 +60,14 @@ process RUN_BOLTZ { export NUMBA_CACHE_DIR=/tmp export HOME=/tmp - boltz predict "${fasta}" --output_format "pdb" ${args} - cp boltz_results_*/predictions/*/*.pdb ./${meta.id}_boltz.pdb + boltz predict "${fasta}" --output_format "pdb" ${args} --cache ./ + cp boltz_results_*/predictions/${meta.id}/*_0.pdb ./${meta.id}_boltz.pdb extract_metrics.py --name ${meta.id} \\ --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz \\ - --csvs boltz_results_*/msa/${meta.id}_*.csv \\ - - cp ${meta.id}_0_chainwise_ptm.tsv ${meta.id}_summary_chainwise_ptm.tsv - for i in {1..4}; do - paste ${meta.id}_summary_chainwise_ptm.tsv <(cut -f2 ${meta.id}_${i}_chainwise_ptm.tsv) > temp && mv temp ${meta.id}_summary_chainwise_ptm.tsv - done - - cp ${meta.id}_0_chainwise_iptm.tsv ${meta.id}_summary_chainwise_iptm.tsv - for i in {1..4}; do - paste ${meta.id}_summary_chainwise_iptm.tsv <(cut -f2 ${meta.id}_${i}_chainwise_iptm.tsv) > temp && mv temp ${meta.id}_summary_chainwise_iptm.tsv - done - + --csvs boltz_results_*/msa/${meta.id}_*.csv cat <<-END_VERSIONS > versions.yml "${task.process}": @@ -108,10 +95,8 @@ process RUN_BOLTZ { touch "${meta.id}_0_pae.tsv" touch "${meta.id}_0_ptm.tsv" touch "${meta.id}_0_iptm.tsv" - touch "${meta.id}_0_chainwise_ptm.tsv" - touch "${meta.id}_summary_chainwise_ptm.tsv" - touch "${meta.id}_0_chainwise_iptm.tsv" - touch "${meta.id}_summary_chainwise_iptm.tsv" + touch "${meta.id}_chainwise_ptm.tsv" + touch "${meta.id}_chainwise_iptm.tsv" cat <<-END_VERSIONS > versions.yml "${task.process}": From 99bf0e260c291bb1d07b713d313b0d8dce6d9098 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Fri, 8 Aug 2025 12:22:06 +1000 Subject: [PATCH 146/150] Make iptm optional for monomer mode --- modules/local/run_boltz/main.nf | 4 ++-- modules/local/run_helixfold3/main.nf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index 34f69449f..e30c9f1aa 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -32,9 +32,9 @@ process RUN_BOLTZ { tuple val(meta), path ("${meta.id}_msa.tsv") , optional: true, emit: msa_raw tuple val(meta), path ("${meta.id}_*_pae.tsv") , emit: pae_raw tuple val(meta), path ("${meta.id}_ptm.tsv") , emit: ptm_raw - tuple val(meta), path ("${meta.id}_iptm.tsv") , emit: iptm_raw + tuple val(meta), path ("${meta.id}_iptm.tsv") , optional: true, emit: iptm_raw tuple val(meta), path ("${meta.id}_chainwise_ptm.tsv") , emit: summary_chainwise_ptm_raw - tuple val(meta), path ("${meta.id}_chainwise_iptm.tsv") , emit: chainwise_iptm_raw + tuple val(meta), path ("${meta.id}_chainwise_iptm.tsv") , optional: true, emit: chainwise_iptm_raw path "versions.yml", emit: versions diff --git a/modules/local/run_helixfold3/main.nf b/modules/local/run_helixfold3/main.nf index 227cd7443..9d5cd337b 100644 --- a/modules/local/run_helixfold3/main.nf +++ b/modules/local/run_helixfold3/main.nf @@ -31,9 +31,9 @@ process RUN_HELIXFOLD3 { tuple val(meta), path ("${meta.id}_plddt.tsv") , emit: multiqc tuple val(meta), path ("${meta.id}_msa.tsv") , emit: msa // If ${meta.id}-rank*/all_results.json" doesn't have PAE vales in the key, this will be empty - tuple val(meta), path ("${meta.id}_*_pae.tsv") , emit: paes + tuple val(meta), path ("${meta.id}_*_pae.tsv") , emit: paes tuple val(meta), path ("${meta.id}_ptm.tsv") , emit: ptms - tuple val(meta), path ("${meta.id}_iptm.tsv") , emit: iptms + tuple val(meta), path ("${meta.id}_iptm.tsv") , optional: true, emit: iptms path ("versions.yml") , emit: versions when: From e65a400bc68a1d1220586a6789cc6629b65694b7 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Fri, 8 Aug 2025 12:39:27 +1000 Subject: [PATCH 147/150] fix linting --- bin/extract_metrics.py | 14 +++++++------- bin/utils.py | 2 +- modules/local/run_boltz/main.nf | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 28359e303..7c747d9d5 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -86,7 +86,7 @@ def idx_to_letter(idx): iptm_rows = [[""]+[f"{chain_ids[idx[0]]}:{chain_ids[idx[1]]}" for idx, val in next(iter(chain_pair_entries.values()))]] else: iptm_rows = [[""]+[f"{idx_to_letter(idx[0])}:{idx_to_letter(idx[1])}" for idx, val in next(iter(chain_pair_entries.values()))]] - + for model_idx, chain_pair_entries_values in chain_pair_entries.items(): iptm_rows.append([model_idx]+[f"{val:.4f}" for idx, val in chain_pair_entries_values]) @@ -247,7 +247,7 @@ def read_json(name, json_files): print(f"No pTM/iPTM output in {json_file}, it was likely a monomer calculation") else: iptm_data[model_id] = f"{np.round(data['iptm'],3)}\n" - + if 'chain_pair_iptm' not in data.keys() and 'pair_chains_iptm' not in data.keys(): print(f"No chain-wise iPTM output in {json_file}, it was likely a monomer calculation") else: @@ -260,25 +260,25 @@ def read_json(name, json_files): chain_iptm_matrix = np.array([[chain_pair_iptm_data[row][col] for col in sorted(chain_pair_iptm_data[row], key=int)] for row in sorted(chain_pair_iptm_data, key=int)]) basename = os.path.basename(json_file) dirname = os.path.dirname(json_file) - pdb_name = ".".join(basename[11:].split('.')[:-1])+'.pdb' #TODO: Fix magic number + pdb_name = ".".join(basename[11:].split('.')[:-1])+'.pdb' #TODO: Fix magic number chain_ids = get_chain_ids(os.path.join(dirname,pdb_name)) else: raise ValueError("No chain-wise iPTM data found in the JSON file.") - + chain_pair_entries[model_id] = chain_iptm_matrix_to_pairs(chain_iptm_matrix) chainwise_ptms[model_id] = chainwise_iptm_matrix_to_ptms(chain_iptm_matrix) if chainwise_ptms: write_tsv(f"{name}_chainwise_ptm.tsv", format_iptm_rows(chainwise_ptms, chain_ids=chain_ids)) - + if chain_pair_entries: write_tsv(f"{name}_chainwise_iptm.tsv", format_iptm_rows(chain_pair_entries, chain_ids=chain_ids)) - if ptm_data: + if ptm_data: with open(f"{name}_ptm.tsv", 'w') as f: for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): f.write(f"{k} {v}") - + if iptm_data: with open(f"{name}_iptm.tsv", 'w') as f: for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): diff --git a/bin/utils.py b/bin/utils.py index 4c66444de..60f2f1cd8 100755 --- a/bin/utils.py +++ b/bin/utils.py @@ -109,4 +109,4 @@ def plddt_from_struct_b_factor_biopython(struct_file): if bio_is_installed: plddt_from_struct_b_factor = plddt_from_struct_b_factor_biopython else: - plddt_from_struct_b_factor = plddt_from_struct_b_factor_adhoc \ No newline at end of file + plddt_from_struct_b_factor = plddt_from_struct_b_factor_adhoc diff --git a/modules/local/run_boltz/main.nf b/modules/local/run_boltz/main.nf index e30c9f1aa..4b91ef91b 100644 --- a/modules/local/run_boltz/main.nf +++ b/modules/local/run_boltz/main.nf @@ -61,13 +61,13 @@ process RUN_BOLTZ { export HOME=/tmp boltz predict "${fasta}" --output_format "pdb" ${args} --cache ./ - cp boltz_results_*/predictions/${meta.id}/*_0.pdb ./${meta.id}_boltz.pdb + cp boltz_results_*/predictions/${meta.id}/*_0.pdb ./${meta.id}_boltz.pdb extract_metrics.py --name ${meta.id} \\ --structs boltz_results_*/predictions/${meta.id}/*.pdb \\ --jsons boltz_results_*/predictions/${meta.id}/confidence_*_model_*.json \\ --npzs boltz_results_*/predictions/${meta.id}/pae_*_model_*.npz \\ - --csvs boltz_results_*/msa/${meta.id}_*.csv + --csvs boltz_results_*/msa/${meta.id}_*.csv cat <<-END_VERSIONS > versions.yml "${task.process}": From 576e2a68e1a01383fa724d7976ebfe941492a83f Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Fri, 8 Aug 2025 12:46:48 +1000 Subject: [PATCH 148/150] Update changelog --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 08ec261a3..1d98455cf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -59,6 +59,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [[PR #360](https://github.com/nf-core/proteinfold/pull/360)] - Rename some DBs paths in the run modules so they are equal to those when DBs are downloaded. - [[PR #362](https://github.com/nf-core/proteinfold/pull/355)] - Update boltz Dockerfile and image pinning specific version (2.0.3). - [[#364](https://github.com/nf-core/proteinfold/issues/364)] - Move Dockerfiles to its corresponding module. +- [[PR #370](https://github.com/nf-core/proteinfold/pull/370)] - Fix extract chain metrics. +- [[#367](https://github.com/nf-core/proteinfold/issues/367)] - Boltz post-processing crashes. +- [[#368](https://github.com/nf-core/proteinfold/issues/368)] - Helixfold3 iPTM output missing when dealing with monomers make the process to fail. ### Parameters From 727db5287c43ce1eed117bb772f77468ab547427 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Fri, 8 Aug 2025 15:05:25 +1000 Subject: [PATCH 149/150] use csvwriter for extract_metrics --- bin/extract_metrics.py | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/bin/extract_metrics.py b/bin/extract_metrics.py index 7c747d9d5..f14b4aab8 100755 --- a/bin/extract_metrics.py +++ b/bin/extract_metrics.py @@ -164,12 +164,12 @@ def read_pkl(name, pkl_files): ptm_data[f"{model_id}"] = f"{np.round(data['ptm'],3)}\n" iptm_data[f"{model_id}"] = f"{np.round(data.get('iptm',0.),3)}\n" if ptm_data: - with open(f"{name}_ptm.tsv", 'w') as f: - for k, v in ptm_data.items(): #probably better to be ordered - f.write(f"{k} {v}") - with open(f"{name}_iptm.tsv", 'w') as f: - for k, v in iptm_data.items(): #probably better to be ordered - f.write(f"{k} {v}") + ptm_rows = [[k, v.strip()] for k, v in ptm_data.items()] + write_tsv(f"{name}_ptm.tsv", ptm_rows) + + if iptm_data: + iptm_rows = [[k, v.strip()] for k, v in iptm_data.items()] + write_tsv(f"{name}_iptm.tsv", iptm_rows) @@ -275,14 +275,12 @@ def read_json(name, json_files): write_tsv(f"{name}_chainwise_iptm.tsv", format_iptm_rows(chain_pair_entries, chain_ids=chain_ids)) if ptm_data: - with open(f"{name}_ptm.tsv", 'w') as f: - for k, v in sorted(ptm_data.items(), key=lambda x: x[0]): - f.write(f"{k} {v}") + ptm_rows = [[k, v.strip()] for k, v in sorted(ptm_data.items(), key=lambda x: x[0])] + write_tsv(f"{name}_ptm.tsv", ptm_rows) if iptm_data: - with open(f"{name}_iptm.tsv", 'w') as f: - for k, v in sorted(iptm_data.items(), key=lambda x: x[0]): - f.write(f"{k} {v}") + iptm_rows = [[k, v.strip()] for k, v in sorted(iptm_data.items(), key=lambda x: x[0])] + write_tsv(f"{name}_iptm.tsv", iptm_rows) def read_pt(name, pt_files): From 2c479b675d4d23113b6d36683f18be57feb1ec21 Mon Sep 17 00:00:00 2001 From: Thomas Litfin Date: Fri, 8 Aug 2025 17:09:36 +1000 Subject: [PATCH 150/150] fix create_colabfold_index param --- main.nf | 2 +- subworkflows/local/prepare_colabfold_dbs.nf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/main.nf b/main.nf index f7902947a..afe65f15b 100644 --- a/main.nf +++ b/main.nf @@ -455,7 +455,7 @@ workflow NFCORE_PROTEINFOLD { params.colabfold_alphafold2_params_link, params.colabfold_db_link, params.colabfold_uniref30_link, - params.create_colabfold_index + params.colabfold_create_index ) ch_versions = ch_versions.mix(PREPARE_COLABFOLD_DBS.out.versions) diff --git a/subworkflows/local/prepare_colabfold_dbs.nf b/subworkflows/local/prepare_colabfold_dbs.nf index 7e01e94c5..aafb1b989 100644 --- a/subworkflows/local/prepare_colabfold_dbs.nf +++ b/subworkflows/local/prepare_colabfold_dbs.nf @@ -55,7 +55,7 @@ workflow PREPARE_COLABFOLD_DBS { ch_colabfold_db = MMSEQS_TSV2EXPROFILEDB_COLABFOLDDB.out.db_exprofile ch_versions = ch_versions.mix(MMSEQS_TSV2EXPROFILEDB_COLABFOLDDB.out.versions) - if (params.create_colabfold_index) { + if (params.colabfold_create_index) { MMSEQS_CREATEINDEX_COLABFOLDDB ( MMSEQS_TSV2EXPROFILEDB_COLABFOLDDB.out.db_exprofile )