Skip to content
Snippets Groups Projects
Commit 730a2da3 authored by Jeremy Mathews's avatar Jeremy Mathews
Browse files

55-Fail Pipeline if wrong genome is selected

parent 6cf95be0
Branches
Tags
No related merge requests found
......@@ -218,6 +218,13 @@ def main():
shlex.split("samtools flagstat %s" % (bam_filename)),
stdout=temp_file)
#Genome/Bad fastq File Check
file_check = open(bam_mapstats_filename).readlines()
percent = file_check[4].split('(')[1]
percent = percent.split('%')[0]
if float(percent) < 10:
raise Exception ('Mapped Genes too low: Check for correct Genotype')
# Remove sai files
for sai_file in sai:
os.remove(sai_file)
......
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