Skip to content
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

tgt/src ratio based beam stopping condition #1344

Merged
merged 2 commits into from
Mar 8, 2019
Merged

Conversation

vince62s
Copy link
Member

@vince62s vince62s commented Mar 6, 2019

Based on this paper http://aclweb.org/anthology/D18-1342

this PR replaces #1336 which was done on an old codebase.

Usage:
translate.py -length_penalty avg -ratio 1.1
where 1.1 is the predicted ratio tgt_len / src_len

I tested it on a few engines, it brings some improvements.

@vince62s vince62s mentioned this pull request Mar 7, 2019
@yilinyang7
Copy link

Thanks for your efforts.

@vince62s vince62s merged commit 9b3083f into OpenNMT:master Mar 8, 2019
@vince62s vince62s deleted the ratio branch August 17, 2022 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants