mirror of
https://github.com/vladmandic/automatic
synced 2026-09-17 08:19:11 +02:00
10 lines
291 B
Python
10 lines
291 B
Python
import torch
|
|
|
|
def directml_init():
|
|
from modules.dml.backend import DirectML # pylint: disable=ungrouped-imports
|
|
from modules.dml.opts import override_opts # pylint: disable=ungrouped-imports
|
|
# Alternative of torch.cuda for DirectML.
|
|
torch.dml = DirectML
|
|
|
|
override_opts()
|