faster reading for training on a random subsample
bug fix for subsampling in convenience script