Skip to content

Commit 53360e2

Browse files
committed
linting
1 parent cb9bd2f commit 53360e2

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

koboldcpp.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1200,7 +1200,7 @@ def fetch_gpu_properties(testCL,testCU,testVK):
12001200
device_name = None
12011201
current_agent_is_gpu = False
12021202
in_pool_section = False
1203-
1203+
12041204
for line in output.splitlines(): # read through the output line by line
12051205
line = line.strip()
12061206
if line.startswith("Agent ") and "Agent" in line:
@@ -1210,7 +1210,7 @@ def fetch_gpu_properties(testCL,testCU,testVK):
12101210
in_pool_section = False
12111211
elif line.startswith("Marketing Name:"):
12121212
device_name = line.split(":", 1)[1].strip() # if we find a named device, temporarily save the name
1213-
elif line.startswith("Device Type:") and "GPU" in line and device_name is not None:
1213+
elif line.startswith("Device Type:") and "GPU" in line and device_name is not None:
12141214
# if the following Device Type is a GPU (not a CPU) then add it to devices list
12151215
FetchedCUdevices.append(device_name)
12161216
current_agent_is_gpu = True
@@ -1231,7 +1231,7 @@ def fetch_gpu_properties(testCL,testCU,testVK):
12311231
vram_mb = vram_kb // 1024
12321232
FetchedCUdeviceMem.append(str(vram_mb))
12331233
in_pool_section = False
1234-
1234+
12351235
if FetchedCUdevices and FetchedCUdeviceMem:
12361236
print(f"Detected AMD GPU VRAM from rocminfo: {list(zip(FetchedCUdevices, FetchedCUdeviceMem))} MB")
12371237
except Exception:
@@ -1262,7 +1262,7 @@ def fetch_gpu_properties(testCL,testCU,testVK):
12621262
if testVK:
12631263
try: # Get Vulkan names
12641264
foundVkGPU = False
1265-
lowestvkmem = 0
1265+
lowestvkmem = 0
12661266
output = subprocess.run(['vulkaninfo','--summary'], capture_output=True, text=True, check=True, encoding='utf-8', timeout=10).stdout
12671267
devicelist = [line.split("=")[1].strip() for line in output.splitlines() if "deviceName" in line]
12681268
devicetypes = [line.split("=")[1].strip() for line in output.splitlines() if "deviceType" in line]
@@ -1331,11 +1331,11 @@ def fetch_gpu_properties(testCL,testCU,testVK):
13311331
MaxMemory[0] = max(lowestclmem,MaxMemory[0])
13321332
except Exception:
13331333
pass
1334-
1334+
13351335
# Check VRAM detection after all backends have been tested
13361336
if MaxMemory[0] < (1024*1024*256):
13371337
print("Unable to detect VRAM, please set layers manually.")
1338-
1338+
13391339
return
13401340

13411341
def auto_set_backend_cli():

0 commit comments

Comments
 (0)