[Misc] Update default image format of encode_base64 (#33656)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
This commit is contained in:
Cyrus Leung
2026-02-03 03:13:16 -08:00
committed by GitHub
parent e346e2d056
commit 52683ccbe1
2 changed files with 4 additions and 18 deletions
+1 -4
View File
@@ -11,7 +11,6 @@ import numpy as np
import numpy.typing as npt
from PIL import Image
from vllm.logger import init_logger
from vllm.utils.import_utils import LazyLoader
from .inputs import (
@@ -27,8 +26,6 @@ if TYPE_CHECKING:
else:
torch = LazyLoader("torch", globals(), "torch")
logger = init_logger(__name__)
def __getattr__(name: str):
if name == "MEDIA_CONNECTOR_REGISTRY":
@@ -74,7 +71,7 @@ def encode_image_base64(
image: Image.Image,
*,
image_mode: str = "RGB",
format: str | None = None,
format: str = "PNG",
) -> str:
"""
Encode a pillow image to base64 format.