CLIP_prefix_caption icon indicating copy to clipboard operation
CLIP_prefix_caption copied to clipboard

Add model to HuggingFace

Open NielsRogge opened this issue 4 years ago • 3 comments

Hi,

Really cool work! One thing that could be cool (it's a feature that was recently added to HuggingFace Transformers) is the ability to load any custom PyTorch model from the hub as introduced in this PR. The idea would be that you can create a new model on the hub (it's as easy as clicking "new model", then git add ., git commit, git push to upload the weights to the repo on the hub). You can also pass in a custom script defining your model. Next, one can load your custom model as follows:

from transformers import AutoModel

model = AutoModel.from_pretrained("rmokday/clip_prefix_caption", trust_remote_code=True)

This could be easier compared to hosting the models on Google Drive, and you don't need to define the model again everytime someone wants to use it in a notebook :)

Do you mind trying this out?

Kind regards,

Niels

NielsRogge avatar Oct 11 '21 13:10 NielsRogge

@NielsRogge Sounds cool, I'll hope to try it out soon

rmokady avatar Oct 11 '21 18:10 rmokady

@rmokady any updates on this?

RylanSchaeffer avatar Oct 21 '21 15:10 RylanSchaeffer

@rmokady any updates on this?

Currently our top priority is to improve our model, so I guess it will be delayed If someone will find it relevant, we will very appreciate this contribution

rmokady avatar Oct 21 '21 19:10 rmokady