Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Write Faster Python - Common Performance Anti Patterns

PyCon US via YouTube

Overview

Discover common performance anti-patterns in Python and learn how to optimize your code for speed without sacrificing readability in this 30-minute PyCon US talk. Set up profilers to measure application performance, track improvements, and regressions. Explore specific examples of Python code refactoring, including looping variants, list comprehensions, and proper type usage. Gain insights into reading profiler results, understanding tuple iterators, unmutated collections, and function call optimization. Enhance your Python programming skills with practical tips and techniques for writing faster, more efficient code.

Syllabus

Intro
James Murphy talk
How to improve performance
Before you start
Profilers
Sampling profilers
My favourite profilers
Antipatterns
linter
Looping variants
List comprehension
Wrong types
Example
Reading the results
tuple iterator
unmutated collection
calling too many functions
a and b example
Utility library
Wrap up
Outro

Taught by

PyCon US

Reviews

Start your review of Write Faster Python - Common Performance Anti Patterns

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.