From 0ac173d4fbea4a940463613e865de18b15ed5e14 Mon Sep 17 00:00:00 2001 From: m3ultra Date: Sun, 19 Jul 2026 12:46:16 +1000 Subject: [PATCH] =?UTF-8?q?benchmarks:=20A0=20gate=20=E2=80=94=20MLX=20TRE?= =?UTF-8?q?LLIS.2=20(Jourloy=20hybrid)=20BEATS=20MPS=20216.6s=20vs=20248.8?= =?UTF-8?q?s=20at=2014x=20bake=20density;=20dark=20patches=20reproduce=20-?= =?UTF-8?q?>=20Metal=20texel=20sampling=20prime=20suspect?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Fable 5 --- BENCHMARKS.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/BENCHMARKS.md b/BENCHMARKS.md index 40f2e8a..c330595 100644 --- a/BENCHMARKS.md +++ b/BENCHMARKS.md @@ -202,3 +202,28 @@ Verdict: keep (free, safe) but the paint UNet is GEMM-bound — fusion alone is small. The bigger Hunyuan levers are Target 3 (MoE `.item()` sync-tax, −4800 syncs/gen, unlocks whole-DiT compile) and Target 4 (manual→fused SDPA in paint DINO). E2E flag-on-vs-off measurement pending after those. + +## 2026-07-19 — A0 GATE: first end-to-end MLX TRELLIS.2 (Jourloy PR#175 fork, m3ultra) + +Same anatomy image, seed 42, 1024-cascade, tex 2048: + +| path | wall (incl. load) | bake | peak mem | output | +|---|---|---|---|---| +| torch-MPS (trellis-mac) | 248.8 s | 19 s @191K faces | 20.8 GB | 21 MB GLB | +| **mlx-experimental (Jourloy)** | **216.6 s** | 83 s @**2.74M faces** | 75.4 GB | 131 MB PBR GLB | + +**VERDICT: ADOPT — the MLX path BEAT the MPS baseline on wall-clock while +baking 14× the faces.** Key discovery: `mlx-experimental` is a HYBRID — +resolver log shows `Conv backend: flex_gemm; Attention: flex_gemm_sparse_attn`, +i.e. sparse ops still run pedronaugusto's Metal kernels; MLX runs the dense +stages. The feared naive-MLX-sparse-conv path never executes. Model load is +lazy/instant on the MLX side (vs 103 s torch load). + +Quality: geometry excellent at full density; the DARK-PATCH texture defect +REPRODUCES on this second, independent pipeline — both paths share the +pedronaugusto mtldiffrast/BVH texel sampling. Culprit narrowed to those +shared Metal kernels OR the decoded tex attrs; the pure-Python KDTree bake +control (running) decides. fal renders clean with the same weights, so the +attrs are likely fine → Metal sampling is the prime suspect. + +Caveat: 75 GB peak fits both Ultras but check m1 headroom under load.