Instructions to use Ayansk11/Image_Caption_using_ViT_GPT2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Ayansk11/Image_Caption_using_ViT_GPT2 with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "image-to-text" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # 'pip install "transformers<5.0.0' from transformers import pipeline pipe = pipeline("image-to-text", model="Ayansk11/Image_Caption_using_ViT_GPT2")# Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("Ayansk11/Image_Caption_using_ViT_GPT2") model = AutoModelForMultimodalLM.from_pretrained("Ayansk11/Image_Caption_using_ViT_GPT2", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -16,7 +16,6 @@ widget:
|
|
| 16 |
|
| 17 |

|
| 18 |
|
| 19 |
-
* https://ankur3107.github.io/blogs/the-illustrated-image-captioning-using-transformers/
|
| 20 |
|
| 21 |
|
| 22 |
# Sample running code
|
|
|
|
| 16 |
|
| 17 |

|
| 18 |
|
|
|
|
| 19 |
|
| 20 |
|
| 21 |
# Sample running code
|