提交 2f949efb 编写于 作者: B Bin Li 提交者: 叶剑武

Fix multiple models in one yml

上级 da75792c
......@@ -310,6 +310,8 @@ class TensorflowConverter(base_converter.ConverterInterface):
self.add_shape_info(transformed_graph_def)
# reset default graph to clear earlier import
tf.reset_default_graph()
with tf.Session() as session:
with session.graph.as_default() as graph:
tf.import_graph_def(transformed_graph_def, name='')
......@@ -319,7 +321,6 @@ class TensorflowConverter(base_converter.ConverterInterface):
# we have polluted graph with 'shape' ops, so reset it and reload it
# again
tf.reset_default_graph()
with tf.Session() as session:
with session.graph.as_default() as graph:
tf.import_graph_def(transformed_graph_def, name='')
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册