You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The output of the last line should be add_embeddings: encoder embedding: 32101 decoder embedding: 32101 lm_head: 32101. In my understanding, a T5 model shares encoder's embedding, decoder embeddings and lm_head. This can be checked by seeing all(model.encoder.embed_tokens.weight[0] == model.decoder.embed_tokens.weight[0]), all(model.encoder.embed_tokens.weight[0] == model.lm_head.weight[0]). However, as shown above added_embeddings method does not affect model.lm_head. This would be more consistent with resize_token_embeddings's result.
The text was updated successfully, but these errors were encountered:
Environment info
adapter-transformers
version: 3.2.1Information
Model I am using (Bert, XLNet ...):
"t5-small"
Language I am using the model on (English, Chinese ...): English
Adapter setup I am using (if any):
The problem arises when using:
The tasks I am working on is:
To reproduce
Steps to reproduce the behavior:
The outputs are:
Expected behavior
The output of the last line should be
add_embeddings: encoder embedding: 32101 decoder embedding: 32101 lm_head: 32101
. In my understanding, a T5 model shares encoder's embedding, decoder embeddings andlm_head
. This can be checked by seeingall(model.encoder.embed_tokens.weight[0] == model.decoder.embed_tokens.weight[0]), all(model.encoder.embed_tokens.weight[0] == model.lm_head.weight[0])
. However, as shown aboveadded_embeddings
method does not affectmodel.lm_head
. This would be more consistent withresize_token_embeddings
's result.The text was updated successfully, but these errors were encountered: