Commit 0f102700 authored by Your Name's avatar Your Name

fix: remove local os import that was causing scope issue

parent 12bedc4f
...@@ -4821,11 +4821,6 @@ def main(): ...@@ -4821,11 +4821,6 @@ def main():
# Set Vulkan device for image models via GGML_VULKAN_DEVICE environment variable # Set Vulkan device for image models via GGML_VULKAN_DEVICE environment variable
if args.image_vulkan_device is not None: if args.image_vulkan_device is not None:
import os
# Map Vulkan device index to GGML_VULKAN_DEVICE value
# Device 0 = first GPU, Device 1 = second GPU, etc.
# GGML_VULKAN_DEVICE=0 uses integrated GPU, GGML_VULKAN_DEVICE=1 uses discrete GPU
# For multiple GPUs, we need to use VK_ICD_FILENAMES or other methods
os.environ['GGML_VULKAN_DEVICE'] = str(args.image_vulkan_device) os.environ['GGML_VULKAN_DEVICE'] = str(args.image_vulkan_device)
print(f"Setting GGML_VULKAN_DEVICE={args.image_vulkan_device} for image model") print(f"Setting GGML_VULKAN_DEVICE={args.image_vulkan_device} for image model")
...@@ -5332,11 +5327,6 @@ def main(): ...@@ -5332,11 +5327,6 @@ def main():
# Set Vulkan device for image models via GGML_VULKAN_DEVICE environment variable # Set Vulkan device for image models via GGML_VULKAN_DEVICE environment variable
if args.image_vulkan_device is not None: if args.image_vulkan_device is not None:
import os
# Map Vulkan device index to GGML_VULKAN_DEVICE value
# Device 0 = first GPU, Device 1 = second GPU, etc.
# GGML_VULKAN_DEVICE=0 uses integrated GPU, GGML_VULKAN_DEVICE=1 uses discrete GPU
# For multiple GPUs, we need to use VK_ICD_FILENAMES or other methods
os.environ['GGML_VULKAN_DEVICE'] = str(args.image_vulkan_device) os.environ['GGML_VULKAN_DEVICE'] = str(args.image_vulkan_device)
print(f"Setting GGML_VULKAN_DEVICE={args.image_vulkan_device} for image model") print(f"Setting GGML_VULKAN_DEVICE={args.image_vulkan_device} for image model")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment