zhreshold commented on issue #12334: Load pretrained model with new 
load_parameters() API
URL: 
https://github.com/apache/incubator-mxnet/issues/12334#issuecomment-420104644
 
 
   @ShownX If you prefer preserving names, here's the API for it:
   
   ```
   net = get_model('resnet101_v2', pretrained=True)
   net.collect_params().save(filename, strip_prefix=net.prefix)
   new_net.collect_params(collect='the patterns').load(filename, 
restore_prefix=new_net.prefix)
   ```
   
   What your purpose is reusing separate(partial) parameters, not the entire 
network.
   

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to