.. index:: pair: class; gpr::capi::FreeEnergySurrogate .. _doxid-classgpr_1_1capi_1_1_free_energy_surrogate: class gpr::capi::FreeEnergySurrogate ==================================== .. toctree:: :hidden: struct_gpr_capi_FreeEnergySurrogate_Prediction.rst Overview ~~~~~~~~ Owner of a :ref:`gpr_fes_t `. Arrays are row-major, one row per point. :ref:`More...` .. ref-code-block:: cpp :class: doxyrest-overview-code-block #include class FreeEnergySurrogate { public: // structs struct :ref:`Prediction`; // construction :target:`FreeEnergySurrogate`(); :target:`FreeEnergySurrogate`(:ref:`gpr_fes_t` h, :ref:`adopt_t`); :target:`FreeEnergySurrogate`(const FreeEnergySurrogate&); :target:`FreeEnergySurrogate`(FreeEnergySurrogate&& other); :target:`~FreeEnergySurrogate`(); // methods :ref:`FreeEnergySurrogate`& :target:`operator=`(const :ref:`FreeEnergySurrogate`&); :ref:`FreeEnergySurrogate`& :target:`operator=`(:ref:`FreeEnergySurrogate`&& other); void :target:`reset`(); :ref:`gpr_fes_t` :target:`handle`() const; :target:`operator bool`() const; int :target:`dimension`() const; int :target:`n_observations`() const; void :ref:`train`(const std::vector& s, const std::vector& F, const std::vector& F_noise_var, const std::vector& grad_F, const std::vector& grad_noise_var, const std::vector& grad_present, int n_obs); :ref:`Prediction` :target:`predict`(const std::vector& s_query, int n_queries, bool with_gradient, bool with_variance) const; :ref:`FesRateReport` :target:`rate_path`(const std::vector& path, int n_path, int reactant_index, int product_index, const std::vector& diffusion, const :ref:`FesRateConfig`& config) const; static :ref:`FreeEnergySurrogate` :target:`create`(int dimension, const :ref:`ModelConfig`& model_config = :ref:`model_config_defaults`(), const :ref:`FesConfig`& config = :ref:`fes_config_defaults`(), const std::vector& grad_noise_var = {}); }; .. _details-classgpr_1_1capi_1_1_free_energy_surrogate: Detailed Documentation ~~~~~~~~~~~~~~~~~~~~~~ Owner of a :ref:`gpr_fes_t `. Arrays are row-major, one row per point. Methods ------- .. index:: pair: function; train .. _doxid-classgpr_1_1capi_1_1_free_energy_surrogate_1a12951272d82f38785a71f65228b7d88c: .. ref-code-block:: cpp :class: doxyrest-title-code-block void train(const std::vector& s, const std::vector& F, const std::vector& F_noise_var, const std::vector& grad_F, const std::vector& grad_noise_var, const std::vector& grad_present, int n_obs) Values only when grad_F is empty; otherwise grad_F, grad_noise_var and grad_present are all given.