training_images = np.array([i for i in images if i not in validation_images])
The above is wrong (as noted in a comment below). What's a correct and faster way of doing this?
My validation_images is just
validation_images = images[::6]
and the shape of images is (60000, 784). This is a numpy array.
The current method is not acceptable because it is too slow.