tqchen commented on a change in pull request #4357: [Relay tests] AlterOpLayout 
- Temporary attr update
URL: https://github.com/apache/incubator-tvm/pull/4357#discussion_r347151865
 
 

 ##########
 File path: tests/python/relay/test_pass_alter_op_layout.py
 ##########
 @@ -31,6 +31,17 @@ def run_opt_pass(expr, passes):
     entry = mod["main"]
     return entry if isinstance(expr, relay.Function) else entry.body
 
+def reset_retrieve_alter_op_layout(op_name, alter_layout):
 
 Review comment:
   Consider use RAII Pattern, this will allow the code to exit correctly even 
if the testcase raises an exception in the middle of the body
   
   ```
   with TempOpAttr(name, attr):
        body
   ```

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to