Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
Signed-off-by: DarkLight1337 <[email protected]>
  • Loading branch information
DarkLight1337 committed Nov 8, 2024
1 parent 17da63b commit 6034d20
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions vllm/model_executor/models/idefics3.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
from vllm.model_executor.layers.sampler import Sampler, SamplerOutput
from vllm.model_executor.layers.vocab_parallel_embedding import ParallelLMHead
from vllm.model_executor.sampling_metadata import SamplingMetadata
from vllm.multimodal import MULTIMODAL_REGISTRY, MultiModalInputs
from vllm.multimodal import MULTIMODAL_REGISTRY, MultiModalKwargs
from vllm.multimodal.image import cached_get_image_processor
from vllm.sequence import IntermediateTensors, SequenceData
from vllm.transformers_utils.processor import cached_get_processor
Expand Down Expand Up @@ -101,7 +101,7 @@ def input_mapper_for_idefics3(
logger.error("Failed to process image (%s)", data)
raise

return MultiModalInputs(batch_data)
return MultiModalKwargs(batch_data)


def _resize_output_size(height: int,
Expand Down
8 changes: 4 additions & 4 deletions vllm/worker/hpu_model_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
from vllm.model_executor.layers.sampler import SamplerOutput
from vllm.model_executor.model_loader import get_model
from vllm.multimodal import (MULTIMODAL_REGISTRY, BatchedTensorInputs,
MultiModalInputs)
MultiModalKwargs)
from vllm.sampling_params import SamplingParams
from vllm.sequence import (IntermediateTensors, SequenceData,
SequenceGroupMetadata)
Expand Down Expand Up @@ -716,7 +716,7 @@ def _prepare_prompt(
context_lens: List[int] = []
query_lens: List[int] = []
prefix_block_tables: List[List[int]] = []
multi_modal_inputs_list: List[MultiModalInputs] = []
multi_model_kwargs_list: List[MultiModalKwargs] = []

if len(seq_group_metadata_list) == 0:
return PreparePromptMetadata.empty()
Expand Down Expand Up @@ -777,7 +777,7 @@ def _prepare_prompt(
mm_data = seq_group_metadata.multi_modal_data
if mm_data:
mm_kwargs = self.multi_modal_input_mapper(mm_data)
multi_modal_inputs_list.append(mm_kwargs)
multi_model_kwargs_list.append(mm_kwargs)

if seq_group_metadata.block_tables is None:
# During memory profiling, the block tables are not initialized
Expand Down Expand Up @@ -876,7 +876,7 @@ def _prepare_prompt(
multi_modal_placeholder_index_maps=
None # FIXME(kzawora): mutli-modality will not work here
)
multi_modal_kwargs = MultiModalInputs.batch(multi_modal_inputs_list)
multi_modal_kwargs = MultiModalKwargs.batch(multi_model_kwargs_list)

return PreparePromptMetadata(input_tokens=input_tokens,
input_positions=input_positions,
Expand Down

0 comments on commit 6034d20

Please sign in to comment.