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/06 10:40:29 UTC

[GitHub] [incubator-tvm] lfengad commented on a change in pull request #4990: [TF][Relay] BatchNorm support with run-time mean and variance calculation

lfengad commented on a change in pull request #4990: [TF][Relay] BatchNorm support with run-time mean and variance calculation
URL: https://github.com/apache/incubator-tvm/pull/4990#discussion_r388831831
 
 

 ##########
 File path: python/tvm/relay/frontend/tensorflow.py
 ##########
 @@ -887,7 +887,14 @@ def _impl(inputs, attr, params):
         if 'U' in attr:
             need_cast = True
             inputs[0] = _op.cast(inputs[0], dtype=attr['U'].name)
-
+        # Check if mean and variance are empty
+        # If so, replace them with Mean and Variance Ops
+        # For run-time calculation
+        moving_mean_shape = [int(n) for n in inputs[3].type_annotation.shape]
 
 Review comment:
   Thank you for the detailed review comments! I have corrected the related codes in the newest commit. But for the `add CHECK of len(inputs)` issue, does it mean that to check the number of nodes in `inputs` and to see whether this number is 5? Also, it seems in python there is no `CHECK` method?
   Thank you so much for the help!

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