From c8329a77bc923f5064a8795495831da8a3aa215c Mon Sep 17 00:00:00 2001 From: Frank Lee Date: Mon, 20 May 2019 19:13:17 -0700 Subject: [PATCH] OCT delete bug fix --- Embed.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Embed.py b/Embed.py index eff0085..7052ce3 100644 --- a/Embed.py +++ b/Embed.py @@ -139,7 +139,7 @@ def plotOCTDivision(self, *, left = None, right = None, removeOCT = None): if (removeOCT == True): OCTSet = [] for nodes in G.nodes(): - if nodes not in L and nodes not in R: + if nodes not in left and nodes not in right: OCTSet.append(nodes) G.remove_nodes_from(OCTSet) @@ -164,4 +164,4 @@ def clearGraph(self): e = Embedding(graph = [(1,2),(1,5),(1,3),(2,4),(2,5),(3,5),(3,4)]) #e.generateRandomGraph(10, 25) L,R = e.greedyBipartite() - e.plotOCTDivision(left = L, right = R, removeOCT = False) \ No newline at end of file + e.plotOCTDivision(left = L, right = R, removeOCT = True) \ No newline at end of file