fix: fixed issue #709

This commit is contained in:
SWHL committed 2026-07-08 16:04:02 +08:00
1 parent b64a46ffd4
commit 802c05647f
1 file changed
+25 -4
+25 -4
View File
@@ -1,11 +1,32 @@
# -*- encoding: utf-8 -*-
# @Author: SWHL
# @Contact: liekkaskono@163.com
from .main import RapidOCR
from .utils.download_models import download_models
from .utils.load_image import LoadImageError
from .utils.typings import EngineType, LangCls, LangDet, LangRec, ModelType, OCRVersion
from .utils.vis_res import VisRes
def __getattr__(name):
if name == "RapidOCR":
from .main import RapidOCR
return RapidOCR
if name == "LoadImageError":
from .utils.load_image import LoadImageError
return LoadImageError
if name == "VisRes":
from .utils.vis_res import VisRes
return VisRes
if name == "download_models":
from .utils.download_models import download_models
return download_models
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
__all__ = [
"RapidOCR",