-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
PEFT doesn't inject virtual tokens into generate forward pass #2134
Comments
Could you please clarify where you check Also, note that #2096 is in the works that should hopefully fix some issues that prefix tuning has with the latest transformers version. If possible, you could check if that branch fixes the error. |
#2096 never fixes anything except suppressing the warnings since here will convert legacy Then, I started to debug step by step until I found here. The |
I'm not sure if I follow. I set a debugger at the line you mentioned. |
System Info
transformers
version: 4.46.0.dev0Who can help?
@BenjaminBossan @sayakpaul
Information
Tasks
examples
folderReproduction
I met the problem by the following code:
When I add
print(past_key_values)
in transformers side, I gotDynamicCache()
, which means the virtual tokens weren't injected to forward pass.Expected behavior
It should get a cache with length of
num_virtual_tokens
.The text was updated successfully, but these errors were encountered: