Novelty against the training set is exact, and costs about 85 dollars
Compare each of the billion pile images with a reference set of, say, 10 million training images. By brute force that's dot products at 768 dimensions:
At 100 TFLOPS that's seconds, about 43 GPU-hours, roughly $85. It's exact, with no index to tune and no recall lost. It's tempting to assume billion-scale search needs approximation. This one doesn't.
Density within the pile: probe an index, or count in a 1% sample
Every image against every other image is dot products, about 4,300 GPU-hours by brute force.
An inverted file cuts that. With lists, each list holds about 954 vectors. Probing 64 lists scans about 61,000 vectors per query instead of a billion, about 16,000 times fewer. The Faiss paper reports results at this scale: a high-accuracy k-NN graph on 95 million images in 35 minutes, and a graph over 1 billion vectors in less than 12 hours on 4 Maxwell Titan X GPUs.
There's a cheaper move. A density floor doesn't need exact neighbors among a billion images. Count neighbors within a radius among a uniform 1% sample, 10 million images, and multiply by 100. That costs the same 43 GPU-hours as the novelty search, and the two can share one pass.
Semantic dedup and clustering, from earlier, take minutes to under an hour each.
In the editor, write brute_force_hours(queries, refs) and ivf_scanned(n, lists, probes). The last line prices the billion against 10 million novelty search, and the inverted file that probes 64 of its 1,048,576 lists.