复制代码def mean(self, axis=None): return self.sum(axis) / ( self.size if axis==None else self.shape[axis])