vllm.transformers_utils.processor
cached_get_feature_extractor
module-attribute
¶
cached_get_feature_extractor = lru_cache(
get_feature_extractor
)
cached_get_image_processor
module-attribute
¶
cached_get_image_processor = lru_cache(get_image_processor)
HashableDict
¶
Bases: dict
A dictionary that can be hashed by lru_cache.
Source code in vllm/transformers_utils/processor.py
HashableList
¶
Bases: list
A list that can be hashed by lru_cache.
Source code in vllm/transformers_utils/processor.py
_merge_mm_kwargs
¶
_merge_mm_kwargs(model_config: ModelConfig, **kwargs)
Source code in vllm/transformers_utils/processor.py
cached_feature_extractor_from_config
¶
cached_feature_extractor_from_config(
model_config: ModelConfig, **kwargs: Any
)
Source code in vllm/transformers_utils/processor.py
cached_image_processor_from_config
¶
cached_image_processor_from_config(
model_config: ModelConfig, **kwargs: Any
)
Source code in vllm/transformers_utils/processor.py
cached_processor_from_config
¶
cached_processor_from_config(
model_config: ModelConfig,
processor_cls: Union[
type[_P], tuple[type[_P], ...]
] = ProcessorMixin,
**kwargs: Any,
) -> _P
Source code in vllm/transformers_utils/processor.py
get_feature_extractor
¶
get_feature_extractor(
processor_name: str,
*args: Any,
revision: Optional[str] = None,
trust_remote_code: bool = False,
**kwargs: Any,
)
Load an audio feature extractor for the given model name via HuggingFace.
Source code in vllm/transformers_utils/processor.py
get_image_processor
¶
get_image_processor(
processor_name: str,
*args: Any,
revision: Optional[str] = None,
trust_remote_code: bool = False,
**kwargs: Any,
)
Load an image processor for the given model name via HuggingFace.
Source code in vllm/transformers_utils/processor.py
get_processor
¶
get_processor(
processor_name: str,
*args: Any,
revision: Optional[str] = None,
trust_remote_code: bool = False,
processor_cls: Union[
type[_P], tuple[type[_P], ...]
] = ProcessorMixin,
**kwargs: Any,
) -> _P
Load a processor for the given model name via HuggingFace.