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
52e55baa
Commit
52e55baa
authored
Dec 02, 2018
by
Josh Pollock
Committed by
Tianqi Chen
Dec 02, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Relay] Parser Tests (#2209)
parent
d3bc59d2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
src/relay/ir/alpha_equal.cc
+6
-6
src/relay/ir/text_printer.cc
+2
-2
tests/python/relay/test_ir_parser.py
+0
-0
No files found.
src/relay/ir/alpha_equal.cc
View file @
52e55baa
...
...
@@ -26,7 +26,7 @@ class AlphaEqualHandler:
* Check equality of two nodes.
* \param lhs The left hand operand.
* \param rhs The right hand operand.
* \return
t
he compare result.
* \return
T
he compare result.
*/
bool
Equal
(
const
NodeRef
&
lhs
,
const
NodeRef
&
rhs
)
{
if
(
lhs
.
same_as
(
rhs
))
return
true
;
...
...
@@ -46,7 +46,7 @@ class AlphaEqualHandler:
* Check equality of two attributes.
* \param lhs The left hand operand.
* \param rhs The right hand operand.
* \return
t
he compare result.
* \return
T
he compare result.
*/
bool
AttrEqual
(
const
NodeRef
&
lhs
,
const
NodeRef
&
rhs
)
{
return
AttrsEqualHandler
::
Equal
(
lhs
,
rhs
);
...
...
@@ -55,7 +55,7 @@ class AlphaEqualHandler:
* Check equality of two types.
* \param lhs The left hand operand.
* \param rhs The right hand operand.
* \return
t
he compare result.
* \return
T
he compare result.
*/
bool
TypeEqual
(
const
Type
&
lhs
,
const
Type
&
rhs
)
{
if
(
lhs
.
same_as
(
rhs
))
return
true
;
...
...
@@ -72,7 +72,7 @@ class AlphaEqualHandler:
*
* \param lhs The left hand operand.
* \param rhs The right hand operand.
* \return
t
he compare result.
* \return
T
he compare result.
*/
bool
ExprEqual
(
const
Expr
&
lhs
,
const
Expr
&
rhs
)
{
if
(
lhs
.
same_as
(
rhs
))
return
true
;
...
...
@@ -94,7 +94,7 @@ class AlphaEqualHandler:
* \brief Check if data type equals each other.
* \param lhs The left hand operand.
* \param rhs The right hand operand.
* \return
t
he compare result.
* \return
T
he compare result.
*/
bool
DataTypeEqual
(
const
DataType
&
lhs
,
const
DataType
&
rhs
)
{
return
lhs
==
rhs
;
...
...
@@ -104,7 +104,7 @@ class AlphaEqualHandler:
* if map_free_var_ is set to true, try to map via equal node.
* \param lhs The left hand operand.
* \param rhs The right hand operand.
* \return
t
he compare result.
* \return
T
he compare result.
*/
bool
LeafNodeEqual
(
const
NodeRef
&
lhs
,
const
NodeRef
&
rhs
)
{
if
(
lhs
.
same_as
(
rhs
))
return
true
;
...
...
src/relay/ir/text_printer.cc
View file @
52e55baa
...
...
@@ -38,7 +38,7 @@ inline std::ostream& operator<<(std::ostream& os, const TextValue& val) { // NO
* It can be hard to design a text format for all the possible nodes
* as the set of nodes can grow when we do more extensions.
*
* Instead of trying to design readable text format for every node
s
,
* Instead of trying to design readable text format for every node,
* we support a meta-data section in the text format.
* We allow the text format to refer to a node in the meta-data section.
*
...
...
@@ -73,7 +73,7 @@ inline std::ostream& operator<<(std::ostream& os, const TextValue& val) { // NO
* \endcode
*
* Note that we store tvm.var("n") in the meta data section.
* Since it is stored in the index-0 in the meta-data sec
it
on,
* Since it is stored in the index-0 in the meta-data sec
ti
on,
* we print it as meta.Variable(0).
*
* The text parser can recover this object by loading from the corresponding
...
...
tests/python/relay/test_ir_parser.py
0 → 100644
View file @
52e55baa
This diff is collapsed.
Click to expand it.
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