I am trying to convert my `EXECUTE_CLUSTERING` loc...
# subworkflows
e
I am trying to convert my
EXECUTE_CLUSTERING
local subworkflow to an nf-core one:
MMSEQS_FASTA_CLUSTER
. Is there a way to use a patched nf-core/module in an nf-core subworkflow? I want to use stageAs aliases in the inputs to avoid executing a module twice, the way it's done here: https://github.com/nf-core/proteinfamilies/blob/main/modules/nf-core/mmseqs/createtsv/main.nf Otherwise I would have to execute
MMSQES_CREATEDB
twice, which is a huge waste of resources and unnecessary code duplication. If not, is there a smarter way? We could always update the module to always use stageAs.. @Joon Klaps, @Jasmin Frangenberg?
j
On phone, so didnt check the code yet but couldnt you do an easy cluster?
Or is that not the point?
e
Oh, a clarification; I meant update the
MMSEQS_CREATETSV
module. The whole point of this is to have a ready-to-use nf-core subworkflow that goes from a fasta file to a clustering TSV (rep,member) along with per cluster fasta file.
j
Ooh yeah no totally update the createtsv module, no harm in just adding a stageAs in the input
🙏 1
e
Thanks! I'll wait for Jasmin's input since it's also used in funcscan, to make sure nothing breaks. And maybe any other idea from anyone else.
j
I don't follow the logic... why does setting the
stageAs
prevent running the module twice?
e
because in the case of clustering, you can use the createtsv module to extract the clustering.tsv. In this case, the query_db and the target_db must be the same db (created with CREATE_DB); inputs [1] and [2] respectively
So setting the stageAs in the MMSEQS_CREATETSV module, will give different folder names to the same db, preventing running the MMSEQS_CREATEDB module twice
I've patched the createtsv module in the nf-core/proteinfamilies pipeline, but I guess you can't use patched module in pure nf-core/subworkflows in the modules repo
j
No, I don't thin kyou can use patched modules in an official nf-core subwrofklow. But what would the harm be in setting stageAs for both in the module anyway?
You can still have the same in both even if they are in differently named folders? Right/
e
Yep!
j
I would just do that
e
Tested and works fine...will push the module change and then the subworkflow
👍 1
j
Late to the discussion because I focused elsewhere today, but got the e-mail from Github 😉 Agree to use stageAs here!
🙌 1
e
Thank y'all 😊
I updated the verisons on the PR and those were fixed..but I also get this docker-only error during MMSEQS_TAXONOMY...any idea why? https://github.com/nf-core/modules/actions/runs/17239040881/job/48911045591?pr=8949
Copy code
1211 Killed                  $RUNNER "$MMSEQS" prefilter "$INPUT" "$TARGET" "$TMP_PATH/pref_$STEP" $PREFILTER_PAR -s "$SENS"
    >   Error: Prefilter died
    >   Error: Search step died
    >   Error: First search died
Probably need to tune it for a bit more memory
j
I HATE MMSEQS
😆 1
j
Yes it's most likely dying due to memory. I got exactly the same errors for that module on our cluster, increasing mem solved 😬
e
And here is the subworkflow PR: https://github.com/nf-core/modules/pull/8951 Will also post in request-review tomorrow if you core people don't have the time for it 😛
oopsy, rebasing porbably went wrong because I still see the module changes I did..might reopen