-
Notifications
You must be signed in to change notification settings - Fork 498
/
Copy path11b_sglang_infer.yaml
44 lines (40 loc) · 1.74 KB
/
11b_sglang_infer.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# SGLang inference config for Llama 3.2 11B Vision Instruct.
#
# Requirements:
# - Install SGLang: https://docs.sglang.ai/start/install.html
# - Log into HF: `huggingface-cli login`
# - Request access to Llama 3.2: https://huggingface.co/meta-llama/Llama-3.2-11B-Vision-Instruct
#
# Usage:
# oumi infer -i -c configs/recipes/vision/llama3_2_vision/inference/11b_sglang_infer.yaml \
# --image "tests/testdata/images/the_great_wave_off_kanagawa.jpg"
#
# Sample command to start SGLang server:
# CUDA_VISIBLE_DEVICES=0 python -m sglang.launch_server \
# --model-path meta-llama/Llama-3.2-11B-Vision-Instruct \
# --tokenizer-path meta-llama/Llama-3.2-11B-Vision-Instruct \
# --port 6864 --disable-cuda-graph --mem-fraction-static=0.9
# For GPU-s with less than 40GB of VRAM, try --mem-fraction-static=0.99
#
# See Also:
# - Documentation: https://oumi.ai/docs/en/latest/user_guides/infer/infer.html
# - Config class: oumi.core.configs.InferenceConfig
# - Config source: https://github.com/oumi-ai/oumi/blob/main/src/oumi/core/configs/inference_config.py
# - Other inference configs: configs/**/inference/
model:
model_name: "meta-llama/Llama-3.2-11B-Vision-Instruct"
torch_dtype_str: "bfloat16"
model_max_length: 1024
chat_template: "llama3-instruct"
trust_remote_code: True
generation:
max_new_tokens: 32
batch_size: 1
remote_params:
# This address is just an example (it's what you usually get when you start sglang sever locally).
# For production use, set it to a remote address/port.
# For more details, see the following:
# https://sgl-project.github.io/references/sampling_params.html
# https://github.com/skypilot-org/skypilot/blob/master/llm/sglang/README.md
api_url: "http://127.0.0.1:6864/generate"
engine: SGLANG