Hauptinhalt

gensim

(To be removed) Generate Simulink block for shallow neural network simulation

gensim will be removed in a future release. For more information, see Transition Legacy Neural Network Code to dlnetwork Workflows.

For advice on updating your code, see Version History.

Description

gensim(net,st) creates a Simulink® system containing a block that simulates neural network net with a sampling time of st.

If net has no input or layer delays (net.numInputDelays and net.numLayerDelays are both 0), you can use –1 for st to get a network that samples continuously.

gensim does not support deep learning networks such as convolutional or LSTM networks. For more information on code generation for deep learning, see Generate Code and Deploy Deep Neural Networks.

For more information on gensim, at the MATLAB command prompt, enter help network/gensim.

example

Examples

collapse all

This example shows how to generate a Simulink block for a feedforward network.

Create a feedforward network using the data from the simple fit data set and generate the Simulink block.

[x,t] = simplefit_dataset;
net = feedforwardnet(10);
net = train(net,x,t)
gensim(net)

Input Arguments

collapse all

Input network, specified as a network object. To create a network object, use for example, feedforwardnet or narxnet.

Specify the sample time as a value other than -1. For more information, see Specify Sample Time (Simulink).

More About

collapse all

Version History

Introduced before R2006a