You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2020/03/10 18:58:28 UTC

[GitHub] [incubator-tvm] trevor-m commented on issue #5018: Look for TupleType instead of TupleNode in LayoutRewriter

trevor-m commented on issue #5018: Look for TupleType instead of TupleNode in LayoutRewriter
URL: https://github.com/apache/incubator-tvm/pull/5018#issuecomment-597257018
 
 
   > IMHO, I don't think we need to test this functionality in the partitioning pass as it is a unit test of layout itself. Instead, You can directly make the "partitioned" graph and run Alterlayout pass and assert whatever IR it should emit.
   
   Hi Zhi, I don't think it is possible to create the partitioned graph without actually using partitoning.
   ```
   input_type = relay.TensorType((1, 5, 6, 6), "float32")
   x = relay.var("x", relay.TupleType([input_type, input_type]))
   out = relay.concatenate(x, axis=1)
   func = relay.Function([x], out)
   ```
   The `relay.concatenate` python API does not accept a Var node as the input:
   ```
     File "test_pass_alter_op_layout.py", line 1053, in test_concatenate
       out = relay.concatenate(x, axis=1)
   
     File "/data/neo-ai-tvm/python/tvm/relay/op/tensor.py", line 888, in concatenate
       data = list(data)
   
   TypeError: 'Var' object is not iterable
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services