Conversion to Python 3.

Entirely handled by the 2to3 tool.
Updating version number to 1.13 for Python 3 transition.