Unverified Commit b1cfb4e9 authored by fzyzcjy's avatar fzyzcjy Committed by GitHub
Browse files

Fix BadRequestError wrong arguments and remove openai dependency (#4882)

parent 19e96e59
...@@ -10,7 +10,6 @@ import numpy as np ...@@ -10,7 +10,6 @@ import numpy as np
import PIL import PIL
import transformers import transformers
from decord import VideoReader, cpu from decord import VideoReader, cpu
from openai import BadRequestError
from PIL import Image from PIL import Image
from sglang.srt.utils import load_audio, load_image, logger from sglang.srt.utils import load_audio, load_image, logger
...@@ -252,9 +251,7 @@ class BaseMultimodalProcessor(ABC): ...@@ -252,9 +251,7 @@ class BaseMultimodalProcessor(ABC):
except Exception as e: except Exception as e:
logger.error(f"An exception occurred while loading images: {e}") logger.error(f"An exception occurred while loading images: {e}")
raise BadRequestError( raise RuntimeError(f"An exception occurred while loading images: {e}")
f"An exception occurred while loading images: {e}"
)
out = BaseMultiModalProcessorOutput( out = BaseMultiModalProcessorOutput(
mm_data_hashes=hashes, mm_data_hashes=hashes,
......
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