mirror of
https://github.com/easydiffusion/easydiffusion.git
synced 2025-06-05 09:27:17 +02:00
Potential fix for #1869
This commit is contained in:
parent
fe2443ec0c
commit
d5277cd38c
@ -404,8 +404,15 @@ def has_discrete_graphics_card():
|
|||||||
|
|
||||||
if system == "Windows":
|
if system == "Windows":
|
||||||
try:
|
try:
|
||||||
|
env = dict(os.environ)
|
||||||
|
env["PATH"] += (
|
||||||
|
os.pathsep
|
||||||
|
+ "C:/Windows/System32".replace("/", os.path.sep)
|
||||||
|
+ os.pathsep
|
||||||
|
+ "C:/Windows/System32/wbem".replace("/", os.path.sep)
|
||||||
|
)
|
||||||
output = subprocess.check_output(
|
output = subprocess.check_output(
|
||||||
["wmic", "path", "win32_videocontroller", "get", "name"], stderr=subprocess.STDOUT
|
["wmic", "path", "win32_videocontroller", "get", "name"], stderr=subprocess.STDOUT, env=env
|
||||||
)
|
)
|
||||||
# Filter for discrete graphics cards (NVIDIA, AMD, etc.)
|
# Filter for discrete graphics cards (NVIDIA, AMD, etc.)
|
||||||
discrete_gpus = ["NVIDIA", "AMD", "ATI"]
|
discrete_gpus = ["NVIDIA", "AMD", "ATI"]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user