mexopencv
3.4.1
MEX interface for OpenCV library
|
Represents objective function being optimized, implemented as a MATLAB file. More...
Public Member Functions | |
MatlabFunction (int num_dims, const string &func) | |
Constructor. More... | |
double | calc (const double *x) const |
Evaluates MATLAB objective function. More... | |
int | getDims () const |
Return number of dimensions. More... | |
MxArray | toStruct () const |
Convert object to MxArray. More... | |
Public Member Functions inherited from cv::MinProblemSolver::Function | |
virtual | ~Function () |
virtual void | getGradient (const double *x, double *grad) |
virtual double | getGradientEps () const |
Static Public Member Functions | |
static Ptr< MatlabFunction > | create (const MxArray &s) |
Factory function. More... | |
Represents objective function being optimized, implemented as a MATLAB file.
Definition at line 20 of file DownhillSolver_.cpp.
|
inline |
Constructor.
num_dims | number of variables of the objective function |
func | name of an M-file that computes the objective function |
Definition at line 27 of file DownhillSolver_.cpp.
|
inlinevirtual |
Evaluates MATLAB objective function.
[in] | x | input array of length dims |
x
(scalar value)Calculates y = F(x)
, for the scalar-valued multivariate objective function evaluated at the dims
-dimensional point x
Example:
Implements cv::MinProblemSolver::Function.
Definition at line 47 of file DownhillSolver_.cpp.
|
inlinestatic |
Factory function.
s | input MxArray structure with the following fields:
|
Definition at line 101 of file DownhillSolver_.cpp.
|
inlinevirtual |
Return number of dimensions.
Implements cv::MinProblemSolver::Function.
Definition at line 79 of file DownhillSolver_.cpp.
|
inline |
Convert object to MxArray.
Definition at line 87 of file DownhillSolver_.cpp.