Skip to content

Commit

Permalink
Merge pull request #50 from griffithlab/empty_fasta
Browse files Browse the repository at this point in the history
Skip empty fasta files
  • Loading branch information
susannasiebert committed Dec 6, 2017
2 parents 8fe1aff + c48f5fc commit 2ecc4b2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/pipeline.py
Expand Up @@ -433,6 +433,9 @@ def call_iedb_and_parse_outputs(self, chunks):
split_fasta_file_path = "%s_%s"%(self.split_fasta_basename(), fasta_chunk)
split_iedb_output_files = []
status_message("Processing entries for Allele %s and Epitope Length %s - Entries %s" % (a, epl, fasta_chunk))
if os.path.getsize(split_fasta_file_path) == 0:
status_message("Fasta file is empty. Skipping")
continue
for method in self.prediction_algorithms:
prediction_class = globals()[method]
prediction = prediction_class()
Expand Down Expand Up @@ -540,6 +543,9 @@ def call_iedb_and_parse_outputs(self, chunks):
split_fasta_file_path = "%s_%s"%(self.split_fasta_basename(), fasta_chunk)
split_iedb_output_files = []
status_message("Processing entries for Allele %s - Entries %s" % (a, fasta_chunk))
if os.path.getsize(split_fasta_file_path) == 0:
status_message("Fasta file is empty. Skipping")
continue
for method in self.prediction_algorithms:
prediction_class = globals()[method]
prediction = prediction_class()
Expand Down

0 comments on commit 2ecc4b2

Please sign in to comment.