Code clean up

Cleaned up code, removed some files.