How to run it on non-default GPU or multiple GPUs?
coolbunnyx opened this issue · 0 comments
The code can only run on the default GPU:0. Exceptions occur when device is switched to the non-default one.
os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID"
os.environ["CUDA_VISIBLE_DEVICES"] = "2"
Exception has occurred: AttributeError
'str' object has no attribute 'traceback'
The above exception was the direct cause of the following exception:
File "RPG-DiffusionMaster-main/modules/errors.py", line 98, in run code()
File "RPG-DiffusionMaster-main/modules/devices.py", line 76, in enable_tf32
device_id = (int(shared.cmd_opts.device_id) if shared.cmd_opts.device_id is not None and shared.cmd_opts.device_id.isdigit() else 0) or torch.cuda.current_device()
During handling of the above exception, another exception occurred:
File "RPG-DiffusionMaster-main/modules/errors.py", line 68, in display
te = traceback.TracebackException.from_exception(e)
File "RPG-DiffusionMaster-main/modules/errors.py", line 100, in run
display(task, e)
File "RPG-DiffusionMaster-main/modules/devices.py", line 84, in
errors.run(enable_tf32, "Enabling TF32")
File "RPG-DiffusionMaster-main/modules/interrogate.py", line 13, in
from modules import devices, paths, shared, lowvram, modelloader, errors
File "RPG-DiffusionMaster-main/modules/shared_options.py", line 7, in
from modules import interrogate
File "RPG-DiffusionMaster-main/RPG.py", line 22, in initialize
from modules import options, shared_options
File "RPG-DiffusionMaster-main/RPG.py", line 256, in
initialize(model_name='albedobaseXL_v20.safetensors')