代码:
dm = np.array(bin_data).reshape((189, 5))
报错:
ValueError: cannot reshape array of size 945 into shape (5000,5)
原因:
这是因为5000≠945×5,所以reshape改成:
dm = np.array(bin_data).reshape((189, 5))即可,
因为5000=189*5
ValueError: cannot reshape array of size 945 into shape (5000,5)
最新推荐文章于 2023-11-24 17:16:17 发布