-
Notifications
You must be signed in to change notification settings - Fork 16
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
IndexError: The shape of the mask [425] at index 0 does not match the shape of the indexed tensor [413, 768] at index 0 #3
Comments
Hi @lenijwp , Our code supports unlimited inputs, by chunking long inputs and encoding each chunks separately. Can you check whether there's a "newline" character at the end of the input? Thanks, |
I checked as you suggested and removed the trailing whitespaces and newline characters from the input. The problem has been solved. Thank you for your timely and helpful assistance! |
Thank you for reporting this! I'll make sure to strip all inputs on our
side.
…On Mon, Mar 6, 2023 at 21:36 Lenic Jiang ***@***.***> wrote:
I checked as you suggested and removed the trailing whitespaces and
newline characters from the input. The problem has been solved. Thank you
for your timely and helpful assistance!
—
Reply to this email directly, view it on GitHub
<#3 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ADSOXMFM25KOPJOEGCP2BZTW22NLXANCNFSM6AAAAAAVR4DRTE>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
When I enter a long code snippet, I get an error like this: “IndexError: The shape of the mask [425] at index 0 does not match the shape of the indexed tensor [413, 768] at index 0”. Does this mean that the maximum input length supported by the model configuration is 413 tokens? I was wondering if the API could be further refined to support arbitrary length or automatic truncation.
The text was updated successfully, but these errors were encountered: