Code to build training and testing matrices are done