sandeep-krishnamurthy edited a comment on issue #9410: Training with the same 
parameters and seed gets significantly different results
URL: 
https://github.com/apache/incubator-mxnet/issues/9410#issuecomment-414489047
 
 
   I see that weights initialized are different for each run. To reproduce 
running below initialization and viewing the weights yields different weights. 
   
   Taking a look.
   
   ```
   net.collect_params().initialize(mx.init.Xavier(magnitude=_xavier_magnitude), 
ctx=_ctx_list, force_reinit=True)
   
   net.collect_params()['resnetv21_conv0_weight'].data()
   ```
   ```
   [[[[  1.89611092e-02  -1.63955986e-02  -1.63183715e-02 ...,
        -3.77857126e-03  -6.12869300e-03  -5.09519130e-04]
      [  1.08407550e-02  -9.70634259e-03  -9.24655981e-03 ...,
         7.88253173e-03   6.32613525e-03   5.58372587e-03]
      [  1.66305602e-02  -3.11831571e-02   1.71868391e-02 ...,
         1.45371221e-02  -2.16977187e-02   1.16131082e-03]
      ..., 
      [  8.47874209e-03  -1.09105334e-02   2.11738199e-02 ...,
        -7.37845525e-03  -2.88667846e-02   5.60590997e-03]
   ```
   ```
   net.collect_params().initialize(mx.init.Xavier(magnitude=_xavier_magnitude), 
ctx=_ctx_list, force_reinit=True)
   
   net.collect_params()['resnetv21_conv0_weight'].data()
   ```
   
   ```
   [[[[  2.48766877e-02  -2.38284618e-02   2.93936618e-02 ...,
        -2.53108982e-02   7.16960430e-03   3.47280316e-02]
      [ -2.72196699e-02  -3.16641107e-03  -2.53057741e-02 ...,
         2.93160938e-02  -2.12305132e-02   2.46996880e-02]
      [ -1.13223270e-02   2.28771083e-02   4.12302464e-03 ...,
         3.26776169e-02  -7.82233290e-03  -1.84644368e-02]
      ..., 
      [ -1.44652370e-02   4.28056717e-03   2.71088779e-02 ...,
        -2.38894150e-02  -3.23100463e-02   1.61664635e-02]
      [ -1.10932998e-02   2.97400393e-02  -2.46300120e-02 ...,
         1.50449201e-03   2.24774107e-02   2.15285458e-02]
      [ -2.22768262e-03  -1.62917320e-02   2.92964391e-02 ...,
        -1.20998956e-02  -1.78815369e-02  -1.03423744e-03]]
   
     [[  8.84681195e-03   2.98257805e-02  -1.20900013e-02 ...,
         3.42116766e-02   2.25740559e-02  -1.45227127e-02]
      [ -1.05716512e-02   2.59525068e-02  -2.16498077e-02 ...,
        -2.18278579e-02   6.06125221e-03  -2.86707170e-02]
      [  1.39616653e-02   7.52510503e-03  -2.09881701e-02 ...,
   ```

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to