Browse Source

Profile

pull/9/head
Jure Šorn 6 years ago
parent
commit
81ad53ff4e
1 changed files with 2 additions and 2 deletions
  1. 4
      README.md

4
README.md

@ -1420,7 +1420,7 @@ with PyCallGraph(output=graph):
``` ```
### Profiling Decorators ### Profiling Decorators
#### Prints runtime of decorated function: #### Prints runtime of a decorated function:
```python ```python
from timeit import default_timer from timeit import default_timer
from datetime import timedelta from datetime import timedelta
@ -1435,7 +1435,7 @@ def time_me(func):
return out return out
``` ```
#### Saves run call profile of the decorated function to file: #### Saves run call profile of a decorated function to file:
```python ```python
from cProfile import Profile from cProfile import Profile
from pstats import Stats from pstats import Stats

|||||||
100:0
Loading…
Cancel
Save