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

GeneratingArguments 中的 max_new_tokens 有默认值,任何情况下 max_length 都不会生效 #1356

Closed
liu-zichen opened this issue Nov 2, 2023 · 2 comments
Labels
solved This problem has been already solved

Comments

@liu-zichen
Copy link
Contributor

在设定了 --max_length 而没有 --max_new_tokens 的情况下, --max_length 依然不会生效,因为 max_new_tokens 有默认值而其在不为None时会override max_length。

感谢开发大佬🙏

@hiyouga
Copy link
Owner

hiyouga commented Nov 2, 2023

设置 --max_new_tokens 0 即可

@hiyouga hiyouga added the solved This problem has been already solved label Nov 2, 2023
@hiyouga hiyouga closed this as completed Nov 2, 2023
@hiyouga hiyouga reopened this Nov 2, 2023
@hiyouga hiyouga closed this as completed in dff128c Nov 2, 2023
@hiyouga
Copy link
Owner

hiyouga commented Nov 2, 2023

需要更新代码

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
solved This problem has been already solved
Projects
None yet
Development

No branches or pull requests

2 participants