How to use blip2 for image-text Retrieval.
#3
by
skycyou
- opened
Is there some thing wrong with the model?
When I load Salesforce/blip2-itm-vit-g with Blip2ForImageTextRetrieval, it seems weights were not properly loaded.
Some weights of the model checkpoint at /home/pyr/pretrained_models/Salesforce/blip2-itm-vit-g were not used when initializing Blip2ForImageTextRetrieval: ['cls.predictions.bias', 'cls.predictions.decoder.bias', 'cls.predictions.decoder.weight', 'cls.predictions.transform.LayerNorm.bias', 'cls.predictions.transform.LayerNorm.weight', 'cls.predictions.transform.dense.bias', 'cls.predictions.transform.dense.weight', 'qformer.embeddings.LayerNorm.bias', 'qformer.embeddings.LayerNorm.weight', 'qformer.embeddings.position_embeddings.weight', 'qformer.embeddings.word_embeddings.weight', 'temp', 'text_proj.bias', 'text_proj.weight', 'vision_proj.bias', 'vision_proj.weight']
can you please share a code sample? it should work with the main branch of transformers
can you please share a code sample? it should work with the main branch of transformers
Thanks for your reply. It do work after I reupdate my transformers. I don't know which lib I used has cause the issue above.