Unsupervised Segmentation
Function Introduction
By performing inference on input images with an unsupervised segmentation model package, the model learns normal patterns from OK samples and automatically classifies images as OK, NG, or Unknown without defect annotations, while generating heatmaps and masks of defect regions.
It is suitable for industrial quality-inspection scenarios where defect shape, position, and size are uncertain, while differences among OK images are small.
Input and Output
After this model package is imported in the Deep Learning Model Package Inference step, the following input and output ports are displayed.
Input
| Input Port | Data Type | Description |
|---|---|---|
Image |
Image/Color |
Images entered at this port are used for deep learning model package inference. |
Output
| Output Port | Data Type | Description |
|---|---|---|
Visualization Output |
Image/Color |
Visualization result. |
Segmentation Result |
String |
Defect label. |
Segmented Mask Image |
Image/Color/Mask |
Segmentation mask result. Regions with non-zero pixel values are detected defects. |
Segmented Mask Contour |
Shape2D/Contour[] |
Pixel-coordinate list of segmentation-mask vertices. |
Parameter Description
When an unsupervised segmentation model package is imported, configure the following parameters for this step.
Model Package Settings
- Model Manager Tool
-
Parameter description: This parameter is used to open the deep learning model package management tool and import the deep learning model package. The model package file is a “.dlkpack” or “.dlkpackC” file exported from Mech-DLK.
Tuning instruction: Please refer to Deep Learning Model Package Management Tool for the usage.
- Model Name
-
Parameter description: This parameter is used to select the model package that has been imported for this Step.
Tuning instruction: Once you have imported the deep learning model package, you can select the corresponding model name in the drop-down list.
- DI Algo Type Translated String
-
Parameter description: Once a Model Name is selected, the DI Algo Type Translated String will be filled automatically.
- GPU ID
-
Parameter description: This parameter is used to select the device ID of the GPU that will be used for the inference.
Tuning instruction: Once you have selected the model name, you can select the GPU ID in the drop-down list of this parameter.
Pre-Process
- ROI Path
-
Parameter description: This parameter is used to set or modify the ROI.
Tuning instruction: Once the deep learning model is imported, a default ROI will be applied. If you need to edit the ROI, click Open the editor. Edit the ROI in the pop-up Set ROI window, and fill in the ROI name.
|
Before the inference, please check whether the ROI set here is consistent with the one set in Mech-DLK. If not, the recognition result may be affected. During the inference, the ROI set during model training, i.e. the default ROI, is usually used. If the position of the object changes in the camera’s field of view, please adjust the ROI. |
|
If you would like to use the default ROI again, please delete the ROI file name below the Open the editor button. |
Post-Processing
| Parameter | Description |
|---|---|
Inference Configuration |
Description: Configures related parameters for unsupervised segmentation model package inference. Click Open Editor to open the Inference Configuration window. Adjustment instruction: For related parameter descriptions, refer to Inference Configuration Tool. |
Visualization Settings
- Customize Font Size
-
Parameter description: This parameter determines whether to customize the font size in the visualized outputs. Once this option is selected, you should set the Font Size (0–10).
Default value: Unselected.
Tuning recommendation: Please set this parameter according to your actual needs.