Main Content

Autoencoder class

Superclasses:

Autoencoder class

Description

AnAutoencoder对象包含一个autoencoder网络,这缺点ists of an encoder and a decoder. The encoder maps the input to a hidden representation. The decoder attempts to map this representation back to the original input.

Construction

autoenc= trainAutoencoder(X)returns an autoencoder trained using the training data inX.

autoenc= trainAutoencoder(X,hiddenSize)returns an autoencoder with the hidden representation size ofhiddenSize.

autoenc= trainAutoencoder(___,Name,Value)returns an autoencoder for any of the above input arguments with additional options specified by one or more name-value pair arguments.

Input Arguments

expand all

Training data, specified as a matrix of training samples or a cell array of image data. IfXis a matrix, then each column contains a single sample. IfXis a cell array of image data, then the data in each cell must have the same number of dimensions. The image data can be pixel intensity data for gray images, in which case, each cell contains anm-by-nmatrix. Alternatively, the image data can be RGB data, in which case, each cell contains anm-by-n-3 matrix.

Data Types:single|double|cell

Size of hidden representation of the autoencoder, specified as a positive integer value. This number is the number of neurons in the hidden layer.

Data Types:single|double

Properties

expand all

Size of the hidden representation in the hidden layer of the autoencoder, stored as a positive integer value.

Data Types:double

Name of the transfer function for the encoder, stored as a string.

Data Types:char

Weights for the encoder, stored as a matrix.

Data Types:double

Bias values for the encoder, stored as a vector.

Data Types:double

Name of the transfer function for the decoder, stored as a string.

Data Types:char

Weights for the decoder, stored as a matrix.

Data Types:double

Bias values for the decoder, stored as a vector.

Data Types:double

Parameters thattrainAutoencoderuses for training the autoencoder, stored as a structure.

Data Types:struct

Indicator for data that is rescaled while passing to the autoencoder, stored as eithertrueorfalse.

Autoencoders attempt to replicate their input at their output. For it to be possible, the range of the input data must match the range of the transfer function for the decoder.trainAutoencoderautomatically scales the training data to this range when training an autoencoder. If the data was scaled while training an autoencoder, thepredict,encode, anddecodemethods also scale the data.

Data Types:logical

Methods

decode Decode encoded data
encode Encode input data
generateFunction Generate a MATLAB function to run the autoencoder
generateSimulink Generate a万博1manbetxmodel for the autoencoder
network ConvertAutoencoderobject intonetworkobject
plotWeights Plot a visualization of the weights for the encoder of an autoencoder
predict Reconstruct the inputs using trained autoencoder
堆栈 Stack encoders from several autoencoders together
view View autoencoder

Copy Semantics

Value. To learn how value classes affect copy operations, seeCopying Objects.

版本历史

Introduced in R2015b