6 ModPiece(inputSizes, Eigen::VectorXi::Ones(1))
16 unsigned int const inputDimWrt,
18 Eigen::VectorXd
const& sensitivity)
24 unsigned int const inputDimWrt,
32 unsigned int const inputDimWrt,
34 Eigen::VectorXd
const& vec)
40 unsigned int const inWrt1,
41 unsigned int const inWrt2,
43 Eigen::VectorXd
const& sens,
44 Eigen::VectorXd
const& vec)
58 return dist->LogDensity(inputs);
63 return dist->GradLogDensityImpl(wrt, inputs);
68 return dist->SampleImpl(inputs);
72 unsigned int const inWrt2,
74 Eigen::VectorXd
const& vec)
76 return dist->ApplyLogDensityHessianImpl(inWrt1,inWrt2,input,vec);
81 Eigen::VectorXi output(1+distIn->hyperSizes.size());
82 output(0) = distIn->varSize;
83 output.tail(distIn->hyperSizes.size()) = distIn->hyperSizes;
virtual void JacobianImpl(unsigned int const outputDimWrt, unsigned int const inputDimWrt, ref_vector< Eigen::VectorXd > const &input) override
virtual void ApplyJacobianImpl(unsigned int const outputDimWrt, unsigned int const inputDimWrt, ref_vector< Eigen::VectorXd > const &input, Eigen::VectorXd const &vec) override
virtual void ApplyHessianImpl(unsigned int const outWrt, unsigned int const inWrt1, unsigned int const inWrt2, ref_vector< Eigen::VectorXd > const &input, Eigen::VectorXd const &sens, Eigen::VectorXd const &vec) override
virtual void GradientImpl(unsigned int const outputDimWrt, unsigned int const inputDimWrt, ref_vector< Eigen::VectorXd > const &input, Eigen::VectorXd const &sensitivity) override
DensityBase(Eigen::VectorXi const &inputSizes)
virtual void EvaluateImpl(ref_vector< Eigen::VectorXd > const &inputs) override
static Eigen::VectorXi GetInputSizes(std::shared_ptr< Distribution > distIn)
virtual Eigen::VectorXd GradLogDensityImpl(unsigned int wrt, ref_vector< Eigen::VectorXd > const &inputs) override
virtual Eigen::VectorXd SampleImpl(ref_vector< Eigen::VectorXd > const &inputs) override
Sample the distribution.
std::shared_ptr< Distribution > dist
virtual double LogDensityImpl(ref_vector< Eigen::VectorXd > const &inputs) override
Implement the log-density.
virtual Eigen::VectorXd ApplyLogDensityHessianImpl(unsigned int const inWrt1, unsigned int const inWrt2, ref_vector< Eigen::VectorXd > const &input, Eigen::VectorXd const &vec) override
virtual Eigen::VectorXd ApplyLogDensityHessian(unsigned int const inWrt1, unsigned int const inWrt2, ref_vector< Eigen::VectorXd > const &input, Eigen::VectorXd const &vec)
virtual double LogDensity(ref_vector< Eigen::VectorXd > const &inputs)
Evaluate the log-density.
virtual Eigen::VectorXd GradLogDensity(unsigned int wrt, std::vector< Eigen::VectorXd > const &inputs)
Provides an abstract interface for defining vector-valued model components.
const Eigen::VectorXi inputSizes
std::vector< Eigen::VectorXd > outputs
Eigen::VectorXd hessAction
Eigen::VectorXd jacobianAction
std::vector< std::reference_wrapper< const T > > ref_vector
A vector of references to something ...