const fn resolve_budget(mem: &SystemMemoryInfo) -> (u64, BudgetSource)Expand description
Resolve the memory figure to size against, and say where it came from.
VRAM wins when it is known, because that is the memory the weights will
actually occupy. It is None on a CPU-only host, and on any device whose
memory gglib could not read — which falls back to host RAM. That fallback
is usually too generous, which is exactly why BudgetSource is
returned alongside the number instead of being thrown away: the caller is
expected to say so. A unified-memory device is labelled, not guessed.