AI Classification (Front/Back or Presence/Absence) Tool

You are currently viewing the documentation for a pre-release version (2.2.0). To access documentation for other versions, click the "Switch Version" button located in the upper-right corner of the page.

■ If you're unsure about the version of the product you are using, please contact Mech-Mind Technical Support for assistance.

Function Introduction

The AI Classification (Front/Back or Presence/Absence) Tool is an efficient visual binary-classification tool for custom training with two classes: OK and NG. By following a wizard workflow, you can quickly complete the full process from image acquisition to model inference. Typical scenarios include front/back error-proofing and presence/absence detection for a single workpiece type.

overall workflow
  1. Capture Images: Capture image data for training. Include representative production conditions and keep image quality and diversity high.

  2. Set Target Region: Set ROI on captured images and accurately frame target region for labeling and training.

  3. Label Images: Label target regions as OK or NG. Label diverse samples for each class.

  4. Train and Validate Model: Train with labeled images, validate results, and perform additional training if needed until model performance meets requirements.

Workflow

After opening the tool, click New at the upper-right of the model list to create a new model workflow.

Capture Images

  1. Ensure the input port of current step is connected to image data.

  2. When the tool opens, one image is captured automatically. Click Capture Image to capture additional images.

When capturing images, cover typical production variations:

  • Position and angle changes: translation, rotation, and tilt of workpieces.

  • Lighting and background changes: brightness, shadows, and background complexity.

  • Appearance changes: slight deformation, stains, scratches, and batch color differences.

Diverse images improve model robustness and judgment accuracy.

Set Target Region

After capturing images, set ROI for labeling and training.

If input exists on the 2D Alignment Parameter Group port, ROI is transformed synchronously with target poses. The ROI configured here is the reference ROI, and runtime ROI is dynamically offset by alignment parameters.

  1. Click Edit to open target-region settings.

  2. Set target region with rectangle or circle selection tools.

  3. Optionally set mask region to exclude glare, shadow, or fixed background interference.

  4. Click Save and Use to apply region configuration.

  • You can frame only key-feature areas.

  • If multiple ROIs are required manually, create one ROI first and then duplicate it to keep sizes consistent.

  • If 2D Alignment Parameter Group is provided, usually one ROI is enough and additional ROIs are generated automatically.

If target and mask layers completely overlap, only the top layer is editable.

Right-click to quickly copy, paste, delete, bring to front, or send to back.

Label Images

  1. Click Edit to enter labeling.

  2. Select target ROI and click Label Image for class OK or NG.

  3. Capture more images and repeat labeling.

The tool uses fixed classes OK and NG. You can define business meaning as needed, for example:

  • OK: front side or present.

  • NG: back side or absent.

  • Label both classes and cover varied conditions (offsets, stains, scratches, deformation, tone/background changes).

  • Avoid ambiguous samples.

  • If lighting or angle varies greatly, enable advanced options such as brightness/rotation adaptation to augment data.

  1. Click Save and Use after labeling.

Train and Validate Model

  1. Train model: Click Train and wait for completion.

  2. Validate model: Click Validate and review or set these parameters:

Parameter Description

Validation Result

Shows judgment result (OK/NG).

Time Cost

Inference time per run (ms).

Confidence Threshold

Minimum confidence for OK. Results lower than threshold are judged as NG.

Default value: 0.5

Judgment Mode

For multiple ROIs:

* All OK: result is OK only when all ROIs are OK. * At Least One OK: result is OK when any ROI is OK.

Default value: All OK.

Heatmap

Displays model attention regions on image when enabled.

Default value: Disabled.

  1. Additional training (optional): If validation is unsatisfactory, click Additional Training, label misclassified/missing samples, save, and retrain. Repeat train-validate-additional-training cycle until expected performance is reached.

Additional training is incremental optimization on top of current model, not retraining from scratch.

  1. Save and apply model: Click Save and Use. After closing the tool, select this model in Model Name parameter to use it in inference steps.

Is this page helpful?

You can give a feedback in any of the following ways:

We Value Your Privacy

We use cookies to provide you with the best possible experience on our website. By continuing to use the site, you acknowledge that you agree to the use of cookies. If you decline, a single cookie will be used to ensure you're not tracked or remembered when you visit this website.