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
45584004
Commit
45584004
authored
Oct 05, 2017
by
Tianqi Chen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[COMPILE] More debug message when compile error (#66)
parent
f5a8a5c7
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
5 deletions
+14
-5
nnvm/python/nnvm/compiler/build_module.py
+12
-3
nnvm/python/nnvm/frontend/onnx.py
+1
-1
nnvm/src/compiler/compile_engine.cc
+1
-1
No files found.
nnvm/python/nnvm/compiler/build_module.py
View file @
45584004
...
...
@@ -95,9 +95,18 @@ def build_config(**kwargs):
@tvm.register_func
(
"nnvm.compiler.lower"
)
def
_lower
(
sch
,
inputs
,
func_name
):
f
=
tvm
.
lower
(
sch
,
inputs
,
name
=
func_name
)
logging
.
debug
(
"lower function
%
s"
,
func_name
)
def
_lower
(
sch
,
inputs
,
func_name
,
graph
):
import
traceback
# pylint: disable=broad-except
try
:
f
=
tvm
.
lower
(
sch
,
inputs
,
name
=
func_name
)
logging
.
debug
(
"lower function
%
s"
,
func_name
)
except
Exception
:
msg
=
traceback
.
format_exc
()
msg
+=
"Error during compile graph
\n
"
msg
+=
"--------------------------
\n
"
msg
+=
graph
.
ir
(
join_entry_attrs
=
[
"shape"
])
raise
RuntimeError
(
msg
)
return
f
if
isinstance
(
f
,
(
tvm
.
container
.
Array
,
tuple
,
list
))
else
[
f
]
...
...
nnvm/python/nnvm/frontend/onnx.py
View file @
45584004
...
...
@@ -369,7 +369,7 @@ def from_onnx(graph):
-------
sym : nnvm.Symbol
Compatible nnvm symbol
params : dict of str to tvm.ndarray
Dict of converted parameters stored in tvm.ndarray format
"""
...
...
nnvm/src/compiler/compile_engine.cc
View file @
45584004
...
...
@@ -189,7 +189,7 @@ class CompileEngine {
gf
->
inputs
=
inputs
;
gf
->
outputs
=
outputs
;
static
const
PackedFunc
&
flower
=
GetPackedFunc
(
"nnvm.compiler.lower"
);
gf
->
funcs
=
flower
(
sch
,
all_args
,
gf
->
func_name
);
gf
->
funcs
=
flower
(
sch
,
all_args
,
gf
->
func_name
,
graph
);
return
GraphFunc
(
gf
);
}
...
...
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