From f2faf3acb38e3ccb6e62379e4314f00c844db36f Mon Sep 17 00:00:00 2001 From: "jiangyu.xzy" Date: Tue, 1 Nov 2022 18:04:48 +0800 Subject: [PATCH] fix import bug --- modelscope/hub/utils/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modelscope/hub/utils/utils.py b/modelscope/hub/utils/utils.py index d0a87cbd..61d560fa 100644 --- a/modelscope/hub/utils/utils.py +++ b/modelscope/hub/utils/utils.py @@ -7,7 +7,6 @@ from typing import Optional import requests -from modelscope.hub.api import ModelScopeConfig from modelscope.hub.constants import (DEFAULT_MODELSCOPE_DOMAIN, DEFAULT_MODELSCOPE_GROUP, MODEL_ID_SEPARATOR, MODELSCOPE_SDK_DEBUG, @@ -92,6 +91,7 @@ def file_integrity_validation(file_path, expected_sha256): def create_library_statistics(method: str, name: str, cn_name: Optional[str]): try: + from modelscope.hub.api import ModelScopeConfig path = f'{get_endpoint()}/api/v1/statistics/library' headers = {'user-agent': ModelScopeConfig.get_user_agent()} params = {'Method': method, 'Name': name, 'CnName': cn_name}