how to load the jina-clip-v2 model offline? help me plz!!
#10
by
HT-NEKO
- opened
I want to know how to load the jina-clip-v2 model offline, beacuse the server I use cannot connect to the Internet. . .
I have done this:
- Download https://huggingface.co/jinaai/jina-clip-implementation to the local computer and save it to the folder my_jina_clip
- Download https://huggingface.co/jinaai/jina-clip-v2 to the local computer and save it to the folder jina-clip-v2
- Run the code:
from my_jina_clip.modeling_clip import JinaCLIPModel
model=JinaCLIPModel.from_pretrained("./jina-clip-v2")
But in the HFTextEncoder of hf_model.py, you still need to set trust_remote_code=True to load it remotely.
Please help me, thank you very much! !