Call numpy.ndarray.sum(axis=0) to calculate the sum of each column in numpy.ndarray . Setting axis to 1 would calculate the sum of each row. print(an_array).
確定! 回上一頁