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 2019/07/17 16:49:06 UTC

[GitHub] [incubator-mxnet] ChaiBapchya commented on a change in pull request #15526: Fix AMP Tutorial warnings and failures

ChaiBapchya commented on a change in pull request #15526: Fix AMP Tutorial warnings and failures
URL: https://github.com/apache/incubator-mxnet/pull/15526#discussion_r304534646
 
 

 ##########
 File path: docs/tutorials/amp/amp_tutorial.md
 ##########
 @@ -262,19 +262,20 @@ Below, we demonstrate for a gluon model and a symbolic model:
 ```python
 with mx.Context(mx.gpu(0)):
     # Below is an example of converting a gluon hybrid block to a mixed precision block
-    model = get_model("resnet50_v1")
-    model.collect_params().initialize(ctx=mx.current_context())
-    model.hybridize()
-    model(mx.nd.zeros((1, 3, 224, 224)))
-    converted_model = amp.convert_hybrid_block(model)
+    with warnings.catch_warnings(record=True) as w:
 
 Review comment:
   by catch_warnings and filtering them, we are trying to remove clutter but at the same time keep them logged for future use right?
   Such case would it make sense to let the user know in 1 line about the same - "Warnings are logged and can be viewed with this command `x`"

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