Cleaned code, removed graph debug comments and console out.