Triangulating Python Performance Issues with Scalene

12/15/2022
by   Emery D. Berger, et al.
0

This paper proposes Scalene, a profiler specialized for Python. Scalene combines a suite of innovations to precisely and simultaneously profile CPU, memory, and GPU usage, all with low overhead. Scalene's CPU and memory profilers help Python programmers direct their optimization efforts by distinguishing between inefficient Python and efficient native execution time and memory usage. Scalene's memory profiler employs a novel sampling algorithm that lets it operate with low overhead yet high precision. It also incorporates a novel algorithm that automatically pinpoints memory leaks, whether within Python or across the Python-native boundary. Scalene tracks a new metric called copy volume, which highlights costly copying operations that can occur when Python silently converts between C and Python data representations, or between CPU and GPU. Since its introduction, Scalene has been widely adopted, with over 500,000 downloads to date. We present experience reports from developers who used Scalene to achieve significant performance improvements and memory savings.

READ FULL TEXT
research
06/06/2020

Scalene: Scripting-Language Aware Profiling for Python

Existing profilers for scripting languages (a.k.a. "glue" languages) lik...
research
12/28/2018

Kymatio: Scattering Transforms in Python

The wavelet scattering transform is an invariant signal representation s...
research
06/11/2021

Toward Efficient Interactions between Python and Native Libraries

Python has become a popular programming language because of its excellen...
research
10/08/2022

Demand Layering for Real-Time DNN Inference with Minimized Memory Usage

When executing a deep neural network (DNN), its model parameters are loa...
research
03/15/2022

Performance Comparison of Python Translators for a Multi-threaded CPU-bound Application

Currently, Python is one of the most widely used languages in various ap...
research
08/09/2023

CHERI Performance Enhancement for a Bytecode Interpreter

During our port of the MicroPython bytecode interpreter to the CHERI-bas...
research
05/04/2023

SlipCover: Near Zero-Overhead Code Coverage for Python

Coverage analysis is widely used but can suffer from high overhead. This...

Please sign up or login with your details

Forgot password? Click here to reset