The reduction="mean" will do average with respect to all elements, but in the other one, you are calculating the average with respect to bacth-size. So the denominator for computing the average in the first case is just batch-size (results.shape[0]), where is in the other case it is np.prod(results.shape).