jmerkow commented on issue #14421: Updating mxnet from 1.0.0, networks give 
different outputs
URL: 
https://github.com/apache/incubator-mxnet/issues/14421#issuecomment-494057080
 
 
   Ok I am working on this again.
   
   I've checked that the parameter files are the same. i.e. something like this:
   ```
   ## in a docker with mx1.4.0 loaded
   np_arg_params = {key: value.asnumpy() for key, value in arg_params.items()}
   np.save('mx140.npy', np_arg_params)
   ...
   
   ## in another docker with mx100 loaded
   import numpy as np
   np_arg_params2 = np.load('../140/mx140.npy')[()]
   assert set(np_arg_params2.keys()).difference(np_arg_params.keys()) == set()
   assert set(np_arg_params.keys()).difference(np_arg_params2.keys()) == set()
   assert all((np_arg_params[k]-np_arg_params2[k]).sum() ==0 for k in 
np_arg_params.keys())
   ```
   I double checked that the actual input to the image is the same (after 
transforms etc).
   
   We use the module doing something like this:
   ```
           mod.forward(batch) # batch is basically a named tuple with an 
NDArray at batch.data
           output = mod.get_outputs()[0].asnumpy() 
   ```
   
   
   
   

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


With regards,
Apache Git Services

Reply via email to