CLIP icon indicating copy to clipboard operation
CLIP copied to clipboard

Question: Do the input tokens have to come from clip.tokenize(str) when using the pretrained model?

Open sunnypurewal opened this issue 3 years ago • 0 comments

Can I use a different method to tokenize the input prompt and still get a proper prediction or must I use the clip.tokenize(str) method? I'm wondering if I can, for example, use Hugging Face's Bert tokenizer or SentencePiece?

My intuition says that I must use clip.tokenize(str) since that's the set of tokens that the model was trained with.

sunnypurewal avatar Aug 10 '22 00:08 sunnypurewal