Daniel Lundin
04/04/2024, 12:06 PMDaniel Lundin
06/26/2024, 2:44 PMDaniel Lundin
06/26/2024, 2:58 PMqueryseqfile: 'archaeal_sequences.fna'
refphylogeny: '<https://figshare.scilifelab.se/ndownloader/files/45818916>'
refseqfile: '<https://figshare.scilifelab.se/ndownloader/files/45818919>'
taxonomy: '<https://figshare.scilifelab.se/ndownloader/files/45828279>'
model: 'GTR+F+I+G4'
Bacteria:
queryseqfile: 'bacterial_sequences.fna'
refphylogeny: '<https://figshare.scilifelab.se/ndownloader/files/45818913> bac120.newick'
refseqfile: '<https://figshare.scilifelab.se/ndownloader/files/45818925> bac120.alnfna'
taxonomy: '<https://figshare.scilifelab.se/ndownloader/files/45828282> bac120.taxonomy.tsv'
model: 'GTR+F+I+G4'
Note that there's also a way of writing a samplesheet.csv with the above information:
sample,alignmethod,queryseqfile,refseqfile,refphylogeny,model,taxonomy
bacteria-r08rs214,mafft,bacterial_sequences.fna,<https://figshare.scilifelab.se/ndownloader/files/45818925,https://figshare.scilifelab.se/ndownloader/files/45818913,GTR+F+I+G4,https://figshare.scilifelab.se/ndownloader/files/45828282>
archaea-r08rs214,mafft,archaeal_sequences.fna,<https://figshare.scilifelab.se/ndownloader/files/45818919,https://figshare.scilifelab.se/ndownloader/files/45818916,GTR+F+I+G4,https://figshare.scilifelab.se/ndownloader/files/45828279>
Use with --input.Mark Pampuch
10/29/2024, 7:33 PMDaniel Lundin
02/21/2025, 4:55 PM--phyloplace_input param, which retires the --input param. The new mode -- "phylosearch" -- uses the --phylosearch_input param. The nf-core homepage is not yet updated, but when it is: Check out the documentation there.
My thanks to my reviewers: @Daniel Straub, @Maxime Garcia and @mashehu and every other nf-core member I pestered with questions!Adrià Auladell
03/03/2025, 10:39 AMFeatureCounts output from metatdenovo as a quantification then, after obtaining the ORFs and placing them. That makes quite a lot of sense. Since I was coming from the approaches made by gappa and EPA that focus mostly on placing reads I did not think on this approach. The ORFs however could be included directly in the alignment and tree avoiding EPA no? Or this would make everything slower.
Thanks for your time!Daniel Lundin
03/03/2025, 10:50 AMresults/summary_tables, particularly *.counts.tsv.gz as this is nicely formatted) is the approach I'd advocate.
When it comes to making the trees there's more to think about. You can certainly estimate a de novo phylogeny from the ORF sequences. Since your samples are unlikely to contain a good representation of the sequence space for each protein, however, placing in a reference tree (that was estimated from a balanced selection of sequences) is safer. It will also be faster since in phylogenetic placement, each sequence is placed individually. Resource requirements (cpu) will hence scale linearly with the number of sequences (memory is basically flat), which is not the case with full phylogenetics. The only drawback I see is that with placement you will not resolve the individual sequences' branching when they happen to branch off the reference tree at the same place. In other words, quite similar/closely related sequences will show up as a "multitomy", a brush in the resulting tree.Adrià Auladell
03/03/2025, 11:53 AMDaniel Lundin
03/03/2025, 12:23 PMNicolai Laufer
04/28/2025, 6:56 AMNicolai Laufer
09/21/2025, 12:45 PMNFCORE_AMPLISEQ:AMPLISEQ:FASTA_NEWICK_EPANG_GAPPA:GAPPA_ASSIGN (bac120.r10rs226) terminated for an unknown reason -- Likely it has been terminated by the external system
Command executed:
gappa \
examine assign \
--per-query-results --krona --sativa \
--threads 6 \
--jplace-path bac120.r10rs226.epa_result.jplace.gz \
--taxon-file sbdi-gtdb-sativa.r10rs226.bac120.sprep.taxonomy.tsv \
--file-prefix bac120.r10rs226.taxonomy.
cat <<-END_VERSIONS > versions.yml
"NFCORE_AMPLISEQAMPLISEQFASTA_NEWICK_EPANG_GAPPA:GAPPA_ASSIGN":
gappa: $(echo $(gappa --version 2>&1 | sed 's/v//' ))
END_VERSIONS
Command exit status:
-
Command output:
...' .... ... ... ... ... .... .|'|.
| || '' .|| ||' || ||' || '' .|| .|' ||
|'' .|' || || | || | .|' || .|'|. ||
'.... '|..'|'. ||...' ||...' '|..'|. '||' ||:.
'....' || ||
'''' '''' v0.8.0 (c) 2017-2022
by Lucas Czech and Pierre Barbera
Invocation: gappa examine assign --per-query-results --krona --sativa --threads 6 --jplace-path bac120.r10rs226.epa_result.jplace.gz --taxon-file sbdi-gtdb-sativa.r10rs226.bac120.sprep.taxonomy.tsv --file-prefix bac120.r10rs226.taxonomy.
Command: gappa examine assign
Input:
--jplace-path bac120.r10rs226.epa_result.jplace.gz
--taxon-file sbdi-gtdb-sativa.r10rs226.bac120.sprep.taxonomy.tsv
--root-outgroup
--taxonomy
--ranks-string superkingdom|phylum|class|order|family|genus|species
Settings:
--sub-taxopath
--max-level 0
--distribution-ratio -1
--consensus-thresh 1
--resolve-missing-paths false
--distant-label false
Output:
--out-dir .
--file-prefix bac120.r10rs226.taxonomy.
--file-suffix
--cami false
--sample-id
--krona true
--sativa true
--per-query-results true
--best-hit false
Global Options:
--allow-file-overwriting false
--verbose false
--threads 6
--log-file
Run the following command to get the references that need to be cited:
gappa tools citation Czech2020-genesis-and-gappa
Started 2025-09-21 143340
Found 1 jplace file
Running the assignment
Command error:
INFO: Environment variable SINGULARITYENV_TMPDIR is set, but APPTAINERENV_TMPDIR is preferred
INFO: Environment variable SINGULARITYENV_NXF_TASK_WORKDIR is set, but APPTAINERENV_NXF_TASK_WORKDIR is preferred
INFO: Environment variable SINGULARITYENV_NXF_DEBUG is set, but APPTAINERENV_NXF_DEBUG is preferred
INFO: fuse2fs not found, will not be able to mount EXT3 filesystems
INFO: gocryptfs not found, will not be able to use gocryptfs
Work dir:
/cfs/klemming/projects/supr/naiss2025-22-1066/ampliseq/work/9f/08e866f71ac92b3d080d803f8261d7
Container:
/cfs/klemming/projects/supr/naiss2025-22-1066/ampliseq/work/singularity/depot.galaxyproject.org-singularity-gappa-0.8.0--h9a82719_0.img
Tip: you can replicate the issue by changing to the process work dir and entering the command bash .command.run
-- Check '.nextflow.log' file for details
ERROR ~ Pipeline failed. Please refer to troubleshooting docs: https://nf-co.re/docs/usage/troubleshooting
-- Check '.nextflow.log' file for details
ERROR ~ Failed to invoke workflow.onComplete event handler
-- Check script '/cfs/klemming/home/n/nicolai2/.nextflow/assets/nf-core/ampliseq/subworkflows/local/utils_nfcore_ampliseq_pipeline/main.nf' at line: 123 or see '.nextflow.log' file for more details
Can you help me with that?Nicolai Laufer
10/08/2025, 1:58 PMDaniel Lundin
10/08/2025, 3:04 PMAdrià Auladell
10/21/2025, 2:59 PMAdrià Auladell
10/21/2025, 2:59 PMCommand error:
INFO Selected: Output dir: ./
INFO Selected: Query file: 022_180-2000_DCM.query.hmmalign.masked.afa.gz
INFO Selected: Tree file: tree.nw
INFO Selected: Reference MSA: 022_180-2000_DCM.ref.hmmalign.masked.afa.gz
INFO Selected: Automatic switching of use of per rate scalers
INFO Selected: Preserving the root of the input tree
INFO Selected: Specified model: LG+R8
INFO Selected: Using threads: 12
INFO ______ ____ ___ _ __ ______
/ ____// __ \ / | / | / // ____/
/ __/ / /_/ // /| | ______ / |/ // / __
/ /___ / ____// ___ |/_____// /| // /_/ /
/_____//_/ /_/ |_| /_/ |_/ \____/ (v0.3.8)
INFO Using model parameters:
INFO Rate heterogeneity: FREE (8 cats, mean), weights&rates: (0.125,0.0652803) (0.125,0.208627) (0.125,0.376074) (0.125,0.577429) (0.125,0.830101) (0.125,1.1699) (0.125,1.69315) (0.125,3.07944)
Base frequencies (model): 0.079066 0.055941 0.041977 0.053052 0.012937 0.040767 0.071586 0.057337 0.022355 0.062157 0.099081 0.0646 0.022951 0.042302 0.04404 0.061197 0.053287 0.012066 0.034155 0.069147
Substitution rates (model): 0.425093 0.276818 0.395144 2.48908 0.969894 1.03855 2.06604 0.358858 0.14983 0.395337 0.536518 1.12403 0.253701 1.17765 4.72718 2.1395 0.180717 0.218959 2.54787 0.751878 0.123954 0.534551 2.80791 0.36397 0.390192 2.4266 0.126991 0.301848 6.32607 0.484133 0.052722 0.332533 0.858151 0.578987 0.593607 0.31444 0.170887 5.07615 0.528768 1.69575 0.541712 1.43765 4.50924 0.191503 0.068427 2.14508 0.371004 0.089525 0.161787 4.00836 2.00068 0.045376 0.612025 0.083688 0.062556 0.523386 5.24387 0.844926 0.927114 0.01069 0.015076 0.282959 0.025548 0.017416 0.394456 1.24028 0.42586 0.02989 0.135107 0.037967 0.084808 0.003499 0.569265 0.640543 0.320627 0.594007 0.013266 0.89368 1.10525 0.075382 2.78448 1.14348 0.670128 1.16553 1.95929 4.12859 0.267959 4.81351 0.072854 0.582457 3.23429 1.67257 0.035855 0.624294 1.22383 1.08014 0.236199 0.257336 0.210332 0.348847 0.423881 0.044265 0.069673 1.80718 0.173735 0.018811 0.419409 0.611973 0.604545 0.077852 0.120037 0.245034 0.311484 0.008705 0.044261 0.296636 0.139538 0.089586 0.196961 1.73999 0.129836 0.268491 0.054679 0.076701 0.108882 0.366317 0.697264 0.442472 0.682139 0.508851 0.990012 0.584262 0.597054 5.30683 0.119013 4.14507 0.159069 4.27361 1.11273 0.078281 0.064105 1.03374 0.11166 0.232523 10.6491 0.1375 6.31236 2.59269 0.24906 0.182287 0.302936 0.619632 0.299648 1.70274 0.656604 0.023918 0.390322 0.748683 1.13686 0.049906 0.131932 0.185202 1.79885 0.099849 0.34696 2.02037 0.696175 0.481306 1.89872 0.094464 0.361819 0.165001 2.45712 7.8039 0.654683 1.33813 0.571468 0.095131 0.089613 0.296501 6.47228 0.248862 0.400547 0.098369 0.140825 0.245841 2.18816 3.15182 0.18951 0.249313
INFO Output file: ./epa_result.jplace
terminate called after throwing an instance of 'std::runtime_error'
what(): Sequence with header '022_180-2000_DCM_ERR1712074.25146093_1;weight=1;' does not appear to have any non-gap sites!
/scratch/data3/aauladell/project_big/phylotranscriptomics/work/aa/ba4d9e9061f842ee0c944df9a618b1/.command.sh: line 9: 41 Aborted (core dumped) epa-ng --model LG+R8 --threads 12 --query 022_180-2000_DCM.query.hmmalign.masked.afa.gz --ref-msa 022_180-2000_DCM.ref.hmmalign.masked.afa.gz --tree tree.nw
Work dir:
/scratch/data3/aauladell/project_big/phylotranscriptomics/work/53/85520b58953e69bd4e91f9d0e0f79aAdrià Auladell
10/21/2025, 3:01 PMBy default,enables premasking, which works similarily to the same option in pplacer: If a site of the alignment is all-gaps in either the reference OR query alignment, throw it out. Further, for each query sequence, ignore the leading, and trailing gap columns (this is where we differ from pplacer, as they ignore ALL query gap columns).EPA-ng
Adrià Auladell
10/21/2025, 3:01 PMAdrià Auladell
10/21/2025, 3:01 PMNicolai Laufer
10/24/2025, 4:03 PMDaniel Lundin
10/27/2025, 8:38 AMAdrià Auladell
10/29/2025, 9:49 AM--no-pre-mask flag since it happened for more than 10% of the samples was too much. The options are 1) to include the HMM cleaning as you said and 2) to add the flag, which works because I tested it with one sample. Given that these are a minority of reads I think its a good workaround, and sometimes the users won't have an specific HMM to use I think.This opened though a question when I tried to run the workflow adding by myself the tag. I thought that I should add it in the nextflow.config following this schema:
process {
withName: 'EPANG_PLACE' {
ext.args = ['--no-pre-mask']
}
}
But if I add this, the software is unable to find the files, throwing this error.
ERROR ~ Argument of file function cannot be null
I am guessing that the call ext.args does not include the value upfront but substitutes partially the input that you give manually?
This is my call:
nextflow run nf-core/phyloplace --input data/placement_phyloplace/SIT/SIT_undone_samsheet.csv -profile singularity --outdir data/placement_phyloplace/SIT
Thanks!
PD: it is possible that the error comes from me using a previous version of nextflow (v23) or from the pipeline, I will be testing this, but if your intuition tells you that this is the problem just say that and sorry beforehand!)Adrià Auladell
12/02/2025, 5:03 PM--no-pre-mask option it slows the overall performance.
If I check the number of seqs in the output of hmmalign I can have something like this:
file format type num_seqs sum_len min_len avg_len max_len
- FASTA Protein 250,212 7,200,646 1 28.8 610
(take into account that the length is with gaps removed)
If I filter out any sequence below 15 aa I get something like this:
file format type num_seqs sum_len min_len avg_len max_len
- FASTA Protein 66,256 6,846,372 15 103.3 610
It is quite a reduction. Could it be a step of the pipeline? Or else we should understand what is happening with hmmalign? Let me know what you think, thanks!Nicolai Laufer
02/12/2026, 12:09 PMNFCORE_AMPLISEQ:AMPLISEQ:FASTA_NEWICK_EPANG_GAPPA:EPANG_PLACE (bac120.r10rs226) terminated for an unknown reason -- Likely it has been terminated by the external system
Command executed:
epa-ng \
--model GTR+F+I+G4 \
--threads 10 \
--query bac120.r10rs226.query.hmmalign.masked.afa.gz \
--ref-msa bac120.r10rs226.ref.hmmalign.masked.afa.gz \
--tree sbdi-gtdb-sativa.r10rs226-2.bac120.sprepr.brlenopt.newick \
\
if [ -e epa_result.jplace ]; then
gzip epa_result.jplace
cp epa_result.jplace.gz bac120.r10rs226.epa_result.jplace.gz
fi
[ -e epa_info.log ] && cp epa_info.log bac120.r10rs226.epa_info.log
cat <<-END_VERSIONS > versions.yml
"NFCORE_AMPLISEQAMPLISEQFASTA_NEWICK_EPANG_GAPPA:EPANG_PLACE":
epang: $(echo $(epa-ng --version 2>&1) | sed 's/^EPA-ng v//')
END_VERSIONS
Command exit status:
-
Command output:
INFO Selected: Output dir: ./
INFO Selected: Query file: bac120.r10rs226.query.hmmalign.masked.afa.gz
INFO Selected: Tree file: sbdi-gtdb-sativa.r10rs226-2.bac120.sprepr.brlenopt.newick
INFO Selected: Reference MSA: bac120.r10rs226.ref.hmmalign.masked.afa.gz
INFO Selected: Automatic switching of use of per rate scalers
INFO Selected: Preserving the root of the input tree
INFO Selected: Specified model: GTR+F+I+G4
INFO Selected: Using threads: 10
INFO ______ __ _ _ __ ______
/ ____// __ \ / | / | / // ____/
/ __/ / /_/ // /| | ______ / |/ // / __
/ /___ / ____// _ |/_____// /| // /_/ /
/_____//_/ /_/ |_| /_/ |_/ \____/ (v0.3.8)
INFO Using model parameters:
INFO Rate heterogeneity: GAMMA (4 cats, mean), alpha: 1 (ML), weights&rates: (0.25,0.136954) (0.25,0.476752) (0.25,1) (0.25,2.38629)
P-inv (ML): 0
Base frequencies (empirical): 0.254302 0.200097 0.338562 0.207039
Substitution rates (ML): 0.5 0.5 0.5 0.5 0.5 1
INFO Output file: ./epa_result.jplace
Command error:
INFO: Environment variable SINGULARITYENV_TMPDIR is set, but APPTAINERENV_TMPDIR is preferred
INFO: Environment variable SINGULARITYENV_NXF_TASK_WORKDIR is set, but APPTAINERENV_NXF_TASK_WORKDIR is preferred
INFO: Environment variable SINGULARITYENV_NXF_DEBUG is set, but APPTAINERENV_NXF_DEBUG is preferred
INFO: fuse2fs not found, will not be able to mount EXT3 filesystems
INFO: gocryptfs not found, will not be able to use gocryptfs
Work dir:
/cfs/klemming/projects/supr/naiss2025-22-1066/ampliseq/work/f8/5d7a34040c5551fd0a55eb9b7a8a89
Container:
/cfs/klemming/projects/supr/naiss2025-22-1066/ampliseq/work/singularity/depot.galaxyproject.org-singularity-epa-ng-0.3.8--h9a82719_1.img
Tip: when you have fixed the problem you can continue the execution adding the option -resume to the run command line
-- Check '.nextflow.log' file for details
ERROR ~ Pipeline failed. Please refer to troubleshooting docs: https://nf-co.re/docs/usage/troubleshooting
-- Check '.nextflow.log' file for details
My params-file looks like this:
{
"input": "manifest_BS.tsv",
"skip_cutadapt": true,
"outdir": "results_new",
"pplace_tree": "/cfs/klemming/projects/snic/naiss2023-22-1217/ampliseq_analysis/SBDI_GTDB_v11/sbdi-gtdb-sativa.r10rs226-2.bac120.sprepr.brlenopt.newick",
"pplace_aln": "/cfs/klemming/projects/snic/naiss2023-22-1217/ampliseq_analysis/SBDI_GTDB_v11/sbdi-gtdb-sativa.r10rs226-2.bac120.sprepr.alnfna",
"pplace_taxonomy": "/cfs/klemming/projects/snic/naiss2023-22-1217/ampliseq_analysis/SBDI_GTDB_v11/sbdi-gtdb-sativa.r10rs226-2.bac120.sprepr.taxonomy.tsv",
"pplace_model": "GTR+F+I+G4",
"pplace_name": "bac120.r10rs226",
"skip_qiime_downstream": true,
"skip_barplot": true,
"skip_abundance_tables": true,
"skip_alpha_rarefaction": true,
"skip_ancom": true,
"picrust": false
}
Can you please help me with this? Thank you!Full test notifications
06/15/2026, 1:00 PMFull test notifications
06/16/2026, 9:02 AMDaniel Lundin
06/16/2026, 9:09 AMFull test notifications
07/24/2026, 3:59 PMDaniel Lundin
08/03/2026, 6:39 AMDaniel Lundin
09/11/2026, 7:24 AMDaniel Lundin
09/23/2026, 9:07 AM