Train Your First Model

You are viewing an old version of the documentation. You can switch to the documentation of the latest version by clicking the top-right corner of the page.

This section shows how to train and export an example deep learning model that can be used for defect segmentation. The data used for training is from an image dataset of Ethernet ports.

Preparation

Click here to download the image data and unzip the file.

Training Process

flow chart
  1. Create a New Project: Click New Project in the interface, name the project, and select a directory to save the project.

    new project
    Do NOT include Chinese characters in the path name.
  2. Add the Defect Segmentation Module: Click icon create to add a module. Select Defect Segmentation and then click the OK button.

    add new module
  3. Import Image Data: Click Import in the upper left corner, select Folder and import the image dataset you have downloaded.

    import images
    • Image: Import image(s).

    • Folder: Import all images from the selected folder.

    • Dataset: A dataset contains images and corresponding labels. You can generate one by clicking File  Export Dataset.

  4. Labeling: In this example, you will need to label the OK images and NG images in each dataset. OK means that the connectors meet quality requirements and NG means that there are defects such as deformations and fractures on the Ethernet ports. Labeling is to provide the information required by deep learning training.

    ok defect features

    For NG images, long press the left mouse button or right-click icon tool on the toolbar and then use the Brush Tool to select the regions with defects.

    label data1
    label data2

    Click icon eraser to use the eraser tool to remove the labeled region.

    For OK images that do not contain any defect, please select the image and then right-click and select Set to OK. Please make sure that there is at least one OK image in each dataset.

    label ok
  5. Train the Model: Select Training and then click Train in the lower right corner of the interface to start training the model.

    training chart
  6. Validate the Model: After the training is completed, click  Validate to validate the model and check the results.

    result verification
  7. Export: Click Export in the lower right corner of the interface and click Export in the pop-up window (the default export parameters can be directly used). Then, select a directory to save the exported model in the dlkpack file.

    model files

Now, you have completed the training of the first model. Continue your reading to learn all the details of modules.

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.