Commit b8242aa7 authored by Celine Noirot's avatar Celine Noirot
Browse files

Debug componant after adding add_execution

parent aa5d986f
......@@ -50,8 +50,7 @@ class STAR (Analysis):
def process(self):
#link fasta
link_fasta = ShellFunction( "ln -s $1 $2" , cmd_format="{EXE} {IN} {OUT}")
link_fasta(inputs = self.fasta_file, outputs = self.fasta_file_link)
self.add_shell_execution("ln -s $1 $2" , cmd_format="{EXE} {IN} {OUT}",inputs = self.fasta_file, outputs = self.fasta_file_link)
# run star
if self.read2 :
......@@ -61,7 +60,7 @@ class STAR (Analysis):
"--runThreadN", str(self.n_threads),
"--outSAMunmapped Within",
"--readFilesIn", "$1", "$2" ]
self.aff_shell_execution( ' '.join(command), cmd_format='{EXE} {IN} {OUT}', map=True,
self.add_shell_execution( ' '.join(command), cmd_format='{EXE} {IN} {OUT}', map=True,
inputs = [self.read1 , self.read2], outputs = [self.output_prefixes, self.output_sams_no_md],
includes = self.genome_dir)
else :
......@@ -71,16 +70,16 @@ class STAR (Analysis):
"--outSAMunmapped Within",
"--runThreadN", str(self.n_threads),
"--readFilesIn", "$1" ]
self.aff_shell_execution( ' '.join(command), cmd_format='{EXE} {IN} {OUT}', map=True,
self.add_shell_execution( ' '.join(command), cmd_format='{EXE} {IN} {OUT}', map=True,
inputs = [self.read1], outputs = [self.output_prefixes, self.output_sams_no_md], includes = self.genome_dir)
# sort
self.aff_shell_execution( self.get_exec_path("samtools") + ' view -Sb $1 | ' + self.get_exec_path("samtools") +
self.add_shell_execution( self.get_exec_path("samtools") + ' view -Sb $1 | ' + self.get_exec_path("samtools") +
' sort -@ ' + str(self.n_threads) + ' -f - $2 ' , cmd_format='{EXE} {IN} {OUT}', map=True,
inputs = [self.output_sams_no_md], outputs = [self.output_sorted_bams])
#calmd and convert to bam
self.aff_shell_execution( self.get_exec_path("samtools") + ' calmd -b $1 ' + self.fasta_file_link + ' > $2' ,
self.add_shell_execution( self.get_exec_path("samtools") + ' calmd -b $1 ' + self.fasta_file_link + ' > $2' ,
cmd_format='{EXE} {IN} {OUT}', map=True,
inputs = [self.output_sorted_bams], outputs = [self.output_bams])
......@@ -93,4 +92,4 @@ class STAR (Analysis):
\ No newline at end of file
......@@ -35,5 +35,5 @@ class STARIndex (Component):
# index for star
self.add_shell_execution( "mkdir $2 ; " + self.get_exec_path("STAR") + " --runMode genomeGenerate --genomeFastaFiles $1 --genomeDir $2",
cmd_format='{EXE} {IN} {OUT}' , map=True, inputs = self.normalized_fasta_file, outputs = self.index_directory)
cmd_format='{EXE} {IN} {OUT}' , map=False, inputs = self.normalized_fasta_file, outputs = self.index_directory)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment