[data] improve mmplugin (#7795)
This commit is contained in:
@@ -18,7 +18,6 @@ from typing import TYPE_CHECKING, Optional, Union
|
||||
from typing_extensions import override
|
||||
|
||||
from ..extras import logging
|
||||
from ..extras.misc import check_version
|
||||
from .data_utils import Role
|
||||
from .formatter import EmptyFormatter, FunctionFormatter, StringFormatter, ToolFormatter
|
||||
from .mm_plugin import get_mm_plugin
|
||||
@@ -518,9 +517,6 @@ def get_template_and_fix_tokenizer(tokenizer: "PreTrainedTokenizer", data_args:
|
||||
|
||||
template = TEMPLATES[data_args.template]
|
||||
|
||||
if template.mm_plugin.__class__.__name__ != "BasePlugin":
|
||||
check_version("transformers>=4.45.0")
|
||||
|
||||
if data_args.train_on_prompt and template.efficient_eos:
|
||||
raise ValueError("Current template does not support `train_on_prompt`.")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user