Unverified Commit db0831e0 authored by yilian49's avatar yilian49 Committed by GitHub
Browse files

Quick fix for loading processor for supporting internvl3_5 series (#9676)

parent 6e4e1c8c
...@@ -368,6 +368,15 @@ def get_processor( ...@@ -368,6 +368,15 @@ def get_processor(
if config.model_type not in {"llava", "clip"}: if config.model_type not in {"llava", "clip"}:
kwargs["use_fast"] = use_fast kwargs["use_fast"] = use_fast
try: try:
if "InternVL3_5" in tokenizer_name:
processor = AutoTokenizer.from_pretrained(
tokenizer_name,
*args,
trust_remote_code=trust_remote_code,
revision=revision,
**kwargs,
)
else:
processor = AutoProcessor.from_pretrained( processor = AutoProcessor.from_pretrained(
tokenizer_name, tokenizer_name,
*args, *args,
......
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