Skip to content

get_regress_params_xldGetRegressParamsXldGetRegressParamsXldget_regress_params_xldT_get_regress_params_xld🔗

Short description🔗

get_regress_params_xldGetRegressParamsXldGetRegressParamsXldget_regress_params_xldT_get_regress_params_xld — Return XLD contour parameters.

Signature🔗

get_regress_params_xld( xld_cont Contours, out integer Length, out point.x Nx, out point.y Ny, out number Dist, out point.x Fpx, out point.y Fpy, out point.x Lpx, out point.y Lpy, out real Mean, out real Deviation )void GetRegressParamsXld( const HObject& Contours, HTuple* Length, HTuple* Nx, HTuple* Ny, HTuple* Dist, HTuple* Fpx, HTuple* Fpy, HTuple* Lpx, HTuple* Lpy, HTuple* Mean, HTuple* Deviation )static void HOperatorSet.GetRegressParamsXld( HObject contours, out HTuple length, out HTuple nx, out HTuple ny, out HTuple dist, out HTuple fpx, out HTuple fpy, out HTuple lpx, out HTuple lpy, out HTuple mean, out HTuple deviation )def get_regress_params_xld( contours: HObject ) -> Tuple[Sequence[int], Sequence[float], Sequence[float], Sequence[float], Sequence[float], Sequence[float], Sequence[float], Sequence[float], Sequence[float], Sequence[float]]

Herror T_get_regress_params_xld( const Hobject Contours, Htuple* Length, Htuple* Nx, Htuple* Ny, Htuple* Dist, Htuple* Fpx, Htuple* Fpy, Htuple* Lpx, Htuple* Lpy, Htuple* Mean, Htuple* Deviation )

HTuple HXLDCont::GetRegressParamsXld( HTuple* Nx, HTuple* Ny, HTuple* Dist, HTuple* Fpx, HTuple* Fpy, HTuple* Lpx, HTuple* Lpy, HTuple* Mean, HTuple* Deviation ) const

HTuple HXLDCont.GetRegressParamsXld( out HTuple nx, out HTuple ny, out HTuple dist, out HTuple fpx, out HTuple fpy, out HTuple lpx, out HTuple lpy, out HTuple mean, out HTuple deviation )

Description🔗

get_regress_params_xldGetRegressParamsXld returns the following parameters for all XLD contours given in Contourscontourscontours:

  • the number of contour points Lengthlengthlength,

  • the coordinates Nxnxnx and Nynyny of the normal vector of the regression line (i.e., least-squares approximating line),

  • the distance Distdistdist of the regression line to the origin

  • the sub-pixel precise coordinates Fpxfpxfpx and Fpyfpyfpy of the perpendicular projection of the start point of the contour onto the regression line,

  • the sub-pixel precise coordinates Lpxlpxlpx and Lpylpylpy of the perpendicular projection of the end point of the contour onto the regression line,

  • the mean of the Euclidean distance of the contour points from the regression line,

  • the standard deviation of these distances.

Attention🔗

Before the contour parameters can be returned by get_regress_params_xldGetRegressParamsXld, the parameters of the regression line to the contour must be calculated by calling regress_contours_xldRegressContoursXld.

Execution information🔗

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

Parameters🔗

Contourscontourscontours (input_object) xld_cont-array → objectHObjectHXLDContHObjectHobject

Input XLD contours.

Lengthlengthlength (output_control) integer-array → (integer)HTuple (Hlong)HTuple (int / long)Sequence[int]Htuple (Hlong)

Number of contour points.

Nxnxnx (output_control) point.x-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

X-coordinate of the normal vector of the regression line.

Nynyny (output_control) point.y-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

Y-coordinate of the normal vector of the regression line.

Distdistdist (output_control) number-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

Distance of the regression line from the origin.

Fpxfpxfpx (output_control) point.x-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

X-coordinate of the projection of the start point of the contour onto the regression line.

Fpyfpyfpy (output_control) point.y-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

Y-coordinate of the projection of the start point of the contour onto the regression line.

Lpxlpxlpx (output_control) point.x-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

X-coordinate of the projection of the end point of the contour onto the regression line.

Lpylpylpy (output_control) point.y-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

Y-coordinate of the projection of the end point of the contour onto the regression line.

Meanmeanmean (output_control) real-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

Mean distance of the contour points from the regression line.

Deviationdeviationdeviation (output_control) real-array → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)

Standard deviation of the distances from the regression line.

Combinations with other operators🔗

Combinations

Possible predecessors

regress_contours_xldRegressContoursXld

Possible successors

disp_lineDispLine, line_orientationLineOrientation

See also

fit_line_contour_xldFitLineContourXld, get_contour_global_attrib_xldGetContourGlobalAttribXld, query_contour_global_attribs_xldQueryContourGlobalAttribsXld, get_contour_xldGetContourXld, get_contour_attrib_xldGetContourAttribXld, gen_contours_skeleton_xldGenContoursSkeletonXld, lines_gaussLinesGauss, lines_facetLinesFacet, edges_sub_pixEdgesSubPix

Module🔗

Foundation