Skip to content

Instantly share code, notes, and snippets.

@romantomjak
romantomjak / ProfilingPython3CodeWithcProfieAndCProfileV.md
Last active July 16, 2022 16:49
Profiling Python 3 Code with cProfile and CProfileV

First, profile your code with cProfile:

$ python3 -m cProfile -o profile_output search.py

But output of that is not very helpful. To make sense of the cProfiler's output install CProfileV:

# install cprofilev
$ pip3 install cprofilev