Skip to content

Commit

Permalink
change the definition of target name, which will directly depends on …
Browse files Browse the repository at this point in the history
…fasta file (#42)
  • Loading branch information
BaozCWJ authored Sep 7, 2022
1 parent b81d59d commit d5bf17e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions run_unifold.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ python unifold/homo_search.py \
--mgnify_database_path=$database_dir/mgnify/mgy_clusters_2018_12.fa \
--bfd_database_path=$database_dir/bfd/bfd_metaclust_clu_complete_id30_c90_final_seq.sorted_opt \
--uniclust30_database_path=$database_dir/uniclust30/uniclust30_2018_08/uniclust30_2018_08 \
--uniprot_database_path=$database_dir/uniprot_db/uniprot_220501/uniprot_trembl.fasta \
--uniprot_database_path=$database_dir/uniprot/uniprot.fasta \
--pdb_seqres_database_path=$database_dir/pdb_seqres/pdb_seqres.txt \
--template_mmcif_dir=$database_dir/pdb_mmcif/mmcif_files \
--obsolete_pdbs_path=$database_dir/pdb_mmcif/obsolete.dat \
--use_precomputed_msas=True

echo "Starting prediction..."
fasta_dir=$(dirname $fasta_path)
target_name=${fasta_dir##*/}
fasta_file=$(basename $fasta_path)
target_name=${fasta_file%.fa*}
python unifold/inference.py \
--model_name=$model_name \
--param_path=$param_path \
Expand Down
3 changes: 2 additions & 1 deletion unifold/homo_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import json
import os
import pickle
from pathlib import Path
import shutil
import time
import gzip
Expand Down Expand Up @@ -261,7 +262,7 @@ def main(argv):
)

fasta_path = FLAGS.fasta_path
fasta_name = FLAGS.fasta_path.split("/")[-2]
fasta_name = Path(fasta_path).stem
input_fasta_str = open(fasta_path).read()
input_seqs, input_descs = parsers.parse_fasta(input_fasta_str)
if len(input_seqs) > 1:
Expand Down

0 comments on commit d5bf17e

Please sign in to comment.