You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2020/03/16 06:00:16 UTC
[GitHub] [incubator-tvm] zhiics commented on a change in pull request #5077:
[Refactor][Relay] Refactor Relay Python to use new FFI
zhiics commented on a change in pull request #5077: [Refactor][Relay] Refactor Relay Python to use new FFI
URL: https://github.com/apache/incubator-tvm/pull/5077#discussion_r392795780
##########
File path: python/tvm/relay/__init__.py
##########
@@ -19,111 +19,112 @@
import os
from sys import setrecursionlimit
-from . import call_graph
-from . import base
-from . import ty
-from . import expr
-from . import type_functor
-from . import expr_functor
-from . import adt
-from . import analysis
+from . import ir
+from .ir import adt, expr, ty, base, scope_builder
+from .ir import prelude, loops, parser
+
from . import transform
+from . import analysis
+from .analysis import call_graph, feature, alpha_equal
from .build_module import build, create_executor, optimize
from .transform import build_config
-from . import prelude
-from . import parser
from . import debug
from . import param_dict
-from . import feature
from .backend import vm
# Root operators
from .op import Op
+from .op import annotation
from .op.reduce import *
from .op.tensor import *
from .op.transform import *
from .op.algorithm import *
-from . import nn
-from . import annotation
-from . import vision
-from . import contrib
-from . import image
+from .op.nn import *
+from .op.vision import *
+from .op.contrib import *
+from .op.image import *
from . import frontend
from . import backend
from . import quantize
# Dialects
from . import qnn
-from .scope_builder import ScopeBuilder
# Load Memory pass
-from . import memory_alloc
+from .transform import memory_alloc
# Required to traverse large programs
setrecursionlimit(10000)
# Span
-Span = base.Span
+Span = ir.Span
# Type
-Type = ty.Type
-TupleType = ty.TupleType
-TensorType = ty.TensorType
-TypeKind = ty.TypeKind
-TypeVar = ty.TypeVar
-ShapeVar = ty.ShapeVar
-TypeConstraint = ty.TypeConstraint
-FuncType = ty.FuncType
-TypeRelation = ty.TypeRelation
-IncompleteType = ty.IncompleteType
-scalar_type = ty.scalar_type
-RefType = ty.RefType
-GlobalTypeVar = ty.GlobalTypeVar
-TypeCall = ty.TypeCall
-Any = ty.Any
+Type = ir.Type
Review comment:
@tqchen Are you okay with these aliases or should we do `from ir import *`?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services