tvm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [incubator-tvm] kevinthesun commented on a change in pull request #5429: [RELAY][TF] Support symbolic newshape for Reshape
Date Mon, 27 Apr 2020 23:04:30 GMT

kevinthesun commented on a change in pull request #5429:
URL: https://github.com/apache/incubator-tvm/pull/5429#discussion_r416207982



##########
File path: src/relay/transforms/pattern_util.h
##########
@@ -554,7 +554,10 @@ static inline Expr Reshape(Expr data, Array<Integer> newshape)
{
   attrs->newshape = std::move(newshape);
   attrs->reverse = false;
   static const Op& op = Op::Get("reshape");
-  return Call(op, {data}, Attrs(attrs), {});
+  std::vector<int> value{1};
+  auto dummy_newshape_tensor = MakeConstantTensor(DataType::Int(32), {1}, value);

Review comment:
       I think we should change the Reshape API here as well to make it consistent. After
that we can change the type of newshape attr to be Expr as well.




----------------------------------------------------------------
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



Mime
View raw message