Created
February 12, 2019 21:06
-
-
Save venuktan/5f66ba5bb37bb7531507ca1a182cf1af to your computer and use it in GitHub Desktop.
tf load graph from bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def load_ascii_bytes(model): | |
graph_def = tf.GraphDef() | |
graph_def.ParseFromString(model) | |
with tf.Graph().as_default() as graph: | |
tf.import_graph_def( | |
graph_def, | |
input_map=None, | |
return_elements=None, | |
name="", | |
op_dict=None, | |
producer_op_list=None | |
) | |
return graph |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment