src.eval.simple_curve_evaluation

Classes

SimpleCurveEvaluation(**kwargs)

class src.eval.simple_curve_evaluation.SimpleCurveEvaluation(**kwargs)
Author:

Alberto M. Esmoris Pena

Class representing the result of a SimpleCurveEvaluator. Holds the five quality KPIs (Coverage, Deviation, Hallucination, Self-intersections, Gaps) plus the structured data needed to render reports and plots.

See SimpleCurveEvaluator.

Variables:
  • coverage_pct (float) – Coverage percentage (3D, %).

  • deviation_pct (float) – Deviation percentage (3D, %), length-anchored over the extracted polyline 3D arc. The polyline length is “deviating” where it has no curve-class input neighbour within hallucination_radius but at least one any-class input neighbour within hallucination_radius. Partitions cleanly with hallucination_pct: deviation_length + pure_hallucination_length = hallucination_length.

  • hallucination_pct (float) – Length-weighted hallucination percentage (3D, %).

  • n_hallucinated_features (int) – Count of features whose per-feature score exceeds the threshold.

  • n_features_scored (int) – Count of features scored for hallucination (those with at least 2 vertices and a positive 3D arc length).

  • per_feature_hallucination (list of tuple) – List of tuples (fi, score, hall_len, feat_len) for every scored feature.

  • n_self_intersections (int) – Total count of 2D self-intersections within the same CURVE_ID.

  • n_gaps (int) – Total count of 2D endpoint-to-endpoint gaps within the same CURVE_ID.

  • n_t_junctions (int) – Count of pairs filtered out as T-junctions; always 0 when exclude_t_junctions=False.

  • n_isolated (int) – Curve-class points that have no input neighbour within deviation_radius. Reported as a context KPI separate from deviation_pct (the length-anchored deviation no longer subtracts isolated points from any denominator).

  • n_curve_points (int) – Number of input curve-class points.

  • n_features (int) – Number of features in the shapefile.

  • n_curve_ids (int) – Number of distinct CURVE_ID values.

  • n_dense_points (int) – Number of densified polyline vertices used by the coverage tree.

  • self_intersection_grid_cell (float) – Cell size (m) used by the self-intersection grid index. Recorded for traceability.

  • self_intersection_eps (float) – Parametric-interval tolerance used in the segment-crossing test. Recorded for traceability.

  • self_intersection_parallel_threshold (float) – Cross-product magnitude threshold below which two segments are treated as parallel. Recorded for traceability.

  • degenerate_segment_length (float) – Minimum 3D segment length used by the densifier. Recorded for traceability.

__init__(**kwargs)

Initialize a SimpleCurveEvaluation.

Parameters:

kwargs – The attributes for the evaluation.

report(**kwargs)

Transform the SimpleCurveEvaluation into a SimpleCurveReport.

Returns:

The associated report.

Return type:

SimpleCurveReport

can_report()

See Evaluation.can_report().

plot(**kwargs)

Transform the SimpleCurveEvaluation into a SimpleCurvePlot.

Returns:

The associated plot object.

Return type:

SimpleCurvePlot

can_plot()

See Evaluation.can_plot().