Artwork

محتوای ارائه شده توسط Real Python. تمام محتوای پادکست شامل قسمت‌ها، گرافیک‌ها و توضیحات پادکست مستقیماً توسط Real Python یا شریک پلتفرم پادکست آن‌ها آپلود و ارائه می‌شوند. اگر فکر می‌کنید شخصی بدون اجازه شما از اثر دارای حق نسخه‌برداری شما استفاده می‌کند، می‌توانید روندی که در اینجا شرح داده شده است را دنبال کنید.https://fa.player.fm/legal
Player FM - برنامه پادکست
با برنامه Player FM !

Using a Memory Profiler in Python & What It Can Teach You

1:03:43
 
اشتراک گذاری
 

Manage episode 343337195 series 2637014
محتوای ارائه شده توسط Real Python. تمام محتوای پادکست شامل قسمت‌ها، گرافیک‌ها و توضیحات پادکست مستقیماً توسط Real Python یا شریک پلتفرم پادکست آن‌ها آپلود و ارائه می‌شوند. اگر فکر می‌کنید شخصی بدون اجازه شما از اثر دارای حق نسخه‌برداری شما استفاده می‌کند، می‌توانید روندی که در اینجا شرح داده شده است را دنبال کنید.https://fa.player.fm/legal

Have you used a memory profiler to gauge the performance of your Python application? Maybe you’re using it to troubleshoot memory issues when loading a large data science project. What could running a profiler show you about a codebase you’re learning? This week on the show, Pablo Galindo Salgado returns to talk about Memray, a powerful tracing memory profiler.

Pablo developed Memray while working at Bloomberg to track memory allocations beyond Python code into native extensions and the interpreter itself. It’s a compelling tool that provides fine-grain reports to help you understand where memory is used.

Pablo shares the reporting that Memray provides, including live mode, flame graphs, and a pytest plug-in. We also discuss how a tracing memory profiler can help you understand a new codebase.

He walks through how he developed the first prototype internally and eventually moved the project into open source. This is the first part of my conversation with Pablo. In a couple of weeks, you’ll get the second part, where we talk about Python guilds inside large companies and his work as the release manager for Python 3.10 and 3.11.

Course Spotlight: SQLite and SQLAlchemy in Python: Moving Your Data Beyond Flat Files

In this video course, you’ll learn how to store and retrieve data using Python, SQLite, and SQLAlchemy as well as with flat files. Using SQLite with Python brings with it the additional benefit of accessing data with SQL. By adding SQLAlchemy, you can work with data in terms of objects and methods.

Topics:

  • 00:00:00 – Introduction
  • 00:02:48 – When should you use a memory profiler?
  • 00:05:13 – Fine-grain reporting
  • 00:13:17 – Sampling profiler vs tracing profiler
  • 00:19:46 – Sponsor: Deepgram
  • 00:20:31 – What is a flame graph?
  • 00:30:36 – Using Rich for terminal reporters
  • 00:40:08 – Currently only Linux and macOS
  • 00:41:13 – pytest plug-in
  • 00:42:03 – Showing native allocation details
  • 00:44:20 – Video Course Spotlight
  • 00:45:52 – Using a profiler to learn a codebase
  • 00:54:39 – Moving from internal project to open source
  • 01:02:17 – Thanks and goodbye

Show Links:

Level up your Python skills with our expert-led courses:

Support the podcast & join our community of Pythonistas

  continue reading

272 قسمت

Artwork
iconاشتراک گذاری
 
Manage episode 343337195 series 2637014
محتوای ارائه شده توسط Real Python. تمام محتوای پادکست شامل قسمت‌ها، گرافیک‌ها و توضیحات پادکست مستقیماً توسط Real Python یا شریک پلتفرم پادکست آن‌ها آپلود و ارائه می‌شوند. اگر فکر می‌کنید شخصی بدون اجازه شما از اثر دارای حق نسخه‌برداری شما استفاده می‌کند، می‌توانید روندی که در اینجا شرح داده شده است را دنبال کنید.https://fa.player.fm/legal

Have you used a memory profiler to gauge the performance of your Python application? Maybe you’re using it to troubleshoot memory issues when loading a large data science project. What could running a profiler show you about a codebase you’re learning? This week on the show, Pablo Galindo Salgado returns to talk about Memray, a powerful tracing memory profiler.

Pablo developed Memray while working at Bloomberg to track memory allocations beyond Python code into native extensions and the interpreter itself. It’s a compelling tool that provides fine-grain reports to help you understand where memory is used.

Pablo shares the reporting that Memray provides, including live mode, flame graphs, and a pytest plug-in. We also discuss how a tracing memory profiler can help you understand a new codebase.

He walks through how he developed the first prototype internally and eventually moved the project into open source. This is the first part of my conversation with Pablo. In a couple of weeks, you’ll get the second part, where we talk about Python guilds inside large companies and his work as the release manager for Python 3.10 and 3.11.

Course Spotlight: SQLite and SQLAlchemy in Python: Moving Your Data Beyond Flat Files

In this video course, you’ll learn how to store and retrieve data using Python, SQLite, and SQLAlchemy as well as with flat files. Using SQLite with Python brings with it the additional benefit of accessing data with SQL. By adding SQLAlchemy, you can work with data in terms of objects and methods.

Topics:

  • 00:00:00 – Introduction
  • 00:02:48 – When should you use a memory profiler?
  • 00:05:13 – Fine-grain reporting
  • 00:13:17 – Sampling profiler vs tracing profiler
  • 00:19:46 – Sponsor: Deepgram
  • 00:20:31 – What is a flame graph?
  • 00:30:36 – Using Rich for terminal reporters
  • 00:40:08 – Currently only Linux and macOS
  • 00:41:13 – pytest plug-in
  • 00:42:03 – Showing native allocation details
  • 00:44:20 – Video Course Spotlight
  • 00:45:52 – Using a profiler to learn a codebase
  • 00:54:39 – Moving from internal project to open source
  • 01:02:17 – Thanks and goodbye

Show Links:

Level up your Python skills with our expert-led courses:

Support the podcast & join our community of Pythonistas

  continue reading

272 قسمت

Semua episod

×
 
Loading …

به Player FM خوش آمدید!

Player FM در سراسر وب را برای یافتن پادکست های با کیفیت اسکن می کند تا همین الان لذت ببرید. این بهترین برنامه ی پادکست است که در اندروید، آیفون و وب کار می کند. ثبت نام کنید تا اشتراک های شما در بین دستگاه های مختلف همگام سازی شود.

 

راهنمای مرجع سریع

در حین کاوش به این نمایش گوش دهید
پخش