Skip to content

Commit

Permalink
Keep the linter happy.
Browse files Browse the repository at this point in the history
  • Loading branch information
Clemens Messerschmidt committed Feb 1, 2019
1 parent d4dd646 commit 45694fd
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions digestiflow_demux/bases_mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def split_bases_mask(bases_mask):

result = []
num = ""
for i in range(len(bases_mask)):
for i, _character in enumerate(bases_mask):
if i not in splitat:
num += bases_mask[i]
elif int(num) == 0:
Expand All @@ -45,13 +45,13 @@ def compare_bases_mask(planned_reads, bases_mask):
planned = split_bases_mask(planned_reads)
mask = split_bases_mask(bases_mask)

lengths1 = [i[1] for i in planned]
lengths2 = [i[1] for i in mask]
lengths1 = [count for _type, count in planned]
lengths2 = [count for _type, count in mask]
if not sum(lengths1) == sum(lengths2):
raise BaseMaskConfigException("Your base mask has more or fewer cycles than planned")

matched_mask = []
for type, cycles in planned:
for _type, cycles in planned:
read = []
s = 0
while s < cycles:
Expand Down Expand Up @@ -89,8 +89,6 @@ def return_bases_mask(planned_reads, demux_reads, demux_tool="bcl2fastq"):

new_mask = []
for lst in mask_list:
substr = ""
for t in lst:
substr += translate_tuple_to_basemask(t, demux_tool)
new_mask.append(substr)
substr = [translate_tuple_to_basemask(t, demux_tool) for t in lst]
new_mask.append("".join(substr))
return ",".join(new_mask) if demux_tool == "bcl2fastq" else "".join(new_mask)

0 comments on commit 45694fd

Please sign in to comment.