Page Body

From 3 to 300 FPS: NES Emulation in Python and Cython

James Murphy, PyCon US 2021:

It is sometimes asserted that “Python is a real bad choice for any kind of real-time system”. When I first got my Python NES emulator to boot, only for it to run at 2 frames per second, I felt like agreeing. But is it really true? After just a few days reworking the emulator’s operational core into Cython, the framerate is now above 300fps, proving that Python is a viable choice for emulator development and other performance-dependent projects. In this talk, I will outline the advantages and some challenges of using Cython to achieve realtime performance from an existing Python codebase.

NES Emulation in Python and Cython

Enjoyed this post?

Subscribe to the feed for the latest updates.