These are chat archives for nextflow-io/nextflow

17th
Nov 2016
Phil Ewels
@ewels
Nov 17 2016 10:58
Hi @pditommaso / others. I have what is hopefully a pretty basic groovy language question.. I have a file which is an output from another process. I want to remove its suffix - how do I do this? It's genome.hisat2_index.1.ht2 and I want to get to genome.hisat2_index
According to my googling, this should work: index_base = index - '.1.ht2', however, it doesn't seem to do anything.
Paolo Di Tommaso
@pditommaso
Nov 17 2016 11:00
because, I guess, you have a path not a string
try file.toString() - '.1.ht2'
or file.baseName.baseName .. a bit ugly
Phil Ewels
@ewels
Nov 17 2016 11:01
ok cool, I tried .flatten() already, didn't think of using .toString() (RTFM sorry)
yup, toString() works like a charm, thanks!
Paolo Di Tommaso
@pditommaso
Nov 17 2016 11:02
:+1:
Phil Ewels
@ewels
Nov 17 2016 11:02
(didn't go down the baseName route because in another case I want to remove a bunch of stuff which may or may not be there, regex is better)
Paolo Di Tommaso
@pditommaso
Nov 17 2016 11:02
ok
@jbyars any output file is always copied in the workdir because it's supposed to be used by a downstream process
Paolo Di Tommaso
@pditommaso
Nov 17 2016 13:13
A lot of bugs squashed in the latest release
thanks to @ewels, @fmorency and @mes5k
Phil Ewels
@ewels
Nov 17 2016 13:16
:+1:
Phil Ewels
@ewels
Nov 17 2016 13:56
Before I start making one, I don't suppose anyone knows of a tiny dataset / reference for use with testing?
Paolo Di Tommaso
@pditommaso
Nov 17 2016 14:36
the problem is that it's hard to create a dataset that works everywhere
you can have a look here or here
Phil Ewels
@ewels
Nov 17 2016 14:41
Ah nice, thanks :+1:
Yes I was planning to filter a bam file for a small region, then back convert from there to fastq, gtf, fasta etc.
I did it with chr22 already but apparently that's still too big for STAR on Travis, the processes are getting killed still
Félix C. Morency
@fmorency
Nov 17 2016 15:01
@pditommaso following yesterday's discussion, say I create a new channel with phase and manipulate it such that all required downstream process inputs are contained in the channel. Will NF execute the downstream process as soon as the data are available or if we'll have to wait for all the upstream processes to finish?
Paolo Di Tommaso
@pditommaso
Nov 17 2016 15:15
yes, it should be executed as soon as there's a matching item
Félix C. Morency
@fmorency
Nov 17 2016 15:18
awesome
Félix C. Morency
@fmorency
Nov 17 2016 16:11
   output:
    set sid, "dti_fa.nii.gz" into fa_for_fodf
    set sid, "dti_md.nii.gz", "dti_fa.nii.gz" into md_fa_for_fodf_max_in_ventricles
can I repeat output like ^?
Phil Ewels
@ewels
Nov 17 2016 16:15
I'd do this instead: set sid, "dti_{md,fa}.nii.gz" into md_fa_for_fodf_max_in_ventricles
Félix C. Morency
@fmorency
Nov 17 2016 16:16
oh cool
Félix C. Morency
@fmorency
Nov 17 2016 16:41
mmm but it outputs a list
Phil Ewels
@ewels
Nov 17 2016 16:54
Sorry, probably should have asked what it was that you were trying to do :)
Also, I suck at groovy so although I try to be helpful, I'm usually wrong :P
Félix C. Morency
@fmorency
Nov 17 2016 17:15
haha thanks, all is good now
Jason Byars
@jbyars
Nov 17 2016 19:12
@pditommaso thank you for the clarification. I can plan for the remaining contigencies I need to now. Is there any other useful info I can provide for the issue using storeDir with S3?