mirror of
https://github.com/vladmandic/automatic
synced 2026-09-19 09:14:35 +02:00
Treat Zluda as a different backend and auto disable BF16 for Zluda and ROCm on RDNA1-2
This commit is contained in:
+4
-4
@@ -19,7 +19,6 @@ from modules import errors, devices, shared_items, shared_state, cmd_args, theme
|
||||
from modules.paths import models_path, script_path, data_path, sd_configs_path, sd_default_config, sd_model_file, default_sd_model_file, extensions_dir, extensions_builtin_dir # pylint: disable=W0611
|
||||
from modules.dml import memory_providers, default_memory_provider, directml_do_hijack
|
||||
from modules.onnx_impl import initialize_onnx, execution_providers
|
||||
from modules.zluda import initialize_zluda
|
||||
from modules.memstats import memory_stats
|
||||
import modules.interrogate
|
||||
import modules.memmon
|
||||
@@ -413,8 +412,8 @@ def get_default_modes():
|
||||
|
||||
if devices.backend == "rocm":
|
||||
default_sdp_options = ['Memory attention', 'Math attention']
|
||||
#elif devices.backend == "zluda":
|
||||
# sdp_options_default = ['Math attention']
|
||||
elif devices.backend == "zluda":
|
||||
default_sdp_options = ['Math attention']
|
||||
else:
|
||||
default_sdp_options = ['Flash attention', 'Memory attention', 'Math attention']
|
||||
if (cmd_opts.lowvram or cmd_opts.medvram) and ('Flash attention' not in default_sdp_options):
|
||||
@@ -1124,7 +1123,8 @@ mem_mon = modules.memmon.MemUsageMonitor("MemMon", devices.device)
|
||||
history = history.History()
|
||||
if devices.backend == "directml":
|
||||
directml_do_hijack()
|
||||
elif devices.backend == "cuda":
|
||||
elif devices.backend == "zluda":
|
||||
from modules.zluda import initialize_zluda
|
||||
initialize_zluda()
|
||||
initialize_onnx()
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user