Comments (4)
I think this is happening because you may have declared the build index process input as a channel. Since you want to build index just once you need to specify that input just as file reference.
Look for example how is declare genome_file in this process that's doing exactly what you are looking for.
from hack17-varcall.
Hello,
Thank you for your reply!
I think I made what you are saying, I have declared the build index input as a channel. Here is the part of my script that works for only one sample. Do you think I did something wrong?
Thank you for your attention
process buildIndex {
executor "lsf"
module "STAR/2.5.3a"
publishDir params.outdir, mode: 'copy'
input:
file(genome) from genome_file
file(annot) from annotation_file
output:
file(indexDir) into genome_indexD
file(annot) into annotation_file2
"""
mkdir indexDir
STAR --runMode genomeGenerate --genomeDir indexDir --genomeFastaFiles ${genome} --sjdbGTFfile ${annot} --sjdbGTFtagExonParentTranscript Parent
"""
}
/* Alignment with Star: Single Pass Mode: input are genome, genome index and fastqtrimmed data, output are BAM file*/
process alignment {
executor "lsf"
module "STAR/2.5.3a"
module "picard-tools"
publishDir params.outdir, mode: 'copy'
input:
file(index) from genome_indexD
set pair_id, file(treads) from TrimmomaticPaired3
output:
set pair_id, file("BAMD.*") into bam
"""
mkdir BAMD.${pair_id}
STAR --genomeDir ${index} --outFileNamePrefix BAMD.${pair_id}/${pair_id}_ --readFilesCommand zcat --readFilesIn ${pair_id}.trimmomatic_1P.fq.gz ${pair_id}.trimmomatic_2P.fq.gz --chimSegmentMin 15 --chimJunctionOverhangMin 15 --alignMatesGapMax 20000 --alignIntronMax 20000 --outSAMtype BAM Unsorted --outSAMprimaryFlag AllBestScore --outSAMstrandField intronMotif --outFilterIntronMotifs RemoveNoncanonicalUnannotated --quantMode GeneCounts --outQSconversionAdd -31
"""
}
from hack17-varcall.
I have declared the build index input as a channel
No, it shouldn't be declared like a channel. It should be declared something like:
genome_file = file(params.genome)
from hack17-varcall.
doing file(index) from genome_indexD.collect()
should work
The .collect() operator should mean that the channel isn't consumed and is used for every task of the process.
from hack17-varcall.
Related Issues (1)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hack17-varcall.