A Hugging Face copy of an image decoder I use matched the original's size to the byte, with the same names and shapes for all 128 parts. Then I compared the numbers inside, and 87% of them differ. A loader that trusts names and size takes it without a word.
You download a model and check it like a parcel: right size, right label. Both can pass while the contents differ from what you ordered. The only check that catches it is opening the box and comparing what is inside, one value at a time.
The average gap can come out near zero while the model still picks a different word for 1.26% of them. An average is the wrong summary for something you notice one word at a time. New paper on what quantization costs.
How do you tell whether a shrunk model still thinks the way the original did? Feed both the same text and compare what each one expects to come next, position by position. The gap between those two opinions is the measurement.
A watchdog that fails to read a process gets back 0, and 0 reads as a process using no memory. The limit then switches itself off for the one job running away with your machine. New paper on measuring a Mac process tree.
A watchdog can only stop what it can measure, and on a Mac the obvious memory number is not the one that matters. A program plus its children hide their cost in places the simple reading walks straight past.
Nine image models on my Mac share three decoders between them. Each one still hands its preview a differently shaped bundle of numbers: same weights underneath, six layouts on top. New paper on why sharing a decoder buys you less than it looks like.
Your Mac does not paint an image directly. It works out a compressed sketch, then a second smaller model expands that sketch into pixels. Different image generators borrow the same expander, which sounds like one problem solved once.
A 20B image model takes 20 minutes to make one picture on my Mac. My library skips the steps that add nothing you can see, so 25 of its 48 never run and it finishes in under 12. I cannot tell the two pictures apart.
The bigger the model, the longer you wait, and the more of that wait goes into work that changes nothing you can see. Skipping it pays more on a slow model than on a fast one, which is the opposite of where people go looking for speed.
New paper. A day before my first release, a test compared new output against a saved reference and failed on 5 of 5 prompts. The math was fine. The saved file had captured the script, not the result. What a good test asserts instead. Link below.
A test that checks today's output against a saved copy of yesterday's is only as good as what got saved. If the saved thing quietly includes how it was made, then renaming a file breaks the test, and the test reports that your math is wrong.
So I moved the limit outside. mlx-guard runs your MLX job as a child, watches what the whole process tree costs the operating system, and ends it against a number you set before it takes the machine down with it. Sixth library, Apache licensed.