-
Notifications
You must be signed in to change notification settings - Fork 310
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make use of prefilled cache in beam_search when `predict_batch_with_a…
…ux.prompt_with_targets` is set to True Without this change, the targets that are actually prompts will still be decoded AR style in order to build the cache, the logits are thrown away. With this change, and setting `EncoderDecoder.predict_batch_with_aux.prompt_with_target` to `True` we instead skip over the given prompts all together, speeding up the decode. PiperOrigin-RevId: 559256044
- Loading branch information
1 parent
0728d84
commit aac9b3f
Showing
2 changed files
with
320 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.