Skip to content

Commit

Permalink
[ADD] reduced xrefs
Browse files Browse the repository at this point in the history
  • Loading branch information
alpae committed Dec 18, 2024
1 parent b79b75e commit 241ae58
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 2 deletions.
22 changes: 22 additions & 0 deletions modules/local/xref_fetch/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -135,3 +135,25 @@ process COMBINE_ALL_XREFS {
--xrefs $xref_dbs \\
"""
}

process BUILD_REDUCED_XREFS {
label "process_low"
container "dessimozlab/omabuild:nf-latest"
tag "Building a reduced set of xrefs for lookup and search"

input:
path db
path xref_db

output:
path("reduced-xrefs-db.h5"), emit: red_xref_db_h5

script:
"""
oma-build -vv reduced-xrefs \\
--out reduced-xrefs-db.h5 \\
--xrefs $xref_dbs \\
--db $db \\
--nr-procs ${task.cpus}
"""
}
2 changes: 2 additions & 0 deletions subworkflows/local/xrefs/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,11 @@ workflow GENERATE_XREFS {
db_h5,
seqidx_h5,
source_xref_h5)
BUILD_REDUCED_XREFS(db_h5, MAP_XREFS_WF.out.xref_db)


emit:
taxmap = PREPARE_XREFS.out.taxmap
xref_db = MAP_XREFS_WF.out.xref_db
red_xref_db = BUILD_REDUCED_XREFS.out.red_xref_db_h5
}
5 changes: 3 additions & 2 deletions workflows/oma_browser_build.nf
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ workflow OMA_BROWSER_BUILD {
DOMAINS(IMPORT_HDF5.out.db_h5, domains, cath_names, pfam_names)
domains_h5 = DOMAINS.out.domains_h5
} else {
domains_h5 = null
domains_h5 = Channel.empty()
}
CACHE_BUILDER(IMPORT_HDF5.out.db_h5)
GEN_BROWSER_AUX_FILES(IMPORT_HDF5.out.db_h5)
Expand All @@ -60,7 +60,8 @@ workflow OMA_BROWSER_BUILD {
domains_h5,
GENERATE_XREFS.out.xref_db,
GO_IMPORT.out.go_h5,
CACHE_BUILDER.out.cache_h5)
CACHE_BUILDER.out.cache_h5,
GENERATE_XREFS.out.red_xref_db)
h5_dbs_to_combine.view()
COMBINE_HDF(h5_dbs_to_combine.collect())

Expand Down

0 comments on commit 241ae58

Please sign in to comment.