Add support for python 2and 3.

Closes #16