Spaces:
Running
Running
[fix] fetch device name bug.
Browse files
main.py
CHANGED
@@ -26,8 +26,7 @@ device_options = [
|
|
26 |
|
27 |
def process_url(url, context_length, device_selection):
|
28 |
try:
|
29 |
-
|
30 |
-
device_name = device_selection.split(" ")[0]
|
31 |
selected_device = devices[device_name]
|
32 |
res = os.popen(
|
33 |
f'./{gguf_parser} --ctx-size={context_length} -url {url} --device-metric "{selected_device.FLOPS};{selected_device.memory_bandwidth}GBps" --json'
|
|
|
26 |
|
27 |
def process_url(url, context_length, device_selection):
|
28 |
try:
|
29 |
+
device_name = device_selection.split(" (")[0]
|
|
|
30 |
selected_device = devices[device_name]
|
31 |
res = os.popen(
|
32 |
f'./{gguf_parser} --ctx-size={context_length} -url {url} --device-metric "{selected_device.FLOPS};{selected_device.memory_bandwidth}GBps" --json'
|