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

Fix occasional BERT sentence length warning #2

Open
freddyheppell opened this issue Mar 23, 2021 · 0 comments
Open

Fix occasional BERT sentence length warning #2

freddyheppell opened this issue Mar 23, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@freddyheppell
Copy link
Owner

freddyheppell commented Mar 23, 2021

UserWarning: some of your sentences have more tokens than "max_seq_len=25" set on the server, as consequence you may get less-accurate or truncated embeddings.
here is what you can do:
- disable the length-check by create a new "BertClient(check_length=False)" when you do not want to display this warning
- or, start a new server with a larger "max_seq_len"
  warnings.warn('some of your sentences have more tokens than "max_seq_len=%d" set on the server, '
@freddyheppell freddyheppell added the bug Something isn't working label Mar 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant