"ssh:/git@developer.sourcefind.cn:2222/OpenDAS/vllm_cscc.git" did not exist on "e15a5ff07b89646090458ce6ae7908bcbae82b90"
Unverified Commit 69ecaa7c authored by Alex Brooks's avatar Alex Brooks Committed by GitHub
Browse files

[Misc] Add warning for multimodal data in LLM.beam_search (#16241)


Signed-off-by: default avatarAlex-Brooks <Alex.Brooks@ibm.com>
parent 7f00899f
...@@ -536,6 +536,16 @@ class LLM: ...@@ -536,6 +536,16 @@ class LLM:
tokenizer.eos_token_id, tokenizer.eos_token_id,
length_penalty) length_penalty)
# TODO - fix handling of multimodal data for beam search; we pass it
# through in the async version on the abstract EngineClient, but not
# here.
if any("multi_modal_data" in prompt
and prompt["multi_modal_data"] is not None
for prompt in prompts):
logger.warning(
"Multimodal data appears to have been provided, but is not"
" currently being passed through in LLM.beam_search()!")
tokenizer = self.get_tokenizer() tokenizer = self.get_tokenizer()
# generate 2 * beam_width candidates at each step # generate 2 * beam_width candidates at each step
# following the huggingface transformers implementation # following the huggingface transformers implementation
......
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