making analyzer.d compatible with python2.7