API

MindSpore provides rich interfaces for model building, training, and inference. The functions of each module interface are described below.

Module Name

Descriptions

mindspore

Framework foundation interface.

mindspore.ops

Function interface.

mindspore.nn

A neural network layer for building predefined building blocks or computational units in a neural network.

mindspore.mint

Functional, nn, and optimizer interfaces consistent with mainstream industry usage.

mindspore.common.initializer

Parameter initialization.

mindspore.amp

Mixed-precision interface.

mindspore.train

Traning interface.

mindspore.parallel

Auto Parallel interface.

mindspore.runtime

Runtime interface.

mindspore.device_context

Device and backend management interface.

mindspore.communication

Collection communication interface.

mindspore.dataset

Interfaces for loading and processing various datasets.

mindspore.numpy

NumPy Class interface.

mindspore.scipy

SciPy Class interface.

mindspore.multiprocessing

Multi-processing interface.

mindspore.utils

Tools interface.

mindspore.experimental

Experimental interface.

mindspore.ops.primitive

Primitive operator.

mindspore.boost

Automatic acceleration network interfaces.

mindspore.nn.probability

Parameterizable probability distributions and sampling functions.

mindspore.rewrite

Custom rule-based model source code modification interface.

mindspore.hal

Interface of device management, stream management, event management and memory management.

Environment Variables

Notes related to environment variables.