ml_ParamGrid
import { ml_ParamGrid } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
Native object: release it with using or delete(). Factories can return null; check before calling methods.
The structure represents the logarithmic grid range of statmodel parameters.
It is used for optimizing statmodel accuracy by varying model parameters, the accuracy estimate being computed by cross-validation.
Constructors and members
static create
Creates a ParamGrid Ptr that can be given to the %SVM::trainAuto method
create(minVal: number, maxVal: number, logstep: number): ml_ParamGrid | null;4 available overloads
create(): ml_ParamGrid | null;create(minVal: number): ml_ParamGrid | null;create(minVal: number, maxVal: number): ml_ParamGrid | null;create(minVal: number, maxVal: number, logstep: number): ml_ParamGrid | null;minValminimum value of the parameter grid
maxValmaximum value of the parameter grid
logstepLogarithmic step for iterating the statmodel parameter
The ml_ParamGrid | null result.
clone
Create another handle to the same native object. This retains the object without copying its pixels or algorithm state; dispose both handles separately.
clone(): this;The this result.
minVal
Minimum value of the statmodel parameter. Default value is 0.
minVal: number;maxVal
Maximum value of the statmodel parameter. Default value is 0.
maxVal: number;logStep
Maximum value of the statmodel parameter. Default value is 0. Logarithmic step for iterating the statmodel parameter.
The grid determines the following iteration sequence of the statmodel parameter values:
(minVal, minVal*step, minVal*{step}^2, \dots, minVal*{logStep}^n),
where `n` is the maximal index satisfying
\texttt{minVal} * \texttt{logStep} ^n < \texttt{maxVal}
The grid is logarithmic, so logStep must always be greater than 1. Default value is 1.
logStep: number;These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.