Polishing the code and GUI