Skip to content

Add singlem#702

Draft
dgodin19 wants to merge 13 commits intonf-core:devfrom
dgodin19:singlem
Draft

Add singlem#702
dgodin19 wants to merge 13 commits intonf-core:devfrom
dgodin19:singlem

Conversation

@dgodin19
Copy link

Summary

This PR is an initial attempt to add support for SingleM to the profiling layer of the pipeline.

This work was started during the March 2026 nf-core hackathon by Dennis and Jack.

Changes

The following changes were made:

  • Added a singlem module to modules/nfcore/singlem/singlem
  • Integrated SingleM into the profiling.nf subworkflow
  • Updated nextflow.config
  • Added example samplesheet.csv and databases.csv files for testing

Running the module

I was able to run the module successfully with:
nextflow run main.nf -profile conda --input samplesheet.csv --databases databases.csv --outdir test_out

Database setup

SingleM requires pre-downloaded marker gene data. This must currently be done manually before running the pipeline.

Example workflow:

  1. Create a conda environment with SingleM

  2. Run:
    singlem data --output-directory /path/to/dbs

  3. Add the resulting directory to the databases.csv

Example database and sample sheets have been included in the repository for reference.

Container issues

I attempted to run the module with both Docker and Singularity profiles. However, I encountered an error related to the -ps option in Nextflow. The exact error was something like:
Command error: Command 'ps' required by nextflow to collect task metrics cannot be found

The container referenced in the SingleM documentation appears to be minimal and may be read-only. Because of this, it may be preferable to build a custom container including:

  • SingleM
  • required dependencies
  • writable data directory

and publish it to quay.io.

Remaining issues / TODO

The module produces output, but there are still some integration steps remaining:

  • Integration with taxpasta (currently taxpasta does not support SingleM output format)
  • Adding SingleM results to MultiQC

I started reviewing taxpasta documentation but did not complete this integration.

Notes

This PR is intended as a starting point for discussion and further development.

@jfy133 jfy133 linked an issue Mar 15, 2026 that may be closed by this pull request
@jfy133 jfy133 changed the title Singlem Add singlem Mar 15, 2026
@jfy133
Copy link
Member

jfy133 commented Mar 16, 2026

@dgodin19 confirmed on Slack this was a hackathon project, and likely would not be able to continue

However this is a good scaffold we can continue from (thank you for kicking it off @dgodin19 !), so we leave the
PR open to update in the future.

Some initial notes from a quick review:

  1. The module is currently actually a local module but in the wrong directory. We need to convert that to a proper nf-core module, following the nf-core standards (E.g. use of biocontainers etc)
  2. Some files were incorrectly edited/added (.gitattributes, databases_empty.csv)

But the profiling code looks good, for example, and the new parameters in nextflow.config.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

New profiler: singleM

4 participants