Image-Text-to-Text
Transformers
TensorBoard
Safetensors
vision-encoder-decoder
Generated from Trainer
Instructions to use umarigan/vit-swin-base-224-gpt2-image-captioning with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use umarigan/vit-swin-base-224-gpt2-image-captioning with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="umarigan/vit-swin-base-224-gpt2-image-captioning")# Load model directly from transformers import AutoTokenizer, AutoModelForImageTextToText tokenizer = AutoTokenizer.from_pretrained("umarigan/vit-swin-base-224-gpt2-image-captioning") model = AutoModelForImageTextToText.from_pretrained("umarigan/vit-swin-base-224-gpt2-image-captioning") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use umarigan/vit-swin-base-224-gpt2-image-captioning with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "umarigan/vit-swin-base-224-gpt2-image-captioning" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "umarigan/vit-swin-base-224-gpt2-image-captioning", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/umarigan/vit-swin-base-224-gpt2-image-captioning
- SGLang
How to use umarigan/vit-swin-base-224-gpt2-image-captioning with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "umarigan/vit-swin-base-224-gpt2-image-captioning" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "umarigan/vit-swin-base-224-gpt2-image-captioning", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "umarigan/vit-swin-base-224-gpt2-image-captioning" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "umarigan/vit-swin-base-224-gpt2-image-captioning", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use umarigan/vit-swin-base-224-gpt2-image-captioning with Docker Model Runner:
docker model run hf.co/umarigan/vit-swin-base-224-gpt2-image-captioning
umarigan/dreamoon
Browse files
README.md
CHANGED
|
@@ -17,13 +17,13 @@ should probably proofread and complete it, then remove this comment. -->
|
|
| 17 |
|
| 18 |
This model is a fine-tuned version of [](https://huggingface.co/) on an unknown dataset.
|
| 19 |
It achieves the following results on the evaluation set:
|
| 20 |
-
- Loss: 0.
|
| 21 |
-
- Rouge1: 29.
|
| 22 |
-
- Rouge2: 7.
|
| 23 |
-
- Rougel:
|
| 24 |
-
- Rougelsum:
|
| 25 |
- Bleu: 0.0
|
| 26 |
-
- Gen Len:
|
| 27 |
|
| 28 |
## Model description
|
| 29 |
|
|
|
|
| 17 |
|
| 18 |
This model is a fine-tuned version of [](https://huggingface.co/) on an unknown dataset.
|
| 19 |
It achieves the following results on the evaluation set:
|
| 20 |
+
- Loss: 0.2164
|
| 21 |
+
- Rouge1: 29.2983
|
| 22 |
+
- Rouge2: 7.1349
|
| 23 |
+
- Rougel: 22.7928
|
| 24 |
+
- Rougelsum: 22.796
|
| 25 |
- Bleu: 0.0
|
| 26 |
+
- Gen Len: 32.3291
|
| 27 |
|
| 28 |
## Model description
|
| 29 |
|
model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 961895704
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:664da895a8d505e486891f13d766ee5f1d74e31e7d3ad160932db20c472aa66b
|
| 3 |
size 961895704
|
runs/Jul09_08-56-44_fcc2f6f1de4a/events.out.tfevents.1752051411.fcc2f6f1de4a.4855.0
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:26e7e7c044bb808aefc721e35418d2af33d1631e8976ebb1453b62a300ef50fc
|
| 3 |
+
size 1759365
|
runs/Jul09_08-56-44_fcc2f6f1de4a/events.out.tfevents.1752057505.fcc2f6f1de4a.4855.1
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6224b0c2be9ae09df799a884866a690f8e1e7012b3cddda330ce57a63876b515
|
| 3 |
+
size 661
|
training_args.bin
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 5560
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:69dd866959fa56bcfb3d60b9d46cd9e2ed836970732efbdef51b9c6bcdcf3d4f
|
| 3 |
size 5560
|