Skip to content
This repository was archived by the owner on Nov 17, 2023. It is now read-only.

Commit 05b6dc3

Browse files
Roshriniszha
authored andcommitted
Cherry-pick few commits to release 1.3 branch (#12375)
* Add a tutorial for control flow operators. (#12340) * the first version. * fix. * add to test. * fix. * fix. * fix * fix. * fix. * add title. * add link * fix. * Update ONNX API docs references (#12317) * update onnx API references * update descriptions * [MXAPPS-581] Disable an additional long test in the SD nightly (#12343) * Disable an additional test in the SD nightly that also takes over the timeout. * Documentation update related to sparse support (#12367) * Update sparse.md * Update sparse.md * Update csr.md * Update row_sparse.md * Update train.md
1 parent f0c0a97 commit 05b6dc3

12 files changed

Lines changed: 416 additions & 37 deletions

File tree

docs/api/python/contrib/onnx.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,17 @@ This document describes all the ONNX-MXNet APIs.
2222
.. autosummary::
2323
:nosignatures:
2424
25-
mxnet.contrib.onnx.import_model
26-
mxnet.contrib.onnx.get_model_metadata
27-
mxnet.contrib.onnx.import_to_gluon
28-
mxnet.contrib.onnx.export_model
25+
mxnet.contrib.onnx.onnx2mx.import_model
26+
mxnet.contrib.onnx.onnx2mx.import_to_gluon
27+
mxnet.contrib.onnx.mx2onnx.export_model
2928
```
3029

3130
## ONNX Tutorials
3231

3332
```eval_rst
3433
.. toctree::
3534
:maxdepth: 1
36-
35+
3736
/tutorials/onnx/super_resolution.md
3837
/tutorials/onnx/export_mxnet_to_onnx.md
3938
/tutorials/onnx/inference_on_onnx_model.md
@@ -43,19 +42,20 @@ This document describes all the ONNX-MXNet APIs.
4342
## ONNX Examples
4443

4544
* Face Recognition with [ArcFace](https://github.com/onnx/models/tree/master/models/face_recognition/ArcFace)
46-
* Image Classification with [MobileNet](https://github.com/onnx/models/tree/master/models/image_classification/mobilenet), [ResNet](https://github.com/onnx/models/tree/master/models/image_classification/resnet), [SqueezeNet](https://github.com/onnx/models/tree/master/models/image_classification/squeezenet), [VGG](https://github.com/onnx/models/tree/master/models/image_classification/vgg)
45+
* Image Classification with [MobileNet](https://github.com/onnx/models/tree/master/models/image_classification/mobilenet), [ResNet](https://github.com/onnx/models/tree/master/models/image_classification/resnet), [SqueezeNet](https://github.com/onnx/models/tree/master/models/image_classification/squeezenet), [VGG](https://github.com/onnx/models/tree/master/models/image_classification/vgg)
4746

4847
## API Reference
4948

5049
<script type="text/javascript" src='../../../_static/js/auto_module_index.js'></script>
5150

5251
```eval_rst
5352
54-
.. automodule:: mxnet.contrib.onnx.import_model
55-
.. automodule:: mxnet.contrib.onnx.get_model_metadata
56-
.. automodule:: mxnet.contrib.onnx.import_to_gluon
57-
.. automodule:: mxnet.contrib.onnx.export_model
58-
53+
.. automodule:: mxnet.contrib.onnx.onnx2mx.import_model
54+
:members: import_model, get_model_metadata
55+
.. automodule:: mxnet.contrib.onnx.onnx2mx.import_to_gluon
56+
:members: import_to_gluon
57+
.. automodule:: mxnet.contrib.onnx.mx2onnx.export_model
58+
:members: export_model
5959
```
6060

6161
<script>auto_index("api-reference");</script>

docs/api/python/ndarray/sparse.md

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ This document lists the routines of the *n*-dimensional sparse array package:
1616
```
1717

1818
The `CSRNDArray` and `RowSparseNDArray` API, defined in the `ndarray.sparse` package, provides
19-
imperative sparse tensor operations on **CPU**.
19+
imperative sparse tensor operations.
2020

2121
An `CSRNDArray` inherits from `NDArray`, and represents a two-dimensional, fixed-size array in compressed sparse row format.
2222

@@ -63,16 +63,13 @@ A detailed tutorial is available at
6363

6464
```eval_rst
6565
66-
.. note:: ``mxnet.ndarray.sparse.RowSparseNDArray`` and ``mxnet.ndarray.sparse.CSRNDArray`` DO NOT support the ``mxnet.gluon`` high-level interface yet.
67-
6866
.. note:: ``mxnet.ndarray.sparse`` is similar to ``mxnet.ndarray`` in some aspects. But the differences are not negligible. For instance:
6967
70-
- Only a subset of operators in ``mxnet.ndarray`` have specialized implementations in ``mxnet.ndarray.sparse``.
71-
Operators such as Convolution and broadcasting do not have sparse implementations yet.
68+
- Only a subset of operators in ``mxnet.ndarray`` have efficient sparse implementations in ``mxnet.ndarray.sparse``.
69+
- If an operator do not occur in the ``mxnet.ndarray.sparse`` namespace, that means the operator does not have an efficient sparse implementation yet. If sparse inputs are passed to such an operator, it will convert inputs to the dense format and fallback to the already available dense implementation.
7270
- The storage types (``stype``) of sparse operators' outputs depend on the storage types of inputs.
7371
By default the operators not available in ``mxnet.ndarray.sparse`` infer "default" (dense) storage type for outputs.
7472
Please refer to the [API Reference](#api-reference) section for further details on specific operators.
75-
- GPU support for ``mxnet.ndarray.sparse`` is experimental. Only a few sparse operators are supported on GPU such as ``sparse.dot``.
7673
7774
.. note:: ``mxnet.ndarray.sparse.CSRNDArray`` is similar to ``scipy.sparse.csr_matrix`` in some aspects. But they differ in a few aspects:
7875
@@ -559,7 +556,6 @@ We summarize the interface for each class in the following sections.
559556
sgd_update
560557
sgd_mom_update
561558
adam_update
562-
ftrl_update
563559
adagrad_update
564560
```
565561

docs/api/python/symbol/sparse.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ This document lists the routines of the sparse symbolic expression package:
1616
```
1717

1818
The `Sparse Symbol` API, defined in the `symbol.sparse` package, provides
19-
sparse neural network graphs and auto-differentiation on CPU.
19+
sparse neural network graphs and auto-differentiation.
2020

2121
The storage type of a variable is speficied by the `stype` attribute of the variable.
2222
The storage type of a symbolic expression is inferred based on the storage types of the variables and the operators.
@@ -43,12 +43,11 @@ array([ 1., 1.],
4343
.. note:: most operators provided in ``mxnet.symbol.sparse`` are similar to those in
4444
``mxnet.symbol`` although there are few differences:
4545
46-
- Only a subset of operators in ``mxnet.symbol`` have specialized implementations in ``mxnet.symbol.sparse``.
47-
Operators such as reduction and broadcasting do not have sparse implementations yet.
46+
- Only a subset of operators in ``mxnet.symbol`` have efficient sparse implementations in ``mxnet.symbol.sparse``.
47+
- If an operator do not occur in the ``mxnet.symbol.sparse`` namespace, that means the operator does not have an efficient sparse implementation yet. If sparse inputs are passed to such an operator, it will convert inputs to the dense format and fallback to the already available dense implementation.
4848
- The storage types (``stype``) of sparse operators' outputs depend on the storage types of inputs.
4949
By default the operators not available in ``mxnet.symbol.sparse`` infer "default" (dense) storage type for outputs.
5050
Please refer to the API reference section for further details on specific operators.
51-
- GPU support for ``mxnet.symbol.sparse`` is experimental.
5251
5352
```
5453

0 commit comments

Comments
 (0)