gtm_trn

Optimize (train) the parameters of a GTM model, using an EM algorithm.

Synopsis

[W, beta, llhLog] = gtm_trn(T, FI, W, l, cycles, beta, m, q)
[W, beta] = gtm_trn(T, FI, W, l, cycles, beta)

Arguments

T - matrix containing a sample of the distribution to be modeled; N-by-D

FI - matrix containing the output values from the basis functions, when fed the latent variable sample; K-by-(M+1)

W - an initial weight matrix; (M+1)-by-D

l - weight regularisation factor

cycles - no of training cycles

beta - an initial value for beta, the inverse variance of the Gaussian mixture generated in the data space

m - mode of calculation; it can be set to 0, 1 or 2 corresponding to increasingly elaborate measure taken to reduce the amount of numerical errors; mode = 0 will be fast but less accurate, mode = 2 will be slow but more accurate; the default mode is 1

q - quiet execution; if q equals the string 'quiet', the plotting and echoing of the values of log- likelihood and beta during traaining is supressed. This argument is optional; if omitted the training is run non-quiet.

Return

W, beta - the corresponding weight matrix and inverse variance after training

llhLog - the log-likelihood after each cycle of training; optional output argument


The GTM Toolbox: Contents