IP Library › Granted Patent US 12,423,797
Granted Patent B2
US 12,423,797 · App. 17/530,689 · Granted Sep 23, 2025

Method for selecting a light source for illuminating defects, electronic device, and non-transitory storage medium

Inventors: Chung-Yu Wu (New Taipei, TW); Chin-Pin Kuo (New Taipei, TW)
Assignee: HON HAI PRECISION INDUSTRY CO., LTD.
G06T7/001G01N21/01G01N21/8851G01N2201/061G06T2207/10152G06T2207/20221
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,423,797
App. No.
17/530,689
Granted
Sep 23, 2025
Kind
B2
Abstract

A method for selecting a light source for illuminating defects, an electronic device, and a non-transitory storage medium are provided. The method includes acquire grayscale images of an object with a known defect and generates a pseudo-hyperspectral image cube based on the grayscale images, so that algorithms related to hyperspectral images can analyze the grayscale images collected under different light sources. A most effective or target light source can be automatically and quickly determined from the plurality of light sources, improving an efficiency of light source selection.

Claims (50)

1. A method for selecting a light source for illuminating defects, the method comprising:

acquiring a plurality of grayscale images of an object with a known defect, one grayscale image corresponding to one light source;

generating a pseudo-hyperspectral image cube according to the plurality of grayscale images, comprising: obtaining the pseudo-hyperspectral image cube by performing a three-dimensional fusion of the plurality of grayscale images, wherein a width of the pseudo-hyperspectral image cube is a width of the grayscale image, and a length of the pseudo-hyperspectral image cube is a length of the grayscale image, and a height of the pseudo-hyperspectral image cube is a number of the plurality of grayscale images;

acquiring defect information of the known defect, and acquiring a spectrum wavelength of the defect information from the pseudo-hyperspectral image cube;

generating a characteristic spectrum curve according to the defect information and the spectrum wavelength; and

applying a hyperspectral image analysis algorithm to analyze the characteristic spectrum curve to obtain an analyze result and obtaining a target light source according to the analyze result.

2. The method according to claim 1 , wherein acquiring the plurality of grayscale images of an object with a known defect comprises:

acquiring an image of the object under each of a plurality of light sources; and

converting each of the acquired image through a gray scale conversion algorithm to obtain the plurality of grayscale images.

3. The method according to claim 2 , wherein the gray scale conversion algorithm comprises any one of a floating-point algorithm, an integer algorithm, a shift algorithm, an average value algorithm, and a green-only algorithm.

4. The method according to claim 1 , the method further comprising:

performing hyperspectral image analysis on the pseudo-hyperspectral image cube according to a preset analysis algorithm to obtain data, after generating the pseudo-hyperspectral image cube according to the plurality of grayscale images; and

saving the data in a database.

5. The method according to claim 4 , wherein the preset analysis algorithm comprises any one of a waveband selection algorithm and an orthogonal subspace projection algorithm.

6. The method according to claim 5 , the method further comprising:

acquiring an image of a target object to be detect under the target light source, after obtaining a target light source according to the analyze result;

performing an optical detection on the image of the target object to obtain a result of detection or non-detection of a defect, wherein the result is used to determine whether the target object has the known defect.

7. An electronic device comprising a memory and a processor, the memory stores at least one computer-readable instruction, which when executed by the processor causes the processor to:

acquire a plurality of grayscale images of an object with a known defect, one grayscale image corresponding to one light source, comprising: obtaining the pseudo-hyperspectral image cube by performing a three-dimensional fusion of the plurality of grayscale images, wherein a width of the pseudo-hyperspectral image cube is a width of the grayscale image, and a length of the pseudo-hyperspectral image cube is a length of the grayscale image, and a height of the pseudo-hyperspectral image cube is a number of the plurality of grayscale images;

generate a pseudo-hyperspectral image cube according to the plurality of grayscale images;

acquire defect information of the known defect, and acquire a spectrum wavelength of the defect information from the pseudo-hyperspectral image cube;

generate a characteristic spectrum curve according to the defect information and the spectrum wavelength; and

apply a hyperspectral image analysis algorithm to analyze the characteristic spectrum curve to obtain an analyze result and obtain a target light source according to the analyze result.

8. The device for selecting a light source according to claim 7 , wherein the processor acquires the plurality of grayscale images of an object with a known defect by:

acquiring an image of the object under each of a plurality of light sources; and

converting each of the acquired image through a gray scale conversion algorithm to obtain the plurality of grayscale images.

9. The device for selecting a light source according to claim 8 , wherein the gray scale conversion algorithm comprises any one of a floating-point algorithm, an integer algorithm, a shift algorithm, an average value algorithm, and a green-only algorithm.

10. The device for selecting a light source according to claim 7 , wherein the processor is further caused to:

perform hyperspectral image analysis on the pseudo-hyperspectral image cube according to a preset analysis algorithm to obtain data, after generating the pseudo-hyperspectral image cube according to the plurality of grayscale images; and

save the data in a database.

11. The device for selecting a light source according to claim 9 , wherein the preset analysis algorithm comprises any one of a waveband selection algorithm and an orthogonal subspace projection algorithm.

12. The device for selecting a light source according to claim 11 , wherein the processor is further caused to:

acquire an image of a target object to be detect under the target light source, after obtaining a target light source according to the analyze result;

perform an optical detection on the image of the target object to obtain a result of detection or non-detection of a defect, wherein the result is used to determine whether the target object has the known defect.

13. A non-transitory storage medium having stored thereon at least one computer-readable instructions that, when the at least one computer-readable instructions are executed by a processor to implement a method for selecting a light source for illuminating defects, which comprises:

acquiring a plurality of grayscale images of an object with a known defect, one grayscale image corresponding to one light source;

generating a pseudo-hyperspectral image cube according to the plurality of grayscale images, comprising: obtaining the pseudo-hyperspectral image cube by performing a three-dimensional fusion of the plurality of grayscale images, wherein a width of the pseudo-hyperspectral image cube is a width of the grayscale image, and a length of the pseudo-hyperspectral image cube is a length of the grayscale image, and a height of the pseudo-hyperspectral image cube is a number of the plurality of grayscale images;

acquiring defect information of the known defect, and acquiring a spectrum wavelength of the defect information from the pseudo-hyperspectral image cube;

generating a characteristic spectrum curve according to the defect information and the spectrum wavelength; and

applying a hyperspectral image analysis algorithm to analyze the characteristic spectrum curve to obtain an analyze result and obtaining a target light source according to the analyze result.

14. The non-transitory storage medium according to claim 13 , wherein acquiring the plurality of grayscale images of an object with a known defect comprises:

acquiring an image of the object under each of a plurality of light sources;

converting each of the acquired image through a gray scale conversion algorithm to obtain the plurality of grayscale images.

15. The non-transitory storage medium according to claim 14 , wherein the gray scale conversion algorithm comprises any one of a floating-point algorithm, an integer algorithm, a shift algorithm, an average value algorithm, and a green-only algorithm.

16. The non-transitory storage medium according to claim 13 , the method further comprising:

performing hyperspectral image analysis on the pseudo-hyperspectral image cube according to a preset analysis algorithm to obtain data, after generating the pseudo-hyperspectral image cube according to the plurality of grayscale images; and

saving the data in a database.

17. The non-transitory storage medium according to claim 16 , the method further comprising:

acquiring an image of a target object to be detect under the target light source, after obtaining a target light source according to the analyze result;

performing an optical detection on the image of the target object to obtain a result of detection or non-detection of a defect, wherein the result is used to determine whether the target object has the known defect.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 19, 2021
From: WU, CHUNG-YU; KUO, CHIN-PIN
To: HON HAI PRECISION INDUSTRY CO., LTD.
Reel/Frame 058162/0826 →
Priority Claims (1)
CN 202011530849.1 · Dec 22, 2020 · national
Continuity (1)
Related Publication 20220198634A1 · Jun 23, 2022
References Cited (6)
CN 101282489 · 2008 [cited by applicant]
CN 105632413 · 2016 [cited by applicant]
CN 109348731A · 2019 [cited by examiner]
CN 110263777 · 2019 [cited by applicant]
Choa et al., “Detection of cuticle defects on cherry tomatoes using hyperspectral fluorescence imagery”, pub. 2013 (Year: 2013). [cited by examiner]
Byoung-Kwan Choa et al., “Detection of cuticle defects on cherry tomatoes using hyperspectral fluorescence imagery”, pub. 2013 (Year: 2013). [cited by examiner]