-
Notifications
You must be signed in to change notification settings - Fork 5.7k
add timeline profile howto #8844
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add timeline profile howto #8844
Conversation
|
||
```python | ||
with profiler.profiler('All', 'total', '/tmp/profile') as prof: | ||
for pass_id in range(pass_num): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a warning here:
Don't run many steps (2~3), otherwise the profile will be too large. The profile is only generated after it exits the scope
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
run -> running
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -0,0 +1,27 @@ | |||
## how to use timeline tool to do profile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Capitalize How
|
||
```python | ||
with profiler.profiler('All', 'total', '/tmp/profile') as prof: | ||
for pass_id in range(pass_num): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
run -> running
|
||
 | ||
|
||
1. The resulting timeline should be like: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be like -> should look like
``` | ||
|
||
1. Run `python paddle/tools/timeline.py` to process `/tmp/profile`, it will generate another | ||
file `/tmp/timeline` by default. You can change the path by cmd parameter, please take a look at |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please take a look at -> for further details, refer to
No description provided.