pull request for python 3 compatibility

This version works with Python 2.7.8 as well as Python 3.2.3 (tested on Ubuntu 12.04). The string
Conversion in .__sendData() has been adapted to convert manually to 'utf-8' bytes.
05.11.2014 Thomas Hainmüller, University Freiburg