local.ai icon indicating copy to clipboard operation
local.ai copied to clipboard

Can't enable GPU

Open jtrofficial opened this issue 1 year ago • 8 comments

The button to turn on the GPU is greyed out so it is using my crappy cpu instead of my rtx4050 is there a way to get around this? Screenshot 2023-12-28 175239

jtrofficial avatar Dec 28 '23 23:12 jtrofficial

same here

i run a dual GPU setup (AMD+NVIDIA) the main GPU is the AMD card while the NVIDIA card is reserved for VMs, a vfio-pci driver is loaded at boot for the latter card.

some programs incorrectly pick NVIDIA over AMD, even if the main GPU is AMD. then proceed to fail because the nvidia card has no nvidia driver. leading to a crash or a loss of features.

i'm afraid that this program also suffers from this issue. Please correct me if i'm wrong

Kyr4l avatar Apr 16 '24 12:04 Kyr4l

Can confirm. Have dual GPU - iGPU and V100. Button is grayed out. I recompiled the app locally (first I thought it is an AppImage issue) but no luck.

Any Idea where in the code it might be?

We can

#[cfg(target_os = "linux")]
fn check_gpu() -> bool {
    // Execute a command like `lspci | grep -i nvidia` and check if the output is non-empty
    let output = execute_command("lshw -C display | grep 'configuration: driver=nvidia'");
    !output.is_empty()
}

but what else?

hellkaim avatar Apr 20 '24 17:04 hellkaim

this also happens on my Optimus laptop (iGPU + GTX 1650) even tho i have the nvidia driver installed

Kyr4l avatar Apr 20 '24 20:04 Kyr4l

this also happens on my Optimus laptop (iGPU + GTX 1650) even tho i have the nvidia driver installed

The issue is that the app will only allow this on MacSilicon (from it's code)....

hellkaim avatar Apr 20 '24 21:04 hellkaim

this also happens on my Optimus laptop (iGPU + GTX 1650) even tho i have the nvidia driver installed

The issue is that the app will only allow this on MacSilicon (from it's code)....

im not sure to understand, could you explain a bit more in detail ?

Kyr4l avatar Apr 20 '24 22:04 Kyr4l

this also happens on my Optimus laptop (iGPU + GTX 1650) even tho i have the nvidia driver installed

The issue is that the app will only allow this on MacSilicon (from it's code)....

im not sure to understand, could you explain a bit more in detail ?

Sure Check here

hellkaim avatar Apr 20 '24 22:04 hellkaim

Also you may do this search

hellkaim avatar Apr 20 '24 22:04 hellkaim

this also happens on my Optimus laptop (iGPU + GTX 1650) even tho i have the nvidia driver installed

The issue is that the app will only allow this on MacSilicon (from it's code)....

im not sure to understand, could you explain a bit more in detail ?

Sure Check here

thanks

Kyr4l avatar Apr 20 '24 22:04 Kyr4l