dodal.devices.oav.pin_image_recognition.utils.MxSampleDetect#
- class dodal.devices.oav.pin_image_recognition.utils.MxSampleDetect[source]#
Configures sample detection parameters.
- Parameters:
preprocess (
Callable[[ndarray],ndarray], default:<function MxSampleDetect.<lambda> at 0x7f6f782e7ce0>) – A preprocessing function applied to the array after conversion to grayscale. See implementations of common functions above for predefined conversions Defaults to a no-op (i.e. no preprocessing)operations (for open and close) – https://docs.opencv.org/4.x/d9/d61/tutorial_py_morphological_ops.html
read (please) – https://docs.opencv.org/4.x/d9/d61/tutorial_py_morphological_ops.html
open_ksize (
int, default:0) – kernel size for “open” operation, if set to zero then ignore “open” operationopen_iterations (
int, default:5) – number of iterations for “open” operationcanny_upper (
int, default:100) – upper threshold for canny edge detectioncanny_lower (
int, default:50) – lower threshold for canny edge detectionclose_ksize (
int, default:5) – kernel size for “close” operationclose_iterations (
int, default:5) – number of iterations for “close” operationscan_direction (
ScanDirections, default:<ScanDirections.FORWARD: 1>) – ScanDirections.FORWARD for left-to-right, ScanDirections.REVERSE for right-to-leftmin_tip_height (
int, default:5) – minimum height of pin tip
Methods
process_array(arr)