Heavy rework, the emulator module is now written in full C++ using SWIG to interfere with python