SAM 3 text prompts take 1 second instead of 8
A SAM 3 text prompt on a new image took 8 seconds on a PC with an RTX 3080 Ti and almost 10 on an M5 MacBook Pro, and the window froze until the Shapes appeared.
In Labelme v7.11.0, AI runs on your GPU by default. In v7.11.1 on the same two machines, the same prompt takes about a second.
The times
Scroll sideways to read the table.
| Machine | v7.9, CPU | v7.11, GPU |
|---|---|---|
| Linux PC, RTX 3080 Ti | 8.1 s | 1.1 s |
| M5 MacBook Pro | 9.6 s | 1.3 s |
Each time runs from pressing Enter to the outlines appearing on the canvas. v7.11 then asks for the Label before it adds the Shapes. The prompt is "car" on a 2741×2741 photo that SAM 3 has not encoded yet, after one warm-up prompt on another image. The v7.9 column is Labelme 7.9.1, and the v7.11 column is 7.11.1. We have not timed Windows.
The GPU is the default for every AI model, in AI-Segment as well as AI-Find All.
Which GPUs
On Linux and Windows, Labelme uses the GPU through WebGPU, on Vulkan or Direct3D 12, so it needs no CUDA install (#2850). On an Apple Silicon Mac it uses Metal, and Core ML for SAM 3's image encoder. AI stays on the CPU on Intel Macs (#2882), and on Windows when the graphics adapter lacks Direct3D 12 (#2948).
To keep AI on the CPU yourself, change Compute device in Settings. The status bar shows when AI is running, and says when it runs on the CPU (#2861).
The window no longer freezes
AI now runs in a separate process. A slow model no longer freezes the window, and a model that crashes no longer closes Labelme (#2858).
SAM 3 needs a new download
SAM 3 has new model files, so Labelme asks to download it again. The download is 1.8 to 1.9 GB for a GPU, or 3.7 GB for the CPU (#3099). If AI falls back to the CPU after you downloaded the GPU files, it asks for the CPU files too. The model menu shows the size for your device (#3104). The files from earlier versions stay on disk.
The pip package has used the GPU by default since v7.10.0. v7.11.0 is the first Labelme app release with it.