[Misc] Lazy import registered processors (#36024)

Signed-off-by: Isotr0py <mozf@mail2.sysu.edu.cn>
Co-authored-by: Roger Wang <hey@rogerw.io>
This commit is contained in:
Isotr0py
2026-03-06 06:06:45 -08:00
committed by GitHub
co-authored by Roger Wang
parent fcb73f306c
commit 1d0c0d209c
15 changed files with 68 additions and 51 deletions
@@ -29,7 +29,7 @@ from typing import Any
import torch
import torchvision.transforms as T
from PIL import Image, ImageOps
from transformers import AutoProcessor, BatchFeature, LlamaTokenizerFast
from transformers import BatchFeature, LlamaTokenizerFast
from transformers.processing_utils import ProcessorMixin
@@ -401,6 +401,3 @@ class DeepseekVLV2Processor(ProcessorMixin):
images_spatial_crop,
num_image_tokens,
)
AutoProcessor.register("DeepseekVLV2Processor", DeepseekVLV2Processor)