Change these "print >> sys.stderr" to self._logger.xxx('.....') ?