12 #ifndef MLPACK_METHODS_ANN_LOSS_FUNCTION_RECONSTRUCTION_LOSS_HPP 13 #define MLPACK_METHODS_ANN_LOSS_FUNCTION_RECONSTRUCTION_LOSS_HPP 33 typename InputDataType = arma::mat,
34 typename OutputDataType = arma::mat,
35 typename DistType = BernoulliDistribution<InputDataType>
52 template<
typename PredictionType,
typename TargetType>
53 typename PredictionType::elem_type
Forward(
const PredictionType& prediction,
54 const TargetType& target);
64 template<
typename PredictionType,
typename TargetType,
typename LossType>
65 void Backward(
const PredictionType& prediction,
66 const TargetType& target,
77 template<
typename Archive>
78 void serialize(Archive& ar,
const uint32_t );
85 OutputDataType outputParameter;
92 #include "reconstruction_loss_impl.hpp"
Linear algebra utility functions, generally performed on matrices or vectors.
ReconstructionLoss()
Create the ReconstructionLoss object.
The core includes that mlpack expects; standard C++ includes and Armadillo.
The reconstruction loss performance function measures the network's performance equal to the negative...
void Backward(const PredictionType &prediction, const TargetType &target, LossType &loss)
Ordinary feed backward pass of a neural network.
OutputDataType & OutputParameter()
Modify the output parameter.
PredictionType::elem_type Forward(const PredictionType &prediction, const TargetType &target)
Computes the reconstruction loss.
OutputDataType & OutputParameter() const
Get the output parameter.
void serialize(Archive &ar, const uint32_t)
Serialize the layer.