In machine learning, a loss function is a mathematical function that must be minimized in order to achieve convergence. Choosing the proper loss function is an important step in designing your neural network. The IDLmllfMeanAbsoluteError (Mean Absolute Error) loss function is implemented with the following formula:

where x is the calculated output of the model and y is the predicted output or truth.

Example


Compile_opt idl2
LossFunction = IDLmllfMeanAbsoluteError()
Print, LossFunction(Findgen(10)/9.0, Fltarr(10))
 

Typically, you will pass an object of this class to a neural network model definition:

Classifier = IDLmlFeedForwardNeuralNetwork([3, 7, 1],
LOSS_FUNCTION=IDLmllfMeanAbsoluteError()

Syntax


Kernel = IDLmllfMeanAbsoluteError()

Arguments


None

Keywords


None

Version History


8.7.1

Introduced

See Also


IDLmllfCrossEntropy, IDLmllfHuber, IDLmllfLogCosh, IDLmllfMeanSquaredError