Profiling decorator: added readme and profiler logs added to gitignore

This commit is contained in:
VakarisZ 2020-05-12 12:43:41 +03:00
parent 9b350b8bf5
commit 2debe98052
2 changed files with 12 additions and 0 deletions

3
.gitignore vendored
View File

@ -85,5 +85,8 @@ MonkeyZoo/*
# Exported monkey telemetries
/monkey/telem_sample/
# Profiling logs
/monkey/profiler_logs/
# vim swap files
*.swp

View File

@ -0,0 +1,9 @@
# Profiling island
To profile specific methods on island a `@profile(sort_args=['cumulative'], print_args=[100])`
decorator can be used.
Use it as any other decorator. After decorated method is used, a file will appear in a
directory provided in `profiler_decorator.py`. Filename describes the path of
the method that was profiled. For example if method `monkey_island/cc/resources/netmap.get`
was profiled, then the results of this profiling will appear in
`monkey_island_cc_resources_netmap_get`.