test_train data management