Finished refactoring
finished refactoring and testing
Kumar's method; Updates to preprocessing