Deep Learning avec Simulink
Implémentez des fonctionnalités de Deep Learning dans des modèles Simulink® avec des blocs des bibliothèques Deep Neural Networks, Python Neural Networks et Deep Learning Layers incluses dans Deep Learning Toolbox™ ou en utilisant le bloc Deep Learning Object Detector de la bibliothèque Analysis & Enhancement incluse dans Computer Vision Toolbox™.
Pour générer un modèle Simulink qui utilise la bibliothèque de blocs Deep Learning Layers afin de représenter un réseau, utilisez la fonction exportNetworkToSimulink
.
Certaines fonctionnalités de Deep Learning dans Simulink utilisent le bloc MATLAB Function qui nécessite un compilateur supporté. Pour la plupart des plateformes, un compilateur C par défaut est fourni avec l’installation MATLAB®. Si vous utilisez le langage C++, vous devez installer un compilateur C++ compatible. Pour voir une liste des compilateurs supportés, ouvrez Compilateurs supportés et compatibles, cliquez sur l’onglet qui correspond à votre système d’exploitation, trouvez la table Simulink Product Family et allez dans la colonne For Model Referencing, Accelerator mode, Rapid Accelerator mode, and MATLAB Function blocks. Si vous avez plusieurs compilateurs compatibles MATLAB installés sur votre système, vous pouvez modifier le compilateur par défaut avec la commande mex -setup
. Veuillez consulter Change Default Compiler.
Fonctions
exportNetworkToSimulink | Generate Simulink model that contains deep learning layer blocks and subsystems that correspond to deep learning layer objects (depuis R2024b) |
Blocs
Rubriques
Blocs pour les couches de Deep Learning
- List of Deep Learning Layer Blocks and Subsystems
Discover all the deep learning layer blocks and subsystems in Simulink. - Implement Unsupported Deep Learning Layer Blocks
This example shows how to implement layers using Simulink blocks or MATLAB code in a MATLAB Function block.
Images
- Classify Images in Simulink Using GoogLeNet
This example shows how to classify an image in Simulink® using theImage Classifier
block. - Acceleration for Simulink Deep Learning Models
Improve simulation speed with accelerator and rapid accelerator modes. - Lane and Vehicle Detection in Simulink Using Deep Learning
This example shows how to use deep convolutional neural networks inside a Simulink® model to perform lane and vehicle detection. - Classify ECG Signals in Simulink Using Deep Learning
This example shows how to use wavelet transforms and a deep learning network within a Simulink (R) model to classify ECG signals. - Classify Images in Simulink with Imported TensorFlow Network
Import a pretrained TensorFlow™ network usingimportTensorFlowNetwork
, and then use the Predict block for image classification in Simulink.
Séquences
- Predict and Update Network State in Simulink
This example shows how to predict responses for a trained recurrent neural network in Simulink® by using theStateful Predict
block. - Classify and Update Network State in Simulink
This example shows how to classify data for a trained recurrent neural network in Simulink® by using theStateful Classify
block. - Speech Command Recognition in Simulink
Detect the presence of speech commands in audio using a Simulink model. - Time Series Prediction in Simulink Using Deep Learning Network
This example shows how to use an LSTM deep learning network inside a Simulink® model to predict the remaining useful life (RUL) of an engine. - Simulate Calorie Burn Using Neural Network in Simulink
This example shows how to include a simple fully connected neural network in a Simulink® model that predicts calorie burn when given five time steps of sensor readings from a smart watch. - Battery State of Charge Estimation Using Deep Learning
Define requirements, prepare data, train deep learning networks, verify robustness, integrate networks into Simulink, and deploy models. (depuis R2024b) - Physical System Modeling Using LSTM Network in Simulink
This example shows how to create a reduced order model (ROM) that acts as a virtual sensor in a Simulink® model using a long short-term memory (LSTM) neural network. - Classify Motor Faults Using Deep Learning
This example shows how to train a deep learning model to classify faults in a permanent magnet synchronous motor (PMSM) using simulated data across various revolutions per minute (RPM). (depuis R2025a) - Improve Performance of Deep Learning Simulations in Simulink
This example shows how to use code generation to improve the performance of deep learning simulations in Simulink®.
Reinforcement Learning
- Control Water Level in a Tank Using a DDPG Agent (Reinforcement Learning Toolbox)
Train a controller using reinforcement learning with a plant modeled in Simulink as the training environment. - Train DDPG Agent for Adaptive Cruise Control (Reinforcement Learning Toolbox)
Train a DDPG agent for an adaptive cruise control application. - Train DQN Agent for Lane Keeping Assist Using Parallel Computing (Reinforcement Learning Toolbox)
Train a DQN agent for an automated driving application using parallel computing. - Train DDPG Agent for Path-Following Control (Reinforcement Learning Toolbox)
Train a DDPG agent for lane following control.
Coexécution avec Python
- Classify Images Using TensorFlow Model Predict Block
Classify images using TensorFlow Model Predict block. - Classify Images Using ONNX Model Predict Block
Classify images using ONNX Model Predict block. - Classify Images Using PyTorch Model Predict Block
Classify images using PyTorch Model Predict block. - Predict Responses Using TensorFlow Model Predict Block
Predict Responses Using TensorFlow Model Predict block. - Predict Responses Using ONNX Model Predict Block
Predict Responses Using ONNX Model Predict block. - Predict Responses Using PyTorch Model Predict Block
Predict Responses Using PyTorch Model Predict block. - Predict Responses Using Custom Python Model in Simulink (Statistics and Machine Learning Toolbox)
This example shows how to use the Custom Python Model Predict (Statistics and Machine Learning Toolbox) block for prediction in Simulink®.
Génération de code
- Génération de code de Deep Learning depuis des applications Simulink
Générer du code C/C++ et GPU pour le déploiement sur un ordinateur ou des cibles embarquées - Export Network to FMU
This example shows how to export a trained network as a Functional Mock-up Unit (FMU). (depuis R2023b)