pythonコード


  • データ順序を乱す
  • #   
    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