Lambert Labs
Published in

Lambert Labs

How to use C from Python? — #9

Welcome to Learning at Lambert Labs session #9. This week, Amelia Crowther, explains how to use pre-existing C code from Python modules.

In Today’s Learning Session:

  • Reasons to use C code from Python (old legacy apps, performance, access to the C standard library)
  • Two methods: ctypes and creating a C extension
  • Demo using ctypes
  • ctype function annotations
  • Creating a C extension module
  • Demo using to create a C extension
  • Q&A from our developers!

🔊 Subscribe to our channel for weekly learning sessions!

🔗 Lambert Labs Links 🔗 :

🌎 Website:​​

📱 Twitter:​

📝 LinkedIn:

📂 GitHub:​​

⚡ Please leave a LIKE and SUBSCRIBE for more content! ⚡



Lambert Labs is a Python-focused software development agency based in Earls Court, London.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store