You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the moment, stageInMode sets a single value for the entire process re. how to stage input files. It would be useful in some cases to be able to specify stageInMode multiple times and stage different input files in different modes, similar to #256.
Usage scenario
This would be useful in situations where a tool doesn't like symlinks in some cases, but it would be wasteful to stage all input files in copy mode, e.g. if the inputs are a mix of small config/batch files and large bam files. This would eliminate the need to do workarounds with cp -L in the 'script' block.
Suggest implementation
Specify stageInMode multiple times in the process declaration:
process SOME_PROCESS {
input:
path(batch_file) // tool crashes if this is a symlink
path(bam_file) // but bam files are fine// specify input channel names or file patterns to stageInMode
stageInMode batch_file, mode: "copy"
stageInMode "*.bam", mode: "symlink"script:
""" some_tool --batch ${batch_file} --bam ${bam_file}"""
}
The system would need to be able to handle conflicts (unlike publishDir, it wouldn't make sense to set multiple stageInModes on a single input file):
stageInMode "*.bam", mode: "copy"
stageInMode "*.bam", mode: "symlink"// could throw an error, or just have subsequent declarations for the same pattern overwrite any previous ones
The text was updated successfully, but these errors were encountered:
This does not actually work; gives ERROR ~ No such variable: stageInMode
But if you could handle it like this, you would be able to specify different stage in modes for the input files, while also handling some of the issues that seem to be related to these Fusion filesystem file handling issues;
New feature
At the moment, stageInMode sets a single value for the entire process re. how to stage input files. It would be useful in some cases to be able to specify stageInMode multiple times and stage different input files in different modes, similar to #256.
Usage scenario
This would be useful in situations where a tool doesn't like symlinks in some cases, but it would be wasteful to stage all input files in copy mode, e.g. if the inputs are a mix of small config/batch files and large bam files. This would eliminate the need to do workarounds with
cp -L
in the 'script' block.Suggest implementation
Specify stageInMode multiple times in the process declaration:
Or as a list of directives in nextflow.config:
Maybe it's possible to use closures with nextflow.config to get at the variable names?
The system would need to be able to handle conflicts (unlike publishDir, it wouldn't make sense to set multiple stageInModes on a single input file):
The text was updated successfully, but these errors were encountered: