Skip to content

Commit

Permalink
Merge pull request #35 from microbiomedata/rfam_mem
Browse files Browse the repository at this point in the history
rfam memory and jaws warnings
  • Loading branch information
kaijli authored Aug 9, 2024
2 parents 3786db2 + 9c8ce63 commit 6346f27
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 84 deletions.
16 changes: 6 additions & 10 deletions annotation_full.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ input {
String imgap_project_id
String database_location="/refdata/img/"
String imgap_project_type="metagenome"
String? gm_license="/refdata/licenses/.gmhmmp2_key"
String gm_license="/refdata/licenses/.gmhmmp2_key"
Int additional_threads=16
Int additional_memory = 100
String container="microbiomedata/img-omics@sha256:d5f4306bf36a97d55a3710280b940b89d7d4aca76a343e75b0e250734bc82b71"

# structural annotation
Expand Down Expand Up @@ -49,7 +50,8 @@ input {
imgap_project_type = imgap_project_type,
database_location = database_location,
container=container,
gm_license=gm_license
gm_license=gm_license,
additional_memory = additional_memory
}


Expand Down Expand Up @@ -148,9 +150,7 @@ input {
call finish_ano {
input:
container=container,
input_file=make_map_file.out_fasta,
proj=proj,
start=stage.start,
ano_info_file=make_info_file.imgap_info,
proteins_faa = merge_outputs.proteins_faa,
structural_gff = merge_outputs.structural_gff,
Expand Down Expand Up @@ -235,7 +235,7 @@ task stage {
input {
String container
String target="input.fasta"
String input_file
String input_file
}

command <<<
Expand Down Expand Up @@ -300,7 +300,7 @@ task make_map_file {
task split {
input {
File infile
String blocksize=100
Int blocksize=100
String zfile="zscore.txt"
String cmzfile="cmzscore.txt"
String container
Expand Down Expand Up @@ -504,8 +504,6 @@ task make_info_file {
String fa_version_file = "fa_tool_version.txt"
String fa_db_version_file = "fa_db_version.txt"
String rfam_version_file = "rfam_version.txt"
String sa_version_file = "sa_tool_version.txt"
String sa_db_version_file = "sa_db_version.txt"
}
command <<<
set -euo pipefail
Expand Down Expand Up @@ -618,9 +616,7 @@ task finish_ano {
String container
String proj
String prefix=sub(proj, ":", "_")
String start
File ano_info_file
File input_file
File proteins_faa
File structural_gff
File functional_gff
Expand Down
30 changes: 1 addition & 29 deletions functional-annotation.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,11 @@ workflow f_annotate {
Int? par_hmm_inst
Int? approx_num_proteins
String smart_db="~{database_location}"+"/SMART/01_06_2016/SMART.hmm"
String hmmsearch_bin="/opt/omics/bin/hmmsearch"
String frag_hits_filter_bin="/opt/omics/bin/functional_annotation/hmmsearch_fragmented_hits_filter.py"
String cog_db="~{database_location}"+"/COG/HMMs/2003/COG.hmm"
String tigrfam_db="~{database_location}"+"/TIGRFAM/v15.0/TIGRFAM.hmm"
String hit_selector_bin="/opt/omics/bin/functional_annotation/hmmsearch_hit_selector.py"
String superfam_db="~{database_location}"+"/SuperFamily/v1.75/supfam.hmm"
String pfam_db="~{database_location}"+"/Pfam/Pfam-A/v34.0/Pfam-A.v34.0.hmm"
String pfam_claninfo_tsv="~{database_location}"+"/Pfam/Pfam-A/v34.0/Pfam-A.clans.tsv"
String pfam_clan_filter="/opt/omics/bin/functional_annotation/pfam_clan_filter.py"
String cath_funfam_db="~{database_location}"+"/Cath-FunFam/v4.2.0/funfam.hmm"
# Boolean signalp_execute=true
# String signalp_gram_stain="GRAM_STAIN"
Expand Down Expand Up @@ -61,8 +57,6 @@ workflow f_annotate {
par_hmm_inst = par_hmm_inst,
approx_num_proteins = approx_num_proteins,
smart_db = smart_db,
hmmsearch = hmmsearch_bin,
frag_hits_filter = frag_hits_filter_bin,
container=hmm_container
}

Expand All @@ -74,8 +68,6 @@ workflow f_annotate {
par_hmm_inst = par_hmm_inst,
approx_num_proteins = approx_num_proteins,
cog_db = cog_db,
hmmsearch = hmmsearch_bin,
frag_hits_filter = frag_hits_filter_bin,
container=hmm_container
}

Expand All @@ -87,8 +79,6 @@ workflow f_annotate {
par_hmm_inst = par_hmm_inst,
approx_num_proteins = approx_num_proteins,
tigrfam_db = tigrfam_db,
hmmsearch = hmmsearch_bin,
hit_selector = hit_selector_bin,
container=hmm_container
}

Expand All @@ -100,8 +90,6 @@ workflow f_annotate {
par_hmm_inst = par_hmm_inst,
approx_num_proteins = approx_num_proteins,
superfam_db = superfam_db,
hmmsearch = hmmsearch_bin,
frag_hits_filter = frag_hits_filter_bin,
container=hmm_container
}

Expand All @@ -114,8 +102,6 @@ workflow f_annotate {
approx_num_proteins = approx_num_proteins,
pfam_db = pfam_db,
pfam_claninfo_tsv = pfam_claninfo_tsv,
pfam_clan_filter = pfam_clan_filter,
hmmsearch = hmmsearch_bin,
container=hmm_container
}

Expand All @@ -127,8 +113,6 @@ workflow f_annotate {
par_hmm_inst = par_hmm_inst,
approx_num_proteins = approx_num_proteins,
cath_funfam_db = cath_funfam_db,
hmmsearch = hmmsearch_bin,
frag_hits_filter = frag_hits_filter_bin,
container=hmm_container
}

Expand Down Expand Up @@ -256,8 +240,6 @@ task smart {
Float min_domain_eval_cutoff = 0.01
Float aln_length_ratio = 0.7
Float max_overlap_ratio = 0.1
String hmmsearch
String frag_hits_filter
String base=basename(input_fasta)
String container
String hmmsearch_version_file = "hmmsearch_version.txt"
Expand Down Expand Up @@ -304,8 +286,6 @@ task cog {
Float min_domain_eval_cutoff = 0.01
Float aln_length_ratio = 0.7
Float max_overlap_ratio = 0.1
String hmmsearch
String frag_hits_filter
String base=basename(input_fasta)
String container
String hmmsearch_version_file = "hmmsearch_version.txt"
Expand Down Expand Up @@ -351,8 +331,6 @@ task tigrfam {
Int approx_num_proteins = 0
Float aln_length_ratio = 0.7
Float max_overlap_ratio = 0.1
String hmmsearch
String hit_selector
String base=basename(input_fasta)
String container
String hmmsearch_version_file = "hmmsearch_version.txt"
Expand Down Expand Up @@ -400,8 +378,6 @@ task superfam {
Float min_domain_eval_cutoff = 0.01
Float aln_length_ratio = 0.7
Float max_overlap_ratio = 0.1
String hmmsearch
String frag_hits_filter
String base=basename(input_fasta)
String container
String hmmsearch_version_file = "hmmsearch_version.txt"
Expand Down Expand Up @@ -447,8 +423,6 @@ task pfam {
Int threads = 62
Int par_hmm_inst = 15
Int approx_num_proteins = 0
String hmmsearch
String pfam_clan_filter
String base=basename(input_fasta)
String container
String hmmsearch_version_file = "hmmsearch_version.txt"
Expand Down Expand Up @@ -495,8 +469,6 @@ task cath_funfam {
Float min_domain_eval_cutoff = 0.01
Float aln_length_ratio = 0.7
Float max_overlap_ratio = 0.1
String hmmsearch
String frag_hits_filter
String base=basename(input_fasta)
String container
String hmmsearch_version_file = "hmmsearch_version.txt"
Expand Down Expand Up @@ -529,7 +501,7 @@ task cath_funfam {
}
}

task signalp {
task run_signalp {
input {
String project_id
String prefix=sub(project_id, ":", "_")
Expand Down
8 changes: 6 additions & 2 deletions rfam.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ workflow rfam {
File imgap_input_fasta
String imgap_project_id
Int additional_threads
Int additional_memory
String database_location="/refdata/img/"
String cm="~{database_location}"+"Rfam/13.0/Rfam.cm"
String claninfo_tsv="~{database_location}"+"Rfam/13.0/Rfam.claninfo"
Expand All @@ -21,7 +22,8 @@ workflow rfam {
feature_lookup_tsv = feature_lookup_tsv,
claninfo_tsv = claninfo_tsv,
threads = additional_threads,
container=container
container=container,
memory = additional_memory
}

output {
Expand All @@ -43,6 +45,7 @@ task run {
String claninfo_tsv
String feature_lookup_tsv
Int threads
Int memory = 100
String container
String rfam_version_file = "rfam_version.txt"
}
Expand All @@ -67,8 +70,9 @@ task run {

runtime {
time: "1:00:00"
memory: "86G"
docker: container
cpu: threads
memory: "~{memory} GiB"
}

output {
Expand Down
Loading

0 comments on commit 6346f27

Please sign in to comment.