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/09/01 23:03:24 UTC

[GitHub] [incubator-mxnet] wkcn commented on a change in pull request #16061: Allow loading from model files with empty weights.

wkcn commented on a change in pull request #16061: Allow loading from model files with empty weights.
URL: https://github.com/apache/incubator-mxnet/pull/16061#discussion_r319778476
 
 

 ##########
 File path: python/mxnet/model.py
 ##########
 @@ -431,6 +431,7 @@ def load_params(prefix, epoch):
     aux_params = {}
     if not save_dict:
         logging.warning("Params file '%s' is empty", '%s-%04d.params' % (prefix, epoch))
+        return (arg_params, aux_params)
 
 Review comment:
   Thanks for your contribution!
   In the original code, the function will return empty weights in the line 440 when loading an empty file.

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