first commit
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
import { Agent } from './qvac-master.js';
|
||||
|
||||
try {
|
||||
const resources = await Agent.engine.resources();
|
||||
const hasGpu = Array.isArray(resources.gpus) && resources.gpus.length > 0;
|
||||
console.log(JSON.stringify({
|
||||
policy: 'gpu-required',
|
||||
hasGpu,
|
||||
backendHints: resources.drivers || {},
|
||||
gpus: resources.gpus || [],
|
||||
vramBytes: resources.vramBytes || 0,
|
||||
}, null, 2));
|
||||
if (!hasGpu) {
|
||||
console.error('gpu-doctor: QVAC did not observe a usable GPU; Jarvis will refuse CPU inference');
|
||||
process.exitCode = 1;
|
||||
}
|
||||
} catch (error) {
|
||||
console.error(`gpu-doctor: ${error.message}`);
|
||||
process.exitCode = 1;
|
||||
}
|
||||
Reference in New Issue
Block a user