try to set cuda pcie order first thing

This commit is contained in:
Concedo 2025-06-18 20:25:38 +08:00
parent a8d33ebb0d
commit e0a7694328

View file

@ -8,10 +8,14 @@
# editing tools, save formats, memory, world info, author's note, characters, # editing tools, save formats, memory, world info, author's note, characters,
# scenarios and everything Kobold and KoboldAI Lite have to offer. # scenarios and everything Kobold and KoboldAI Lite have to offer.
import os
try:
os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID" # try set GPU to PCI order first thing
except Exception:
pass
import copy import copy
import ctypes import ctypes
import multiprocessing import multiprocessing
import os
import math import math
import re import re
import argparse import argparse