comaniac commented on a change in pull request #7332:
URL: https://github.com/apache/tvm/pull/7332#discussion_r562983099



##########
File path: python/tvm/relay/dataflow_pattern/__init__.py
##########
@@ -579,6 +602,27 @@ def __init__(self, cond: "DFPattern", true_branch: 
"DFPattern", false_branch: "D
         self.__init_handle_by_constructor__(ffi.IfPattern, cond, true_branch, 
false_branch)
 
 
+@register_df_node
+class LetPattern(DFPattern):
+    """A patern matching a Relay If.

Review comment:
       ```suggestion
       """A patern matching a Relay Let.
   ```

##########
File path: python/tvm/relay/dataflow_pattern/__init__.py
##########
@@ -337,6 +337,29 @@ def is_if(cond, true_branch, false_branch):
     return IfPattern(cond, true_branch, false_branch)
 
 
+def is_let(var, value, body):
+    """
+    Syntatic sugar for creating an IfPattern.

Review comment:
       ```suggestion
       Syntatic sugar for creating a LetPattern.
   ```




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to