Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tic
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wenyuanbo
tic
Commits
3d9b1739
Commit
3d9b1739
authored
Oct 05, 2019
by
Yong Wu
Committed by
Yao Wang
Oct 05, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Bugfix][TF] reset graph after getting tag of savedmodel (#4055)
@zhiics @icemelon9
parent
92ffa062
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
python/tvm/relay/frontend/tensorflow_parser.py
+3
-2
No files found.
python/tvm/relay/frontend/tensorflow_parser.py
View file @
3d9b1739
...
...
@@ -79,15 +79,16 @@ class TFParser(object):
"InputConfiguration: Unable to import tensorflow which is "
"required to restore from saved model."
)
tags
=
self
.
_get_tag_set
()
output_names
=
set
()
with
tf
.
Session
()
as
sess
:
meta_graph_def
=
tf
.
saved_model
.
loader
.
load
(
sess
,
tags
,
self
.
_model_dir
)
output_names
=
set
()
for
sig_def
in
meta_graph_def
.
signature_def
.
values
():
for
output_tensor
in
sig_def
.
outputs
.
values
():
output_names
.
add
(
output_tensor
.
name
.
replace
(
":0"
,
""
))
return
","
.
join
(
output_names
)
tf
.
reset_default_graph
()
return
","
.
join
(
output_names
)
def
_load_saved_model
(
self
):
"""Load the tensorflow saved model."""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment