构建深度神经网络
使用命令行函数或以交互方式使用深度网络设计器构建网络
使用 MATLAB® 代码或以交互方式使用深度网络设计器从头开始构建网络。使用内置层为分类和回归等任务构建网络。要查看内置层的列表,请参阅深度学习层列表。然后,您可以分析您的网络以了解网络架构,并在训练前检查问题。
如果内置层没有提供您的任务所需的层,则您可以定义自己的自定义深度学习层。您可以使用自定义输出层指定自定义损失函数,并定义具有或不具有可学习参数的自定义层。定义自定义层后,您可以检查该层是否有效,是否与 GPU 兼容,以及是否输出正确定义的梯度。
对于无法使用层图创建的网络,可以将自定义网络定义为函数。有关如何训练定义为函数的深度学习模型的示例,请参阅Train Network Using Model Function。
App
深度网络设计器 | 设计、可视化和训练深度学习网络 |
函数
主题
内置层
- 长短期记忆神经网络
了解长短期记忆 (LSTM) 神经网络。 - 创建简单的深度学习神经网络以用于分类
此示例说明如何创建和训练简单的卷积神经网络来进行深度学习分类。卷积神经网络是深度学习的基本工具,尤其适用于图像识别。 - 深度学习层列表
探索 MATLAB 中的所有深度学习层。 - 指定卷积神经网络的层
了解卷积神经网络 (ConvNet) 的层,以及它们在 ConvNet 中出现的顺序。 - 使用深度网络设计器构建网络
在深度网络设计器中以交互方式构建和编辑深度学习网络。 - Example Deep Learning Networks Architectures
This example shows how to define simple deep learning neural networks for classification and regression tasks. - Generate MATLAB Code from Deep Network Designer
Generate MATLAB code to recreate designing and training a network in Deep Network Designer.
自定义层
- 定义自定义深度学习层
了解如何定义自定义深度学习层。 - Define Custom Deep Learning Intermediate Layers
Learn how to define custom deep learning intermediate layers. - Define Custom Deep Learning Output Layers
Learn how to define custom deep learning output layers. - Import Custom Layer into Deep Network Designer
This example shows how to import a custom classification output layer with the sum of squares error (SSE) loss and add it to a pretrained network in Deep Network Designer. - Deep Learning Network Composition
Define custom layers containing layer graphs. - Define Nested Deep Learning Layer
This example shows how to define a nested deep learning layer. - Check Custom Layer Validity
Learn how to check the validity of custom deep learning layers. - View Autogenerated Custom Layers Using Deep Network Designer
This example shows how to import a pretrained TensorFlow™ network and view the autogenerated layers in Deep Network Designer.