Why Don't Some CLIP Variant Text Encoders Use attn_mask or key_padding_mask for Padding Tokens?
#1061
Unanswered
jianhuiliao
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
In the implementations of text encoders for several CLIP variants (e.g., MobileCLIP-S1/S2, SigLIP/SigLIP2, CLIPA), it appears that these models do not utilize
attn_maskorkey_padding_maskto deal with padding tokens.Is this a common practice in model structure design?
This raises concerns as the lack of such masks might cause attention mechanisms to focus on padding rather than just valid tokens, potentially impacting model performance.
Beta Was this translation helpful? Give feedback.
All reactions