Final Year Project - Aspectus
Collection
Aspectus is a VQA system to designed for visually impaired people. In this collection i added the fine-tuned models that we will use in the system • 5 items • Updated
How to use ebrukilic/paligemma2_vizwiz_ft2 with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("image-text-to-text", model="ebrukilic/paligemma2_vizwiz_ft2") # Load model directly
from transformers import AutoProcessor, AutoModelForMultimodalLM
processor = AutoProcessor.from_pretrained("ebrukilic/paligemma2_vizwiz_ft2")
model = AutoModelForMultimodalLM.from_pretrained("ebrukilic/paligemma2_vizwiz_ft2", device_map="auto")How to use ebrukilic/paligemma2_vizwiz_ft2 with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "ebrukilic/paligemma2_vizwiz_ft2"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "ebrukilic/paligemma2_vizwiz_ft2",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/ebrukilic/paligemma2_vizwiz_ft2
How to use ebrukilic/paligemma2_vizwiz_ft2 with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "ebrukilic/paligemma2_vizwiz_ft2" \
--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": "ebrukilic/paligemma2_vizwiz_ft2",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'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 "ebrukilic/paligemma2_vizwiz_ft2" \
--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": "ebrukilic/paligemma2_vizwiz_ft2",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use ebrukilic/paligemma2_vizwiz_ft2 with Docker Model Runner:
docker model run hf.co/ebrukilic/paligemma2_vizwiz_ft2
This model is a fine-tuned version of google/paligemma2-3b-pt-448 on the None dataset. It achieves the following results on the evaluation set:
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss |
|---|---|---|---|
| 0.7985 | 0.1308 | 500 | 0.7325 |
| 0.7331 | 0.2616 | 1000 | 0.7017 |
| 0.6924 | 0.3924 | 1500 | 0.6753 |
| 0.6626 | 0.5232 | 2000 | 0.6491 |
| 0.7161 | 0.6540 | 2500 | 0.6260 |
| 0.6387 | 0.7848 | 3000 | 0.6122 |
| 0.4991 | 0.9156 | 3500 | 0.6080 |
| 0.3359 | 1.0463 | 4000 | 0.6072 |