File size: 371 Bytes
60965be
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
import transformers
from packaging import version

VERSION = "4.35.2"


def check_transformers_version():
    if version.parse(transformers.__version__) < version.parse(VERSION):
        raise ImportError(
            f"You are using transformers=={transformers.__version__}, but transformers>={VERSION} is required to use DeciLM. Please upgrade transformers."
        )