Continuing to rewrite into python.