Commit 513c10bd authored by Rayan  CHIKHI's avatar Rayan CHIKHI
Browse files

updated unpaired support

parent a4df611f
......@@ -22,12 +22,19 @@ def fastp(accession,folder,sdb,extra_args=""):
if fname[-8:] == '_1.fastq':
# If first of pair is found, add both
fname2 = fname[:-8] + '_2.fastq'
assert fname2 in fastq_files, 'Unpaired _1 file: ' + fname
pe_fastq_files.append((fname, fname2))
if fname2 not in fastq_files:
print('Unpaired _1 file: ' + fname)
sdb_log(sdb,accession,'read_unpaired1','True')
se_fastq_files.append(fname)
else:
pe_fastq_files.append((fname, fname2))
elif fname[-8:] == '_2.fastq':
# If second of pair is found, test for presence of first, but do nothing
fname1 = fname[:-8] + '_1.fastq'
assert fname1 in fastq_files, 'Unpaired _2 file: ' + fname
if fname1 not in fastq_files:
print('Unpaired _2 file: ' + fname)
sdb_log(sdb,accession,'read_unpaired2','True')
se_fastq_files.append(fname)
else:
se_fastq_files.append(fname)
......
Markdown is supported
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