change code to be more modular. one piece of data generated at a time and preds/tests run on that.