fix py3 functionality
Merge pull request #35 from mgax/fix-py3

fix py3 functionality