-
Notifications
You must be signed in to change notification settings - Fork 251
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
Text Generation Functions: Add Benchmark Script #342
Text Generation Functions: Add Benchmark Script #342
Conversation
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.
Thanks! Some high level organization comments for now. Will take a more in the weeds pass when those are addressed.
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.
Thanks! Few more comments.
return model | ||
|
||
|
||
def run_graph( |
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.
maybe we should just call this generate_text
?
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.
The idea was to have a separate function for eager mode. Is that worth adding to this script? Or does testing in graph mode suffice?
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.
This looks great! Just one last comment. Also, can you rebase on the latest changes (we recently fixed our testing).
Done! |
This is good to go, we are just waiting for #341 to land, so we can land this PR with beam search. |
@abheesht17 looks like this needs a reformat! |
Yep, give me 15 minutes, I'm running the beam search test, will paste the output in the README |
@mattdangerw, this PR is ready to be merged. |
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.
Thanks!
| Beam Search | 564.23 | 615.17 | | ||
| Random Search | 446.55 | 296.21 | | ||
| Top-k Search | 458.68 | 302.66 | | ||
| Top-p Search | 468.63 | 565.50 | |
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.
These are great results btw! Should we open up a bug for top-p being slower? Or do we already know why?
Resolves #335
Tested it here: https://colab.research.google.com/drive/1eaYRSGYY6qu6KhfUJHNVd22TUol_WkPK?usp=sharing