Skip to content

This is a plugin to run the python line profiler from within the spyder editor.

License

Notifications You must be signed in to change notification settings

spyder-ide/spyder-line-profiler

Repository files navigation

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