NeuralEngine A Game Engine with embeded Machine Learning algorithms based on Gaussian Processes. |

FgAEPSparseDGPR.h
1
11#pragma once
12
13#include <MachineLearning/FgSparseDeepGPBaseModel.h>
14
15 namespace NeuralEngine
16{
17 namespace MachineLearning
18 {
19 namespace GPModels
20 {
21 namespace AEP
22 {
49 template<typename Scalar>
50 class NE_IMPEXP SDGPR : public SparseDeepGPBaseModel<Scalar>
51 {
52 public:
53
65 SDGPR(const af::array& Y, const af::array& X, HiddenLayerDescription hiddenLayerdescription, Scalar alpha = 1.0, LogLikType lType = LogLikType::Gaussian);
66
80 SDGPR(const af::array& Y, const af::array& X, std::vector<HiddenLayerDescription> hiddenLayerdescriptions, Scalar alpha = 1.0, LogLikType lType = LogLikType::Gaussian);
81
87 SDGPR();
88
89 virtual ~SDGPR();
90
101 virtual Scalar Function(const af::array& x, af::array& outGradient) override;
102
103 protected:
104 //SDGPR();
105
106 private:
107 Scalar dAlpha;
108
109 friend class boost::serialization::access;
110
111 template<class Archive>
112 void serialize(Archive& ar, unsigned int version)
113 {
114 ar& boost::serialization::base_object<SparseDeepGPBaseModel<Scalar>>(*this);
115 //ar& boost::serialization::make_nvp("SparseDeepGPBaseModel", boost::serialization::base_object<SparseDeepGPBaseModel<Scalar>>(*this));
116 ar& BOOST_SERIALIZATION_NVP(dAlpha);
117 }
118 };
119 }
120 }
121 }
122}
NeuralEngine::MachineLearning::GPModels::AEP::SDGPR
Deep sparse Gaussian process via Approximated Expectation Propagation (AEP).
Definition: FgAEPSparseDGPR.h:51
NeuralEngine::MachineLearning::GPModels::AEP::SDGPR::Function
virtual Scalar Function(const af::array &x, af::array &outGradient) override
Cost function the given x inputs.
NeuralEngine::MachineLearning::GPModels::AEP::SDGPR::SDGPR
SDGPR(const af::array &Y, const af::array &X, HiddenLayerDescription hiddenLayerdescription, Scalar alpha=1.0, LogLikType lType=LogLikType::Gaussian)
Constructor.
NeuralEngine::MachineLearning::GPModels::AEP::SDGPR::SDGPR
SDGPR()
Default constructor.
NeuralEngine::MachineLearning::GPModels::AEP::SDGPR::SDGPR
SDGPR(const af::array &Y, const af::array &X, std::vector< HiddenLayerDescription > hiddenLayerdescriptions, Scalar alpha=1.0, LogLikType lType=LogLikType::Gaussian)
Constructor.
NeuralEngine::MachineLearning::GPModels::SparseDeepGPBaseModel
Base class with abstract and basic function definitions. All deep GP models will be derived from this...
Definition: FgSparseDeepGPBaseModel.h:32
NeuralEngine::MachineLearning::HiddenLayerDescription
Description of the layer.
Definition: FgIModel.h:36
Scalar
NeuralEngine
Definition: NeArray2.h:18