From 9794cbc80184f28a7f075a61f4938f632da8667f Mon Sep 17 00:00:00 2001 From: Luca Venturini Date: Wed, 3 Oct 2018 09:49:07 +0100 Subject: [PATCH] Fixed the bug found by @gemygk in the last run (still pertaining to #129) --- Mikado/loci/locus.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Mikado/loci/locus.py b/Mikado/loci/locus.py index 9226dd081..cd4a2d442 100644 --- a/Mikado/loci/locus.py +++ b/Mikado/loci/locus.py @@ -626,7 +626,7 @@ def _find_communities_boundaries(self, five_clique, three_clique): comm = five_clique.popleft() comm = deque(sorted(list(set.difference(set(comm), five_found)), key=lambda internal_tid: self[internal_tid].start)) - if len(comm) == 1: + if len(comm) < 2: continue first = comm.popleft() five_found.add(first) @@ -650,7 +650,7 @@ def _find_communities_boundaries(self, five_clique, three_clique): comm = three_clique.popleft() comm = deque(sorted(list(set.difference(set(comm), three_found)), key=lambda internal_tid: self[internal_tid].end, reverse=True)) - if len(comm) == 1: + if len(comm) < 2: continue first = comm.popleft() three_found.add(first)