![]() Plot the network structure for the generator. LgraphGenerator = connectLayers(lgraphGenerator, 'emb', 'cat/in2') LgraphGenerator = addLayers(lgraphGenerator,layers) ImageInputLayer(, 'Name', 'labels', 'Normalization', 'none')ĮmbedAndReshapeLayer(projectionSize(1:2),embeddingDimension,numClasses, 'emb')] ![]() LgraphGenerator = layerGraph(layersGenerator) TransposedConv2dLayer(,1, 'Stride',2, 'Cropping', 'Name', 'tconv5') TransposedConv2dLayer(,numFilters, 'Stride',4, 'Cropping', 'Name', 'tconv4')īatchNormalizationLayer( 'Name', 'bn4', 'Epsilon',5e-5) TransposedConv2dLayer(,2*numFilters, 'Stride',4, 'Cropping', 'Name', 'tconv3')īatchNormalizationLayer( 'Name', 'bn3', 'Epsilon',5e-5) TransposedConv2dLayer(,4*numFilters, 'Stride',4, 'Cropping', 'Name', 'tconv2')īatchNormalizationLayer( 'Name', 'bn2', 'Epsilon',5e-5) TransposedConv2dLayer(,8*numFilters, 'Name', 'tconv1')īatchNormalizationLayer( 'Name', 'bn1', 'Epsilon',5e-5) ProjectAndReshapeLayer(projectionSize,numLatentInputs, 'proj') ImageInputLayer(, 'Normalization', 'none', 'Name', 'in') ![]() For categorical inputs, use an embedding dimension of 100. The embedAndReshapeLayer object converts a categorical label to a one-channel array of the specified size using an embedding and a fully connected operation. To embed and reshape the label input, use the custom layer embedAndReshapeLayer, attached to this example as a supporting file. To input the labels into the network, use an imageInputLayer object and specify a size of 1-by-1. The projectAndReshapeLayer object upscales the input using a fully connected layer and reshapes the output to the specified size. To project and reshape the noise input, use the custom layer projectAndReshapeLayer, attached to this example as a supporting file. ![]() Upsamples the resulting arrays to 1201-by-1-by-1 arrays using a series of 1-D transposed convolution layers with batch normalization and ReLU layers. Projects and reshapes the 1-by-1-by-100 arrays of noise to 4-by-1-by-1024 arrays by a custom layer.Ĭonverts the categorical labels to embedding vectors and reshapes them to a 4-by-1-by-1 arrays.Ĭoncatenates the results from the two inputs along the channel dimension. If you have the data in a folder different from that specified by tempdir, change the directory name in the following code. Each signal has 1201 signal samples with a sample rate of 1000 Hz.ĭownload and unzip the data in your temporary directory, whose location is specified by MATLAB® tempdir command. The data set contains 1575 pump output flow signals, of which 760 are healthy signals and 815 have a single fault, combinations of two faults, or combinations of three faults. The Simulink model is configured to model three types of faults: cylinder leaks, blocked inlets, and increased bearing friction. ![]() The simulated data is generated by the pump Simulink model presented in the Multi-Class Fault Detection Using Simulated Data (Predictive Maintenance Toolbox) example. Ideally, these strategies result in a generator that generates convincingly realistic data corresponding to the input labels and a discriminator that has learned strong features characteristic of the training data for each label. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |