采用np.set_printoptions()进行打印 img = cv2.imread('./test.jpg') np.set_printoptions(threshold=sys.maxsize) print(img) 错误: 原代码: np.set_printoptions(threshold=np.nan) 报错: ValueError: threshold must be non-NAN, try sys.maxsize for untruncated representation 解决: np.set_printoptions(sys.maxsize)