mxnet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [incubator-mxnet] anirudh2290 commented on a change in pull request #16817: Fix InferType logic - add backward inference for some ops
Date Sat, 16 Nov 2019 01:18:09 GMT
anirudh2290 commented on a change in pull request #16817: Fix InferType logic - add backward
inference for some ops
URL: https://github.com/apache/incubator-mxnet/pull/16817#discussion_r347066890
 
 

 ##########
 File path: src/operator/contrib/deformable_convolution-inl.h
 ##########
 @@ -453,18 +454,10 @@ class DeformableConvolutionProp : public OperatorProperty {
                  std::vector<int> *out_type,
                  std::vector<int> *aux_type) const override {
     CHECK_GE(in_type->size(), 1U);
-    int dtype = (*in_type)[0];
-    CHECK_NE(dtype, -1) << "First input must have specified type";
-    for (size_t i = 0; i < in_type->size(); ++i) {
-      if ((*in_type)[i] == -1) {
-        (*in_type)[i] = dtype;
-      } else {
-        UNIFORM_TYPE_CHECK((*in_type)[i], dtype, ListArguments()[i]);
-      }
-    }
-    out_type->clear();
-    out_type->push_back(dtype);
 
 Review comment:
   yep, many operators behave this way. probably more than what we have captured in the issue
list :)

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

Mime
View raw message