Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion bin/lib/nim.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@ function detectGpu() {
const perGpuMB = lines.map((l) => parseInt(l.trim(), 10)).filter((n) => !isNaN(n));
if (perGpuMB.length > 0) {
const totalMemoryMB = perGpuMB.reduce((a, b) => a + b, 0);
// Only mark nimCapable if at least one NIM model fits in GPU VRAM
const canRunNim = nimImages.models.some((m) => m.minGpuMemoryMB <= totalMemoryMB);
return {
type: "nvidia",
count: perGpuMB.length,
totalMemoryMB,
perGpuMB: perGpuMB[0],
nimCapable: true,
nimCapable: canRunNim,
};
}
}
Expand Down
3 changes: 3 additions & 0 deletions bin/lib/onboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,9 @@ async function preflight() {
const gpu = nim.detectGpu();
if (gpu && gpu.type === "nvidia") {
console.log(` ✓ NVIDIA GPU detected: ${gpu.count} GPU(s), ${gpu.totalMemoryMB} MB VRAM`);
if (!gpu.nimCapable) {
console.log(" ⓘ GPU VRAM too small for local NIM — will use cloud inference");
}
} else if (gpu && gpu.type === "apple") {
console.log(` ✓ Apple GPU detected: ${gpu.name}${gpu.cores ? ` (${gpu.cores} cores)` : ""}, ${gpu.totalMemoryMB} MB unified memory`);
console.log(" ⓘ NIM requires NVIDIA GPU — will use cloud inference");
Expand Down