Merge pull request #45 from methane/python3

[python3] refactoring
cleanup