From 2ce2a437375ce7753f108baf55c6bdbb71e89920 Mon Sep 17 00:00:00 2001 From: Kostis Anagnostopoulos Date: Thu, 3 Oct 2019 15:29:12 +0300 Subject: [PATCH] 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 0000dd52..06447271 100644 --- a/graphkit/network.py +++ b/graphkit/network.py @@ -108,6 +108,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)