mxnet.gluon

The Gluon library in Apache MXNet provides a clear, concise, and simple API for deep learning. It makes it easy to prototype, build, and train deep learning models without sacrificing training speed.

Example

The following example shows how you might create a simple neural network with three layers: one input layer, one hidden layer, and one output layer.

net = gluon.nn.Sequential()
# When instantiated, Sequential stores a chain of neural network layers.
# Once presented with data, Sequential executes each layer in turn, using
# the output of one layer as the input for the next
with net.name_scope():
    net.add(gluon.nn.Dense(256, activation="relu")) # 1st layer (256 nodes)
    net.add(gluon.nn.Dense(256, activation="relu")) # 2nd hidden layer
    net.add(gluon.nn.Dense(num_outputs))

Neural network module.

Tutorials

Gluon Guide../../tutorials/packages/gluon/index.html

The Gluon guide. Start here!

Gluon-CV Toolkithttps://gluon-cv.mxnet.io/

A Gluon add-on module for computer vision.

Gluon-NLP Toolkithttps://gluon-nlp.mxnet.io/

A Gluon add-on module for natural language processing.

APIs and Packages

Core Modules

gluon.nnnn/index.html

Neural network components.

gluon.rnnrnn/index.html

Recurrent neural network components.

Training

gluon.lossloss/index.html

Loss functions for training neural networks.

gluon.Parameterparameter.html

Parameter getting and setting functions.

gluon.Trainertrainer.html

Functions for applying an optimizer on a set of parameters.

Data

gluon.datadata/index.html

Dataset utilities.

gluon.data.visiondata/vision/index.html

Image dataset utilities.

gluon.model_zoo.visionmodel_zoo/index.html

A module for loading pre-trained neural network models.

Utilities

gluon.utilsutils/index.html

A variety of utilities for training.