RuntimeWarning: invalid value encountered in true_divide
Add the following before this line:numpy.seterr(divide='ignore', invalid='ignore')或者是:RuntimeWarning: invalid value encountered in divideimport numpy as npolderr = np.seterr(all='ignore')...