WizardAnalyzer ============== Wizard Analyzer for parameter wizard intensity and shape analysis. This module provides analysis functions for the Quick Select Parameters wizard, including intensity distribution analysis and shape estimation. Classes ------- .. py:class:: WizardAnalyzer Analyzes collected samples for the parameter wizard. This class provides methods to analyze foreground and background intensity distributions and estimate shape characteristics from sampled points. **Methods:** .. py:method:: analyze_intensities() Analyze foreground and background intensity distributions. .. py:method:: analyze_shape() Analyze structure shape from sampled points. .. py:method:: estimate_boundary_roughness() Estimate boundary roughness from traced points. Functions --------- .. py:function:: analyze_intensities() Analyze foreground and background intensity distributions. Args: samples: WizardSamples containing foreground and background data. Returns: IntensityAnalysisResult with distribution statistics and thresholds. Raises: ValueError: If samples are missing foreground or background data. .. py:function:: analyze_shape() Analyze structure shape from sampled points. Args: samples: WizardSamples containing foreground points and/or boundary points. spacing_mm: Voxel spacing in mm (x, y, z). Returns: ShapeAnalysisResult with shape characteristics. .. py:function:: estimate_boundary_roughness() Estimate boundary roughness from traced points. Analyzes the deviation of boundary points from a smooth curve. For smooth curves (circles, ellipses), the curvature is consistent. For rough boundaries, curvature varies significantly. Args: boundary_points: List of (x, y, z) boundary coordinates. Returns: Roughness from 0 (smooth) to 1 (rough).