show available RAM, fixed SD vae tiling noise

This commit is contained in:
Concedo
2025-06-18 18:44:50 +08:00
parent 7966bdd1ad
commit 40443a98f5
2 changed files with 12 additions and 4 deletions
+11 -4
View File
@@ -1213,10 +1213,6 @@ def fetch_gpu_properties(testCL,testCU,testVK):
MaxMemory[0] = max(lowestclmem,MaxMemory[0])
except Exception:
pass
if MaxMemory[0]>0:
print(f"Detected Free GPU Memory: {int(MaxMemory[0]/1024/1024)} MB (Set GPU layers manually if incorrect)")
else:
print("Unable to determine GPU Memory")
return
def auto_set_backend_cli():
@@ -6672,6 +6668,17 @@ def kcpp_main_process(launch_args, g_memory=None, gui_launcher=False):
args.threads = get_default_threads()
print(f"Auto Set Threads: {args.threads}")
if MaxMemory[0]>0:
print(f"Detected Available GPU Memory: {int(MaxMemory[0]/1024/1024)} MB")
else:
print("Unable to determine GPU Memory")
try:
import psutil
vmem = psutil.virtual_memory()
print(f"Detected Available RAM: {int(vmem.available/1024/1024)} MB")
except Exception:
print("Unable to determine available RAM")
init_library() # Note: if blas does not exist and is enabled, program will crash.
print("==========")
time.sleep(1)