The Python Profilers¶ Source code: Lib/profile.py and Lib/pstats.py Introduction to the profilers¶ cProfile and profile provide deterministic profiling of Python programs. A profile is a set of statistics that describes how often and for how long various parts of the program executed. These statistics can be formatted into reports via the pstats module. The Python standard library provides two dif