ScanMultipleRidges_Direct


Locates multiple dark or bright pixel peaks along a given path (without a scan map).

Applications:Very fast detection of multiple thin structures like wires or scale marks - usually for counting or distance measurements.

Syntax

C++
C#
Python
 
def ScanMultipleRidges_Direct(
	inImage: Image,
	inScanPath: Path,
	/,
	*,
	inScanPathAlignment: CoordinateSystem2D | None = None,
	inScanWidth: int = 5,
	inSamplingParams: SamplingParams = SamplingParams(InterpolationMethod.Bilinear, 1.0, None),
	inRidgeScanParams: RidgeScanParams = RidgeScanParams(ProfileInterpolationMethod.Quadratic4, 0.6, 5, 2, RidgeOperator.Minimum, 5.0, Polarity.Dark),
	inMinDistance: float = 0.0,
	inMaxDistance: float | None = None,
	inLocalBlindness: LocalBlindness | None = None,
	outAlignedScanPath: Path | None = None,
	outBrightnessProfile: Profile | None = None,
	outResponseProfile: Profile | None = None
)
-> (
	outRidges: list[Ridge1D],
	outGaps: list[Gap1D],
	diagSamplingPoints: list[Path],
	diagSamplingStep: float
)

Parameters

Name Type Range Default Description
Input value inImage Image Input image
Input value inScanPath Path Path along which the scan is performed
Input value inScanPathAlignment CoordinateSystem2D | None None Adjusts the scan path to the position of the inspected object
Input value inScanWidth int 1 - 5 Width of the scan field in pixels
Input value inSamplingParams SamplingParams SamplingParams(InterpolationMethod.Bilinear, 1.0, None) Parameters controlling the sampling process
Input value inRidgeScanParams RidgeScanParams RidgeScanParams(ProfileInterpolationMethod.Quadratic4, 0.6, 5, 2, RidgeOperator.Minimum, 5.0, Polarity.Dark) Parameters controlling the ridge extraction process
Input value inMinDistance float 0.0 - 0.0 Minimal distance between consecutive ridges
Input value inMaxDistance float | None 0.0 - None Maximal distance between consecutive ridges
Input value inLocalBlindness LocalBlindness | None None Defines conditions in which weaker ridges can be detected in the vicinity of stronger ridges
Output value outRidges list[Ridge1D] Found ridges
Output value outGaps list[Gap1D] Gaps between consecutive ridges
Output value outAlignedScanPath Path | None None Transformed input path
Output value outBrightnessProfile Profile | None None Extracted image profile
Output value outResponseProfile Profile | None None Profile of the ridge operator response
Diagnostic input diagSamplingPoints list[Path] Array of paths each one containing the sampling points that contributes to a single value of the extracted profile
Diagnostic input diagSamplingStep float Used distance between consecutive sampling points on the scan path

Hardware Acceleration

This operation is optimized for SSE2 technology for pixels of type: UINT8.

This operation is optimized for AVX2 technology for pixels of type: UINT8.

This operation is optimized for NEON technology for pixels of type: UINT8.

This operation supports automatic parallelization for multicore and multiprocessor systems.