You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by sk...@apache.org on 2018/11/15 00:31:18 UTC
[incubator-mxnet] branch master updated: Addressed ONNX module
documentation warnings and added notes for short-form representation
(#13259)
This is an automated email from the ASF dual-hosted git repository.
skm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git
The following commit(s) were added to refs/heads/master by this push:
new 100a4aa Addressed ONNX module documentation warnings and added notes for short-form representation (#13259)
100a4aa is described below
commit 100a4aa6d42942df9bc191411553d72e11acf866
Author: vdantu <36...@users.noreply.github.com>
AuthorDate: Wed Nov 14 16:31:03 2018 -0800
Addressed ONNX module documentation warnings and added notes for short-form representation (#13259)
---
python/mxnet/contrib/onnx/mx2onnx/export_model.py | 5 +++++
python/mxnet/contrib/onnx/onnx2mx/import_model.py | 9 +++++++++
python/mxnet/contrib/onnx/onnx2mx/import_to_gluon.py | 5 +++++
3 files changed, 19 insertions(+)
diff --git a/python/mxnet/contrib/onnx/mx2onnx/export_model.py b/python/mxnet/contrib/onnx/mx2onnx/export_model.py
index e515805..f5e4c3b 100644
--- a/python/mxnet/contrib/onnx/mx2onnx/export_model.py
+++ b/python/mxnet/contrib/onnx/mx2onnx/export_model.py
@@ -58,6 +58,11 @@ def export_model(sym, params, input_shape, input_type=np.float32,
-------
onnx_file_path : str
Onnx file path
+
+ Notes
+ -----
+ This method is available when you ``import mxnet.contrib.onnx``
+
"""
try:
diff --git a/python/mxnet/contrib/onnx/onnx2mx/import_model.py b/python/mxnet/contrib/onnx/onnx2mx/import_model.py
index 0f1a7c4..0048c74 100644
--- a/python/mxnet/contrib/onnx/onnx2mx/import_model.py
+++ b/python/mxnet/contrib/onnx/onnx2mx/import_model.py
@@ -41,6 +41,11 @@ def import_model(model_file):
aux_params : dict of ``str`` to :class:`~mxnet.ndarray.NDArray`
Dict of converted parameters stored in ``mxnet.ndarray.NDArray`` format
+
+ Notes
+ -----
+ This method is available when you ``import mxnet.contrib.onnx``
+
"""
graph = GraphProto()
@@ -58,6 +63,10 @@ def get_model_metadata(model_file):
"""
Returns the name and shape information of input and output tensors of the given ONNX model file.
+ Notes
+ -----
+ This method is available when you ``import mxnet.contrib.onnx``
+
Parameters
----------
model_file : str
diff --git a/python/mxnet/contrib/onnx/onnx2mx/import_to_gluon.py b/python/mxnet/contrib/onnx/onnx2mx/import_to_gluon.py
index 8e1b354..13ad5b9 100644
--- a/python/mxnet/contrib/onnx/onnx2mx/import_to_gluon.py
+++ b/python/mxnet/contrib/onnx/onnx2mx/import_to_gluon.py
@@ -36,6 +36,11 @@ def import_to_gluon(model_file, ctx):
-------
sym_block : :class:`~mxnet.gluon.SymbolBlock`
A SymbolBlock object representing the given model file.
+
+ Notes
+ -----
+ This method is available when you ``import mxnet.contrib.onnx``
+
"""
graph = GraphProto()
try: