How to divide MNIST training dataset into subparts?
I think you can just read each line of the file which gives you one data point and write it into an output file. Run a loop for the number of data points you want.