env: Compute engine
Model: Qwen/Qwen2.5-VL-3B-Instruct
GPU: T4 16GB
command to initialize:
docker run --runtime nvidia --gpus all -v ~/.cache/huggingface:/root/.cache/huggingface -e HUGGING_FACE_HUB_TOKEN=... -p 8000:8000 -e VLLM_USE_V1=0 --ipc=host vllm/vllm-openai:latest --model Qwen/Qwen2.5-VL-3B-Instruct --trust-remote-code --dtype auto --gpu-memory-utilization 0.9 --max-model-len 8192
Why is it that when I just send a text message the response is ok but when I send an image I get this error?
if i sen this one, the return is ok:
{
"model": "Qwen/Qwen2.5-VL-3B-Instruct",
"messages": [
{
"role": "user",
"content": [
{
"type": "text", "text": "What is the text in the illustrate?"
}
]
}
]
}
but if i sent image like that, the errors occurs:
{
"model": "Qwen/Qwen2.5-VL-3B-Instruct",
"messages": [
{
"role": "user",
"content": [
{
"type": "image_url",
"image_url": {
"url": "https://modelscope.oss-cn-beijing.aliyuncs.com/resource/qwen.png"
}
},
{
"type": "text", "text": "What is the text in the illustrate?"
}
]
}
]
}
The error:
(APIServer pid=1) ERROR: Exception in ASGI application(APIServer pid=1) Traceback (most recent call last):(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/uvicorn/protocols/http/httptools_impl.py”, line 409, in run_asgi(APIServer pid=1) result = await app( # type: ignore[func-returns-value](APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/uvicorn/middleware/proxy_headers.py”, line 60, in call(APIServer pid=1) return await self.app(scope, receive, send)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/fastapi/applications.py”, line 1054, in call(APIServer pid=1) await super().call(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/applications.py”, line 113, in call(APIServer pid=1) await self.middleware_stack(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/errors.py”, line 186, in call(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/errors.py”, line 164, in call(APIServer pid=1) await self.app(scope, receive, _send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/cors.py”, line 85, in call(APIServer pid=1) await self.app(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/prometheus_fastapi_instrumentator/middleware.py”, line 177, in call(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/prometheus_fastapi_instrumentator/middleware.py”, line 175, in call(APIServer pid=1) await self.app(scope, receive, send_wrapper)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/exceptions.py”, line 63, in call(APIServer pid=1) await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 53, in wrapped_app(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 42, in wrapped_app(APIServer pid=1) await app(scope, receive, sender)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 716, in call(APIServer pid=1) await self.middleware_stack(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 736, in app(APIServer pid=1) await route.handle(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 290, in handle(APIServer pid=1) await self.app(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 78, in app(APIServer pid=1) await wrap_app_handling_exceptions(app, request)(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 53, in wrapped_app(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 42, in wrapped_app(APIServer pid=1) await app(scope, receive, sender)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 75, in app(APIServer pid=1) response = await f(request)(APIServer pid=1) ^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/fastapi/routing.py”, line 302, in app(APIServer pid=1) raw_response = await run_endpoint_function((APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/fastapi/routing.py”, line 213, in run_endpoint_function(APIServer pid=1) return await dependant.call(**values)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/utils.py”, line 91, in wrapper(APIServer pid=1) return handler_task.result()(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/utils.py”, line 114, in wrapper(APIServer pid=1) return await func(*args, **kwargs)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/openai/api_server.py”, line 671, in create_chat_completion(APIServer pid=1) generator = await handler.create_chat_completion(request, raw_request)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/openai/serving_chat.py”, line 324, in create_chat_completion(APIServer pid=1) return await self.chat_completion_full_generator((APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/openai/serving_chat.py”, line 1072, in chat_completion_full_generator(APIServer pid=1) async for res in result_generator:(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/engine/multiprocessing/client.py”, line 583, in _process_request(APIServer pid=1) raise request_output(APIServer pid=1) IndexError: list index out of rangeINFO 09-17 15:13:06 [metrics.py:386] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 0.0 tokens/s, Running: 0 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.0%, CPU KV cache usage: 0.0%.(APIServer pid=1) WARNING 09-17 15:15:02 [sampling_params.py:311] temperature 1e-06 is less than 0.01, which may cause numerical errors nan or inf in tensors. We have maxed it out to 0.01.(APIServer pid=1) INFO: 177.37.143.134:10075 - “POST /v1/chat/completions HTTP/1.1” 500 Internal Server ErrorINFO 09-17 15:15:02 [metrics.py:386] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 11.7 tokens/s, Running: 0 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.0%, CPU KV cache usage: 0.0%.(APIServer pid=1) ERROR: Exception in ASGI application(APIServer pid=1) Traceback (most recent call last):(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/uvicorn/protocols/http/httptools_impl.py”, line 409, in run_asgi(APIServer pid=1) result = await app( # type: ignore[func-returns-value](APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/uvicorn/middleware/proxy_headers.py”, line 60, in call(APIServer pid=1) return await self.app(scope, receive, send)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/fastapi/applications.py”, line 1054, in call(APIServer pid=1) await super().call(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/applications.py”, line 113, in call(APIServer pid=1) await self.middleware_stack(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/errors.py”, line 186, in call(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/errors.py”, line 164, in call(APIServer pid=1) await self.app(scope, receive, _send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/cors.py”, line 85, in call(APIServer pid=1) await self.app(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/prometheus_fastapi_instrumentator/middleware.py”, line 177, in call(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/prometheus_fastapi_instrumentator/middleware.py”, line 175, in call(APIServer pid=1) await self.app(scope, receive, send_wrapper)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/middleware/exceptions.py”, line 63, in call(APIServer pid=1) await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 53, in wrapped_app(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 42, in wrapped_app(APIServer pid=1) await app(scope, receive, sender)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 716, in call(APIServer pid=1) await self.middleware_stack(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 736, in app(APIServer pid=1) await route.handle(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 290, in handle(APIServer pid=1) await self.app(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 78, in app(APIServer pid=1) await wrap_app_handling_exceptions(app, request)(scope, receive, send)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 53, in wrapped_app(APIServer pid=1) raise exc(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/_exception_handler.py”, line 42, in wrapped_app(APIServer pid=1) await app(scope, receive, sender)(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/starlette/routing.py”, line 75, in app(APIServer pid=1) response = await f(request)(APIServer pid=1) ^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/fastapi/routing.py”, line 302, in app(APIServer pid=1) raw_response = await run_endpoint_function((APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/fastapi/routing.py”, line 213, in run_endpoint_function(APIServer pid=1) return await dependant.call(**values)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/utils.py”, line 91, in wrapper(APIServer pid=1) return handler_task.result()(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/utils.py”, line 114, in wrapper(APIServer pid=1) return await func(*args, **kwargs)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/openai/api_server.py”, line 671, in create_chat_completion(APIServer pid=1) generator = await handler.create_chat_completion(request, raw_request)(APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/openai/serving_chat.py”, line 324, in create_chat_completion(APIServer pid=1) return await self.chat_completion_full_generator((APIServer pid=1) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/entrypoints/openai/serving_chat.py”, line 1072, in chat_completion_full_generator(APIServer pid=1) async for res in result_generator:(APIServer pid=1) File “/usr/local/lib/python3.12/dist-packages/vllm/engine/multiprocessing/client.py”, line 583, in _process_request(APIServer pid=1) raise request_output(APIServer pid=1) IndexError: list index out of range