From 617e577ecf76fa8273934ff047013ebae97a8cfc Mon Sep 17 00:00:00 2001 From: Kostis Anagnostopoulos Date: Sat, 28 Sep 2019 18:02:46 +0300 Subject: [PATCH 1/2] FIX(build): py2 needs pinning networkx-2.2 --- setup.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index bd7883f4..d3dfec84 100644 --- a/setup.py +++ b/setup.py @@ -28,7 +28,10 @@ author_email='huyng@yahoo-inc.com', url='http://github.com/yahoo/graphkit', packages=['graphkit'], - install_requires=['networkx'], + install_requires=[ + "networkx; python_version >= '3.5'", + "networkx == 2.2; python_version < '3.5'", + ], extras_require={ 'plot': ['pydot', 'matplotlib'] }, From a989f2edd71aa1175fe26eb53445ca65d23d9765 Mon Sep 17 00:00:00 2001 From: Kostis Anagnostopoulos Date: Thu, 3 Oct 2019 15:29:12 +0300 Subject: [PATCH 2/2] FIX(net): new Ops invalidate execution-plan cache... Probaly unreported bug in v1.2.4 for '_neccessary_steps_cache`. --- graphkit/network.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/graphkit/network.py b/graphkit/network.py index 0df3ddf8..60f08858 100644 --- a/graphkit/network.py +++ b/graphkit/network.py @@ -73,6 +73,9 @@ def add_op(self, operation): # assert layer is only added once to graph assert operation not in self.graph.nodes(), "Operation may only be added once" + ## Invalidate old plans. + self._cached_execution_plans = {} + # add nodes and edges to graph describing the data needs for this layer for n in operation.needs: self.graph.add_edge(DataPlaceholderNode(n), operation)