π² Snakeviz
Snakeviz is a browser-based GUI for visualising the output of Pythonβs cProfile module.
Usage Example
Install Snakeviz with: pip install snakeviz
First, youβll need to generate a profile file using cProfile
:
import cProfile
cProfile.run('example_function()', 'profile_output')
Then, you can visualise the performance with Snakeviz:
snakeviz profile_output
This will open a browser tab with an interactive visualisation.