vllm.v1.worker.utils
gather_mm_placeholders
¶
Reconstructs the embeddings from the placeholder tokens.
This is the operation of [scatter_mm_placeholders][].
Source code in vllm/v1/worker/utils.py
sanity_check_mm_encoder_outputs
¶
Perform sanity checks for the result of
vllm.model_executor.models.SupportsMultiModal.get_multimodal_embeddings.
Source code in vllm/v1/worker/utils.py
scatter_mm_placeholders
¶
Scatter the multimodal embeddings into a contiguous tensor that represents the placeholder tokens.
vllm.multimodal.processing.PromptUpdateDetails.is_embed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
embeds
|
Tensor
|
The multimodal embeddings.
Shape: |
required |
is_embed
|
Optional[Tensor]
|
A boolean mask indicating which positions in the placeholder
tokens need to be filled with multimodal embeddings.
Shape: |
required |