Imaging system
The imaging system addresses the challenge of accurately measuring non-uniform surface colors by using multiple light sources, a color reference member, and advanced image processing to generate precise color identification data.
Patent Information
- Application Number
- JP2020006586
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2020-01-20
- Publication Date
- 2025-06-03
- Estimated Expiration
- 2040-01-20
AI Technical Summary
Conventional color measurement techniques struggle to accurately evaluate the color of objects with non-uniform surface colors, such as fabrics, papers, and unevenly painted surfaces, due to difficulties in capturing high-precision two-dimensional color information.
An imaging system comprising an illumination device with multiple light sources emitting light in different wavelength ranges, an imaging device, a processing device, a color reference member, and a light-shielding housing. The system generates image data based on light reflected from both the object and the color reference member, allowing for accurate color identification and correction.
The imaging system enables precise evaluation of the color of objects with non-uniform surface colors by blocking external light, using a color reference member for correction, and processing image data to generate identification data for the object's color.
Smart Images

Figure 0007687559000010 
Figure 0007687559000011 
Figure 0007687559000012
Abstract
Description
Technical Field
[0001] The present disclosure relates to an imaging system.
Background Art
[0002] Conventionally, various techniques for measuring or evaluating colors have been developed. For example, Patent Documents 1 to 3 disclose examples of techniques for measuring or evaluating the color of an object.
Prior Art Documents
Patent Documents
[0003]
Patent Document 1
Patent Document 2
Patent Document 3
Summary of the Invention
Problems to be Solved by the Invention
[0004] The present disclosure provides a novel imaging system capable of appropriately evaluating the color of an object whose surface color is not uniform, such as a fabric.
Means for Solving the Problems
[0005] An imaging system according to one aspect of the present disclosure includes an illumination device, an imaging device, a processing device, a color reference member, and a light-shielding housing. The illumination device includes one or more light sources that respectively emit light in one or more wavelength ranges. The processing device controls the illumination device and the imaging device and processes a signal output from the imaging device. The color reference member reflects the light respectively emitted from the one or more light sources and is arranged such that the reflected light is incident on the imaging device. The housing has an opening and houses the illumination device, the imaging device, and the color reference member therein. Imaging of the object is performed with the object being held by a portion around the opening in the housing. The processing device sequentially causes the one or more light sources to emit the light, and each time the light is emitted from the one or more light sources, causes the imaging device to generate image data based on the light reflected by the object and the color reference member. The processing device generates and outputs identification data for identifying the color of the object based on the image data.
[0006] The above general aspect can be implemented by an apparatus, a system, a method, an integrated circuit, a computer program, a recording medium, or any combination thereof.
Advantages of the Invention
[0007] According to an embodiment of the present disclosure, it becomes possible to appropriately evaluate the color of an object whose surface color is not uniform, such as a fabric.
Brief Description of the Drawings
[0008]
Figure 1
Figure 2
Figure 3
Figure 4
Figure 5
Figure 6
Figure 7
Figure 8A
Figure 8B
Figure 9
Figure 10
Figure 11
Figure 12
Figure 13
Figure 14
Figure 15
Figure 16
Figure 17
Figure 18
Figure 19
Mode for Carrying Out the Invention
[0009] Before explaining the embodiments of the present disclosure, the findings on which the present disclosure is based will be explained.
[0010] Conventionally, for color measurement and evaluation, methods such as color measurement using a colorimeter or spectroscopic analysis using a spectral measuring instrument have been used. These methods generally measure the color in a small spot (for example, several millimeters or less). Therefore, it is difficult to measure the color of an object with a non-uniform surface color with high accuracy. For example, it is difficult to measure with high accuracy the colors of fabrics with patterns or folds, paper (especially those with large fibers), carpets, walls, or unevenly applied paints or inks. When measuring such objects, the measured values vary greatly even if the positions of the measurement points differ slightly. Therefore, with the conventional color measurement methods, stable measurement results could not be obtained for the above-mentioned objects.
[0011] In order to measure the color of a non-uniform object such as a fabric, it is necessary to photograph or measure a certain area with a device capable of acquiring two-dimensional information such as a camera. In order to distinguish minute color differences, high-precision photography is required. However, for this purpose, a high-quality lighting device, an optical system, and a cover for blocking stray light are required, and the scale of the entire device becomes large.
[0012] Also, in a color camera generally used to acquire color information in a two-dimensional area, a color filter array is arranged in front of the image sensor, and the incident light is separated into the components of the three primary colors of R, G, and B for each pixel. However, these filters do not necessarily have the spectral characteristics required in the standard color space and may not be suitable for high-precision color analysis. On the other hand, these filters are usually incorporated into the image sensor or the optical system, and it is not easy to replace or adjust them.
[0013] In addition, the characteristics of lighting devices such as LEDs and cameras often change over time, and it is difficult to maintain stable characteristics. Furthermore, dirt, fine particles, etc. may adhere to the surface of the lens of the camera or the surface of the lighting device such as an LED over time. Such dirt and fine particles may affect the light - electricity conversion characteristics.
[0014] The inventors of the present invention have found the above problems and have developed a novel imaging system that can solve at least a part of the above problems. Hereinafter, an outline of the embodiments of the present disclosure will be described.
[0015] An imaging system according to an exemplary embodiment of the present disclosure includes a lighting device, an imaging device, a processing device, a color reference member, and a light - shielding housing. The lighting device includes one or more light sources that respectively emit light in one or more wavelength ranges. The processing device controls the lighting device and the imaging device and processes a signal output from the imaging device. The color reference member reflects the light respectively emitted from the one or more light sources and is arranged such that the reflected light is incident on the imaging device. The housing has an opening and houses the lighting device, the imaging device, and the color reference member therein. Imaging of the object is performed with the object being held by a portion around the opening in the housing. The processing device sequentially causes the one or more light sources to emit the light, and each time the light is emitted from the one or more light sources, causes the imaging device to generate image data based on the light reflected by the object and the color reference member. The processing device generates and outputs identification data for identifying the color of the object based on the image data.
[0016] According to the above configuration, imaging of the object is performed with the object being held by a portion around the opening in the light-shielding housing. As a result, external light can be blocked, enabling more accurate color measurement. Further, the color reference member is imaged together with the object, and identification data for identifying the color of the object is generated based on the resulting image data. Therefore, as will be described in detail later, even when the characteristics of the imaging device or the lighting device change over time, it is possible to appropriately correct the influence thereof.
[0017] The color reference member may have a reflecting surface inclined with respect to the surface including the opening. According to such a configuration, the influence of reflected light from the object can be suppressed, and the accuracy of the correction process using the color reference member can be improved.
[0018] The imaging system may include a transparent plate for holding the object in the opening. The transparent plate may have an uneven structure on the surface on the side of the imaging device for suppressing light reflection. By disposing a transparent plate having such a fine uneven structure, the color of the object can be measured more stably. The transparent plate may be a translucent member such as ground glass.
[0019] The processing device can generate corrected image data by correcting data in a region corresponding to the object in the image data based on data in a region corresponding to the color reference member in the image data, and can generate the identification data based on the corrected image data.
[0020] The treatment device can generate the identification data, for example, by the following processes (A) to (C). (A) Extract n pixel blocks (n is an integer of 3 or more) from the corrected image data, and determine a representative value of pixel values for each of the n extracted pixel blocks. (B) For each of the n pixel blocks, calculate the sum of the values indicating the degree of difference between the representative value of the pixel values and the representative values of the pixel values for all other pixel blocks included in the n pixel blocks. (C) Determine a value indicating one color based on the representative values of the pixel values in m (m is an integer greater than or equal to 2 and less than n) pixel blocks selected in order from those with smaller sums of the values indicating the degree of difference among the n pixel blocks, and generate the identification data based on the value.
[0021] According to the above processing, for each wavelength range, one value representing the color of the object is determined, and based on the value, identification data is generated. By such processing, the color of the object can be more appropriately quantified.
[0022] The "value indicating the degree of difference" in step (B) above may be the difference itself between the representative values of the pixel values in the two pixel blocks to be compared, or may be the difference between other values converted from the representative values of the pixel values. The "value indicating one color" in step (C) above may be the average value of the representative values of the pixel values in the m pixel blocks, or may be other values obtained by calculations based on the representative values.
[0023] The above one or more wavelength ranges may be one wavelength range or a plurality of wavelength ranges. When the above one or more wavelength ranges are singular, the degree of shading of the object can be evaluated with one value by the above method. In this specification, shading is also included in the concept of color. When the above one or more wavelength ranges are plural, the color of the object can be evaluated with a plurality of values. The above plurality of wavelength ranges may include, for example, the wavelength ranges of the three primary colors of red (R), green (G), and blue (B). However, it is not necessarily limited to the wavelength ranges of the three primary colors. Depending on the application, the above method can also be used for the evaluation of multi-spectral colors such as four wavelengths or five wavelengths. Each wavelength range in the present disclosure is not limited to the wavelength range of visible light, and may be, for example, the wavelength range of invisible light such as infrared or ultraviolet.
[0024] According to the above method, m pixel blocks that are estimated to have similar colors or densities are selected from the n pixel blocks extracted from the image. Then, a value indicating one color based on the representative value of each pixel value of the above one or more colors of the m pixel blocks is output as color identification data. Through such processing, it becomes possible to appropriately evaluate the color of an object whose color or density is not uniform.
[0025] When the one or more wavelength ranges are a plurality of wavelength ranges, the step (B) of calculating the sum of the values indicating the degree of the difference may include the following steps (B1) and (B2). (B1) For each of the n pixel blocks, convert the representative value of the pixel values for each of the plurality of wavelength ranges into a plurality of values in a second color space different from the first color space composed of a plurality of colors respectively corresponding to the plurality of wavelength ranges. (B2) For each of the n pixel blocks, calculate the sum of the distances between the points on the second color space indicated by the plurality of values and the points on the second color space indicated by the plurality of values for all other pixel blocks included in the n pixel blocks as the sum of the values indicating the degree of the difference.
[0026] The value indicating the one color may be the representative value of each of the plurality of values in the m pixel blocks selected in order from those with the smallest sum of the distances among the n pixel blocks.
[0027] According to the above method, the color of the object can be more appropriately evaluated.
[0028] The one or more light sources may include a first light source that emits light in a first wavelength range, a second light source that emits light in a second wavelength range, and a third light source that emits light in a third wavelength range. In that case, the processing device can execute, for example, the following operations. · Cause the first light source to emit light in the first wavelength range, and cause the imaging device to generate first image data based on the light in the first wavelength range reflected by the object and the color reference member. · Cause the second light source to emit light in the second wavelength range, and cause the imaging device to generate second image data based on the light in the second wavelength range reflected by the object and the color reference member. · Cause the third light source to emit light in the third wavelength range, and cause the imaging device to generate third image data based on the light in the third wavelength range reflected by the object and the color reference member. · Generate and output the identification data based on the first image data, the second image data, and the third image data.
[0029] In the above configuration, lights in the first to third different wavelength ranges are sequentially emitted, and the first to third image data are sequentially generated. By synthesizing the first to third image data, it is possible to stably obtain identification data indicating the color of an object with non-uniform surface color, such as a non-flat surface.
[0030] The color reference member may be configured to reflect light in each of the first to third wavelength ranges with an equal reflectance. In one example, the color reference member has a plate-like structure. A color reference member with such a structure can be referred to as a "color reference plate".
[0031] The first wavelength range may be the red wavelength range. The second wavelength range may be the green wavelength range. The third wavelength range may be the blue wavelength range. In this specification, the red wavelength range refers to the wavelength range in which the wavelength in air is included in the range of 600 nm to 700 nm. The green wavelength range refers to the wavelength range in which the wavelength in air is included in the range of 500 nm to 600 nm. The blue wavelength range refers to the wavelength range in which the wavelength in air is included in the range of 400 nm to 500 nm. However, it is not limited to these wavelength ranges, and other wavelength ranges may be used. Not limited to the wavelength range of visible light, a light source that emits light in the infrared or ultraviolet wavelength range may also be used. In this specification, not limited to visible light, infrared rays and ultraviolet rays are also referred to as "light".
[0032] The processing device generates first color data based on the data of the region corresponding to the object in the first image data, generates second color data based on the data of the region corresponding to the object in the second image data, generates third color data based on the data of the region corresponding to the object in the third image data, corrects the first color data based on the data of the region corresponding to the color reference member in the first image data, corrects the second color data based on the data of the region corresponding to the color reference member in the second image data, corrects the third color data based on the data of the region corresponding to the color reference member in the third image data, and may generate the identification data based on the corrected first to third color data.
[0033] The processing device may execute, for example, the following processes (a) to (c). (a) Extract n pixel blocks (n is an integer of 3 or more) from the image indicated by the data of the region corresponding to the object in the first image data, and for each of the n extracted pixel blocks, determine the representative value of the pixel values in the first wavelength range, and generate data indicating the n representative values as the first color data. (b) Extract n pixel blocks located at positions corresponding to the n pixel blocks from the image shown by the data of the region corresponding to the object in the second image data, and for each of the extracted n pixel blocks, determine a representative value of the pixel values in the second wavelength range, and generate data indicating the n representative values as the second color data. (c) Extract n pixel blocks located at positions corresponding to the n pixel blocks from the image shown by the data of the region corresponding to the object in the third image data, and for each of the extracted n pixel blocks, determine a representative value of the pixel values in the third wavelength range, and generate data indicating the n representative values as the third color data.
[0034] The processing device may further execute the following processes (d) to (g). (d) Based on the corrected first to third color data, for each of the n pixel blocks, convert the representative values of the pixel values in the respective first to third wavelength ranges into three values in a second color space different from the first color space defined by the first to third wavelength ranges. (e) For each of the n pixel blocks, calculate the sum of the distances between the points in the second color space indicated by the three values and the points in the second color space indicated by the three values for all other pixel blocks included in the n pixel blocks. (f) Calculate the representative value of each of the three values in m (m is an integer greater than or equal to 2 and less than n) pixel blocks selected in order from those with the smallest sum of the distances among the n pixel blocks. (g) Output the representative value of each of the three values as the identification data.
[0035] Each representative value of the three values in the second color space in step (f) above is used as identification data for identifying the color of the object. Each representative value of the three values may be, for example, the average value of the three values in m pixel blocks. According to the above method, m pixel blocks estimated to have similar colors are selected from the n pixel blocks extracted from the RGB image. Then, each representative value of the three values of the m pixel blocks in the second color space is output as color identification data. By such processing, it becomes possible to more appropriately evaluate the color of an object with non-uniform color.
[0036] The above method can be used, for example, for inspecting the color of products produced by similar processes. In such applications, first, for a product (referred to as the first object) produced in advance, identification data is recorded on a recording medium in advance as reference data by the above method. Next, for a second object produced by the same process as the above product, identification data is generated by the same method as above. By comparing the generated identification data with the reference data recorded in advance, it is possible to determine the quality of the color of the object.
[0037] In such applications, the processing device may further perform the following processing. (h) Calculate the distance between the point on the second color space indicated by each representative value (for example, the average value) of the three values in the m pixel blocks and the point on the second color space indicated by each reference value of the three values recorded in advance. (i) Determine the quality of the color of the object according to the distance and output the determination result.
[0038] Steps (h) and (i) make it possible to determine the quality of the color of the second object based on the degree of approximation between the color of the first object recorded in advance and the color of the second object to be inspected. The quality of the color may be evaluated, for example, with a binary value of good / bad, or may be evaluated with three or more values according to the degree of approximation.
[0039] Instead of the processes (h) and (i) above, the processing device may perform the following processes (h’) and (i’). (h’) Calculate the difference between the representative value of one of the three values in the m pixel blocks and the reference value of one of the three values recorded in advance. (i’) Determine the quality of the color of the object according to the difference and output the determination result.
[0040] Through such processing, the difference in the color (including shade) of the object can be expressed with a sign. For example, when “one of the three values” indicates luminance, the difference in luminance is expressed with a sign. Therefore, the shade of the object can be appropriately evaluated.
[0041] The three values in the second color space are, for example, L * a * b * value, a * value, and b * value in the color space L * value, a * value, and b * value in the color space L * a b color space is designed to approximate human vision. Therefore, by selecting in order from the pixel blocks with a small sum of distances in the L * a * b * a b color space, a quantification closer to human vision becomes possible. Note that depending on the purpose of color quantification, it is not always necessary to be close to human vision. Therefore, the second color space may be a color space different from the L * a * b * a b color space.
[0042] The processing device may determine the conversion coefficient used when converting the representative value of each pixel value of R, G, and B into the three values in the second color space by machine learning.
[0043] The step of determining the representative value of each pixel value of the R, G, and B may include the step of smoothing and averaging each pixel value of the R, G, and B.
[0044] The one or more light sources may further include a fourth light source that emits light in a fourth wavelength range.
[0045] The processing device may further cause the fourth light source to emit light in the fourth wavelength range, cause the imaging device to generate fourth image data based on the light in the fourth wavelength range reflected by the object and the color reference member, and generate and output the identification data based on the first image data, the second image data, the third image data, and the fourth image data.
[0046] The fourth wavelength range is different from the first to third wavelength ranges. The fourth wavelength range may be, for example, a near-infrared wavelength range. By using the fourth light source, more information about the color of the surface of the object can be obtained.
[0047] The processing device may include a processor and a memory that stores a computer program executed by the processor. Each of the above-described processes may be realized by the processor executing the computer program.
[0048] Hereinafter, embodiments of the present disclosure will be described. However, detailed descriptions that are more than necessary may be omitted. For example, detailed descriptions of well-known matters and duplicate descriptions of substantially the same configurations may be omitted. This is to avoid making the following description unnecessarily redundant and to facilitate the understanding of those skilled in the art. Note that the inventors provide the accompanying drawings and the following description so that those skilled in the art can fully understand the present disclosure, and do not intend to limit the subject matter described in the claims thereby. In this specification, the same or similar components are denoted by the same reference numerals. Note that the shape and size of the whole or a part of the structure shown in the drawings of the present application do not limit the actual shape and size. Also, other embodiments may be configured by appropriately combining the configurations of the embodiments described below.
[0049] (Embodiment) [1. Configuration] FIG. 1 is a diagram schematically showing the configuration of an imaging system 100 in an exemplary embodiment of the present invention. The imaging system 100 identifies the color of an object 230 and outputs the identification result. The object 230 is, for example, an object whose surface color is not uniform, such as a fabric with a pattern or a fold, paper (especially with large fibers), a carpet, a wall, or a hand-painted paint or ink with unevenness. Note that the object 230 is not limited to an object with a non-uniform color, and any object can be the object 230. The object 230 can be, for example, a product mass-produced by manual work or a production line. In that case, color variations may occur for each product. For this reason, for each produced object 230, color identification processing using the imaging system 100 is executed, and a determination of the quality of the color is made. In the following description, as an example, it is assumed that the object 230 is a fabric with a pattern or a fold.
[0050] The imaging system 100 in this embodiment includes a processing device 110, an illumination device 120, an imaging device 140, a color reference plate 240, a light-shielding housing 170, and a transparent plate 176. The processing device 110 is connected to the illumination device 120 and the imaging device 140. In this embodiment, the imaging system 100 further includes a display 220. The display 220 is connected to the processing device 110 and displays an image based on a signal generated by the processing device 110.
[0051] The illumination device 120 includes one or more light sources that respectively emit light in one or more wavelength ranges. In the example of FIG. 1, the illumination device 120 includes three light sources 121, 122, and 123 that respectively emit light in three different wavelength ranges. The first light source 121 emits light in the first wavelength range. The second light source 122 emits light in the second wavelength range. The third light source 123 emits light in the third wavelength range. In this embodiment, the first wavelength range is the red (R) wavelength range, the second wavelength range is the green (G) wavelength range, and the third wavelength range is the blue (B) wavelength range. The light sources 121, 122, and 123 in the illumination device 120 can be realized, for example, by light-emitting diodes (LEDs) that respectively emit light in the red, green, and blue wavelength ranges. Each light source is not limited to an LED and may be another type of light source such as a fluorescent lamp or an organic light-emitting element.
[0052] FIG. 2 is a diagram showing another configuration example of the illumination device 120. In the example of FIG. 2, the illumination device 120 includes two sets of the light sources 121, 122, and 123. The sets of the light sources 121, 122, and 123 are arranged on both sides of the imaging device 140. With such an arrangement of the light sources, the object 230 can be irradiated more uniformly. Note that, in the example of FIG. 2, unlike the example of FIG. 1, the transparent plate 176 is not provided. As in this example, the transparent plate 176 may be omitted.
[0053] The imaging device 140 includes an image sensor having sensitivity in the wavelength range of visible light and a lens optical system 142 that forms an image on the imaging surface of the image sensor. The imaging device 140 is disposed at a position where it receives the light emitted from the illumination device 120 and reflected by the object 230 and the color reference plate 240. The imaging device 140 captures an image of the object 230 and outputs an image signal. Different from a general color camera, the imaging device 140 in the present embodiment does not include a color filter array. The light sources 121, 122, and 123 of the three primary colors R, G, and B are sequentially turned on, and imaging is performed each time. Thereby, the image signals of R, G, and B are sequentially generated.
[0054] The color reference plate 240 is a color reference member having a plate-like structure and is imaged together with the object 230 by the imaging device 140. The color reference plate 240 is arranged to reflect the light emitted from the three light sources 121, 122, and 123 respectively and the reflected light is incident on the imaging device 140. The color of the surface of the color reference plate 240 is known, and based on the color information, the processing device 110 corrects the color of the image of the object 230.
[0055] The housing 170 is a light-shielding member and has, for example, a cylindrical or prismatic shape. The housing 170 has an opening 174 and houses the illumination device 120, the imaging device 140, and the color reference plate 240 inside. Imaging of the object 230 is performed with the object 230 being held by the portion around the opening 174 in the housing 170. The opening 174 can have an arbitrary shape such as, for example, circular, elliptical, rectangular, or polygonal. The housing 170 has a light-shielding packing 172 around the opening 174. By providing the light-shielding packing 172 between the housing 170 and the object 230, external light that affects the measurement result can be blocked. In the example of FIG. 1, the processing device 110 is disposed outside the housing 170, but it may also be disposed inside the housing 170.
[0056] The transparent plate 176 is a plate-shaped member for pressing the object 130 and is provided in the opening 174. Imaging is performed with the object 130 being pressed against the surface of the transparent plate 176. The transparent plate 176 in the present embodiment is provided with an uneven structure for suppressing light reflection on the surface on the imaging device 142 side. The uneven structure has a plurality of concave portions and a plurality of convex portions arranged one-dimensionally or two-dimensionally. By providing the uneven structure, more stable measurement becomes possible.
[0057] FIG. 3 is a diagram for explaining the function of the transparent plate 176. (a) of FIG. 3 shows a state where the transparent plate 176 is not provided. (b) of FIG. 3 shows a state where the transparent plate 176 without an uneven structure on the surface is provided. (c) of FIG. 3 shows a state where the transparent plate 176 with an uneven structure on the surface is provided. When the object 230 is a fabric, as shown in (a) of FIG. 3, the direction of the fibers on the surface may be uneven. In such a case, the measured value is likely to be unstable. Therefore, as shown in (b) of FIG. 3, by pressing the fibers with a transparent plate 176 such as glass, the direction of the fibers can be stabilized. However, when using a transparent plate 176 with a flat surface, the reflected light of the light from the lighting device 120 may enter the imaging device 140, and the measurement may become unstable. Therefore, in the present embodiment, as shown in (c) of FIG. 3, a transparent plate 176 with fine unevenness on the surface, such as frosted glass, is used. By using the transparent plate 176 with fine unevenness on the surface, the reflected light caused by the light from the lighting device 120 is diffused, and the measurement is stabilized. The transparent plate 176 may be a translucent member.
[0058] The processing device 110 is a computer that controls the lighting device 120 and the imaging device 140 and processes the signals output from the imaging device 140. The processing device 110 causes the one or more light sources included in the lighting device 120 to sequentially emit light, and each time light is emitted from the one or more light sources, causes the imaging device 140 to perform imaging. In the example of FIG. 1, the imaging device 140 causes the first light source 121, the second light source 122, and the third light source 123 to sequentially emit light, and each time, causes the imaging device 140 to perform imaging. Thereby, the imaging device 140 generates image data based on the light reflected by the object 230 and the color reference plate 240. The processing device 110 generates and outputs identification data for identifying the color of the object 230 based on the image data.
[0059] FIG. 4 is a block diagram showing a configuration example of the processing device 110. The processing device 110 in this example includes a control circuit 111, a signal processing circuit 112, an input / output interface (IF) 116, and a memory 114. The control circuit 111 controls the timing of light emission by each of the light sources 121, 122, 123 of the lighting device 120, imaging by the imaging device 140, and signal processing by the signal processing circuit 112. The control circuit 111 also performs processing to cause the display 220 to generate an image based on the data generated by the signal processing circuit 112. The control circuit 111 can be realized by an integrated circuit including a processor such as a microcontroller unit. The signal processing circuit 112 generates and outputs identification data for identifying the color of the object 230 based on the image data output from the imaging device 140. The signal processing circuit 112 can be realized by an integrated circuit including a processor such as a CPU (Central Processing Unit) or a GPU (Graphics Processing Unit). The signal processing circuit 112 processes the image signal output from the imaging device 140 to identify the color of the object 230, and outputs the identification result to the display 220. This operation is realized by the signal processing circuit 112 executing a computer program stored in the memory 114.
[0060] In the example shown in FIG. 4, one processing device 110 includes a control circuit 111 and a signal processing circuit 112. The device that realizes the function of the control circuit 111 and the device that realizes the function of the signal processing circuit 112 may be distributed and arranged. Further, at least a part of the functions of the processing device 110 may be executed by a computer installed at a location far from the imaging system 100. For example, a server computer connected to the control circuit 111 via a network such as the Internet may execute at least a part of the functions of the signal processing circuit 112.
[0061] The display 220 displays the color identification result according to an instruction from the control circuit 111. The display 220 is a monitor such as a CRT, a liquid crystal, or an organic EL, for example. The display 220 may be mounted on the housing 170.
[0062] In the present embodiment, an imaging device 140, which is a monochrome camera that does not acquire color information, is used for photographing the object 230. A plurality of images are acquired by photographing while sequentially lighting a plurality of light sources 121, 122, and 123 of the three primary colors R, G, and B, not simultaneously. By synthesizing those images, a color image is generated and color information is obtained.
[0063] FIG. 5 is a diagram showing an example of each of the R, G, and B images generated by imaging with the imaging system 100 of the present embodiment. For the sake of convenience of explanation, FIG. 5 shows an example in the case where a Macbeth Color Checker, which is a color chart in which a plurality of color samples are two-dimensionally arranged, is used as a subject. When such a subject is imaged, as shown in FIG. 5, the data of each of the R image, the G image, and the B image are sequentially generated. By synthesizing the data of those images, the data of an RGB color image is obtained. Note that the actually obtained image is not an image of a color chart as shown in FIG. 5, but an image including an object 230 such as a fabric and a color reference plate 240, for example.
[0064] In a color filter incorporated in a general color camera, it is impossible to adjust the spectral characteristics of the filter once it is incorporated, and it is difficult to accurately know its characteristics in advance. On the other hand, light sources such as LEDs can be easily selected or replaced individually, and their emission characteristics can be accurately known in advance using a spectrometer or the like.
[0065] Here, the light source used can be, for example, an LED light source with red (R): 700.0 [nm], green (G): 546.1 [nm], and blue (B): 435.8 [nm] defined by the CIE (Commission internationale de l'eclairage). However, even if it does not necessarily match this spectral characteristic, if the spectral characteristic can be measured in advance, adjustments such as correction are easy.
[0066] Furthermore, more detailed color information may be obtained by using methods such as taking pictures while independently adjusting the illuminance of a plurality of light sources, or turning on a plurality of light sources simultaneously after adjusting the illuminance of the plurality of light sources.
[0067] [2. Operation] FIG. 6 is a flowchart showing an outline of the processing executed by the imaging system 100 of the present embodiment. In the present embodiment, as a preparation for the process of determining the quality of the color of the object 230, a color registration process of the object 230 is performed (step S10). In this registration process, the processing device 110 determines a numerical value indicating the color of the object 230 by a process described later, and records the numerical value as a reference value in a recording medium such as the memory 114. After the registration process is completed, a color determination process (step S20) of the object 230 of the same type as the object 230 whose color has been registered is performed. Specific examples of each process will be described.
[0068] [2-1. Color registration process] FIG. 7 is a flowchart showing the flow of the color registration process in step S10. The imaging system 100 registers identification data (reference value) indicating the color of the object 230 by executing the operations from step S110 to S160.
[0069] In step S110, the control circuit 111 turns on the first light source 121, turns off the second light source 122 and the third light source 123, sends an imaging instruction to the imaging device 140, and generates data of a red (R) image. The generated data of the R image is recorded in the memory 114.
[0070] In step S120, the control circuit 111 turns on the second light source 122, turns off the first light source 121 and the third light source 123, sends an imaging instruction to the imaging device 140, and generates data of a green (G) image. The generated data of the B image is recorded in the memory 114.
[0071] In step S130, the control circuit 111 turns on the third light source 123, turns off the first light source 121 and the second light source 122, sends an imaging instruction to the imaging device 140, and generates data of a blue (B) image. The generated data of the B image is recorded in the memory 114.
[0072] In step S140, the signal processing circuit 112 extracts data of the area of the color reference plate 240 and data of the area of the object 230 from the generated R, G, and B image data. Since the position of the color reference plate 240 is known, the signal processing circuit 112 can easily extract the area of the color reference plate 240 and the area of the object 230.
[0073] In step S150, the signal processing circuit 112 corrects the data of the RGB image of the area of the object 230 based on the data of the RGB image of the area of the color reference plate 240.
[0074] Here, with reference to FIGS. 8A and 8B, an example of the correction process using the color reference plate 240 will be described. FIG. 8A schematically shows the state of imaging using the color reference plate 240. As shown in FIG. 8A, a color reference plate 240 with a known surface color is arranged in a part of the range photographed by the imaging device 140. The color reference plate 240 is photographed simultaneously with the object 230. In FIG. 8A, the dotted line shows an example of the path of light reflected by the color reference plate 240 and incident on the imaging device 140, and the dashed-dotted line shows an example of the path of light reflected by the object 230 and incident on the imaging device 140. In the present embodiment, the surface of the color reference plate 240 is arranged to be inclined with respect to the surface of the object 230. Thereby, it is possible to make it less susceptible to the influence of the color of the object 230.
[0075] At the time of registering and measuring the reference color, the object 230 and the color reference plate 240 are photographed simultaneously, and based on the information on the color of the color reference plate 240 that is known in advance, the color of the object 230 is corrected. For the color reference plate 240, for example, a gray plate with substantially the same reflectance of light of each color of R, G, and B can be used.
[0076] FIG. 8B shows an example of the image 310 generated by the imaging device 140. The image 310 includes the region 230i of the object and the region 240i of the color reference plate. The signal processing circuit 112 extracts the region 230i of the object and the region 240i of the color reference plate from the generated image 310, and corrects the data of the region of the region 230i of the object based on the data of the region 240i of the color reference plate.
[0077] Here, let the representative values of the red, green, and blue values in the region 240i of the color correction plate be Rr, Gr, and Br respectively, and let the red, green, and blue pixel values in the region 230i of the object be Rt, Gt, and Bt respectively. The corrected red, green, and blue pixel values Rc, Gc, and Bc in the region 230i of the object are obtained by the calculation of Equation 1 below.
Equation
[0078] The signal processing circuit 112 corrects the data of each pixel of the RGB image of the region 230i of the object based on Equation 1. The values of Rr, Gr, and Br can be, for example, the average values of the respective values of R, G, and B of a plurality of pixels in the region 240i of the color reference plate.
[0079] In step S160, the signal processing circuit 112 generates and outputs identification data (reference value) indicating one color from the data of the corrected RGB image in the region 230i of the object. The signal processing circuit 112 records this reference value in a recording medium such as the memory 114.
[0080] FIG. 9 is a flowchart showing a specific example of the process of step S160. Step S160 includes the processes of steps S162 to S167 shown in FIG. 9. Hereinafter, the processes of each step will be described.
[0081] In step S162, the signal processing circuit 112 extracts a plurality (n) of pixel blocks from the corrected RGB image data in the region 230i of the object. The number n of the extracted pixel blocks can be set to any number of 3 or more. In one example, n can be set to a number of about 100.
[0082] FIGS. 10 and 11 are diagrams for explaining an example of the pixel block extraction process. The pixel block extraction process can be performed, for example, as follows. (1) Select n points (for example, 100 points) from the RGB image. Fig. 10 shows an example of n points selected from the RGB image. The + marks in Fig. 10 indicate the selected points. The dark-colored region 230i in Fig. 10 is the region indicating the object 230. The n points may be selected at regular intervals in the vertical and horizontal directions as shown in Fig. 10, or may be selected randomly. In the example of Fig. 10, some of the n points are inside the region 230i indicating the object, and the remaining points are outside the region 230i. Thus, it is not necessary for all of the n selected points to be inside the region 230i indicating the object. (2) Extract a pixel block with a certain area (for example, about 100 pixels) around each of the selected n points. Fig. 11 is a diagram showing an example of the n extracted pixel blocks. In Fig. 11, the regions marked with □ indicate the pixel blocks. In the example shown in Fig. 11, none of the n pixel blocks overlap with other pixel blocks, but overlaps may occur between the pixel blocks. Also, the sizes of the pixel blocks may be different for each pixel block.
[0083] Refer to Fig. 9 again.
[0084] In step S163, the signal processing circuit 112 smoothes (or averages) the images of each pixel block and determines the representative values for each of the R, G, and B colors. For example, the representative values for each color are determined by smoothing the R, G, and B image data of each pixel block using a smoothing filter of a predetermined size. More specifically, the image data of each pixel block can be smoothed using a smoothing filter such as an averaging filter, a weighted averaging filter, or a Gaussian filter having a size such as 3×3 pixels or 5×5 pixels. The smoothing process may be performed multiple times. By performing the smoothing, the R, G, and B values of each pixel block are averaged. The signal processing circuit 112 determines, for each pixel block, one averaged value for each of R, G, and B as the representative value. Note that instead of using a smoothing filter, the average value of the R, G, and B pixel values of a plurality of pixels within each pixel block may simply be used as the representative value. By step S163, for each of the plurality of pixel blocks, averaged data for R, G, and B is obtained.
[0085] In step S165, the signal processing circuit 112 converts the representative values of the R, G, and B pixel values for each of the n pixel blocks into the L * a * b * data in the CIE-L * 、a * 、b * color space. This conversion is performed, for example, as follows. First, the signal processing circuit 112 converts the R, G, and B data into the X, Y, and Z data in the CIE-XYZ color space. This conversion is performed using a known conversion matrix. For example, with the red, green, and blue values being R, G, and B respectively, the X, Y, and Z values are obtained by the following conversion formulas (2) to (4).
Equation
Equation
Equation
[0086] Next, the signal processing circuit 112 converts the X, Y, and Z data into L * 、a * 、b * data according to the following conversion formulas (5) to (7).
Equation
Equation
Equation
[0087] In this way, the signal processing circuit 112 converts the R, G, and B values in each pixel block into three values L * a * b * in a color space different from the RGB color space. The three values L * 、a * 、b * are hereinafter referred to as L * a * b * data. By this conversion, the distance difference in the color space can be adjusted to the color difference perceived by humans regardless of the direction.
[0088] In step S165, the signal processing circuit 112 calculates, for each of the n pixel blocks, L * a * b *The L indicated by the data * a * b * The sum of the distances between the point in the color space and the L in all other pixel blocks * a * b * The L indicated by the data * a * b * Calculate the sum of the distances between the point in the color space and all other points. This process will be described with reference to FIGS. 12 and 13.
[0089] FIGS. 12 and 13 show the L of n pixel blocks * a * b * The L indicated by the data * a * b * Schematically shows an example of a plurality of points in the color space. For simplicity in this example, five points from a to e are illustrated. In FIG. 12, the distances between point a and all other points are indicated by arrows. In FIG. 13, the distances between point b and all other points are indicated by arrows. Similarly for the other points c, d, e, the L * a * b * The distance in the color space is defined. The signal processing circuit 112 * a * b * For each of the n points in the color space, calculate the sum of the distances to all other points. For the L of the i-th (where i is an integer from 1 to n) pixel block among the n pixel blocks * , a * , b * values are respectively L i , a i , b i Let it be, then the signal processing circuit 112 calculates the sum of distances Si represented by the following Equation 8 for all pixel blocks.
Equation
[0090] In step S166, the signal processing circuit 112 selects, from among the n pixel blocks, m pixel blocks (where m is an integer greater than or equal to 2 and less than n) in order from those with the smallest total distance calculated in step S165. m can be set to a number on the order of one tenth to one several tenths of the number of n. For example, when n is 100, m can be set to a number such as around 20.
[0091] FIG. 14 is a diagram showing an example of m points 320 whose total distance to other points is relatively small among n points in the color space. As shown in FIG. 14, by step S166, points with a relatively large total distance to other points are excluded, and only some points 320 with a relatively small total distance are left. Through the above processing, * a * b * data of m points located in the densely populated part of the color space is adopted. By setting the color space to * a * b * it is possible to effectively extract only approximate colors. * a * b * This makes it possible to effectively extract only approximate colors.
[0092] In step S167, the signal processing circuit 112 calculates the average value of each of the values of L * a * b * in the selected m pixel blocks, and records this average value in the memory 114 as a reference value. Instead of the average value, other representative values determined based on the values of L * a * b * in the m pixel blocks may be recorded. The reference values of L * a * b * recorded here are denoted as L r a r b r respectively.
[0093] Through the above processing, the registration of the color of the object 230 is completed. The recorded reference values L r a r br represents the reference color of the object 230 and is referred to in the color determination process (step S20) of other objects 230 of the same type.
[0094] [2-2. Color determination process] Subsequently, the color determination process of step S20 shown in FIG. 6 will be described.
[0095] FIG. 15 is a flowchart showing the flow of the color determination process. The color determination process includes steps S201 to S209. Step S201 is the same as the operations of steps S110 to S150 described with reference to FIG. 7. The processes of steps S202 to S207 are the same as the processes of steps S162 to S167 shown in FIG. 9, respectively. Therefore, the detailed description of the processes of steps S201 to S207 will be omitted. The signal processing circuit 112 calculates the respective average values of L * , a * , b * from the corrected RGB image data of the object 230 to be inspected by the processes of steps S201 to S207. The calculated average values of L * , a * , b * are taken as the measured values L m , a m , b m , respectively. Thereafter, in steps S208 and S209, the measured values L m , a m , b m are compared with the previously recorded reference values L r , a r , b r to determine the quality of the color of the object 230. Hereinafter, the processes of steps S208 and S209 will be described in more detail.
[0096] In step S208, the signal processing circuit 112 determines that the respective average values L * , a * , b * calculated in step S207 represent L m , a m , b m shown by * a * b* A point in color space and the pre-recorded L * , a * , b * of each reference value L r , a r , b r indicated by L * a * b * Calculate the distance between the point in color space and the reference values. This distance corresponds to the color difference and is represented by ΔE. The color difference ΔE is calculated by the following formula.
Equation
[0097] Thus, in this specification, the "color difference" between two colors means the distance between the two colors in color space. When the conversion from RGB to L * a * b * is performed as in this embodiment, the distance ΔE in the L * a * b * color space corresponds to the color difference. When other conversions are performed, the distance in other color spaces is calculated as the color difference. Note that instead of ΔE, (ΔE) 2 may be used as the color difference.
[0098] In step S209, the signal processing circuit 112 determines the quality of the color of the object 230 according to the calculated distance ΔE and outputs the determination result. The determination result is displayed on the display 220. ΔE is a one-dimensional numerical value and is excellent as a numerical value representing the color difference because the weights of each dimension are equal. Therefore, ΔE is convenient for measuring the difference from the reference color and determining pass or fail. Only the value of ΔE may be displayed on the display 220. However, by setting several threshold values based on this numerical value, pass / fail determination or classification can be performed. For example, if ΔE is less than the threshold value, it can be determined as "pass", and if it is greater than or equal to the threshold value, it can be determined as "fail". Alternatively, classification such as "rank A" if ΔE is less than the first threshold value, "rank B" if it is greater than or equal to the first threshold value and less than the second threshold value, and "rank C" if it is greater than or equal to the second threshold value and less than the third threshold value may be performed.
[0099] FIG. 16 is a diagram showing an example of a pass / fail determination method. (a) of FIG. 16 shows an example of pass / fail determination based on the comparison between ΔE and one threshold value. (b) of FIG. 16 shows an example of rank determination based on the comparison between ΔE and a plurality of threshold values. In the example of (a), the threshold value is set to 1.0, and if ΔE < 1.0, it is determined as "pass (OK)", and if ΔE ≧ 1.0, it is determined as "fail (NG)". In the example of (b), three threshold values 0.5, 1.0, and 1.5 are set, and if ΔE < 0.5, it is determined as "rank A", if 0.5 ≦ ΔE < 1.0, it is determined as "rank B", if 1.0 ≦ ΔE < 1.5, it is determined as "rank C", and if ΔE > 1.5, it is determined as "fail (NG)". The number of threshold values may be four or more. The larger the number of threshold values, the more classes can be classified.
[0100] In the above example, each threshold value may be set manually, but various conditions need to be considered for determining each threshold value, and it may not be easily determined in some cases. On the other hand, in this embodiment, in the process of measuring and registering the reference color, a lot of point data is obtained. Therefore, the tolerance of the color of the object to be measured can be known in advance from statistical data such as the standard deviation. Therefore, each threshold value can be determined based on statistical data such as the standard deviation. Thereby, a more appropriate pass / fail determination becomes possible.
[0101] FIG. 17 is a conceptual diagram showing an example of a pass / fail determination based on statistical data. In FIG. 17, two spheres 330 and 340 in the L * a * b * color space determined from the statistical data (i.e., n L * a * b * data) obtained in step S164 or S204 are illustrated. The inner sphere 330 can be a sphere having a radius equal to the standard deviation σ of any of the statistical data of, for example, L * 、a * 、b * 。The outer sphere 340 can be a sphere having a radius equal to 1.3 times the standard deviation σ of any of the statistical data of, for example, L * 、a * 、b * 。If the point indicated by the measured values L m 、a m 、b m is inside the inner sphere 330, it can be determined as a "high-rank product"; if it is outside the inner sphere 330 and inside the outer sphere 340, it can be determined as a "low-rank product"; and if it is outside the outer sphere 340, it can be determined as a "defective product". In the example of FIG. 17, the two spheres 330 and 340 are defined in the L * a * b * color space, but one or three or more spheres or other solids (e.g., ellipsoids) may be defined. When one solid is defined, if the point of the measurement data is inside the solid, it can be determined as a "non-defective product", and if it is outside the solid, it can be determined as a "defective product". Also, when three or more solids are defined, the object to be measured can be classified into four or more classes.
[0102] In color management, its density often becomes a problem. For example, when color unevenness occurs due to the degree of dilution of a dye or the thickness of coating, it is important to evaluate the density. In such a case, with the above display of ΔE, it is not possible to determine whether the density is higher or lower than the reference. Therefore, the signal processing circuit 112 measures the previously measured reference color L r 、a r 、b r and the measured color Lm , a m , b m , based on this, ΔL = (L m - L r ) may be calculated. Since ΔL is a parameter representing the lightness of color, a lighter color concentration will have a larger value than a darker one. Therefore, the lightness of the color concentration can be easily determined.
[0103] In such a calculation method, when the color of the object is darker (i.e., lower in lightness) than the reference color, it will be a negative value, and when the color of the object is lighter (i.e., higher in lightness), it will be a positive value. When it comes to the concentration of dyes or the thickness of coatings, this expression is different from the perception. Therefore, the signal processing circuit 112 may evaluate the concentration based on ΔL′ = (L r - L m ). By using ΔL′, when the color of the object is darker (i.e., lower in lightness) than the reference color, it will be a positive value, and when the color of the object is lighter (i.e., higher in lightness), it will be a negative value, enabling an expression that matches the perception. By displaying ΔE and ΔL’, the color difference and lightness difference of the object can be understood, facilitating pass / fail determination, ranking, and feedback to the previous process. Thus, the signal processing circuit 112 calculates the difference between the representative value Lm of one of the three values L * , a * , b * which is L * in m pixel blocks, and the reference value Lr of one of the three values L * , a * , b * which is L * pre-recorded, determines the quality of the color of the object according to the difference, and outputs the determination result.
[0104] In this embodiment, the signal processing circuit 112 performs conversion from RGB values to XYZ values, and further performs conversion to L * a * b * values, and calculates the difference between the measured L * a * b * values and the pre-registered L * a * b* Calculate the distance (i.e., color difference) calculated from the values. However, L * a * b * Not limited to conversion to these values, conversion to values in other color spaces may also be performed. For example, conversion to XYZ or L * u * v * etc. may be performed, and the same processing as described above may be applied. In that case, the distance in the other color space may be treated as the color difference.
[0105] [3. Effects] As described above, according to the present embodiment, the imaging system 100 includes an illumination device 120, an imaging device 140, a processing device 110, a color reference member 240, and a light-shielding housing 170. The illumination device 120 includes one or more light sources that respectively emit light in one or more wavelength ranges. The processing device 110 controls the illumination device 120 and the imaging device 140, and processes the signal output from the imaging device 140. The color reference member 240 reflects the light respectively emitted from the one or more light sources, and is arranged such that the reflected light is incident on the imaging device 140. The housing 170 has an opening, and houses the illumination device 120, the imaging device 140, and the color reference member 240 therein. Imaging of the object is performed in a state where the object 230 is pressed by a portion around the opening in the housing 170. The processing device 110 sequentially causes the one or more light sources to emit light, and each time light is emitted from the one or more light sources, causes the imaging device 140 to generate image data based on the light reflected by the object 230 and the color reference member 240. The processing device 110 generates and outputs identification data for identifying the color of the object 230 based on the image data.
[0106] The signal processing circuit 112 in the processing device 110 performs color registration processing and color determination processing on the object 230. In the registration processing, the signal processing circuit 112 determines n pixel blocks from the image indicated by the RGB image data acquired from the imaging device 140, and determines representative values (for example, average values) of the respective pixel values of R, G, and B for each pixel block. Then, for each pixel block, the representative values of the respective pixel values of R, G, and B are converted into three values (for example, L * a * b * in a second color space different from the RGB color space (for example, the L * a * b * values). Further, for each pixel block, the sum of the distances between the point in the second color space indicated by the three values and the points in the second color space indicated by the three values for all the other pixel blocks included in the n pixel blocks is calculated. For the m pixel blocks selected in order from those with the smallest sum of distances among the n pixel blocks, representative values (for example, average values) of the respective three values are calculated and output as reference values. The above processing can be executed for all objects that require color registration. In the color determination processing, the signal processing circuit 112 calculates representative values of the respective three values in the second color space as measurement values for the object to be measured in the same manner as described above. Then, the distance between the point in the second color space indicated by the measurement value and the point in the second color space indicated by the reference value recorded in advance is calculated. The signal processing circuit determines the quality of the color of the object according to the distance and outputs the determination result.
[0107] According to the above processing, representative values of the respective three values in the m pixel blocks selected in order from those with the smallest sum of distances among the n pixel blocks are calculated. As a result, only some pixel blocks with similar colors among the n pixel blocks are selected, and the representative values of the three values are determined based only on the data of the some pixel blocks. By such processing, for example, for an object such as a fabric or paper (especially those with large fibers) having a ground pattern or a fold, the color of the object with a non-uniform surface color can be more accurately identified or evaluated.
[0108] In conventional color measurement, the measurement results were often expressed in a standard color space of three dimensions or more, such as the XYZ color space system or the Lab color space system. However, such expressions are generally difficult to understand, and it is difficult to evaluate the color of an object. For example, when measuring the color of a manufactured product in the inspection process at a manufacturing site and determining the pass or fail of the manufactured product based on the measurement results, it is difficult to determine pass or fail with the conventional method, and it is also difficult to provide feedback to the manufacturing process. According to this embodiment, the determination result of the quality of the color of the object is displayed in an easy-to-understand manner, such as "pass", "fail", or "rank A", "rank B", "rank C". Therefore, it is possible to easily evaluate the color of the manufactured product, and for example, it becomes easier to provide feedback to the manufacturing process.
[0109] Also, according to this embodiment, the conversion coefficients used when converting the representative values of the respective pixel values of R, G, and B into three values in the second color space are determined by machine learning. Thereby, the color discrimination performance can be significantly improved.
[0110] Conventionally, in color measurement where high accuracy is required, it is required to use a camera having a predefined color filter or lighting. For example, in photographing the three primary colors of R, G, and B, the wavelengths of the respective colors are defined, and the Commission internationale de l’eclairage (CIE) has defined red (R): 700.0 [nm], green (G): 546.1 [nm], and blue (B): 435.8 [nm]. Originally, under these preconditions, the conversion from RGB to XYZ and the conversion from XYZ to L * a * b * are performed.
[0111] Since this technology does not aim at absolute value evaluation of colors, there is no necessity to accurately conform to these standards. However, it can be said that it is desirable to perform measurement using these standard wavelengths in order to measure objects of a wide range of colors with uniform sensitivity.
[0112] On the one hand, physical devices such as commonly used LEDs and cameras do not necessarily have characteristics as specified. Those close to the specified values generally tend to be large and expensive, and it is particularly difficult to approach the ideal theoretical values within limited costs and sizes. Although there is a method of photographing known colors with a physical device and correcting each coefficient of the conversion formula based on the result, there are many parameters and it is difficult to adapt to a variety of colors. For this reason, it is often only carried out for representative colors or colors with high usage frequencies.
[0113] In contrast, in the method of this embodiment, each coefficient of each conversion formula is optimized by using a machine learning algorithm such as the error backpropagation method. Therefore, the optimal coefficients can be determined without depending on the actually used device.
[0114] [4. Modification Example] Next, a modification example of the above embodiment will be described.
[0115] In the above embodiment, as an image, an RGB image including a plurality of pixels each having three pixel values corresponding to three colors of R, G, and B respectively, which is generated by imaging an object, is used. However, the image is not limited to an RGB image and may be a monochromatic, two-color, or four-color or more image. For example, as shown in FIG. 18, the lighting device 120 may include a light source 124 that emits infrared light in addition to light sources 121, 122, and 123 that emit light in the wavelength ranges of R, G, and B respectively. Also, as shown in FIG. 19, the lighting device 120 may include one light source 125 that emits light in one wavelength range.
[0116] In the above embodiment, the representative value of the pixel value of each color in each pixel block is a second color space different from the first color space composed of R, G, and B (for example, L * a * b *It is converted into a color space or the like. However, such conversion processing may be omitted. Even in such a case, for each pixel block, the sum of the values indicating the degree of difference between the representative value of each pixel value of one or more colors and the representative value of each pixel value of the one or more colors for all other pixel blocks included in the n pixel blocks is calculated. Then, among the n pixel blocks, one color value based on the representative value of each pixel value of one or more colors in the m pixel blocks (m is an integer greater than or equal to 2 and less than n) selected in order from the ones with the smallest sum of the values indicating the degree of difference is determined. By such processing, the color or density of the object can be appropriately evaluated.
Industrial Applicability
[0117] The technology of the present disclosure can be used for the purpose of identifying the color of an object. For example, it can be used for the inspection of the color of a product with a non-uniform surface color.
Explanation of Signs
[0118] 100 Imaging system 110 Processing device 111 Control circuit 112 Signal processing circuit 114 Memory 116 Input / output interface 120 Lighting device 121 First light source 122 Second light source 123 Third light source 142 Lens optical system 170 Housing 172 Light-shielding packing 174 Opening 180 Gap 220 Display 230 Object 240 Color reference plate
Claims
1. An illumination device including a plurality of light sources that respectively emit lights in a plurality of different wavelength bands, an imaging device, a processing device that controls the illumination device and the imaging device and processes a signal output from the imaging device, a color reference member that reflects the lights respectively emitted from the plurality of light sources and is arranged such that the reflected light is incident on the imaging device, a light-shielding housing having an opening and housing the illumination device, the imaging device, and the color reference member therein, a transparent plate located at the opening and for pressing an object, the transparent plate having an uneven structure on a surface on the imaging device side for suppressing light reflection, comprising, imaging of the object is performed in a state where the object is pressed by a portion around the opening in the housing, the processing device, causes the plurality of light sources to sequentially emit the light, each time the light is emitted from the plurality of light sources, causes the imaging device to generate image data based on the light reflected by the object and the color reference member, generates and outputs identification data for identifying the color of the object based on the respective image data in the plurality of wavelength bands corresponding to the plurality of light sources, the plurality of light sources, a first light source that emits light in a first wavelength band, a second light source that emits light in a second wavelength band, a third light source that emits light in a third wavelength band, including, the color reference member reflects the lights in the first to third wavelength bands with equal reflectance, the processing device, causes the first light source to emit the light in the first wavelength band, and causes the imaging device to generate first image data based on the light in the first wavelength band reflected by the object and the color reference member, causes the second light source to emit the light in the second wavelength band, and causes the imaging device to generate second image data based on the light in the second wavelength band reflected by the object and the color reference member, causes the third light source to emit the light in the third wavelength band, and causes the imaging device to generate third image data based on the light in the third wavelength band reflected by the object and the color reference member, generates corrected image data by correcting data in a region corresponding to the object in each of the first image data, the second image data, and the third image data based on data in a region corresponding to the color reference member in the image data, Extract n (n is an integer of 3 or more) pixel blocks from the corrected image data, For each of the n extracted pixel blocks, determine a representative value of the pixel values, For each of the n pixel blocks, calculate the sum of the values indicating the degree of difference between the representative value of the pixel values and the representative values of the pixel values for all other pixel blocks included in the n pixel blocks, Based on the average value of the representative values of the pixel values in m (m is an integer of 2 or more and less than n) pixel blocks selected in order from those with the smallest sum of the values indicating the degree of difference among the n pixel blocks, determine a value indicating one color, and generate the identification data based on the value, An imaging system.
2. The imaging system according to claim 1, wherein the color reference member has a reflecting surface inclined with respect to the surface including the opening.
3. The imaging device is a monochrome camera that does not acquire color information, The imaging system according to claim 1 or 2.
4. The first wavelength range is the wavelength range of red, The second wavelength range is the wavelength range of green, The third wavelength range is the wavelength range of blue, The imaging system according to any one of claims 1 to 3.
5. The processing device, Generate first color data based on the data of the region corresponding to the object in the first image data, Generate second color data based on the data of the region corresponding to the object in the second image data, Generate third color data based on the data of the region corresponding to the object in the third image data, Correct the first color data based on the data of the region corresponding to the color reference member in the first image data, Correct the second color data based on the data of the region corresponding to the color reference member in the second image data, Correct the third color data based on the data of the region corresponding to the color reference member in the third image data, Generate the identification data based on the corrected first to third color data, The imaging system according to any one of claims 1 to 4.
6. The processing device, Extract n (n is an integer of 3 or more) pixel blocks from the image indicated by the data of the region corresponding to the object in the first image data, and for each of the n extracted pixel blocks, determine a representative value of the pixel values in the first wavelength range, and generate data indicating the n representative values as the first color data. Extract n pixel blocks located at positions corresponding to the n pixel blocks from the image indicated by the data of the region corresponding to the object in the second image data, and for each of the n extracted pixel blocks, determine a representative value of the pixel values in the second wavelength range, and generate data indicating the n representative values as the second color data. Extract n pixel blocks located at positions corresponding to the n pixel blocks from the image indicated by the data of the region corresponding to the object in the third image data, and for each of the n extracted pixel blocks, determine a representative value of the pixel values in the third wavelength range, and generate data indicating the n representative values as the third color data. The imaging system according to claim 5.
7. The processing device is Based on the corrected first to third color data, for each of the n pixel blocks, convert the representative values of the pixel values in the first to third wavelength ranges into three values in a second color space different from the first color space defined by the first to third wavelength ranges. For each of the n pixel blocks, calculate the sum of the distances between the points on the second color space indicated by the three values and the points on the second color space indicated by the three values for all other pixel blocks included in the n pixel blocks. Among the n pixel blocks, calculate the representative values of the three values for m (m is an integer of 2 or more and less than n) pixel blocks selected in order from those with the smallest sum of the distances. Output the representative values of the three values as the identification data. The imaging system according to claim 6.
8. The processing device further Calculate the distance between the points on the second color space indicated by the representative values of the three values in the m pixel blocks and the points on the second color space indicated by the reference values of the three values recorded in advance. Determine the quality of the color of the object according to the distance and output the determination result. The imaging system according to claim 7.
9. The processing device further Calculate the difference between the representative value for one of the three values in the m pixel blocks and the reference value for one of the three values recorded in advance. Determine the quality of the color of the object according to the difference and output the determination result. The imaging system according to claim 7.
10. The plurality of light sources further includes a fourth light source that emits light in a fourth wavelength range. The processing device further causes the fourth light source to emit light in the fourth wavelength range, and causes the imaging device to generate fourth image data based on the light in the fourth wavelength range reflected by the object and the color reference member. Generate and output the identification data based on the first image data, the second image data, the third image data, and the fourth image data. The imaging system according to any one of claims 1 to 9.
Citation Information
Patent Citations
Apparatus for analyzing color of test sample
JP1977047785A
Measuring device and scanning device for photoelectrically measuring a measurement object on the basis of pixels
JP2008518218A
Color information identification device, color information identification method, color information identification program and recording medium storing the program
JP2009025867A
Dental colorimetric device
JP2009053160A
Image processing apparatus, image processing method and program
JP2012133607A