From 109069c0da07b621cfe4f1d491b086f349d3c81c Mon Sep 17 00:00:00 2001 From: Jerry Yan <792602257@qq.com> Date: Mon, 19 Jan 2026 13:09:48 +0800 Subject: [PATCH] 1 --- runtime/ops/__init__.py | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100644 runtime/ops/__init__.py diff --git a/runtime/ops/__init__.py b/runtime/ops/__init__.py deleted file mode 100644 index 9d0c918..0000000 --- a/runtime/ops/__init__.py +++ /dev/null @@ -1,34 +0,0 @@ -# -*- coding: utf-8 -*- -"""Datamate built-in operators package. - -This package contains built-in operators for filtering, slicing, annotation, etc. -It is mounted into the runtime container under ``datamate.ops`` so that -``from datamate.ops.annotation...`` imports work correctly. -""" - -import importlib -import os - -from loguru import logger - -__all__ = [ - "annotation", - "filter", - "formatter", - "llms", - "mapper", - "slicer", - "user", -] - -# 自动导入所有子模块以触发算子注册 -current_dir = os.path.dirname(__file__) - -for module_name in os.listdir(current_dir): - module_path = os.path.join(current_dir, module_name) - # 检查是否是目录且包含 __init__.py - if os.path.isdir(module_path) and '__init__.py' in os.listdir(module_path): - try: - importlib.import_module(f".{module_name}", package=__name__) - except Exception as e: - logger.error(f"Failed to load Ops module {module_name}: {e}")