This is really two questions, but they are so similar, and to keep it simple, I figured I\'d just roll them together:
Firstly: Given an est
Run your app through the Python profiler. Find a serious bottleneck. Rewrite that bottleneck in C. Repeat.