ngless-toolkit / ngless

NGLess: NGS with less work
https://ngless.embl.de
Other
142 stars 24 forks source link

Implement readset return type types for modules #119

Open mkuhn opened 5 years ago

mkuhn commented 5 years ago

We were trying to add a filtering step as an external module (having a read set as input and output). However, only counts and mapped read sets are supported at the moment, everything else throws an exception:

https://github.com/ngless-toolkit/ngless/blob/bd2bed1f5d951f757c82bf4853c66103f91b5b14/NGLess/ExternalModules.hs#L284

We circumvented this by loading the results with load_mocat_sample, so we don't have an urgent need to have this added to the source code. But perhaps a note in the documentation on the rtype would be helpful.

unode commented 5 years ago

Indeed the docs mention readset as a valid return type but the code linked above disagrees.

From an implementation point of view this will also require specifying how many fastq files are expected fq1 (single-end), fq2 (paired-end) or fq3(paired + single) since NGLess has to generate up to 3 output paths.

Another point to consider is if the external tool outputs only 1 file but in interleaved format, something we can now also handle.

unode commented 5 years ago

I've updated documentation for now but leaving this issue open as we will want to implement support for readset in the future.