union_collinear_contours_ext_xldunion_collinear_contours_ext_xldUnionCollinearContoursExtXldUnionCollinearContoursExtXldunion_collinear_contours_ext_xld (Operator)
Name
union_collinear_contours_ext_xldunion_collinear_contours_ext_xldUnionCollinearContoursExtXldUnionCollinearContoursExtXldunion_collinear_contours_ext_xld — Vereinigen von kollinearen Konturen (Operator mit erweitertem
Funktionsumfang).
Signatur
union_collinear_contours_ext_xld(Contours : UnionContours : MaxDistAbs, MaxDistRel, MaxShift, MaxAngle, MaxOverlap, MaxRegrError, MaxCosts, WeightDist, WeightShift, WeightAngle, WeightLink, WeightRegr, Mode : )
Herror union_collinear_contours_ext_xld(const Hobject Contours, Hobject* UnionContours, double MaxDistAbs, double MaxDistRel, double MaxShift, double MaxAngle, double MaxOverlap, double MaxRegrError, double MaxCosts, double WeightDist, double WeightShift, double WeightAngle, double WeightLink, double WeightRegr, const char* Mode)
Herror T_union_collinear_contours_ext_xld(const Hobject Contours, Hobject* UnionContours, const Htuple MaxDistAbs, const Htuple MaxDistRel, const Htuple MaxShift, const Htuple MaxAngle, const Htuple MaxOverlap, const Htuple MaxRegrError, const Htuple MaxCosts, const Htuple WeightDist, const Htuple WeightShift, const Htuple WeightAngle, const Htuple WeightLink, const Htuple WeightRegr, const Htuple Mode)
void UnionCollinearContoursExtXld(const HObject& Contours, HObject* UnionContours, const HTuple& MaxDistAbs, const HTuple& MaxDistRel, const HTuple& MaxShift, const HTuple& MaxAngle, const HTuple& MaxOverlap, const HTuple& MaxRegrError, const HTuple& MaxCosts, const HTuple& WeightDist, const HTuple& WeightShift, const HTuple& WeightAngle, const HTuple& WeightLink, const HTuple& WeightRegr, const HTuple& Mode)
HXLDCont HXLDCont::UnionCollinearContoursExtXld(double MaxDistAbs, double MaxDistRel, double MaxShift, double MaxAngle, double MaxOverlap, double MaxRegrError, double MaxCosts, double WeightDist, double WeightShift, double WeightAngle, double WeightLink, double WeightRegr, const HString& Mode) const
HXLDCont HXLDCont::UnionCollinearContoursExtXld(double MaxDistAbs, double MaxDistRel, double MaxShift, double MaxAngle, double MaxOverlap, double MaxRegrError, double MaxCosts, double WeightDist, double WeightShift, double WeightAngle, double WeightLink, double WeightRegr, const char* Mode) const
HXLDCont HXLDCont::UnionCollinearContoursExtXld(double MaxDistAbs, double MaxDistRel, double MaxShift, double MaxAngle, double MaxOverlap, double MaxRegrError, double MaxCosts, double WeightDist, double WeightShift, double WeightAngle, double WeightLink, double WeightRegr, const wchar_t* Mode) const
(
Nur Windows)
static void HOperatorSet.UnionCollinearContoursExtXld(HObject contours, out HObject unionContours, HTuple maxDistAbs, HTuple maxDistRel, HTuple maxShift, HTuple maxAngle, HTuple maxOverlap, HTuple maxRegrError, HTuple maxCosts, HTuple weightDist, HTuple weightShift, HTuple weightAngle, HTuple weightLink, HTuple weightRegr, HTuple mode)
HXLDCont HXLDCont.UnionCollinearContoursExtXld(double maxDistAbs, double maxDistRel, double maxShift, double maxAngle, double maxOverlap, double maxRegrError, double maxCosts, double weightDist, double weightShift, double weightAngle, double weightLink, double weightRegr, string mode)
def union_collinear_contours_ext_xld(contours: HObject, max_dist_abs: float, max_dist_rel: float, max_shift: float, max_angle: float, max_overlap: float, max_regr_error: float, max_costs: float, weight_dist: float, weight_shift: float, weight_angle: float, weight_link: float, weight_regr: float, mode: str) -> HObject
Beschreibung
Wie der Operator union_collinear_contours_xldunion_collinear_contours_xldUnionCollinearContoursXldUnionCollinearContoursXldunion_collinear_contours_xld vereinigt
union_collinear_contours_ext_xldunion_collinear_contours_ext_xldUnionCollinearContoursExtXldUnionCollinearContoursExtXldunion_collinear_contours_ext_xld aus einer Menge von
geraden, linienförmige Konturen (ContoursContoursContourscontourscontours) diejenigen
miteinander, die zueinander kollinear sind, und gibt das Ergebnis in
UnionContoursUnionContoursUnionContoursunionContoursunion_contours zurück.
Das grundsätzliche Verhalten ist identisch zu
union_collinear_contours_xldunion_collinear_contours_xldUnionCollinearContoursXldUnionCollinearContoursXldunion_collinear_contours_xld und wird dort beschrieben, es
stehen jedoch zahlreiche weitere Parameter zur Verfügung, die es
erlauben, den Vereinigungsprozess genauer zu steuern.
Parameter
Die Parameter MaxDistAbsMaxDistAbsMaxDistAbsmaxDistAbsmax_dist_abs, MaxDistRelMaxDistRelMaxDistRelmaxDistRelmax_dist_rel,
MaxShiftMaxShiftMaxShiftmaxShiftmax_shift und MaxAngleMaxAngleMaxAnglemaxAnglemax_angle sind identisch wie wie beim Operator
union_collinear_contours_xldunion_collinear_contours_xldUnionCollinearContoursXldUnionCollinearContoursXldunion_collinear_contours_xld beschrieben.
MaxOverlapMaxOverlapMaxOverlapmaxOverlapmax_overlap
-
Zusätzlich lässt sich hier mit MaxOverlapMaxOverlapMaxOverlapmaxOverlapmax_overlap ein
Überlappungsbereich zwischen beiden Konturen definieren, so dass
auch Konturen, die sich (geringfügig) überlappen, miteinander
vereinigt werden können.
Intern wird dabei sichergestellt, dass sich -- unabhängig von dem
mit MaxOverlapMaxOverlapMaxOverlapmaxOverlapmax_overlap übergebenen Parameter -- die Konturen nicht
um mehr als ein Drittel ihrer Länge überlappen.
MaxRegrErrorMaxRegrErrorMaxRegrErrormaxRegrErrormax_regr_error
-
Der Parameter MaxRegrErrorMaxRegrErrorMaxRegrErrormaxRegrErrormax_regr_error wird z.Zt. noch nicht
verwendet.
Er soll später sicherstellen, dass nach der Vereinigung zweier
Konturen die resultierende Kontur nicht zu stark von ihrer
Regressionsgeraden abweicht.
Dieser Wert ist defaultmäßig ausgeschaltet (-1), da er
unter normalen Bedingungen nicht notwendig und der Rechenaufwand
sehr hoch ist.
Unter bestimmten Bedingungen können jedoch Ergebniskonturen
entstehen, die relativ stark um ihre Regressionsgerade schwanken
(„wellige“ Eingangskonturen, Shift und Winkeldifferenz nah an den
-- relativ hoch eingestellten -- Grenzen, rekursive Vereinigung sehr
vieler kurzer Konturen).
MaxCostsMaxCostsMaxCostsmaxCostsmax_costs
-
Mit dem Parameter MaxCostsMaxCostsMaxCostsmaxCostsmax_costs ist es möglich, die Gesamtkosten
der Vereinigung zu begrenzen und so nicht nur die Vereinigung der
Konturpaare auszuschließen, die in einer Disziplin die vorgegebenen
Grenzwerte überschreiten, sondern auch jener, die in mehreren
Disziplinen die Grenzen nur knapp einhalten können.
Dabei werden die Kosten immer auf einen Wert zwischen 0 und 1
normiert, der Wert 1 bedeutet dabei, dass alle Werte auf dem
jeweiligen Grenzwert liegen.
WeightDistWeightDistWeightDistweightDistweight_dist, WeightShiftWeightShiftWeightShiftweightShiftweight_shift, WeightAngleWeightAngleWeightAngleweightAngleweight_angle,
WeightLinkWeightLinkWeightLinkweightLinkweight_link und WeightRegrWeightRegrWeightRegrweightRegrweight_regr
-
Der Einfluss der verschiedenen Messwerte auf die Gesamtkosten wird
durch die Übergabe einer entsprechenden Gewichtung mit Hilfe der
Parameter WeightDistWeightDistWeightDistweightDistweight_dist, WeightShiftWeightShiftWeightShiftweightShiftweight_shift,
WeightAngleWeightAngleWeightAngleweightAngleweight_angle, WeightLinkWeightLinkWeightLinkweightLinkweight_link und WeightRegrWeightRegrWeightRegrweightRegrweight_regr
eingestellt.
Dabei ist zu beachten, dass die Gesamtkosten immer auf 1 normiert
werden.
Der Parameter WeightRegrWeightRegrWeightRegrweightRegrweight_regr wird z.Zt. nicht verwendet.
ModeModeModemodemode
-
Der Parameter ModeModeModemodemode steuert -- wie beim Operator
union_collinear_contours_xldunion_collinear_contours_xldUnionCollinearContoursXldUnionCollinearContoursXldunion_collinear_contours_xld -- die Behandlung der Attribute
der Eingabekontur.
Ausführungsinformationen
- Multithreading-Typ: reentrant (läuft parallel zu nicht-exklusiven Operatoren).
- Multithreading-Bereich: global (kann von jedem Thread aufgerufen werden).
- Wird ohne Parallelisierung verarbeitet.
Parameter
ContoursContoursContourscontourscontours (input_object) xld_cont-array → objectHXLDContHObjectHObjectHobject
Eingabe-Konturen.
UnionContoursUnionContoursUnionContoursunionContoursunion_contours (output_object) xld_cont-array → objectHXLDContHObjectHObjectHobject *
Ausgabe-Konturen.
MaxDistAbsMaxDistAbsMaxDistAbsmaxDistAbsmax_dist_abs (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Maximaler Abstand der Endpunkte in Richtung der
Referenzregressionsgeraden.
Default:
10.0
Wertebereich:
0.0
≤
MaxDistAbs
MaxDistAbs
MaxDistAbs
maxDistAbs
max_dist_abs
MaxDistRelMaxDistRelMaxDistRelmaxDistRelmax_dist_rel (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Maximaler Abstand der Endpunkte in Richtung der
Referenzregressionsgeraden relativ zur Länge der zu
verlängernden Kontur.
Default:
1.0
Wertebereich:
0.0
≤
MaxDistRel
MaxDistRel
MaxDistRel
maxDistRel
max_dist_rel
MaxShiftMaxShiftMaxShiftmaxShiftmax_shift (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Maximaler Abstand der Konturen von der
Referenzregressionsgeraden.
Default:
2.0
Wertebereich:
0.0
≤
MaxShift
MaxShift
MaxShift
maxShift
max_shift
MaxAngleMaxAngleMaxAnglemaxAnglemax_angle (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Maximale Richtungsdifferenz.
Default:
0.1
Wertebereich:
0.0
≤
MaxAngle
MaxAngle
MaxAngle
maxAngle
max_angle
≤
0.78539816339
MaxOverlapMaxOverlapMaxOverlapmaxOverlapmax_overlap (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Maximal erlaubter Überlappungsbereich.
Default:
0.0
Wertebereich:
0.0
≤
MaxOverlap
MaxOverlap
MaxOverlap
maxOverlap
max_overlap
MaxRegrErrorMaxRegrErrorMaxRegrErrormaxRegrErrormax_regr_error (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Maximaler Regressionsfehler der resultierenden Konturen
(NICHT BENUTZT).
Default:
-1.0
MaxCostsMaxCostsMaxCostsmaxCostsmax_costs (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Schwellenwert zum Begrenzen der Gesamtkosten der
Vereinigung
Default:
1.0
Wertebereich:
0.0
≤
MaxCosts
MaxCosts
MaxCosts
maxCosts
max_costs
WeightDistWeightDistWeightDistweightDistweight_dist (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Einfluss des Abstandes in Linienrichtung auf die
Gesamtkosten.
Default:
1.0
Wertebereich:
0.0
≤
WeightDist
WeightDist
WeightDist
weightDist
weight_dist
WeightShiftWeightShiftWeightShiftweightShiftweight_shift (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Einfluss des Abstandes von der Regressionsgeraden auf
die Gesamtkosten.
Default:
1.0
Wertebereich:
0.0
≤
WeightShift
WeightShift
WeightShift
weightShift
weight_shift
WeightAngleWeightAngleWeightAngleweightAngleweight_angle (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Einfluss der Winkeldifferenz auf die Gesamtkosten.
Default:
1.0
Wertebereich:
0.0
≤
WeightAngle
WeightAngle
WeightAngle
weightAngle
weight_angle
WeightLinkWeightLinkWeightLinkweightLinkweight_link (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Einfluss von Störungen der Linie durch das
Verbindungsstück (Überlappung und Winkelabweichung)
auf die Gesamtkosten.
Default:
1.0
Wertebereich:
0.0
≤
WeightLink
WeightLink
WeightLink
weightLink
weight_link
WeightRegrWeightRegrWeightRegrweightRegrweight_regr (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Einfluss von Regressionsfehlern der resultierenden
Kontur auf die Gesamtkosten (NICHT BENUTZT).
Default:
0.0
Wertebereich:
0.0
≤
WeightRegr
WeightRegr
WeightRegr
weightRegr
weight_regr
ModeModeModemodemode (input_control) string → HTuplestrHTupleHtuple (string) (string) (HString) (char*)
Modus für die Behandlung der Konturattribute
Default:
'attr_keep'
"attr_keep"
"attr_keep"
"attr_keep"
"attr_keep"
Werteliste:
'attr_forget'"attr_forget""attr_forget""attr_forget""attr_forget", 'attr_keep'"attr_keep""attr_keep""attr_keep""attr_keep"
Vorgänger
split_contours_xldsplit_contours_xldSplitContoursXldSplitContoursXldsplit_contours_xld,
select_contours_xldselect_contours_xldSelectContoursXldSelectContoursXldselect_contours_xld
Alternativen
union_collinear_contours_xldunion_collinear_contours_xldUnionCollinearContoursXldUnionCollinearContoursXldunion_collinear_contours_xld,
union_cocircular_contours_xldunion_cocircular_contours_xldUnionCocircularContoursXldUnionCocircularContoursXldunion_cocircular_contours_xld,
union_cotangential_contours_xldunion_cotangential_contours_xldUnionCotangentialContoursXldUnionCotangentialContoursXldunion_cotangential_contours_xld,
union_adjacent_contours_xldunion_adjacent_contours_xldUnionAdjacentContoursXldUnionAdjacentContoursXldunion_adjacent_contours_xld,
union_straight_contours_xldunion_straight_contours_xldUnionStraightContoursXldUnionStraightContoursXldunion_straight_contours_xld
Siehe auch
edges_sub_pixedges_sub_pixEdgesSubPixEdgesSubPixedges_sub_pix,
threshold_sub_pixthreshold_sub_pixThresholdSubPixThresholdSubPixthreshold_sub_pix,
gen_polygons_xldgen_polygons_xldGenPolygonsXldGenPolygonsXldgen_polygons_xld,
split_contours_xldsplit_contours_xldSplitContoursXldSplitContoursXldsplit_contours_xld,
select_contours_xldselect_contours_xldSelectContoursXldSelectContoursXldselect_contours_xld,
get_contour_xldget_contour_xldGetContourXldGetContourXldget_contour_xld,
get_contour_attrib_xldget_contour_attrib_xldGetContourAttribXldGetContourAttribXldget_contour_attrib_xld
Modul
Foundation