Image-Text-to-Text
Transformers
Safetensors
glm5_next
glm
exl3
tr3
vllm
sm120
nvfp4
dflash2
multimodal
shapleymcg
conversational
Eval Results (legacy)
4-bit precision
Instructions to use brandonmusic/GLM-5.3-Flash-tr3-4bpw with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use brandonmusic/GLM-5.3-Flash-tr3-4bpw with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="brandonmusic/GLM-5.3-Flash-tr3-4bpw") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("brandonmusic/GLM-5.3-Flash-tr3-4bpw") model = AutoModelForMultimodalLM.from_pretrained("brandonmusic/GLM-5.3-Flash-tr3-4bpw", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use brandonmusic/GLM-5.3-Flash-tr3-4bpw with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "brandonmusic/GLM-5.3-Flash-tr3-4bpw" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "brandonmusic/GLM-5.3-Flash-tr3-4bpw", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/brandonmusic/GLM-5.3-Flash-tr3-4bpw
- SGLang
How to use brandonmusic/GLM-5.3-Flash-tr3-4bpw 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 "brandonmusic/GLM-5.3-Flash-tr3-4bpw" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "brandonmusic/GLM-5.3-Flash-tr3-4bpw", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'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 "brandonmusic/GLM-5.3-Flash-tr3-4bpw" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "brandonmusic/GLM-5.3-Flash-tr3-4bpw", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use brandonmusic/GLM-5.3-Flash-tr3-4bpw with Docker Model Runner:
docker model run hf.co/brandonmusic/GLM-5.3-Flash-tr3-4bpw
Publish independent five-run FP8 KLD reports
Browse files- runtime-results/v34/fp8-five-run-gpu23/run-01/kld-report.json +30 -0
- runtime-results/v34/fp8-five-run-gpu23/run-02/kld-report.json +30 -0
- runtime-results/v34/fp8-five-run-gpu23/run-03/kld-report.json +30 -0
- runtime-results/v34/fp8-five-run-gpu23/run-04/kld-report.json +30 -0
- runtime-results/v34/fp8-five-run-gpu23/run-05/kld-report.json +30 -0
runtime-results/v34/fp8-five-run-gpu23/run-01/kld-report.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"capture_manifest_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/capture/run-01-capture-manifest.json",
|
| 3 |
+
"capture_manifest_sha256": "aa43e7373459c7eae28b4d38ba62d8ab59d86c733a49073fef213de2bc72c4e5",
|
| 4 |
+
"compute_device": "cuda:2",
|
| 5 |
+
"compute_dtype": "float64",
|
| 6 |
+
"elapsed_seconds": 1.4390679769567214,
|
| 7 |
+
"kld_direction": "bf16_teacher_to_r19_exl3_runtime",
|
| 8 |
+
"max_mean_kld": 0.06,
|
| 9 |
+
"mean_kld_gate_passed": true,
|
| 10 |
+
"prediction_positions": 2047,
|
| 11 |
+
"schema": "glm53-r19-runtime-window-kld.v1",
|
| 12 |
+
"summary": {
|
| 13 |
+
"count": 2047,
|
| 14 |
+
"cvar95": 0.20200835167128647,
|
| 15 |
+
"max": 1.1246660671716389,
|
| 16 |
+
"mean": 0.024677178792442127,
|
| 17 |
+
"p50": 0.010969144496658936,
|
| 18 |
+
"p95": 0.08036719864205093,
|
| 19 |
+
"p99": 0.24636326137225797,
|
| 20 |
+
"std": 0.06256522662169968
|
| 21 |
+
},
|
| 22 |
+
"teacher_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/inputs/kld/teacher/logits/window-0000.safetensors",
|
| 23 |
+
"teacher_sha256": "9f49af1b1b1a6ac88a00f5feaa89c25232597306d73d7c0cd30bb7e9c775cfb6",
|
| 24 |
+
"tokens_sha256": "338027e62f41540f73e38c6f9b4b9a06a50196cbd38cd9c69f11886af9d3cf9f",
|
| 25 |
+
"tokenwise_kld_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/measurements/run-01/tokenwise-kld.npy",
|
| 26 |
+
"tokenwise_kld_sha256": "0abcf822d6c1788aba767940bf439f01a23d3cda009aa25f61c20345d7c77949",
|
| 27 |
+
"top1_agreement": 0.9408891060087934,
|
| 28 |
+
"vocab_size": 154880,
|
| 29 |
+
"window_id": "final-0000"
|
| 30 |
+
}
|
runtime-results/v34/fp8-five-run-gpu23/run-02/kld-report.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"capture_manifest_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/capture/run-02-capture-manifest.json",
|
| 3 |
+
"capture_manifest_sha256": "dc993031e86b7d6674133bafad61697d711b02535acd971d49a78aee479b0814",
|
| 4 |
+
"compute_device": "cuda:2",
|
| 5 |
+
"compute_dtype": "float64",
|
| 6 |
+
"elapsed_seconds": 1.4359246700187214,
|
| 7 |
+
"kld_direction": "bf16_teacher_to_r19_exl3_runtime",
|
| 8 |
+
"max_mean_kld": 0.06,
|
| 9 |
+
"mean_kld_gate_passed": true,
|
| 10 |
+
"prediction_positions": 2047,
|
| 11 |
+
"schema": "glm53-r19-runtime-window-kld.v1",
|
| 12 |
+
"summary": {
|
| 13 |
+
"count": 2047,
|
| 14 |
+
"cvar95": 0.20869389888984513,
|
| 15 |
+
"max": 1.1246660671716389,
|
| 16 |
+
"mean": 0.02453289589104624,
|
| 17 |
+
"p50": 0.01054206169041206,
|
| 18 |
+
"p95": 0.07934805258915137,
|
| 19 |
+
"p99": 0.24636326137225797,
|
| 20 |
+
"std": 0.06428862883447375
|
| 21 |
+
},
|
| 22 |
+
"teacher_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/inputs/kld/teacher/logits/window-0000.safetensors",
|
| 23 |
+
"teacher_sha256": "9f49af1b1b1a6ac88a00f5feaa89c25232597306d73d7c0cd30bb7e9c775cfb6",
|
| 24 |
+
"tokens_sha256": "338027e62f41540f73e38c6f9b4b9a06a50196cbd38cd9c69f11886af9d3cf9f",
|
| 25 |
+
"tokenwise_kld_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/measurements/run-02/tokenwise-kld.npy",
|
| 26 |
+
"tokenwise_kld_sha256": "ac539781b1dc47154db0eb9e187013ca37ee7baa49a4a4c44b26bdaf0583f5d4",
|
| 27 |
+
"top1_agreement": 0.9418661455788959,
|
| 28 |
+
"vocab_size": 154880,
|
| 29 |
+
"window_id": "final-0000"
|
| 30 |
+
}
|
runtime-results/v34/fp8-five-run-gpu23/run-03/kld-report.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"capture_manifest_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/capture/run-03-capture-manifest.json",
|
| 3 |
+
"capture_manifest_sha256": "faf78b9b2ac5d8a5f1c3f864fd1df53663fae30fa82776f56422e921d6b7b3ec",
|
| 4 |
+
"compute_device": "cuda:2",
|
| 5 |
+
"compute_dtype": "float64",
|
| 6 |
+
"elapsed_seconds": 1.4361105849966407,
|
| 7 |
+
"kld_direction": "bf16_teacher_to_r19_exl3_runtime",
|
| 8 |
+
"max_mean_kld": 0.06,
|
| 9 |
+
"mean_kld_gate_passed": true,
|
| 10 |
+
"prediction_positions": 2047,
|
| 11 |
+
"schema": "glm53-r19-runtime-window-kld.v1",
|
| 12 |
+
"summary": {
|
| 13 |
+
"count": 2047,
|
| 14 |
+
"cvar95": 0.21029045130079735,
|
| 15 |
+
"max": 1.1246660671716389,
|
| 16 |
+
"mean": 0.024732589677082917,
|
| 17 |
+
"p50": 0.010488501989464195,
|
| 18 |
+
"p95": 0.08158327316170517,
|
| 19 |
+
"p99": 0.25701062479841114,
|
| 20 |
+
"std": 0.06408516449215676
|
| 21 |
+
},
|
| 22 |
+
"teacher_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/inputs/kld/teacher/logits/window-0000.safetensors",
|
| 23 |
+
"teacher_sha256": "9f49af1b1b1a6ac88a00f5feaa89c25232597306d73d7c0cd30bb7e9c775cfb6",
|
| 24 |
+
"tokens_sha256": "338027e62f41540f73e38c6f9b4b9a06a50196cbd38cd9c69f11886af9d3cf9f",
|
| 25 |
+
"tokenwise_kld_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/measurements/run-03/tokenwise-kld.npy",
|
| 26 |
+
"tokenwise_kld_sha256": "b3192e6d32d1530686776bb45071c2b0be770617147644c1890913038325bb69",
|
| 27 |
+
"top1_agreement": 0.9355153883732291,
|
| 28 |
+
"vocab_size": 154880,
|
| 29 |
+
"window_id": "final-0000"
|
| 30 |
+
}
|
runtime-results/v34/fp8-five-run-gpu23/run-04/kld-report.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"capture_manifest_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/capture/run-04-capture-manifest.json",
|
| 3 |
+
"capture_manifest_sha256": "01523a113b4d458583f6680726a143fd768653dc57ade3ba82686e9e1b37090f",
|
| 4 |
+
"compute_device": "cuda:2",
|
| 5 |
+
"compute_dtype": "float64",
|
| 6 |
+
"elapsed_seconds": 1.4678278209757991,
|
| 7 |
+
"kld_direction": "bf16_teacher_to_r19_exl3_runtime",
|
| 8 |
+
"max_mean_kld": 0.06,
|
| 9 |
+
"mean_kld_gate_passed": true,
|
| 10 |
+
"prediction_positions": 2047,
|
| 11 |
+
"schema": "glm53-r19-runtime-window-kld.v1",
|
| 12 |
+
"summary": {
|
| 13 |
+
"count": 2047,
|
| 14 |
+
"cvar95": 0.2029298909564702,
|
| 15 |
+
"max": 1.1246660671716389,
|
| 16 |
+
"mean": 0.024675638200136674,
|
| 17 |
+
"p50": 0.010874614560910037,
|
| 18 |
+
"p95": 0.07954193875120669,
|
| 19 |
+
"p99": 0.24636326137225797,
|
| 20 |
+
"std": 0.06287675274531215
|
| 21 |
+
},
|
| 22 |
+
"teacher_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/inputs/kld/teacher/logits/window-0000.safetensors",
|
| 23 |
+
"teacher_sha256": "9f49af1b1b1a6ac88a00f5feaa89c25232597306d73d7c0cd30bb7e9c775cfb6",
|
| 24 |
+
"tokens_sha256": "338027e62f41540f73e38c6f9b4b9a06a50196cbd38cd9c69f11886af9d3cf9f",
|
| 25 |
+
"tokenwise_kld_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/measurements/run-04/tokenwise-kld.npy",
|
| 26 |
+
"tokenwise_kld_sha256": "a5564d2ecfaad9ed8dec0c6bc16417ef64477608721bf04f85e21793d209cc3d",
|
| 27 |
+
"top1_agreement": 0.9379579872984856,
|
| 28 |
+
"vocab_size": 154880,
|
| 29 |
+
"window_id": "final-0000"
|
| 30 |
+
}
|
runtime-results/v34/fp8-five-run-gpu23/run-05/kld-report.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"capture_manifest_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/capture/run-05-capture-manifest.json",
|
| 3 |
+
"capture_manifest_sha256": "9dbaf33f7af6c1ab250bc3aa67072b2a20bdf75204657b4ed1198cf954f4cc09",
|
| 4 |
+
"compute_device": "cuda:2",
|
| 5 |
+
"compute_dtype": "float64",
|
| 6 |
+
"elapsed_seconds": 1.406656460952945,
|
| 7 |
+
"kld_direction": "bf16_teacher_to_r19_exl3_runtime",
|
| 8 |
+
"max_mean_kld": 0.06,
|
| 9 |
+
"mean_kld_gate_passed": true,
|
| 10 |
+
"prediction_positions": 2047,
|
| 11 |
+
"schema": "glm53-r19-runtime-window-kld.v1",
|
| 12 |
+
"summary": {
|
| 13 |
+
"count": 2047,
|
| 14 |
+
"cvar95": 0.20711919074033824,
|
| 15 |
+
"max": 1.1246660671716389,
|
| 16 |
+
"mean": 0.024891557640764127,
|
| 17 |
+
"p50": 0.010840633548772204,
|
| 18 |
+
"p95": 0.08330548731561549,
|
| 19 |
+
"p99": 0.25701062479841114,
|
| 20 |
+
"std": 0.06259468217485271
|
| 21 |
+
},
|
| 22 |
+
"teacher_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/inputs/kld/teacher/logits/window-0000.safetensors",
|
| 23 |
+
"teacher_sha256": "9f49af1b1b1a6ac88a00f5feaa89c25232597306d73d7c0cd30bb7e9c775cfb6",
|
| 24 |
+
"tokens_sha256": "338027e62f41540f73e38c6f9b4b9a06a50196cbd38cd9c69f11886af9d3cf9f",
|
| 25 |
+
"tokenwise_kld_path": "/home/brandonmusic/KLC_SANDBOXES/glm53-exl3-k4-sm120/results/kld/fp8-dcp1-eager-five-run-gpu23-v34/measurements/run-05/tokenwise-kld.npy",
|
| 26 |
+
"tokenwise_kld_sha256": "2ce972e4b56173e55b035309de433aa805e83886533cfd603b5a79553737d101",
|
| 27 |
+
"top1_agreement": 0.9394235466536395,
|
| 28 |
+
"vocab_size": 154880,
|
| 29 |
+
"window_id": "final-0000"
|
| 30 |
+
}
|