同じモデル、同じQ4_K_Mラベル:5.02、5.07、5.27ビット/重み
Same model, same Q4_K_M label: 5.02, 5.07 and 5.27 bits per weight (github.com)
要約
picchioは、ローカルLLMのパフォーマンスを測定するためのPythonツールです。モデルの量子化ラベルが同じでも、実際のビット/重みやトークン/秒(tok/s)の速度が異なる場合があることを示し、GPUオフロードの失敗やCPUフォールバックといった問題点を明らかにします。このツールは、プリフィル、デコード、ウォールクロックの各速度を分離して計測し、GPUが実際に処理を行っているか、その理由を検証します。
全文翻訳
[画像: pixel woodpecker on a trunk](https://github.com/logxio/picchio/blob/main/assets/picchio-mark-a.svg)
Inference Placement Receipts for local LLMs
[画像: selftest](https://github.com/logxio/picchio/actions/workflows/selftest.yml) [画像: license: MIT](https://github.com/logxio/picchio/blob/main/LICENSE) [画像: python 3.9+, stdlib only](https://camo.githubusercontent.com/bdf1d9e5721298fee42b4594b8fc03145f5d60be2af3e8b0433390af05ddaabb/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f707974686f6e2d332e392532422532432532307374646c69622532306f6e6c792d333737366162)
Run it · Browse results · Add your machine
推論配置レシート(Inference Placement Receipt)は、エンジンのレイヤー配置、システムのGPU測定値、および実行ごとの個別の速度測定値を結合したものです。単一のトークン/秒(tok/s)の数値だけでは分からない、ローカルモデルが実際にどこで実行されたかを示します。例えば、27Bモデルが5.7 tok/sで応答した場合でも、その記録されたレシートは、66レイヤー中28レイヤーがCPUで実行され、メモリ不足が原因であったことを示しています。Watch the demo。
[画像: Recorded Qwen3.8-27B run: 38 of 66 layers on GPU, 28 on CPU, 5.7 tok/s warm decode](https://github.com/logxio/picchio/blob/main/assets/picchio-demo.svg)
別のLinux CUDA 27Bレシートは、RTX 5090上で66レイヤーすべてを実行し、GPU使用率92%、ウォームデコードで81.5 tok/sを記録しています。その3回のキャプチャされたパスとNVMLサンプルは、Apple M5 GPUおよび強制CPU実行の結果と共に公開されています。
著者によるKaggle Linux T4ペアの実行では、同じQwen3.5-9Bファイルと正確なパスごとのプロンプトを使用しました。GPUレシートは33/33レイヤーと40.1 tok/sのウォームデコードを示し、一方強制CPUレシートは0/33レイヤーと2.6 tok/sを示しています。これらのキャプチャされたレシートを、GPUやモデルのダウンロードなしで再計算してください:
python3 scripts/replay_receipts.py
このコマンドは、公開されている各レシートをキャプチャされた入力に対してチェックします。不一致があった場合、影響を受けたファイルまたはレシートの行を示し、ゼロ以外のコードで終了します。
Run it
curl -fsSL https://raw.githubusercontent.com/logxio/picchio/main/public/picchio.pyz -o picchio
chmod +x picchio
./picchio
Windowsでは、PowerShellで以下を実行します:
curl.exe -fsSL https://raw.githubusercontent.com/logxio/picchio/main/public/picchio.pyz -o picchio.pyz
python picchio.pyz
引数なしで実行すると、PicchioはOllamaタグ、ローカルGGUFファイル、およびHugging FaceとLM Studioのキャッシュにあるモデルを検索します。いずれかを選択すると、3回のパスを実行します。
モデルまたは実行中のサーバーを直接指定することもできます:
./picchio model.gguf
./picchio qwen3.5:9b
./picchio http://127.0.0.1:8080
Python 3.9+がインストールされていれば、macOS、Linux、Windowsで動作します。ダウンロードは1ファイルで、標準ライブラリのみを使用します。
Next
- Linux Radeonの実行結果をさらに収集し、実際のエンジン出力と比較してGPUアクティビティとマルチカードの結果を確認します。これはRX 7900 XTXレポートに基づいています。
- WindowsハードウェアでのOllamaの完全なパスを検証します。モデルの検索から実行場所の報告までを行います。
公開されている作業は2026年7月から9月にかけて行われ、v1.0.0は8月にリリースされました。Issue #1では、Radeonユーザーが速度測定値の欠落とコールドランの誤った内訳を報告しました。メンテナーは修正を返信し、新しい評価を求めました。ユーザーはその再実行結果をまだ投稿していないため、そのマシンでの修正された結果は検証されていません。
Use the result
| I want to… |
| --- | --- |
| catch CPU fallback and measure the run | ./picchio MODEL |
| know whether a model fits here before I download it | ./picchio plan https://huggingface.co/.../model-Q4_K_M.gguf · ./picchio plan qwen3.5:9b |
| check that fit at my own context and KV type | ./picchio plan MODEL --ctx 262144 --kv q8_0 |
| guard something already running and get told the moment it leaves the GPU: your own command, a loaded model, a server | ./picchio guard -- COMMAND · ./picchio guard ollama · ./picchio guard http://127.0.0.1:8080 |
| compare two runs and show the first changed setting | ./picchio compare before.txt after.txt |
| turn one run into a complete Ollama or llama.cpp Issue report | ./picchio MODEL --share bug-report |
マシン可読の出力を得るには--jsonを追加してください。問題がより大きなコンテキストでのみ発生する場合は--ctx 262144を追加してください。
フィットチェックは、ファイルヘッダーとレジストリマニフェストから、ダウンロード前に行われ、1つの単語と1つの操作で回答します。ブラウザでは:will it fit?
FITS. The whole model fits in this machine's memory.
5.3 GiB to download
What it gives you
- the exact number of model layers on the GPU
- separate prefill, decode and wall-clock speeds
- GPU activity, memory, power and energy per generated token
- the first setting that changed when you compare two runs
- a clear
HEALTHY,CPU FALLBACKorPARTIAL OFFLOADresult - a paste-ready GitHub Issue with your machine, model, GPU placement and measured rates
Compare machines
I measured these with Picchio:
| machine | model and engine | placement | prefill | decode | wall-clock |
|---|---|---|---|---|---|
| Apple M5 | Qwen3.5-9B, llama.cpp Metal | 33/33 | 588.0 | 21.1 | 15.5 |
| Apple M5 | same file, forced CPU | 0/33 | 26.8 | 12.2 | 3.0 |
| RTX 4090 | same file, llama.cpp CUDA | 33/33 | 6763.3 | 138.0 | 25.2 |
| RTX 5090 | same file, llama.cpp CUDA | 33/33 | 9135.9 | 226.4 | 57.3 |
| RTX 5090 | same file, llama.cpp Vulkan | 33/33 | 6206.3 | 198.4 | 51.0 |
| RTX 5090 | qwen3.5:9b, Ollama | 100% GPU | 8614.7 | 193.5 | 153.9 |
| RTX 4070 SUPER | same file, llama.cpp CUDA | 33/33 | 4187.8 | 78.2 | 28.9 |
| your machine |
Open every result or compare the outputs in examples/。
What Picchio reads
- llama.cpp: per-layer placement, applied sampling settings and timing
- Ollama: CPU/GPU weight split and timing
- macOS: Apple GPU activity, memory, power and energy per token
- NVIDIA on Linux and Windows: GPU activity, memory, power and energy per token through NVML
- AMD on Linux: GPU activity and memory through amdgpu sysfs
PicchioをGGUFパス、Ollamaタグ、または実行中のllama-server URLに向けます。結果はモデルがどこで実行されたか、そして比較に安全な数値はどれかを示します。
One run, two sources of evidence
llama-bench documentationは、backends、n_gpu_layers、および繰り返しテストのavg_ts / stddev_ts出力を示しています。そのn_gpu_layersはテスト設定であり、GPUアクティビティの測定値ではありません。llama-cli documentationには--show-timingsが含まれています。Picchioはエンジンの出力を読み取り、同じ実行中にOSをサンプリングします:
| Input and source | Output in the public Apple M5 / Qwen3.5-9B receipts | What it can establish |
|---|---|---|
| llama.cpp stderr from each pass | offloaded 33/33 with prompt/eval timings in the GPU run; offloaded 0/33 in the forced CPU run | Actual layer placement and engine timing as reported by llama.cpp; not independent proof that the GPU was busy. |
| Picchio's time-aligned macOS GPU samples from those same passes | GPU run: 99% work, +6.0 GiB, 11.0 W, 0.52 J/token; forced CPU run: 5% work, +0.3 GiB, 0.1 W, 0.01 J/token | OS-side activity, memory and energy alongside the engine report; these are whole-GPU readings, not per-process attribution or total-system energy. |
| Picchio's combined result | HEALTHY versus SILENT CPU FALLBACK, with --device none -ngl 0 identified in the CPU run | A diagnosis for each recorded run. The different placement and rates come from the GPU settings, not from Picchio accelerating inference. |
2つのM5レシートは、1つのApple M5、同じモデルパス、エンジンビルド、コンテキスト、サンプリング設定を報告しています。強制CPU実行は--device none -ngl 0を変更します。生のファイルには独立したマシンまたはモデルバイトのフィンガープリントは含まれておらず、OSサンプルはGPU全体を測定します。この比較にはllama-benchのスループット数は含まれていません。Linux 27Bレシートは、3回の記録されたCUDAパスとNVMLサンプルから再生されます。OSサンプルはGPU全体を測定し、生のファイルには独立したマシンまたはモデルバイトのフィンガープリントはありません。4070 SUPER 27Bレシートは、それ自体の算術(66 − 38 = 28 CPUレイヤー)でチェックできます。その生のレイヤーとタイミングログは公開されていないため、再生コマンドはそれらの測定値を独立して再現しません。2つの27Bマシン間の速度は、制御された比較ではなく、Picchioが推論を高速化することの証拠でもありません。
Send me your machine
./picchio MODEL --share row > result.md 2> picchio.txt
Add your result。Picchioがあなたの実行を誤りと判断した場合、まずそれを送ってください。