MUQ  0.4.3
muq::Modeling::UMBridgeModPieceWrapper Class Reference

Wrap a ModPiece in an UM-Bridge Model. More...

#include <UMBridgeModPieceServer.h>

Inheritance diagram for muq::Modeling::UMBridgeModPieceWrapper:

Detailed Description

Wrap a ModPiece in an UM-Bridge Model.

This is needed in order to easily serve a MUQ ModPiece via UM-Bridge.

Definition at line 11 of file UMBridgeModPieceServer.h.

Public Member Functions

 UMBridgeModPieceWrapper (std::shared_ptr< muq::Modeling::ModPiece > modPiece, std::string name)
 Constructor. More...
 
std::vector< std::size_t > GetInputSizes (const json &config_json=json()) const override
 
std::vector< std::size_t > GetOutputSizes (const json &config_json=json()) const override
 
std::vector< std::vector< double > > Evaluate (const std::vector< std::vector< double >> &inputs, json config) override
 
std::vector< double > Gradient (unsigned int outWrt, unsigned int inWrt, const std::vector< std::vector< double >> &inputs, const std::vector< double > &sens, json config=json()) override
 
std::vector< double > ApplyJacobian (unsigned int outWrt, unsigned int inWrt, const std::vector< std::vector< double >> &inputs, const std::vector< double > &vec, json config=json()) override
 
std::vector< double > ApplyHessian (unsigned int outWrt, unsigned int inWrt1, unsigned int inWrt2, const std::vector< std::vector< double >> &inputs, const std::vector< double > &sens, const std::vector< double > &vec, json config=json()) override
 
bool SupportsEvaluate () override
 
bool SupportsGradient () override
 
bool SupportsApplyJacobian () override
 
bool SupportsApplyHessian () override
 
- Public Member Functions inherited from umbridge::Model
 Model (std::string name)
 
std::string GetName () const
 

Constructor & Destructor Documentation

◆ UMBridgeModPieceWrapper()

muq::Modeling::UMBridgeModPieceWrapper::UMBridgeModPieceWrapper ( std::shared_ptr< muq::Modeling::ModPiece modPiece,
std::string  name 
)
inline

Constructor.

Parameters
modPieceThe ModPiece to wrap.
nameThe name of the model as exposed by UM-Bridge.

Definition at line 19 of file UMBridgeModPieceServer.h.

Member Function Documentation

◆ ApplyHessian()

std::vector<double> muq::Modeling::UMBridgeModPieceWrapper::ApplyHessian ( unsigned int  outWrt,
unsigned int  inWrt1,
unsigned int  inWrt2,
const std::vector< std::vector< double >> &  inputs,
const std::vector< double > &  sens,
const std::vector< double > &  vec,
json  config = json() 
)
inlineoverridevirtual

◆ ApplyJacobian()

std::vector<double> muq::Modeling::UMBridgeModPieceWrapper::ApplyJacobian ( unsigned int  outWrt,
unsigned int  inWrt,
const std::vector< std::vector< double >> &  inputs,
const std::vector< double > &  vec,
json  config = json() 
)
inlineoverridevirtual

◆ Evaluate()

std::vector<std::vector<double> > muq::Modeling::UMBridgeModPieceWrapper::Evaluate ( const std::vector< std::vector< double >> &  inputs,
json  config 
)
inlineoverridevirtual

◆ GetInputSizes()

std::vector<std::size_t> muq::Modeling::UMBridgeModPieceWrapper::GetInputSizes ( const json config_json = json()) const
inlineoverridevirtual

Implements umbridge::Model.

Definition at line 24 of file UMBridgeModPieceServer.h.

References modPiece.

◆ GetOutputSizes()

std::vector<std::size_t> muq::Modeling::UMBridgeModPieceWrapper::GetOutputSizes ( const json config_json = json()) const
inlineoverridevirtual

Implements umbridge::Model.

Definition at line 28 of file UMBridgeModPieceServer.h.

References modPiece.

◆ Gradient()

std::vector<double> muq::Modeling::UMBridgeModPieceWrapper::Gradient ( unsigned int  outWrt,
unsigned int  inWrt,
const std::vector< std::vector< double >> &  inputs,
const std::vector< double > &  sens,
json  config = json() 
)
inlineoverridevirtual

◆ SupportsApplyHessian()

bool muq::Modeling::UMBridgeModPieceWrapper::SupportsApplyHessian ( )
inlineoverridevirtual

Reimplemented from umbridge::Model.

Definition at line 80 of file UMBridgeModPieceServer.h.

◆ SupportsApplyJacobian()

bool muq::Modeling::UMBridgeModPieceWrapper::SupportsApplyJacobian ( )
inlineoverridevirtual

Reimplemented from umbridge::Model.

Definition at line 79 of file UMBridgeModPieceServer.h.

◆ SupportsEvaluate()

bool muq::Modeling::UMBridgeModPieceWrapper::SupportsEvaluate ( )
inlineoverridevirtual

Reimplemented from umbridge::Model.

Definition at line 77 of file UMBridgeModPieceServer.h.

◆ SupportsGradient()

bool muq::Modeling::UMBridgeModPieceWrapper::SupportsGradient ( )
inlineoverridevirtual

Reimplemented from umbridge::Model.

Definition at line 78 of file UMBridgeModPieceServer.h.

Member Data Documentation

◆ modPiece

std::shared_ptr<muq::Modeling::ModPiece> muq::Modeling::UMBridgeModPieceWrapper::modPiece
private

The documentation for this class was generated from the following file: