Inspection device and inspection method
The inspection device and method address the challenge of detecting bacteria across varying proliferation levels and foreign objects by calculating brightness statistics, excluding abnormal areas, and enhancing contrast, resulting in improved bacterial detection and image quality.
Patent Information
- Application Number
- PCT/JP2023/010897
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-03-20
- Publication Date
- 2024-09-26
AI Technical Summary
Conventional methods struggle to accurately detect and separate bacteria in images, especially when they proliferate and overlap, leading to difficulties in distinguishing individual bacteria and determining their number across a wide dynamic range, and fail to effectively handle foreign objects in images.
An inspection device and method that captures images of bacterial growth, calculates statistics related to brightness spread, excludes abnormal brightness areas, and performs contrast enhancement to sharpen images, determining the degree of proliferation based on feature amounts and outputting the determination result.
Enables accurate extraction and detection of bacteria regardless of proliferation degree and presence of foreign substances, improving image quality and bacterial detection accuracy.
Smart Images

Figure JP2023010897_26092024_PF_FP
Abstract
Description
Inspection device and inspection method
[0001] The present invention relates to an inspection device and an inspection method.
[0002] International epidemics of infectious diseases are a major concern for human health on a global scale. In recent years, various emerging infectious diseases have been spreading one after another, prompting the development of new testing methods for identifying and detecting causative viruses and bacteria, as well as new vaccines. For example, in the field of bacterial infections, the emergence of multidrug-resistant bacteria is currently a serious global problem. The U.S. CDC has identified carbapenem-resistant Acinetobacter, carbapenem-resistant Enterobacteriaceae, Clostridiodis difficile, and the fungus Candida auris as major threats. Because outbreaks of such resistant bacteria pose a high risk of patient death, it is important to rapidly identify and measure the susceptibility of the causative bacteria, detect drug-resistant bacteria, and promptly implement appropriate treatment. Mass spectrometry-based identification (ID) testing for causative bacteria has become the mainstream, enabling testing within one hour from colony or positive blood culture samples.
[0003] In addition, while turbidity measurement has been the mainstream method for evaluating bacterial drug susceptibility testing (AST), a method has also been put into practical use in which bacteria are imaged under a microscope to detect bacterial growth with higher sensitivity than conventional methods in order to speed up testing. Generally, bacteria grow twice as fast according to a certain growth cycle. Therefore, the number of bacteria present in an image captured by a microscope also grows twice as fast, exponentially, and therefore a wide dynamic range is required to accurately capture changes in growth over time.
[0004] As prior art techniques relating to detecting the growth level of bacteria from an image, those described in Patent Documents 1 to 3, for example, are known.
[0005] Patent Literature 1 discloses a method for detecting areas where bacteria exist by acquiring an image of bacteria and extracting bacterial regions through image processing. Specifically, bacterial regions are detected by combining an image of the bacterial image binarized using a certain threshold with an image binarized after contour extraction processing. This method makes it possible to accurately extract bacterial regions when the number of bacteria in the image is small and individual bacteria are captured isolated in the image.
[0006] Japanese Patent Application Laid-Open No. 2003-124222 discloses a method of adjusting contrast by expanding the histogram of image brightness values so that the brightness of an output image does not fluctuate even when the brightness of an input image changes.
[0007] Patent Document 3 discloses a method for detecting foreign objects using images. Specifically, it discloses a method for adjusting contrast by expanding the histogram of image brightness values in order to achieve good foreign object detection. With this method, when there is a pixel defect, the influence of the pixel resulting from the defect can be corrected and contrast can be enhanced.
[0008] US Patent No. 10902592 JP 2001-119683 A JP 2006-194869 A
[0009] However, the above-mentioned conventional techniques have the following problems.
[0010] In the prior art described in Patent Document 1, when bacteria grow so rapidly that they no longer appear isolated, it is difficult to separate and correctly detect individual bacteria in an image. When bacteria grow so rapidly that they no longer appear isolated, their contours become common, making it difficult to separate the boundaries between adjacent bacteria, resulting in multiple bacteria being recognized as a single large mass. Therefore, it is not easy to isolate and detect and recognize individual bacteria and detect the number of bacteria over a sufficiently wide dynamic range. Furthermore, the amount of light irradiated to the detection unit decreases due to the growth of bacteria, reducing the difference in image brightness between the background and bacterial regions in the image. This necessitates processing to appropriately adjust the contrast and extract bacteria, but it is difficult to correctly detect bacterial regions when the number of bacteria in the image differs or when foreign matter is present in the image.
[0011] Furthermore, although the conventional technology described in Patent Document 2 attempts to accurately detect foreign matter other than the target object, it does not accurately detect the target object, and is not suitable for detecting objects in images where the number of measurement targets contained in the image, such as bacteria, varies within a range of several orders of magnitude.
[0012] Furthermore, in the conventional technology described in Patent Document 3, when a foreign object other than the target object is captured in the image, correction is performed to enhance the contrast. By performing enhancement processing while excluding the influence of the foreign object, it is possible to perform image processing more accurately, but it is unclear whether the degree of corrected contrast enhancement is appropriate, and there is still room for improvement.
[0013] The present invention has been made in consideration of the above, and aims to provide an inspection device and inspection method that can more accurately extract bacteria and detect areas where bacteria exist that correspond to the degree of proliferation, regardless of differences in the degree of proliferation in images containing particulate measurement objects such as proliferating bacteria, or whether or not foreign matter other than bacteria is captured.
[0014] The present application includes multiple means for solving the above problem, and one example thereof includes an imaging unit that captures an image inside a container holding a liquid containing fine particles, and an image processing unit that performs image processing on the image captured by the imaging unit, wherein the image processing unit calculates a first statistical quantity related to the spread of brightness values of the image, excludes areas of abnormal brightness values of the image based on the results of comparing the brightness values of the image with a predetermined brightness threshold, performs a correction process to sharpen the image excluding the areas of abnormal brightness values, calculates a second statistical quantity related to the spread of brightness values of the image after the correction process, determines the validity of the correction process based on the results of comparing the ratio of the first statistical quantity and the second statistical quantity with a predetermined statistical quantity ratio threshold, determines the degree of proliferation of the fine particles based on the features of the image for which the correction process is determined to be valid, and outputs the determination result of the degree of proliferation.
[0015] According to the present invention, bacteria can be extracted more accurately in images containing particulate measurement objects such as growing bacteria, regardless of the degree of growth or whether or not foreign matter other than bacteria is visible, and the area where bacteria exist corresponding to the growth degree can be detected.
[0016] 1 is a diagram schematically showing the configuration of a bacteria testing apparatus as an example of a testing apparatus. FIG. 1 is a functional block diagram generally showing the configuration of the processing function of an image processing unit. FIG. 1 is a diagram explaining image characteristics according to the level of bacterial growth, showing an image before culture (before bacterial growth). FIG. 1 is a diagram explaining image characteristics according to the level of bacterial growth, showing an image when bacterial growth has progressed to a certain extent. FIG. 1 is a diagram explaining image characteristics according to the level of bacterial growth, showing an image when bacterial growth has progressed significantly. FIG. 1 is a diagram showing an example of a histogram of image brightness values. FIG. 1 is a diagram showing an example of a bacterial image when a correction process (contrast enhancement) of appropriate strength has been performed on the bacterial image shown in FIG. 4. FIG. 2 is a diagram showing histograms corresponding to the bacterial images of FIGS. 4 and 7 when histogram expansion has been performed as correction process (contrast enhancement). FIG. 2 is a diagram showing brightness histograms before and after histogram enhancement process when a dark object is present in the image. FIG. 3 is a diagram showing brightness histograms before and after histogram enhancement process when almost no bacteria are captured in the image. FIG. 10 is a diagram showing an example of an image after contrast enhancement process (after correction process) as shown in FIG. 11. FIG. 12 is a flowchart showing the content of bacteria detection process in the image processing unit of a bacteria testing apparatus according to a first embodiment. 14 is a diagram showing a schematic view focusing on a single bacterium in an image. FIG. 15 is a diagram showing the relationship between pixel positions and brightness values in FIG. 13. FIG. 16 is a diagram explaining the effect of image processing in an image processing unit. FIG. 17 is a diagram showing an example of an image processing result output to an input / output unit of a control device. FIG. 18 is a diagram showing an example of a brightness histogram when many foreign objects are captured in an image. FIG. 19 is a flowchart showing the contents of a part of image processing relating to a second embodiment.
[0017] This embodiment discloses a technology for, for example, performing contrast enhancement on an image of microparticles captured under a microscope in a well holding a liquid containing the microparticles, determining the appropriateness of the contrast enhancement, and accurately determining the degree of proliferation of the microparticles. Hereinafter, embodiments of the present disclosure will be described with reference to the drawings. While the accompanying drawings illustrate specific embodiments based on the principles of the present technology, these drawings are intended to facilitate understanding of the present technology and are not intended to limit the scope of the present disclosure. In addition, in the present embodiment and the drawings, components having the same function are designated by the same reference numerals, and repeated description may be omitted. Examples of microparticles include bacteria, archaea, fungi, and biological cells. Here, bacteria will be described as one type of microparticle.
[0018] First Embodiment A first embodiment of the present invention will be described with reference to FIGS.
[0019] (Bacteria Testing Device 100) FIG. 1 is a diagram showing a schematic configuration of a bacteria testing device as an example of a testing device according to this embodiment.
[0020] 1, the bacterial testing device 100 is generally composed of an illumination unit 110, a test plate 120, a stage 130, an objective lens 140, an imaging unit 150, an image processing unit 160, and a humidification and temperature adjustment unit 190. The bacterial testing device 100 also includes a control device 200 that controls the overall operation of the bacterial testing device 100.
[0021] The test plate 120 has one or more wells, preferably 96 or 384 wells, each holding a sample solution 180. The sample solution 180 contains a bacterial sample and may also contain a culture medium for bacterial growth and one or more antimicrobial agents at pre-adjusted concentrations. Because the test plate 120 varies depending on the type of bacteria and type of agent to be tested, it is preferable that multiple test plates 120, each different for each test, be installed in the bacterial testing device 100. The test plates 120 are preferably distinguished by patient ID, the type of bacteria to be tested, the type of agent to be used, etc., and are individually identified by, for example, a barcode label, a two-dimensional code, or RFID.
[0022] The illumination unit 110 irradiates light toward the test plate 120. The illumination unit 110 may be a white light source such as a lamp or a light source such as an LED that emits light in a specific wavelength range. The light irradiated from the illumination unit 110 to the test plate 120 passes through each well in the test plate 120 and the sample solution 180, is focused by the objective lens 140, and is imaged and captured by the imaging unit 150. The stage 130 may be moved, for example, under the control of the control device 200, to change the relative positions of the wells of the test plate 120 and the imaging unit 150, thereby enabling imaging of different wells. The control device 200 also controls the imaging operation, which is performed at predetermined time intervals (e.g., every 30 minutes). The obtained images are processed by the image processing unit 160 and sent to the control device 200.
[0023] The objective lens 140 is preferably focused on the bottom surface of the well of the test plate 120, but may also be focused on the interior of the sample solution 180 away from the bottom surface. Alternatively, images of multiple points within the well may be captured, or multiple images of the interior of the sample solution 180 away from the bottom surface of the well of the test plate 120 may be captured.
[0024] The humidification and temperature control unit 190 adjusts the temperature and humidity of the entire imaging system that acquires images. For example, by adjusting the temperature to approximately 35°C and the humidity to approximately 30%, bacterial growth on the test plate 120 can be efficiently promoted.
[0025] The control device 200 is, for example, a general computer that controls the entire bacterial testing device 100, including the imaging unit 150 and image processing unit 160, and has an input / output unit 210 that performs functions such as inputting various information related to testing, such as measurement conditions and setting values, to the bacterial testing device 100, and receiving and outputting (displaying) test results. The input / output unit 210 is, for example, a display, a mouse, a keyboard, a touch panel, etc.
[0026] (Image Processing Unit 160) FIG. 2 is a functional block diagram showing the outline of the configuration of the processing functions of the image processing unit.
[0027] 2, the image processing unit 160 performs a bacteria detection process of calculating and outputting the degree of bacterial growth from the image obtained by the image capturing unit 150 under the control of the control device 200, and includes an image acquiring unit 161 that acquires the image captured by the image capturing unit 150, a statistical quantity calculation unit 162 that calculates a statistical quantity relating to the spread of luminance values of the image acquired by the image acquiring unit 161, an abnormal luminance region calculation unit 163 that excludes regions of abnormal luminance values from the image based on the comparison result between the luminance value of the image and a predetermined luminance threshold value, and a correction processing unit 164 that performs a correction process to sharpen the image from which the abnormal luminance value regions have been excluded. The image processing unit 160 is generally composed of a validity determination unit 166 that determines the validity of the correction processing by the correction processing unit 164 based on the comparison result between the ratio of the statistics of the image before the correction processing and the statistics of the image after the correction processing and a predetermined statistical quantity ratio threshold value; an adjustment unit 165 that adjusts the reference value used for the correction processing by the correction processing unit 164 when the validity determination unit 166 determines that the correction processing by the correction processing unit 164 is invalid; and an image processing output unit 167 that determines the degree of proliferation of microparticles based on the features of the image for which the validity determination unit 166 determines that the correction processing by the correction processing unit 164 is valid, and outputs the determination result.
[0028] Hereinafter, details of the bacterial testing process performed by the bacterial testing device 100 (control device 200) including the image processing unit 160 (bacteria detection process) will be described.
[0029] (Basic Principle) First, the basic principle of the bacterial testing process performed by the bacterial testing device according to this embodiment will be described.
[0030] Figures 3 to 5 are diagrams explaining the characteristics of images according to the degree of bacterial growth, with Figure 3 showing an image before culture (before bacterial growth), Figure 4 showing an image when bacterial growth has progressed to a certain extent, and Figure 5 showing an image when bacterial growth has progressed significantly. Figures 3 to 5 show grayscale images with 256 gradations in 8 bits.
[0031] As shown in FIGS. 3 to 5, the image has as its main components a background region 300, a bacteria region 301, and a region of foreign matter other than the background 300 and the bacteria 301.
[0032] For example, as shown in FIG. 3, in an image before culture (before bacteria grow), most of the image is made up of a background 300, and bacteria 301 are in a tiny area.
[0033] 4, in the image taken after culturing (when the bacteria have grown to a certain extent), the bacteria have divided and grown, increasing the area of bacteria 301. Even in this case, the area of background 300 can be confirmed.
[0034] Furthermore, as shown in FIG. 5, when proliferation progresses significantly, the background 300 area becomes almost invisible, and most of the image becomes filled with the bacteria 301 area.
[0035] Fig. 6 is a diagram showing an example of a histogram for image brightness values, with the horizontal axis representing brightness in the range of 0 to 255 and the vertical axis representing the number of pixels at the corresponding brightness value. Fig. 6 shows histogram A corresponding to an image before bacterial growth (Fig. 3), histogram B corresponding to an image after bacterial growth has progressed to a certain extent (Fig. 4), and histogram C corresponding to an image after bacterial growth has progressed significantly (Fig. 5).
[0036] Histogram A, corresponding to an image before bacterial growth, exhibits a small difference between its minimum and maximum values and a steep shape. This is because the majority of the image is the background 300 region. As bacteria begin to grow, the region of bacteria 301 increases. Because the interior of the region of bacteria 301 appears brighter than the background and the outline of bacteria 301 appears darker than the background, the width of the histogram expands as bacteria grow, as shown in histogram B. As bacteria grow further, scattered light creates areas where the amount of light increases or decreases locally, further expanding the width as shown in histogram C. As bacteria grow, the histogram of the image changes as shown in histograms A, B, and C. Not only does the histogram width change, but the peak position also shifts. However, the histogram changes in a complex manner depending on factors other than the degree of bacterial growth, such as the bacterial species and strain, and therefore does not form a regular pattern. Furthermore, the histogram changes even more complexly when foreign matter other than bacteria, such as dust, dirt, air bubbles, or biological cells other than bacteria, is present in the image. As described above, it has been difficult with conventional techniques to perform correction processing such as contrast enhancement processing at an appropriate intensity on various images whose histograms change in complex ways depending on various conditions.
[0037] (Example of Correction Processing with Appropriate Intensity) Fig. 7 is a diagram showing an example of an image of bacteria when correction processing (contrast enhancement) with appropriate intensity is performed on the image of bacteria shown in Fig. 4. Fig. 8 is a diagram showing histograms corresponding to the images of bacteria in Fig. 4 and Fig. 7 when histogram expansion is performed as the correction processing (contrast enhancement).
[0038] As shown in Figure 7, when contrast enhancement is performed as a correction process on the image of bacteria shown in Figure 4 and the contrast enhancement process is performed as expected, the difference in shading between the high-luminance region inside the bacteria 301 and the low-luminance region at the outline of the bacteria 301 is emphasized compared to Figure 4. In other words, the difference in luminance between the background region 300 and the region of the bacteria 301 in the image of bacteria shown in Figure 7 is sufficiently large, making it easier to distinguish between the two and calculate the image feature amount of the bacteria. Note that, as one method of correction process, for example, histogram expansion disclosed in Patent Document 2 (Japanese Patent Laid-Open No. 2001-119683) can be used.
[0039] As shown in FIG. 8 , when performing histogram expansion for contrast enhancement on the bacteria image shown in FIG. 4 , first, the number of pixels is accumulated in descending order of brightness value for the brightness histogram B before correction, and the brightness value at which the accumulated value exceeds the reference value is set as the lower limit value B1_min of saturated brightness. The reference value can be selected as a percentage of all pixels in the target image. For example, if a percentage of 1% for a 100 x 100 pixel image is set as the reference value, the reference value becomes 100, and the lowest brightness value at which the accumulated number of pixels exceeds 100 becomes the lower limit value B1_min of saturated brightness. In other words, increasing or decreasing this percentage (reference value) changes the strength of the correction process (contrast enhancement process). Similarly, second, the number of pixels is accumulated in ascending order of brightness value for the brightness histogram B before correction, and the brightness value at which the accumulated value exceeds the reference value is set as the upper limit value B1_max of saturated brightness. Finally, the brightness of pixels corresponding to the lower limit B1_min and upper limit B1_Max of the saturation brightness are regarded as the minimum and maximum image brightness (for example, 0 and 255 in the case of an 8-bit, 256-level image), and the histogram is uniformly expanded to obtain the corrected histogram B1. Note that by expanding the histogram B before correction, the corrected histogram B1 becomes more discrete.
[0040] (Example of Correction Processing with Inappropriate Intensity) While correction processing with appropriate intensity may be performed as shown in FIGS. 7 and 8, there may be cases where enhancement processing is not performed as expected depending on the conditions of the image.
[0041] FIG. 9 shows the luminance histograms before and after the histogram enhancement process when a dark object appears in the image.
[0042] 9, when dust or bubbles are present in an image, the incident light is blocked, resulting in low-brightness regions appearing in the image, and histogram D has not only a background peak D_P1 but also a foreign-matter peak D_P2. When a simple histogram expansion as described above is performed on an image with such a histogram, the shape of the histogram remains almost unchanged before and after the correction process, as can be seen from the histogram D before the correction process and the histogram D1 after the correction process. This is equivalent to not performing histogram enhancement (correction), and there is a possibility that image processing such as distinguishing between the background and bacteria in the image or extracting features may not be performed with sufficient accuracy.
[0043] FIG. 10 shows histograms of brightness before and after histogram enhancement processing in a case where there are almost no bacteria in the image.
[0044] As shown in Fig. 10, the histogram E before correction has a steep peak near the center of the brightness range, while the peak of the histogram E1 after correction is gentler. Fig. 11 is a diagram showing an example of an image after the contrast enhancement process (correction process) shown in Fig. 10. In Fig. 11, not only is the contrast of the outline of the bacteria 301 region enhanced, but the scratch 302 region in the background 300 region is also enhanced. In other words, this is excessive histogram enhancement process that clearly captures scratches and other objects other than the bacteria 301 being inspected in the image, and can be said to be an inappropriate correction process.
[0045] In this embodiment, in consideration of the above situation, a detection device and a detection method are described below that can perform corrective processing even when particles grow like bacteria, causing large changes in particle density in an image and foreign matter is included.
[0046] (Bacteria Detection Processing) FIG. 12 is a flowchart showing the details of bacteria detection processing in the image processing unit of the bacteria testing device according to this embodiment.
[0047] As shown in FIG. 12 , in the bacteria detection process, the image acquisition unit 161 of the image processing unit 160 first acquires an image captured by the imaging unit 150 (step S100). Specifically, the image acquisition unit 161 receives the image captured by the imaging unit 150 and stores it in the internal memory (not shown) of the image processing unit 160 or the memory (not shown) of the control device 200. Note that, in images captured under favorable conditions, the interior of the bacterial region often appears white and the outline appears black, but this is not necessarily the case. In the following description, the image is assumed to be an 8-bit grayscale image, with a pixel value of 0 representing black and a pixel value of 255 representing white. Note that the processing of this embodiment is also effective for grayscale images other than 8-bit and inverted black and white images. The processing of this embodiment can also be applied to color images by converting the image into a color space such as R, G, B, or H, S, V.
[0048] After the process of step S100 is completed, the statistical quantity calculation unit 162 then calculates a statistical quantity (first statistical quantity) relating to the spread of brightness values of the image acquired by the image acquisition unit 161 (step S110). Here, the statistical quantity preferably indicates information on the pixel value histogram, i.e., the average value and standard deviation of brightness values of all pixels, for example. Information on the peak position of the histogram can be obtained from the average value of all pixels, and information on the spread of the peaks can be obtained from the standard deviation of the histogram. Note that the statistical quantity does not necessarily have to be the above; for example, the mode may be used instead of the average value of brightness values of all pixels, and the half-width of the peak may be used instead of the standard deviation.
[0049] After the processing of step S120 is completed, the abnormal brightness area calculation unit 163 calculates the abnormal brightness area of the image based on the comparison result between the brightness value of the image and a predetermined brightness threshold, and excludes the calculated area from further processing (step S120). In other words, the abnormal brightness area caused by foreign matter contained in the image is calculated. Specifically, foreign matter often absorbs, reflects, or scatters the illuminating light, and therefore often has a brightness value near the lower or upper limit. Therefore, a lower or upper brightness threshold is set as the brightness threshold, and pixels with brightness values below the lower threshold or exceeding the upper threshold are extracted as pixels in the abnormal brightness area. In other words, the extracted pixels are excluded from further processing. Note that when extracting pixels in the abnormal brightness area, both a lower and upper brightness threshold may be set and pixels with brightness values outside the respective thresholds may be excluded, or only one of the lower and upper brightness thresholds may be set and pixels with brightness values outside the threshold may be excluded. Furthermore, the upper and lower thresholds may be appropriately changed depending on the condition of the sample.
[0050] After the process of step S120 is completed, the correction processing unit 164 then performs a correction process to sharpen the image excluding the area with abnormal brightness values (step S130). Specifically, the correction process is performed by excluding the abnormal brightness area extracted in step S120. One example of the correction process is contrast enhancement by expanding the histogram. At this time, when calculating the lower and upper limits of saturation brightness by cumulative calculation, the abnormal brightness area is excluded from the cumulative calculation, thereby eliminating the influence of foreign matter on contrast enhancement.
[0051] After the process of step S130 is completed, the statistical quantity calculation unit 162 calculates a statistical quantity (second statistical quantity) relating to the spread of luminance values of the image corrected by the correction processing unit 164 (step S140). That is, the second statistical quantity of pixel values is calculated for the image corrected by step S130. At this time, it is preferable to calculate the average value and standard deviation of luminance of all pixels, similar to the first statistical quantity.
[0052] After the process of step S140 is completed, the appropriateness determination unit 166 determines the appropriateness of the correction process performed by the correction processing unit 164 based on the comparison result of the ratio between the statistics of the image before the correction process (first statistics) and the statistics of the image after the correction process (second statistics) with a predetermined statistics ratio threshold (step S150). Specifically, the ratio of the pixel average values before and after the correction process and the ratio of the standard deviations are first calculated. A high standard deviation ratio indicates excessive contrast enhancement. For example, the standard deviation ratio is compared with a certain threshold (statistics ratio threshold: e.g., 5). If the ratio is equal to or greater than the threshold, the contrast enhancement is determined to be excessive, i.e., inappropriate. The statistics ratio threshold is determined through prior experiments, etc. (described below). Furthermore, if the ratio of the average values to the standard deviations is close to 1, it indicates that the correction process has had little effect, and the contrast enhancement is determined to be insufficient, i.e., inappropriate. Otherwise, the contrast enhancement is determined to be appropriate.
[0053] After the process of step S150 is completed, it is then confirmed whether the validity determination unit 166 has determined that the correction process of the correction processing unit 164 is valid (step S160).
[0054] If the determination result in step S160 is NO, i.e., if the validity determination unit 166 determines that the correction processing by the correction processing unit 164 is invalid, the adjustment unit 165 adjusts the reference value used in the correction processing by the correction processing unit 164 (step S161) and returns to the processing of step S120. That is, the processing of step S160 is processing in which an additional correction processing (step S130) and a re-determination (step S161) are performed as necessary. Specifically, if the contrast enhancement processing is invalid (not appropriate), for example, if the contrast enhancement processing is excessive, the reference value for the cumulative determination may be set to a low value and the intensity of the enhancement processing may be weakened, or the process may proceed to the next processing (step S170) without performing the contrast enhancement processing. Alternatively, if the contrast enhancement processing is insufficient, the reference value for the cumulative determination may be set to a high value and the intensity of the enhancement processing may be increased, or an abnormality flag may be added to the image indicating that a foreign object that was not removed by the processing of step S120 is captured in the image. In this embodiment, the processes of steps S120 to S160 and S161 are repeatedly executed until it is determined that the correction process is appropriate, and the range of the abnormal brightness area and the strength of contrast enhancement are sequentially changed while the process is executed until the appropriate correction process is performed.
[0055] Furthermore, if the determination result in step S160 is YES, i.e., if the validity determination unit 166 determines that the correction processing by the correction processing unit 164 is valid, the image processing output unit 167 determines the degree of growth of particles based on the feature values of the image for which the correction processing was determined to be valid, and outputs the determination result to the control device 200 (step S170). Specifically, the image processing output unit 167 performs a series of image processing on the image for which the correction processing has been completed, such as edge extraction processing, processing for detecting maximum or minimum regions by comparing the brightness values with neighboring pixels, and binarization, and calculates and outputs numerical information from the image. In the case of bacterial testing, it is important to calculate the degree of bacterial growth, and for regions recognized as bacteria in the image, it calculates feature values indicating the number of bacteria, the area of each region, the total area, and shape information for each region (e.g., circularity, roundness, perimeter, convexity, aspect ratio).
[0056] Here, a method for setting the statistical quantity ratio threshold used in the validity determination unit 166 in the process of step S150 in FIG. 12 will be described.
[0057] Fig. 13 is a diagram showing a schematic diagram focusing on a single bacterium in an image, and Fig. 14 is a diagram showing the relationship between pixel positions and brightness values in Fig. 13 .
[0058] In Figure 13, compared to the background 300, the interior 700 of the bacterium 301 region appears with a higher brightness value, while the outline 701 of the bacterium 301 region appears with a lower brightness value. Furthermore, the boundary 702 between the outline of the bacterium 301 region and the background appears with a slightly higher brightness value than the background. In such a case, the distribution of brightness values along a line crossing the bacterium 301 region in Figure 13 is as shown in Figure 14. As shown in Figure 14, the distribution of brightness values is symmetrical, with a maximum peak 703 inside the bacterium 301 region as the center, a minimum peak on the bacterium outline, and a maximum peak 704 at the boundary between the bacterium and the background, and the amplitudes gradually decrease. In this embodiment, the bacterium region is determined in the processing of step S170, by searching for the maximum peak 703 inside the bacterium region, for example. On the other hand, if it is determined in the process of step S160 that the contrast enhancement process has been performed excessively, it is considered that the maximum peak 704 at the boundary between the bacteria and the background has also been amplified, and therefore it may become impossible to distinguish between the two maximum peaks by simple threshold determination. Therefore, the maximum peak 704 at the boundary between the bacteria and the background can be regarded as noise, and it is preferable to perform contrast enhancement within a range in which this noise does not affect detection.
[0059] In this embodiment, the noise value is approximately 10. Contrast enhancement processing also increases noise. For example, if the standard deviation ratio calculated in step S140 is 5, the noise is (initial value 10) × (standard deviation ratio 5) = 50. That is, if a threshold value of 50 is used to determine the bacteria region in step S170, the ring-shaped region at the boundary 702 between the bacterial outline and the background, which is noise, will be mistakenly recognized as a bacteria. From the above, it can be said that the threshold used to determine whether the contrast enhancement processing is excessive is preferably (threshold value used to determine the bacteria region in step S170) ÷ (noise value). In this embodiment, the maximum peak 704 at the boundary between the bacteria 301 region and the background is the dominant noise. However, if the background noise in the background 300 region is large, for example, the value of this background noise can be used to determine the optimal threshold.
[0060] (Effect) FIG. 15 is a diagram for explaining the effect of image processing in the image processing unit.
[0061] In Figure 15, the image processing unit 160 performs correction and binarization on images of bacteria that are clearly growing normally and that were acquired by the imaging system of the bacteria testing device 100 according to this embodiment, and the number of detected bacteria is displayed as a time series.
[0062] In FIG. 15, data 800 is the result when the correction process of the prior art is used, and data 801 is the result when the correction process determined to be appropriate according to this embodiment is used.
[0063] As shown in Figure 15, at time 0, the output value of data 800 is larger, more than 10 times higher. This is because the contrast enhancement process was excessive when the number of bacteria was small, resulting in the scratches on the well bottom being mistakenly identified as bacteria.
[0064] From time 7 onwards, the output value of data 800 according to the conventional technology is small and gradually decreases, whereas data 801 according to the present embodiment accurately shows the increase and saturation of bacteria in accordance with the changes in the bacterial image acquired, which indicates the expected normal bacterial growth. This is because, in data 800 according to the conventional technology, foreign matter floating in the well appears in the image from time 7 onwards, resulting in insufficient contrast enhancement, whereas data 801 according to the present embodiment allows for contrast enhancement to be performed at an appropriate intensity.
[0065] As described above, in this embodiment, by appropriately performing contrast enhancement processing, accurate image processing can be performed even when the density of the object, such as bacteria, varies greatly and foreign matter is included.
[0066] (Result Output) FIG. 16 is a diagram showing an example of the image processing result output to the input / output unit of the control device.
[0067] FIG. 16 shows the results of the bacterial detection process by the image processing unit 160, in other words, the results of the bacterial testing process by the bacterial testing device 100 (control device 200), which is shown to the user, for example, by being displayed in the form of a GUI (Graphical User Interface) on the input / output unit 210 of the control device 200.
[0068] As shown in FIG. 16, the results of the bacterial testing process are displayed on a measurement condition display section 211, a measurement result display section 212, an apparatus status display section 213, and the like, which allow the display contents to be switched in tab format.
[0069] The measurement result display section 212 displays, as the results of the bacterial testing process, for example, the ID of the specimen to be tested, the current measurement state of the specimen to be tested, the measurement results, and the output results 212a of the image processing.
[0070] The sample measurement status column preferably displays the current measurement time, the time remaining until the measurement is completed, instructions to the user to remove the plate, and the like.
[0071] The measurement results column preferably displays the presence or absence of errors and warnings during measurement, as well as error information determined by image processing, such as the presence or absence of foreign matter. It is also preferable to include a plot of the time-dependent change in numerical information calculated by image processing, which is useful for intuitively showing the level of bacterial growth to the user. Specifically, each square point in this plot represents a point where a measurement was performed, and if a foreign matter is present, the condition may be clearly indicated by displaying it in a different color or shape from the others. It is also preferable that the user be able to select the relevant plot to view details of the error and the corresponding image.
[0072] The measurement condition display unit 211 displays the conditions for carrying out a bacterial test and allows input and output. For example, the measurement conditions for the test, such as the type of bacteria to be tested, the drug, the test time, and the image capture cycle, are displayed, and output from the user is also possible.
[0073] The device status display unit 213 displays information indicating the device status and is capable of inputting and outputting information, such as device error and warning information, temperature and humidity information, device door open / close information, device maintenance information, and various device setting information, and can also receive output from the user.
[0074] As described above, this embodiment is configured to include an imaging unit that captures an image of the inside of a container holding a liquid containing fine particles, and an image processing unit that performs image processing on the image captured by the imaging unit. The image processing unit calculates a first statistical quantity related to the spread of brightness values of the image, excludes areas of the image with abnormal brightness values based on the results of comparing the brightness values of the image with a predetermined brightness threshold, performs a correction process to sharpen the image excluding the areas of abnormal brightness values, calculates a second statistical quantity related to the spread of brightness values of the corrected image, determines the appropriateness of the correction process based on the results of comparing the ratio of the first statistical quantity to the second statistical quantity with a predetermined statistical quantity ratio threshold, determines the proliferation degree of fine particles based on the features of the image for which the correction process is determined to be appropriate, and outputs the proliferation degree determination result.Therefore, it is possible to more accurately extract bacteria and detect areas where bacteria exist corresponding to the proliferation degree, regardless of differences in the degree of proliferation in images containing particulate measurement objects such as proliferating bacteria, or whether or not foreign matter other than bacteria is captured.
[0075] Second Embodiment A second embodiment of the present invention will be described with reference to Figures 17 and 18. In the figures, the same members as those in the first embodiment are denoted by the same reference numerals, and the description thereof will be omitted where appropriate.
[0076] In this embodiment, the threshold value is changed depending on whether or not there is a foreign object in the image, thereby making it possible to deal with cases where a larger number of foreign objects are captured in the image.
[0077] In the first embodiment, when performing contrast enhancement processing, the number of pixels is accumulated in descending order of brightness value, and the point where the accumulated value exceeds a reference value is set as the lower limit value B1_min of saturation brightness, and the number of pixels is accumulated in ascending order of brightness value, and the point where the accumulated value exceeds the reference value is set as the upper limit value B1_Max of saturation brightness (see Figure 8). This method is simple because it only requires setting a certain reference value, and it is possible to exclude foreign matter by combining it with the calculation of abnormal brightness areas, but it is possible that appropriate correction processing cannot be performed in situations where a large number of foreign matter appear in the image.
[0078] FIG. 17 is a diagram showing an example of a luminance histogram when many foreign objects appear in an image.
[0079] As shown in Figure 17, in histogram F, a foreign substance peak F_P2 and a second foreign substance peak F_P3 are present to the left of the background region peak F_P1. This means that there are at least two regions corresponding to foreign substances with different brightness levels in the image. Furthermore, the foreign substance peak F_P2 and the second foreign substance peak F_P3 cannot be clearly separated on histogram F. In this case, if the brightness value intermediate between the foreign substance peak F_P2 and the second foreign substance peak F_P3 is selected as the abnormal brightness threshold TH1, it is impossible to eliminate the influence of the pixels of the second foreign substance. Therefore, in this embodiment, a method is shown that can more accurately exclude foreign substance regions and perform contrast enhancement processing.
[0080] FIG. 18 is a flowchart showing part of the image processing according to this embodiment.
[0081] Fig. 18 shows processing that is performed between the processing of step S120 and the processing of step S130 in the flowchart of the first embodiment shown in Fig. 12. The following processing can be performed for both the lower limit and the upper limit of saturation brightness, but the following description will be given taking as an example the case where the processing is performed for the lower limit of saturation brightness.
[0082] After the process of step S120 (see FIG. 12) is completed, it is next determined whether or not a foreign object is present in the image based on the calculation result of the abnormal brightness area (step S121). For example, assuming that the initial value of the abnormal brightness threshold is 40, the reference value is 1%, and the image size is 100 x 100 pixels, it is determined that a foreign object is present if there are 100 or more pixels with a brightness of less than 40, and otherwise it is determined that no foreign object is present.
[0083] If the determination result in step S121 is NO, that is, if it is determined that no foreign object is present, the process proceeds to step S140 (see FIG. 12).
[0084] If the determination result in step S121 is YES, i.e., if it is determined that a foreign object is present, a search for an appropriate abnormal brightness threshold is performed (step S122). Specifically, the most frequent value of the brightness histogram is first calculated, and then a search is performed in descending order to find a minimum value on the histogram. Since the distribution of the histogram is not necessarily smooth, it is preferable to perform smoothing processing or low-pass filtering, and then calculate the first and second derivatives of the histogram to search for a minimum brightness value. Alternatively, signal processing such as curve fitting may be performed.
[0085] When the process of step S122 is completed, it is then determined whether or not a minimum value equal to or greater than the abnormal brightness threshold value has been found (step S123).
[0086] If the determination result in step S123 is YES, that is, if a minimum value is found and the minimum value is equal to or greater than the initial value of the abnormal brightness threshold, the found minimum value is replaced with the abnormal brightness threshold (step S124), and processing proceeds to step S130 (see Figure 12).
[0087] Furthermore, if the judgment result in step S122 is NO, that is, if no minimum value is found, or if a minimum value is found but is less than the initial value of the abnormal brightness threshold or is some other invalid value, the abnormal brightness threshold is left at the initial value (step S125), and processing proceeds to step S130 (see FIG. 12).
[0088] The other configurations are the same as those of the first embodiment.
[0089] The present embodiment configured as above can also achieve the same effects as the first embodiment.
[0090] Furthermore, it is possible to set an appropriate abnormal brightness threshold for each image and perform correction processing that excludes abnormal areas. Therefore, even when there are multiple peaks of foreign matter, as in the histogram shown in FIG. 17, it is possible to select an appropriate abnormal brightness threshold TH2.
[0091] <Additional Notes> The functions of each embodiment can also be realized by software program code. In this case, a storage medium on which the program code is recorded is provided to a system or device, and the computer (or CPU or MPU) of the system or device reads the program code stored in the storage medium. In this case, the program code itself read from the storage medium realizes the functions of the above-mentioned embodiments, and the program code itself and the storage medium on which it is stored constitute the present disclosure. Examples of storage media for supplying such program code include flexible disks, CD-ROMs, DVD-ROMs, hard disks, optical disks, magneto-optical disks, CD-Rs, magnetic tape, non-volatile memory cards, and ROMs.
[0092] Furthermore, an operating system (OS) running on a computer may perform some or all of the actual processing based on instructions in the program code, and the functions of the above-described embodiments may be realized by this processing.Furthermore, after the program code is read from a storage medium and written to memory on the computer, a CPU of the computer may perform some or all of the actual processing based on instructions in the program code, and the functions of the above-described embodiments may be realized by this processing.
[0093] Furthermore, the program code of the software that realizes the functions of the embodiments may be distributed via a network and stored in a storage means such as a hard disk or memory of the system or device, or in a storage medium such as a CD-RW or CD-R, so that when used, the computer (or CPU or MPU) of the system or device reads and executes the program code stored in the storage means or storage medium.
[0094] It should also be understood that the processes and techniques described herein are not inherently related to any particular apparatus, but may be implemented by any suitable combination of components. Furthermore, various types of general-purpose devices can be used in accordance with the teachings of the present invention. It may prove useful to construct specialized apparatus to perform the method steps described herein. Various inventions can also be formed by suitable combinations of multiple components disclosed in the embodiments. For example, some components may be omitted from all of the components shown in the embodiments. Furthermore, components from different embodiments may be combined as appropriate. While the present disclosure has been described with reference to specific examples, these are intended in all respects to be illustrative and not limiting. Those skilled in the art will recognize that there are numerous combinations of hardware, software, and firmware suitable for practicing the present disclosure. For example, the described software can be implemented in a wide variety of programming or scripting languages, such as assembler, C / C++, Perl, Shell, PHP, Java, etc.
[0095] Furthermore, in the above-described embodiment, the control lines and information lines are those that are considered necessary for the explanation, and not all control lines and information lines in the product are necessarily shown. All components may be interconnected.
[0096] Furthermore, the present disclosure is not limited to the above-described embodiments and examples, but includes various modifications. The above-described embodiments have been described in detail to clearly explain the technology of the present disclosure, and are not necessarily limited to those including all of the described configurations. Furthermore, it is possible to replace part of the configuration of one embodiment with the configuration of another embodiment, or to add the configuration of another embodiment to the configuration of one embodiment. Furthermore, it is possible to add, delete, or replace part of the configuration of each embodiment with other configurations.
[0097] 100...bacteria testing device, 110...illumination unit, 120...test plate, 130...stage, 140...objective lens, 150...imaging unit, 160...image processing unit, 161...image acquisition unit, 162...statistics calculation unit, 163...abnormal brightness area calculation unit, 164...correction processing unit, 165...adjustment unit, 166...validity determination unit, 167...image processing output unit, 180...sample solution, 190...humidification temperature adjustment unit, 200...control device, 210...input / output unit, 211...measurement condition display unit, 212...measurement result display unit, 212a...output result, 213...device status display unit, 300...background, 301...bacteria, 302...wound
Claims
1. An inspection device comprising: an imaging unit which captures an image of the inside of a container holding a liquid containing fine particles; and an image processing unit which performs image processing on the image captured by the imaging unit, wherein the image processing unit: calculates a first statistical quantity relating to the spread of luminance values of the image; excludes areas of abnormal luminance values of the image based on a result of comparing the luminance values of the image with a predetermined luminance threshold; performs a correction process to sharpen the image from which the areas of abnormal luminance values have been excluded; calculates a second statistical quantity relating to the spread of luminance values of the image after the correction process; judges the appropriateness of the correction process based on a result of comparing a ratio of the first statistical quantity and the second statistical quantity with a predetermined statistical quantity ratio threshold; judges the degree of proliferation of the fine particles based on features of the image for which the correction process is judged to be appropriate; and outputs the judgment result of the degree of proliferation.
2. An inspection device according to claim 1, wherein said image processing section calculates a standard deviation of brightness values of said image as said first statistical quantity and said second statistical quantity.
3. An inspection device according to claim 1, wherein the image processing unit calculates a half-width of a histogram of brightness values of the image as the first statistical quantity and the second statistical quantity.
4. An inspection device according to claim 1, wherein the image processing unit calculates average values of luminance values of the image as the first statistical quantity and the second statistical quantity.
5. An inspection device according to claim 1, wherein the correction process is a process for enhancing the contrast of the shading of the image by expanding a histogram of the luminance values of the image in the luminance value direction.
6. An inspection device according to claim 1, characterized in that the correction process is a process for emphasizing the contrast between light and dark in the image by searching for extreme values in ascending or descending order from the peak value of a histogram of brightness values of the image, determining at least one brightness value which is a minimum brightness value on the histogram, and stretching the histogram of brightness values of the image in the brightness value direction with the brightness value set as a lower limit or upper limit.
7. An inspection device according to claim 1, wherein the image processing unit cancels the correction process for the image for which the correction process is determined to be inappropriate, or performs additional correction process.
8. An inspection device according to claim 7, wherein the correction process is a process of searching for extreme values in ascending or descending order from the peak value of a histogram of brightness values of the image, determining at least one brightness value which is a minimum brightness value on the histogram, and stretching the histogram of brightness values of the image in the brightness value direction with the brightness value set as a lower limit or upper limit, thereby emphasizing the contrast of shading in the image, and wherein the additional correction process is a process of changing at least one of the lower limit and the upper limit when stretching the histogram, thereby emphasizing the contrast of shading in the image.
9. In the inspection device described in claim 1, the image processing unit performs a binarization process on the image for which the correction process is determined to be appropriate, detects areas of fine particles in the image using the binarization process, calculates features related to the number and shape of the fine particles, and determines the degree of proliferation of the fine particles from the features.
10. An inspection method comprising the steps of: calculating a first statistical quantity relating to the spread of brightness values of an image captured inside a container holding a liquid containing fine particles; excluding areas of abnormal brightness values of the image based on a comparison result between the brightness values of the image and a predetermined brightness threshold; performing a correction process to sharpen the image from which the areas of abnormal brightness values have been excluded; calculating a second statistical quantity relating to the spread of brightness values of the image after the correction process; determining the validity of the correction process based on a comparison result between the ratio of the first statistical quantity and the second statistical quantity and a predetermined statistical quantity ratio threshold; determining the degree of proliferation of the fine particles based on features of the image for which the correction process is determined to be valid; and outputting the determination result of the degree of proliferation.
Citation Information
Patent Citations
Analysis of images of biological material
US10902592B2
Image sensor device
JP2001119683A
Automatic testing equipment and debris inspection method
JP2006194869A
Testing apparatus and testing method
WO2020178931A1
