modify a bug in numpy.reshape