spyder-line-profiler

Plugin for the Spyder 5 IDE that integrates the Python line profiler.


Keywords
Qt, PyQt5, PySide2, spyder, plugins, spyplugins, line_profiler, profiler, python, spyder-plugin
License
MIT
Install
pip install spyder-line-profiler==0.3.1

Documentation

Spyder line profiler plugin

Project details

license conda version download count pypi version Join the chat at https://gitter.im/spyder-ide/public OpenCollective Backers OpenCollective Sponsors

Build status

Windows status Linux status MacOS status codecov

Description

This is a plugin to run the Python line_profiler from within the Python IDE Spyder.

The code is an adaptation of the profiler plugin integrated in Spyder.

Installation

To install this plugin, you can use either pip or conda package managers, as follows:

Using conda (the recommended way!):

conda install spyder-line-profiler -c conda-forge

Using pip:

pip install spyder-line-profiler

Usage

Add a @profile decorator to the functions that you wish to profile then Shift+F10 (line profiler default) to run the profiler on the current script, or go to Run > Run line profiler.

The results will be shown in a dockwidget, grouped by function. Lines with a stronger color take more time to run.

Screenshot

Screenshot of spyder-line-profiler plugin showing profiler results

Contributing

Everyone is welcome to contribute!

Sponsors

Spyder and its subprojects are funded thanks to the generous support of

QuansightNumfocus

and the donations we have received from our users around the world through Open Collective:

Sponsors