Episode 60: Building a Platform Game With Arcade and Covering Python News Monthly
The Real Python Podcast
May 14, 2021 54m
Did you know the Python Software Foundation is hiring! With the recent support of three Visionary Sponsors, the PSF has been able to open positions for a developer-in-residence and a Python packaging project manager. Real Python now has a monthly Python news article. Frequent guest of the show, David Amos compiles and summarizes the biggest Python news from the past month.
Episode Sponsor:
This week on the show, David Amos is back, and he’s brought another batch of PyCoder’s Weekly articles and projects. We discuss David’s news article from the last month. We also discuss previous guest Jon Fincher’s new step-by-step tutorial about creating a platform game with the arcade framework.
We cover several other articles and projects from the Python community including, how to use ipywidgets to make your Jupyter notebook interactive, the hidden performance overhead of Python C extensions, adding else to for loops, film simulations from scratch using Python, a gradual programming language named Hedy, and a Python raytracer.
Spotlight: CPython Internals: Your Guide to the Python 3 Interpreter
Unlock the Inner Workings of the Python Language, Compile the Python Interpreter From Source Code, And Participate in the Development of CPython
Topics:
- 00:00:00 – Introduction
- 00:02:04 – How to Use ipywidgets to Make Your Jupyter Notebook Interactive
- 00:06:07 – Build a Platform Game in Python With arcade
- 00:12:35 – Sponsor: Digital Ocean’s App Platform
- 00:13:11 – The Hidden Performance Overhead of Python C Extensions
- 00:21:17 – For-Else: A Weird but Useful Feature in Python
- 00:25:42 – Python News: What’s New From April 2021?
- 00:39:43 – Spotlight: CPython Internals Now in Paperback!
- 00:41:15 – Film Simulations From Scratch Using Python
- 00:47:44 – hedy: Hedy Is a Gradual Programming Language, Which Increases in Syntactic Elements Level by Level
- 00:50:27 – Python-Raytracer: A Basic Ray Tracer That Exploits NumPy Arrays and Functions to Work Fast
- 00:53:31 – Thanks and goodbye
Show Links:
How to Use ipywidgets to Make Your Jupyter Notebook Interactive – Jupyter Notebooks are great for exploratory data analysis. They’re also a good way to share results and analysis with other people, who can alter the notebook to further explore the data themselves. But there are some limitations to notebook interactivity. That’s where ipywidgets
comes in! In this tutorial you’ll learn how to create widgets like check boxes, drop-down menus, sliders, and how to handle events like button clicks.
Build a Platform Game in Python With arcade – Building games can be a fun way to learn new Python concepts and practice techniques you’ve already learned. Plus, they make for great projects to share! This step-by-step tutorial shows you how to build a platform game using the arcade
library. You’ll learn techniques for designing levels, sourcing assets, and implementing advanced features
The Hidden Performance Overhead of Python C Extensions – It’s no secret that Python is slower than compiled languages like C, C++, and Rust. If you need a performance boost, you can write compiled Python C extensions. But there are some hidden performance costs that you should be aware of if you decide to do this. This article explains two ways that Python C extensions can actually be slower than pure Python and discusses some solutions and work around for them.
For-Else: A Weird but Useful Feature in Python – Python for
loops have an unusual feature: they support an else
block that only executes if there is no break in the loop. The pattern isn’t used very often with the argument against it being that it is a bit weird and potentially difficult to understand. But there may be times when for/else
makes sense. This article presents three situations where for/else
is useful and argues that, in these situations, the pattern makes the code more readable.
Python News: What’s New From April 2021? – April 2021 was an eventful month in the world of Python. In this article, you’ll get up to speed on everything that happened in the past month, including new sponsorships for the PSF, changes to Python error messages, and a community-led discussion over the future of type annotations.
Film Simulations From Scratch Using Python – In analog photography, you can achieve different “looks” for your photographs by selecting different kinds of film to shoot with. Digital camera manufacturers often include different presets to simulate different kinds of film. In this article, you’ll learn how to simulate different films on your own images using color lookup tables, or CLUTs, using NumPy and the Pillow image library.
Projects:
- hedy: Hedy Is a Gradual Programming Language, Which Increases in Syntactic Elements Level by Level
- Python-Raytracer: A Basic Ray Tracer That Exploits NumPy Arrays and Functions to Work Fast
Additional Links:
- The Python Arcade Library
- Arcade: A Primer on the Python Game Framework
- Kenney: Free game assets, no strings attached
- Tiled: Free and Open Source, Flexible Level Editor
- Episode 24: Options for Packaging Your Python Application: Wheels, Docker, and More
- Your Code Is Without a Doubt the Worst I Have Ever Run
- Welcoming Google as a Visionary Sponsor of the PSF
- Welcoming Microsoft as a Visionary Sponsor
- Python Job Board: Project Manager - Python Packaging
- PEP 563 – Postponed Evaluation of Annotations
- Episode 45: Processing Images in Python With Pillow
- RawTherapee: A free, cross-platform raw image processing program