You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2018/06/16 18:04:53 UTC

[GitHub] ThomasDelteil commented on a change in pull request #11320: Static alloc for hybridblock

ThomasDelteil commented on a change in pull request #11320: Static alloc for hybridblock
URL: https://github.com/apache/incubator-mxnet/pull/11320#discussion_r195908700
 
 

 ##########
 File path: python/mxnet/gluon/block.py
 ##########
 @@ -502,8 +502,16 @@ def hybridize(self, active=True, **kwargs):
         ----------
         active : bool, default True
             Whether to turn hybrid on or off.
-        **kwargs : string
-            Additional flags for hybridized operator.
+        static_alloc : bool, default False
+            Statically allocate memory to improve speed. Memory usage may increase.
+        static_shape : bool, default False
+            Optimize for invariant input shapes between iterations. Must also
+            set static_alloc to True. Change of input shapes is still allowed
 
 Review comment:
   can we assert that static_alloc is set if static_shape is set so that we don't open the door to undefined behaviours?
   ```
   if static_shape:
       assert static_alloc, "static_alloc must be True if static_shape is True"
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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