diff --git a/cortex-js/src/domain/models/resource.interface.ts b/cortex-js/src/domain/models/resource.interface.ts index 16dafb9dc..a048c38fd 100644 --- a/cortex-js/src/domain/models/resource.interface.ts +++ b/cortex-js/src/domain/models/resource.interface.ts @@ -17,5 +17,5 @@ export interface UsedMemInfo { export interface GpuInfo { name: string | undefined; - vram: number | null; + vram: UsedMemInfo; } diff --git a/cortex-js/src/infrastructure/services/resources-manager/resources-manager.service.ts b/cortex-js/src/infrastructure/services/resources-manager/resources-manager.service.ts index 565c788dc..190d79779 100644 --- a/cortex-js/src/infrastructure/services/resources-manager/resources-manager.service.ts +++ b/cortex-js/src/infrastructure/services/resources-manager/resources-manager.service.ts @@ -25,7 +25,10 @@ export class ResourcesManagerService { }, gpus: (await si.graphics()).controllers.map((gpu) => ({ name: gpu.name, - vram: gpu.vram, + vram: { + total: gpu.vram ?? 0, + used: gpu.memoryUsed ?? 0, + } })), }; }