Skip to content

Commit

Permalink
[docs] Update relay docs (apache#5112)
Browse files Browse the repository at this point in the history
* Update relay docs

* any -> py:func

* make clean
  • Loading branch information
zhiics authored and Trevor Morris committed Apr 16, 2020
1 parent 37d21e1 commit 11db4db
Show file tree
Hide file tree
Showing 16 changed files with 34 additions and 440 deletions.
44 changes: 4 additions & 40 deletions docs/api/python/relay/analysis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,43 +19,7 @@ tvm.relay.analysis
----------------------

.. automodule:: tvm.relay.analysis

.. autofunction:: tvm.relay.analysis.post_order_visit

.. autofunction:: tvm.relay.analysis.well_formed

.. autofunction:: tvm.relay.analysis.check_kind

.. autofunction:: tvm.relay.analysis.check_constant

.. autofunction:: tvm.relay.analysis.free_vars

.. autofunction:: tvm.relay.analysis.bound_vars

.. autofunction:: tvm.relay.analysis.all_vars

.. autofunction:: tvm.relay.analysis.free_type_vars

.. autofunction:: tvm.relay.analysis.bound_type_vars

.. autofunction:: tvm.relay.analysis.all_type_vars

.. autofunction:: tvm.relay.analysis.alpha_equal

.. autofunction:: tvm.relay.analysis.assert_alpha_equal

.. autofunction:: tvm.relay.analysis.graph_equal

.. autofunction:: tvm.relay.analysis.assert_graph_equal

.. autofunction:: tvm.relay.analysis.collect_device_info

.. autofunction:: tvm.relay.analysis.collect_device_annotation_ops

.. autofunction:: tvm.relay.analysis.get_total_mac_number

.. autofunction:: tvm.relay.analysis.unmatched_cases

.. autofunction:: tvm.relay.analysis.detect_feature

.. autofunction:: tvm.relay.analysis.structural_hash
:members:
:imported-members:
:exclude-members: Object, RelayExpr, IRModule, Type
:autosummary:
26 changes: 0 additions & 26 deletions docs/api/python/relay/base.rst

This file was deleted.

32 changes: 0 additions & 32 deletions docs/api/python/relay/build_module.rst

This file was deleted.

67 changes: 0 additions & 67 deletions docs/api/python/relay/expr.rst

This file was deleted.

7 changes: 3 additions & 4 deletions docs/api/python/relay/image.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
tvm.relay.image
---------------

.. automodule:: tvm.relay.image
:members:

.. automodule:: tvm.relay.op.image
:members:
:members:
:imported-members:
:exclude-members:
16 changes: 11 additions & 5 deletions docs/api/python/relay/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,22 @@ compiler stack.
.. toctree::
:maxdepth: 2

analysis
backend
base
build_module
expr
frontend
image
analysis
transform
nn
op
scope_builder
vision
testing

.. automodule:: tvm.relay
:members:
:imported-members:
:exclude-members: RelayExpr, Pass, PassInfo, function_pass, PassContext,
ModulePass, FunctionPass, Sequential, module_pass, Type, TypeKind,
TypeVar, GlobalTypeVar, TypeConstraint, FuncType, TupleType, IncompleteType,
TypeCall, TypeRelation, TensorType, RelayRefType, GlobalVar, SourceName,
Span, Var, Op, Constructor
:autosummary:
5 changes: 2 additions & 3 deletions docs/api/python/relay/nn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
tvm.relay.nn
------------
.. automodule:: tvm.relay.nn
:members:

.. automodule:: tvm.relay.op.nn.nn
:members:
:imported-members:
:exclude-members:
2 changes: 1 addition & 1 deletion docs/api/python/relay/op.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@ tvm.relay.op
.. automodule:: tvm.relay.op
:members:
:imported-members:
:exclude-members: Tuple
:exclude-members: Tuple, TupleWrapper
:autosummary:
24 changes: 0 additions & 24 deletions docs/api/python/relay/scope_builder.rst

This file was deleted.

72 changes: 3 additions & 69 deletions docs/api/python/relay/transform.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,73 +19,7 @@ tvm.relay.transform
----------------------

.. automodule:: tvm.relay.transform

.. autofunction:: tvm.relay.transform.build_config

.. autofunction:: tvm.relay.transform.module_pass

.. autofunction:: tvm.relay.transform.function_pass

.. autofunction:: tvm.relay.transform.InferType

.. autofunction:: tvm.relay.transform.FoldScaleAxis

.. autofunction:: tvm.relay.transform.BackwardFoldScaleAxis

.. autofunction:: tvm.relay.transform.ForwardFoldScaleAxis

.. autofunction:: tvm.relay.transform.SimplifyInference

.. autofunction:: tvm.relay.transform.CanonicalizeOps

.. autofunction:: tvm.relay.transform.DeadCodeElimination

.. autofunction:: tvm.relay.transform.FoldConstant

.. autofunction:: tvm.relay.transform.FuseOps

.. autofunction:: tvm.relay.transform.CombineParallelConv2D

.. autofunction:: tvm.relay.transform.CombineParallelDense

.. autofunction:: tvm.relay.transform.AlterOpLayout

.. autofunction:: tvm.relay.transform.Legalize

.. autofunction:: tvm.relay.transform.RewriteAnnotatedOps

.. autofunction:: tvm.relay.transform.ToANormalForm

.. autofunction:: tvm.relay.transform.ToCPS

.. autofunction:: tvm.relay.transform.EtaExpand

.. autofunction:: tvm.relay.transform.ToGraphNormalForm

.. autofunction:: tvm.relay.transform.EliminateCommonSubexpr

.. autofunction:: tvm.relay.transform.PartialEvaluate

.. autofunction:: tvm.relay.transform.CanonicalizeCast

.. autofunction:: tvm.relay.transform.LambdaLift

.. autofunction:: tvm.relay.transform.PrintIR

.. autoclass:: tvm.relay.transform.Pass
:members:

.. autoclass:: tvm.relay.transform.PassInfo
:members:

.. autoclass:: tvm.relay.transform.PassContext
:members:

.. autoclass:: tvm.relay.transform.ModulePass
:members:

.. autoclass:: tvm.relay.transform.FunctionPass
:members:

.. autoclass:: tvm.relay.transform.Sequential
:members:
:imported-members:
:exclude-members: Object
:autosummary:
10 changes: 3 additions & 7 deletions docs/api/python/relay/vision.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,7 @@
tvm.relay.vision
----------------

.. automodule:: tvm.relay.vision
:members:

.. automodule:: tvm.relay.op.vision.multibox
:members:

.. automodule:: tvm.relay.op.vision.nms
.. automodule:: tvm.relay.op.vision
:members:
:imported-members:
:autosummary:
1 change: 1 addition & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,7 @@ def run_doxygen(folder):
tvm_alias_check_map = {
"tvm.te": ["tvm.tir"],
"tvm.tir": ["tvm.ir", "tvm.runtime"],
"tvm.relay": ["tvm.ir", "tvm.tir"],
}

def update_alias_docstring(name, obj, lines):
Expand Down
Loading

0 comments on commit 11db4db

Please sign in to comment.