moved out log transform for monkey path (https://mail.python.org/pipermail/python-dev/2008-January/076194.html)