- 打乱数据顺序
# 打乱
index_train = [i for i in range(len(image_train))]
np.random.shuffle(index_train)
# 1 train
data = image_train
label = label_train
data = data[index_train]
label = label[index_train]
image_train = data
label_train = label
# 打乱
index_train = [i for i in range(len(image_train))]
np.random.shuffle(index_train)
# 1 train
data = image_train
label = label_train
data = data[index_train]
label = label[index_train]
image_train = data
label_train = label