MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / is_frozen_graph

Function is_frozen_graph

tensorflow/lite/python/util.py:254–269  ·  view source on GitHub ↗

Determines if the graph is frozen. Determines if a graph has previously been frozen by checking for any operations of type Variable*. If variables are found, the graph is not frozen. Args: sess: TensorFlow Session. Returns: Bool.

(sess)

Source from the content-addressed store, hash-verified

252
253
254def is_frozen_graph(sess):
255 """Determines if the graph is frozen.
256
257 Determines if a graph has previously been frozen by checking for any
258 operations of type Variable*. If variables are found, the graph is not frozen.
259
260 Args:
261 sess: TensorFlow Session.
262
263 Returns:
264 Bool.
265 """
266 for op in sess.graph.get_operations():
267 if op.type.startswith("Variable") or op.type.endswith("VariableOp"):
268 return False
269 return True
270
271
272def build_debug_info_func(original_graph):

Callers 2

freeze_graphFunction · 0.85

Calls 1

get_operationsMethod · 0.80

Tested by

no test coverage detected