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-494122473 Here is a small example that you can use to reproduce the issue: Code: ``` import mxnet as mx class Batch(object): def __init__(self, data): self.data = data def get_batch_shape(self): return tuple(self.data[0].shape) data = mx.sym.Variable('data') gpool = mx.sym.Pooling(data, name='gpooling', global_pool=True, pad=(1,1), pool_type='avg', kernel=(8,8)) mod = mx.mod.Module(gpool, context=mx.gpu(0), label_names=[]) data = Batch([mx.ndarray.ones((1, 3, 5, 5))]) mod.bind(for_training=True, force_rebind=True, data_shapes=[('data', data.get_batch_shape())],) mod.init_params() mod.forward(data) print(mod.get_outputs()[0].asnumpy().squeeze().tolist()) ``` MX 1.0.0 output: [0.6399999856948853, 0.6399999856948853, 0.6399999856948853] MX 1.4.0 output: [1.0, 1.0, 1.0]
---------------------------------------------------------------- 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
