Instructions to use AiDevelopment/donut-base-sroie with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use AiDevelopment/donut-base-sroie with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="AiDevelopment/donut-base-sroie")# Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("AiDevelopment/donut-base-sroie") model = AutoModelForMultimodalLM.from_pretrained("AiDevelopment/donut-base-sroie") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use AiDevelopment/donut-base-sroie with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "AiDevelopment/donut-base-sroie" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AiDevelopment/donut-base-sroie", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/AiDevelopment/donut-base-sroie
- SGLang
How to use AiDevelopment/donut-base-sroie 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 "AiDevelopment/donut-base-sroie" \ --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": "AiDevelopment/donut-base-sroie", "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 "AiDevelopment/donut-base-sroie" \ --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": "AiDevelopment/donut-base-sroie", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use AiDevelopment/donut-base-sroie with Docker Model Runner:
docker model run hf.co/AiDevelopment/donut-base-sroie
Commit ·
d2efb1b
1
Parent(s): a3b32c6
Training in progress, epoch 1
Browse files- runs/Dec16_15-46-02_968654b9638d/events.out.tfevents.1671205567.968654b9638d.11185.14 +2 -2
- runs/Dec16_15-50-54_968654b9638d/1671205859.0339/events.out.tfevents.1671205859.968654b9638d.11185.17 +3 -0
- runs/Dec16_15-50-54_968654b9638d/events.out.tfevents.1671205859.968654b9638d.11185.16 +3 -0
- training_args.bin +1 -1
runs/Dec16_15-46-02_968654b9638d/events.out.tfevents.1671205567.968654b9638d.11185.14
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9c83980a034d003af2d774f5d3da4b53d16bd729ccb0aa76a80324221f70c4f8
|
| 3 |
+
size 8365
|
runs/Dec16_15-50-54_968654b9638d/1671205859.0339/events.out.tfevents.1671205859.968654b9638d.11185.17
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:4a549c1d38064b3d1816b543a7aec9374981b4d95e62f794e9a01fa1d359a572
|
| 3 |
+
size 5909
|
runs/Dec16_15-50-54_968654b9638d/events.out.tfevents.1671205859.968654b9638d.11185.16
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a4dc98047ff87ab516b71b8cd2fdc1815a046d71c8a1a594d0d77eae3344b31a
|
| 3 |
+
size 8232
|
training_args.bin
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 3707
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cb2aa3eb245a35776b3fbed1f1d94f2c6c69a2188403e3967ed40af4c121e2d9
|
| 3 |
size 3707
|