Specimen liquid inspection device, program, and recording medium

The urine testing device uses image processing and threshold-adjusted binarization to reliably detect reagent pad attachment on urine test strips, addressing peeling issues and enhancing test accuracy.

WO2026028685A1PCT designated stage Publication Date: 2026-02-05ARKRAY INC
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
PCT/JP2025/023323
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-08-01
Filing Date
2025-06-27
Publication Date
2026-02-05

AI Technical Summary

Technical Problem

Existing urine test strips face issues with reagent pads peeling off, leading to false positive or negative determinations due to difficulty in reliably detecting proper attachment, especially with varying reagent pad colors and backgrounds.

Method used

A urine testing device uses image processing to capture and analyze reagent pad images, employing threshold adjustments for binarization to determine the presence of a rectangular shape, ensuring accurate detection of reagent pad attachment.

Benefits of technology

Stably detects color changes and abnormal states, such as reagent pad detachment, improving the reliability of urine test results by preventing false determinations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure JP2025023323_05022026_PF_FP_ABST
    Figure JP2025023323_05022026_PF_FP_ABST
Patent Text Reader

Abstract

An image processing unit 21 cuts out a partial region of an image of a urine test paper, and generates, as a reagent pad image, an image including the outer region of the outer edge of a reagent pad. An abnormality detection unit 23 cuts out only a test paper region from the reagent pad image to generate a reagent pad cutout image, binarizes the generated reagent pad cutout image using a threshold value that is a maximum value or a minimum value of a predetermined luminance range, and determines whether or not a rectangular shape can be detected. If the abnormality detection unit 23 fails to detect a rectangular shape, the abnormality detection unit 23 repeats binarization processing by raising or lowering the threshold value until a rectangular shape can be detected or until every luminance value in the predetermined luminance range is used as the threshold value. If a rectangular shape can be detected with any threshold value, the abnormality detection unit 23 determines that the reagent pad did not fall off, and if no rectangular shape can be detected, the abnormality detection unit 23 determines that the reagent pad has fallen off.
Need to check novelty before this filing date? Find Prior Art

Description

Sample fluid testing device, program and recording medium

[0001] The present disclosure relates to a sample fluid testing device, a program, and a recording medium.

[0002] A urine test strip is equipped with multiple reagent pads, each containing a different reagent. In a qualitative urine test, the urine to be tested is applied to each of the multiple reagent pads, and the amount of a specific component in the urine and whether or not the specific component is present (positive or negative) are determined by detecting the color of the color reaction on the reagent pads to which the urine is applied.

[0003] For example, Patent Document 1 listed below discloses a measurement system that measures the reflectance of light irradiated onto a reagent pad attached to a urine test strip, thereby measuring the concentration of specific components in a urine sample, such as glucose, hemoglobin, and albumin.

[0004] The reagent pad is attached to the urine test strip, for example, by adhesive. Although rare, there is a possibility that the reagent pad may peel off and fall off the urine test strip. If a qualitative test is performed with the reagent pad detached from the urine test strip, the qualitative test for the test item corresponding to the detached reagent pad will not be performed correctly. This may result in a false positive determination for a test item that would normally have detected an abnormality, or a false negative determination for a test item that would normally have been detected.

[0005] Patent Document 1: Japanese Patent Application Laid-Open No. 2016-206185

[0006] To prevent such erroneous judgments, it is necessary to confirm that the reagent pad is properly attached to the urine test strip. If an abnormality such as the reagent pad falling off the urine test strip is detected, the urine test strip from which the reagent pad has fallen off should be discarded, and the process of applying urine to another urine test strip should be repeated.

[0007] However, the colors of the multiple reagent pads attached to the urine test strip vary greatly depending on the original color of the reagent contained in the reagent pad. Furthermore, because the color of each reagent pad changes when urine is applied, the color of each reagent pad also varies greatly after urine is applied. Furthermore, some of the multiple reagent pads are close to the white background color of the urine test strip. Therefore, even if an attempt is made to detect whether a reagent pad has fallen off based on an image that includes the outer frame of the reagent pad, it is difficult to determine whether the reagent pad has been properly attached using a certain threshold value.

[0008] Therefore, the technology disclosed herein aims to provide a sample fluid testing device, program, and recording medium that can reliably determine whether a reagent pad, which changes color due to a color reaction, has fallen off a urine test strip or is properly attached.

[0009] In one aspect of the sample liquid testing device of the present disclosure, a camera captures an image of a thin test paper having a predetermined width and length, with multiple rectangular reagent pads placed at intervals along the length and having a height dimension that is approximately the same as the width. Next, an image processing unit crops a portion of the test paper image captured by the camera to generate a reagent pad crop image for each reagent pad, which is an image of an area larger than the shape of the reagent pad and includes an outer region of the reagent pad. The abnormality detection unit then binarizes the cropped reagent pad image using a maximum or minimum value within a predetermined brightness range as a threshold value and determines whether a rectangular shape can be detected. If a rectangular shape is not detected, the abnormality detection unit raises or lowers the threshold value and repeats the binarization process until a rectangular shape is detected or until all brightness values ​​within the predetermined brightness range are used as the threshold value. If a rectangular shape is detected at any threshold value, the device determines that the reagent pad has not fallen off. If a rectangular shape is not detected even when all brightness values ​​within the predetermined brightness range are used as the threshold value, the device determines that the reagent pad has fallen off.

[0010] According to the technology disclosed herein, when determining the color change of a reagent pad attached to a urine test strip using an image, it is possible to stably detect the color change of the reagent pad and detect an abnormal state in which the reagent pad has fallen off or an abnormal spotting condition.

[0011] 1 is a schematic perspective view showing an example of a urine testing apparatus 10 according to an embodiment of the present disclosure. FIG. 2 is a block diagram showing an example of the configuration of the urine testing apparatus 10 according to an embodiment of the present disclosure. FIG. 3 is a schematic view showing an example of the configuration of the main parts of the urine testing apparatus 10 according to an embodiment of the present disclosure. FIG. 4 is a perspective view showing how an image of a urine test strip 8 onto which a urine sample has been applied is captured by a camera 13. FIG. 5 is a block diagram showing an example of the functional configuration of a control unit 11 according to an embodiment of the present disclosure. FIG. 6 is a flowchart showing an outline of the overall operation of the urine testing apparatus 10 according to an embodiment of the present disclosure. FIG. 7 is a diagram showing an example image of a urine test strip 8 captured by a camera 13, and how a first clipped image 61 and a second clipped image (reagent pad image) 62 are clipped from an image of a certain reagent pad. FIG. 8 is a diagram showing how the image processing unit 21 clips the second clipped image 62 for each reagent pad 80. FIG. 9 is a diagram showing an example image of a urine test strip 8 from which a certain reagent pad 80 has fallen off. 10(A) shows an example of an image of an actual urine test strip 8 captured by the camera 13, and FIG. 10(B) shows an example of an actual reagent pad image obtained by cutting out an image including the outer edge of one reagent pad 80 from the example image of the urine test strip 8 shown in FIG. 10(A) as a reagent pad image. FIGS. 11(A) and 11(B) show how the color of the reagent pad changes due to a color reaction, and FIG. 11(C) shows an example of a reagent pad image of a light-colored reagent pad. This is a flowchart for explaining the details of the process for generating a reagent pad cutout image (step S103) in the flowchart of FIG. 6. This is a diagram showing how two minimum rectangles with a percentage of white pixels equal to or greater than a preset value are detected between the threshold values ​​of 255 and 0. This is a diagram showing how a reagent pad cutout image is generated by cutting out the regions sandwiched between the upper and lower bases of the two minimum rectangles detected in the reagent pad image. This is a flowchart for explaining the details of the process for determining whether a reagent pad has fallen off (step S104) in the flowchart of FIG. 6. 10 is a diagram showing how the minimum rectangle with a proportion of black pixels equal to or greater than a preset value is detected when the reagent pad is in a normal state, with the threshold value varying from 255 to 0. FIG. 11 is a diagram showing an example of an image of a reagent pad cut out when the reagent pad has fallen off a urine test strip.FIG. 10 is a diagram showing how, when the threshold value changes from 255 to 0, a minimum rectangle in which the proportion of black pixels is equal to or greater than a preset value is not detected when the reagent pad is in a detached state.

[0012] Next, embodiments of the present disclosure will be described in detail with reference to the drawings.

[0013] An example of an embodiment of the technology of the present disclosure will be described below with reference to the drawings. Note that components and processes that perform the same operations, actions, and functions are given the same reference numerals throughout the drawings, and redundant explanations may be omitted as appropriate. Each drawing is merely a schematic illustration to allow a sufficient understanding of the technology of the present disclosure. Therefore, the technology of the present disclosure is not limited to the illustrated examples. Furthermore, in this embodiment, explanations of configurations that are not directly related to the present disclosure or well-known configurations may be omitted.

[0014] FIG. 1 is a schematic perspective view showing an example of a urine testing apparatus 10 according to an embodiment of the present disclosure.

[0015] As shown in Figure 1, the urine testing apparatus 10 of this embodiment is made up of a main body 1 and a transport device 2. The urine testing apparatus 10 is used to perform an analytical process on a urine sample contained in, for example, a container 30, and is configured such that the transport device 2 is assembled to the front surface of the main body 1.

[0016] When a urine sample is analyzed, the test strip used is a urine test strip that includes reaction areas for multiple test items, such as urinary protein, urinary ketone bodies, and urinary sugar. The sample to be analyzed is not limited to a urine sample, and may be a biological component other than urine (e.g., blood, plasma, saliva, etc.). The sample may also be a liquid for water quality testing.

[0017] The transport device 2 is a device for transporting racks holding upright containers 30 along a fixed route. When a rack holding containers 30 is placed in a predetermined area, the transport device 2 transports the rack in sequence in the direction indicated by the arrow in the figure. During the process of transporting the rack, urine samples are collected from the containers 30 by the suction nozzle 50.

[0018] The main body 1 is provided with an operation panel 20 and a printer 17. The operation panel 20 displays the operation screen of the urine testing apparatus 10 and accepts operation input from the user via this operation screen. The printer 17 prints and outputs the analysis results of the urine sample on a predetermined form.

[0019] FIG. 2 is a block diagram showing an example of the configuration of the urine testing apparatus 10 according to this embodiment.

[0020] As shown in Figure 2, the main body 1 of the urine testing apparatus 10 of this embodiment includes a control unit 11, a spotting device 12, a camera 13, an operation panel 20, a urine test paper supply device 14, a memory unit 15, a communication unit 16, and a printer 17.

[0021] The control unit 11 includes a processor such as a CPU (Central Processing Unit), and controls the operation of each unit of the urine testing apparatus 10 and performs various types of data processing in accordance with a control program stored in the storage unit 15 .

[0022] The storage unit 15 is accessible by the control unit 11, and stores control programs for controlling the operation of each unit of the urine testing apparatus 10 and for executing various types of data processing, as well as various types of data.

[0023] The communication unit 16 performs data communication with an external device or the like by wireless communication such as a wireless LAN (Local Area Network) or by wired communication using a communication cable or the like.

[0024] The functions of the spotting device 12, the camera (photographing unit) 13, and the urine test paper supply device 14 will be described with reference to FIGS.

[0025] FIG. 3 is a schematic diagram showing an example of the configuration of the main parts of the urine testing apparatus 10 according to this embodiment.

[0026] As shown in Figure 3, the urine test strip supplying device 14 is a device for supplying urine test strips 8 for performing qualitative tests on urine samples to a predetermined location P1. The spotting device 12 uses a suction nozzle 50 to collect a urine sample from a container 30 and deposits the collected urine sample on a urine test strip 8 supplied to the predetermined location P1. The suction nozzle 50 is movable vertically and horizontally by a drive mechanism (not shown).

[0027] FIG. 4 is a perspective view showing how the camera 13 captures an image of the urine test strip 8 onto which the urine sample has been applied.

[0028] As shown in FIG. 4 , the urine test strip 8 is provided with a plurality of reagent pads 80, and the urine sample collected by the suction nozzle 50 is sequentially deposited onto the plurality of reagent pads 80. Each of the plurality of reagent pads 80 contains a reagent that reacts with a predetermined component in the urine sample and develops a color to a degree corresponding to the concentration of that component. Reagents containing various components are used depending on the test items for the urine sample. The urine test strip 8 is driven by a drive mechanism (not shown), and after the urine sample is deposited onto the plurality of reagent pads 80 by the suction nozzle 50, the urine test strip 8 is moved to a position where it can be photographed by the camera 13. The camera 13 then captures an image of the entire urine test strip 8 after the urine sample has been deposited onto the plurality of reagent pads 80.

[0029] Specifically, the camera 13 photographs the elongated urine test strip 8 on which a plurality of reagent pads 80 of a predetermined shape onto which a urine sample, which is a specimen liquid, has been deposited are arranged side by side. That is, the camera 13 photographs the elongated urine test strip 8 on which a plurality of rectangular reagent pads 80 having a predetermined width and length and a height dimension that is approximately the same as the width in the width direction are placed at intervals in the length direction.

[0030] FIG. 5 is a block diagram showing an example of the functional configuration of the control unit 11 according to this embodiment.

[0031] As shown in FIG. 5, the control unit 11 according to this embodiment functions as an image processing unit 21, a measurement unit 22, and an abnormality detection unit 23 by executing a control program stored in the storage unit 15.

[0032] The image processing unit 21 cuts out a portion of the image of the urine test paper 8 photographed by the camera 13, and generates, for each reagent pad 80, a first cut-out image which is an image of an area smaller than the shape of the reagent pad 80 and does not include the outer edge of the reagent pad 80, and a second cut-out image (reagent pad image) which is an image of an area larger than the shape of the reagent pad 80 and includes the outer area of ​​the outer edge of the reagent pad 80.

[0033] For example, each of the multiple reagent pads 80 is rectangular, the first cut-out image is a rectangular cut-out image with dimensions of 90% or less of the length of each side of each reagent pad 80, and the second cut-out image is a rectangular cut-out image with dimensions of 110% or more of the length of each side of each reagent pad 80.

[0034] The measurement unit 22 measures the color state of the urine sample using the first cut-out image generated by the image processing unit 21. Specifically, the measurement unit 22 performs a qualitative analysis of the urine sample applied to the reagent pad 80 by comparing the color values ​​of the measured color state of the first cut-out image with preset color values. For example, the measurement unit 22 converts the color values ​​of the first cut-out image in the RGB color space into color values ​​in the Lab color space, and compares them with the preset Lab values ​​to determine the color state of each reagent pad, thereby performing a qualitative analysis of the urine sample applied to the reagent pad 80.

[0035] The abnormality detection unit 23 detects an abnormality in the reagent pad 80 or an abnormality in the placement of the urine sample on the reagent pad 80 using the second clipped image generated by the image processing unit 21 .

[0036] For example, the abnormality detection unit 23 detects, as an abnormality in application, a state in which no urine sample is applied to the reagent pad 80 or a state in which the amount of urine sample applied to the reagent pad 80 is less than a predetermined amount, based on the color information of the second cropped image. Alternatively, the abnormality detection unit 23 may detect an abnormality in application of the urine sample to the reagent pad 80 by inputting the second cropped image into a learning model generated by machine learning using as training data an image of the reagent pad 80 in which the urine sample is normally applied and an image of the reagent pad 80 in which the urine sample is abnormally applied.

[0037] Furthermore, the abnormality detection unit 23 detects the state in which the reagent pad 80 has fallen off the urine test paper 8 as an abnormality in the reagent pad 80 by identifying the shape of an area in the second cut-out image that is a color different from the color of the urine test paper 8.

[0038] In this embodiment, a first cut-out image that does not include the outer edge of the reagent pad 80 and a second cut-out image that is an image that includes the outer area of ​​the outer edge of the reagent pad 80 are cut out for each reagent pad 80 from the photographed image of the urine test strip 8. The first cut-out image is used for a qualitative test based on the color reaction of the reagent pad, and the second cut-out image is used for detecting abnormalities such as a dropped reagent pad. Therefore, this embodiment makes it possible to stably detect color changes due to the color reaction of the reagent pad 80 and to detect abnormal conditions such as a dropped reagent pad 80.

[0039] If the abnormality detection unit 23 detects that the reagent pad 80 has peeled off from the urine test paper 8, the abnormality is detected by the following process.

[0040] Specifically, the abnormality detection unit 23 generates a reagent pad cutout image by cutting out only the test paper region from the reagent pad image (second cutout image) cut out by the image processing unit 21. The abnormality detection unit 23 then binarizes the generated reagent pad cutout image using the maximum or minimum value in a predetermined brightness range as a threshold value and determines whether a rectangular shape can be detected. If a rectangular shape cannot be detected, the abnormality detection unit 23 raises or lowers the threshold value and repeats the binarization process until a rectangular shape is detected or until all brightness values ​​in the predetermined brightness range are set as the threshold value. If a rectangular shape is detected at any threshold value, the abnormality detection unit 23 determines that the reagent pad has not fallen off. If a rectangular shape cannot be detected even when all brightness values ​​in the predetermined brightness range are set as the threshold value, the abnormality detection unit 23 determines that the reagent pad has fallen off.

[0041] The abnormality detection unit 23 determines that a rectangular shape has been detected when the ratio of white pixels or black pixels in the smallest rectangle surrounding the area of ​​white pixels or black pixels detected while changing the threshold value becomes equal to or greater than a preset value.

[0042] The image processing unit 21 cuts out reagent pad images for each reagent pad 80 from the image of the urine test strip 8 taken by the camera 13 by dividing the image of the urine test strip 8 in the longitudinal direction based on the assumed position of each reagent pad 80 on the urine test strip 8. The abnormality detection unit 23 then converts the reagent pad image into a monochrome image and generates a reagent pad cut-out image by cutting out only the area sandwiched between the upper and lower bases of the reagent pad 80 from the reagent pad image converted into the monochrome image.

[0043] Specifically, the abnormality detection unit 23 binarizes the reagent pad image converted into a monochrome image using the maximum value of a predetermined brightness range as a threshold, detects the smallest rectangle enclosing a region of white pixels in the binarized image, and determines whether two smallest rectangles with a white pixel ratio equal to or greater than a predetermined value can be detected. If the abnormality detection unit 23 cannot detect two smallest rectangles with a white pixel ratio equal to or greater than the predetermined value, it lowers the threshold and repeats the binarization process until two smallest rectangles with a white pixel ratio equal to or greater than the predetermined value are detected. If the abnormality detection unit 23 detects two smallest rectangles with a white pixel ratio equal to or greater than the predetermined value, it determines that the two smallest rectangles are regions of a urine test strip where no reagent pad is placed, and generates a reagent pad cutout image by cutting out only the region between the upper and lower bases of the reagent pad 80 from the reagent pad image converted into a monochrome image.

[0044] Next, the operation of the urine testing apparatus 10 of this embodiment will be described in detail with reference to the drawings.

[0045] First, the overall operation of the urine testing apparatus 10 of this embodiment is outlined in the flowchart of FIG.

[0046] First, the image of the urine test strip 8 taken by the camera 13 is subjected to tilt correction and distortion correction by the image processing unit 21 (step S101). Because the urine test strip 8 is a horizontally long test strip, when it is photographed by a single camera 13, the edges of the urine test strip 8 will be tilted more than the center, resulting in a distorted image. Therefore, the image processing unit 21 identifies the region of the urine test strip 8 from the image of the urine test strip 8 taken by the camera 13, and performs image processing to suppress tilt and distortion in the identified region of the urine test strip 8.

[0047] Next, the image processing unit 21 cuts out, for each reagent pad 80, a first cut-out image, which is an image of an area smaller than the shape of the reagent pad 80 and does not include the outer edge of the reagent pad 80, and a second cut-out image (reagent pad image), which is an image of an area larger than the shape of the reagent pad 80 and includes the outer area of ​​the outer edge of the reagent pad 80 (step S102).

[0048] Thereafter, the abnormality detection unit 23 generates a reagent pad cutout image by cutting out the background area other than the urine test strip 8 from the reagent pad image, which is the second cutout image, and cutting out only the area of ​​the urine test strip 8 (step S103).The abnormality detection unit 23 then executes a process to determine whether or not the reagent pad has fallen off using the generated reagent pad cutout image (step S104).The process of steps S103 and S104 will be described in detail later.

[0049] An example image of the urine test strip 8 photographed in this manner is shown in Figure 7. Figure 7 shows an image of the urine test strip 8 photographed by the camera 13, and illustrates how a first cropped image 61 and a second cropped image (reagent pad image) 62 are cropped from the image of a particular reagent pad. The first cropped image 61 is then sent to the measurement unit 22 and used for a qualitative test based on the color state of the reagent pad 80. The second cropped image 62 is sent to the abnormality detection unit 23 and used for detecting detachment of the reagent pad and detecting abnormal application of the reagent pad.

[0050] 7, the first cropped image 61 is an image cropped from the central region of the reagent pad 80, excluding the outer edge of the reagent pad 80. The second cropped image 62 is an image cropped from the region including the outer edge and peripheral portion of the reagent pad 80. As can be seen from FIG. 7, the region of the urine test strip 8 other than the reagent pad 80 is white, whereas the background when the urine test strip 8 is photographed is dark.

[0051] The image processing unit 21 performs such image cutout processing for each of the plurality of reagent pads 80. The manner in which the image processing unit 21 cuts out the second cutout image 62 for each reagent pad 80 is shown in FIG.

[0052] The abnormality detection unit 23 detects an abnormality in each reagent pad 80 or an abnormality in the application of a urine sample to the reagent pad 80, based on the second cut-out image 62 cut out by the image processing unit 21. Note that in this embodiment, a case where the abnormality detection unit 23 determines whether each reagent pad 80 is in a properly attached state or in a detached and fallen-off state based on the second cut-out image 62 will be described in detail, and a description of a method for detecting an abnormality in the application of a urine sample to the reagent pad 80 will be omitted.

[0053] An example image of a urine test strip 8 in which a certain reagent pad 80 has fallen off is shown in Figure 9. Referring to Figure 9, it can be seen that the image of the urine test strip includes an area 71 where a certain reagent pad has fallen off. The urine sample is also applied to this area 71 by the application device 12, so the urine sample is applied directly to the urine test strip 8. The abnormality detection unit 23 detects that a reagent pad has fallen off from the image of this area 71.

[0054] Next, an example of an image of an actual urine test strip 8 and an example of an image of an actual reagent pad are shown in FIG.

[0055] Fig. 10(A) is a diagram showing an example of an image of an actual urine test strip 8 captured by the camera 13. Fig. 10(B) is a diagram showing an example of an actual reagent pad image obtained by cutting out an image including the outer edge of one reagent pad 80 from the example image of the urine test strip 8 shown in Fig. 10(A) as a reagent pad image. Referring to Fig. 10(A), it can be seen that the color intensity of each reagent pad varies greatly.

[0056] Although the actual image examples shown in Figures 10(A) and 10(B) are black and white images, they are actually color images. Here, the background color of the urine test strip 8 is white, and each reagent pad 80 attached to this urine test strip 8 is a variety of colors, such as purple, green, pink, blue, yellow, brown, and white, depending on the color of the reagent contained therein. Each reagent pad 80 changes from its original color to a variety of colors when a urine sample is applied. For example, a GLU (glucose) pad, which measures the concentration of glucose in a urine sample, will develop a darker color when the glucose concentration in the urine sample is high.

[0057] The color change of the reagent pad due to the color reaction is shown in Figures 11(A) and 11(B). Figure 11(A) shows an example of a reagent pad image corresponding to a certain reagent pad. In the reagent pad image of Figure 11(A), the area of ​​the urine test strip is white, while the background area other than the urine test strip is black. As described above, the reagent pad can take on various colors depending on the color of the reagent. However, if the reagent pad changes to a dark color after a urine sample is applied, the color of the reagent pad may change to a darker color, as shown in Figure 11(B). As a result, the color of the background area and the color of the reagent pad area in the reagent pad image may have very similar intensities. Here, when attempting to determine whether a reagent pad has fallen off using image processing as described above, it is necessary to detect whether the reagent pad has a rectangular shape. To do this, it is necessary to determine where the area of ​​the urine test strip ends and where the background area other than the urine test strip begins, otherwise it is impossible to determine whether the reagent pad has a rectangular shape.

[0058] Conversely, some reagent pads remain nearly white even after a urine sample has been applied, similar in color to the urine test strip 8. An example of a reagent pad image of such a light-colored reagent pad is shown in FIG. 11C. Because the color density of the reagent pads varies, it is difficult to make the same judgment for light-colored reagent pads and dark-colored reagent pads when attempting to detect the presence or absence of a rectangular shape using a fixed threshold value. Specifically, unless a threshold value is set between the color density value of the urine test strip and the color density value of the reagent pad, it is impossible to distinguish between the urine test strip area and the reagent pad area. However, if the threshold value were changed for each color of reagent pad, it would be impossible to determine whether or not reagent pads of various colors have fallen off using the same process.

[0059] Therefore, the urine testing apparatus 10 of this embodiment is designed to perform the process described below so that the state of detachment of the reagent pad, which changes color in various ways, can be determined by the same process.

[0060] First, the details of the process for generating an image of a cut-out reagent pad (step S103) in the flowchart of FIG. 6 will be described with reference to the flowchart of FIG.

[0061] The abnormality detection unit 23 performs a monochrome conversion process on the reagent pad image cut out by the image processing unit 21 (step S201). Here, the image of the urine test strip 8 captured by the camera 13 is assumed to be a color image in the RGB color space, with each pixel value ranging from 0 to 255. Therefore, the reagent pad image cut out by the image processing unit 21 is also a color image in the RGB color space. Therefore, the abnormality detection unit 23 first converts the color image of the reagent pad image into an HSV image. Here, an HSV image is an image in which the color value of each pixel is expressed by H (Hue), S (Saturation), and V (Value). The abnormality detection unit 23 acquires the V image of the HSV image as a monochrome image.

[0062] Next, the abnormality detection unit 23 sets the threshold value for the binarization process to 255 (step S202). Note that instead of setting the threshold value to 255, the largest luminance value in the monochrome image may be set as the threshold value for the binarization process.

[0063] Then, the abnormality detection unit 23 performs binarization processing on the monochrome reagent pad image based on the set threshold value (step S203).

[0064] The anomaly detection unit 23 then detects the smallest rectangles enclosing the white pixels from the binary image after the binarization process (step S204), and calculates the ratio of white pixels within each of the detected smallest rectangles (step S205).

[0065] The anomaly detection unit 23 then determines whether the ratio of white pixels in the two minimum rectangles in the binary image is equal to or greater than a predetermined value, for example, 90% (step S206). Note that this value of 90% is merely an example, and any value suitable for detecting the minimum rectangle is set.

[0066] If it is determined in step S206 that the ratio of white pixels in both of the two smallest rectangles in the binary image is 90% or more, the abnormality detection unit 23 generates a reagent pad cutout image by cutting out the reagent pad image at the upper and lower bases of the detected smallest rectangle (step S207).If it is determined in step S206 that the ratio of white pixels in either of the two smallest rectangles in the binary image is not 90% or more, the abnormality detection unit 23 determines whether the currently set threshold is 0 (step S208).

[0067] If it is determined in step S208 that the currently set threshold is not 0, the abnormality detection unit 23 decreases the threshold by 1 (step S209) and performs the binarization process in step S203 again.

[0068] If it is determined in step S208 that the currently set threshold is 0, the abnormality detection unit 23 determines that an error has occurred (step S210). If it is determined that an error has occurred in step S210, the abnormality detection unit 23 terminates the process abnormally, determines that there is some abnormality in the reagent pad in the reagent pad image, and terminates the process.

[0069] By performing the above-described process, steps S203 to S206 are repeated until the threshold value changes from 255 to 0. As a result, as shown in Fig. 13, if the reagent pad is in a normal state, two minimum rectangles in which the proportion of white pixels is equal to or greater than a preset value at either threshold value are detected. When two minimum rectangles are detected, the abnormality detection unit 23 determines that these two minimum rectangles are areas of the urine test strip on which no reagent pad is placed, and generates a reagent pad cut-out image by cutting out only the area sandwiched between the upper and lower bases of the reagent pad 80 from the reagent pad image converted into a monochrome image.

[0070] FIG. 14 is a diagram showing how an area sandwiched between the upper and lower bases of the two minimum rectangles detected in this manner is cut out to generate a cut-out image of the reagent pad.

[0071] If the threshold value becomes 0 without detecting two minimum rectangles even after repeating the processes of steps S203 to S206, an error is determined in step S210.

[0072] Next, the details of the process of determining whether or not the reagent pad has fallen off (step S104) in the flowchart of FIG. 6 will be described with reference to the flowchart of FIG.

[0073] First, the abnormality detection unit 23 sets the threshold value for the binarization process to 255 (step S301). Note that instead of setting the threshold value to 255, the largest luminance value in the monochrome image may be set as the threshold value for the binarization process.

[0074] Next, the abnormality detection unit 23 performs binarization processing on the cut-out image of the reagent pad cut out in the processing of step S103 based on the set threshold value (step S302).

[0075] The anomaly detection unit 23 then detects the smallest rectangle enclosing the black pixels from the binary image after the binarization process (step S303), and calculates the proportion of black pixels in the detected smallest rectangle (step S304).

[0076] The anomaly detection unit 23 then determines whether the proportion of black pixels in the smallest rectangle in the binary image is equal to or greater than a predetermined value, for example, 90% (step S305). Note that this value of 90% is merely an example, and any value suitable for detecting the smallest rectangle is set.

[0077] If it is determined in step S305 that the proportion of black pixels in the minimum rectangle in the binary image is 90% or more, the abnormality detection unit 23 determines that the reagent pad is not in a detached state (step S308).

[0078] If it is determined in step S305 that the proportion of black pixels in the minimum rectangle in the binary image is not 90% or more, the abnormality detection unit 23 determines whether the currently set threshold is 0 (step S306).

[0079] If it is determined in step S306 that the currently set threshold is not 0, the abnormality detection unit 23 decreases the threshold by 1 (step S307) and re-executes the binarization process in step S302.

[0080] If it is determined in step S306 that the currently set threshold value is 0, the abnormality detection unit 23 determines that the reagent pad is in a detached state (step S309).

[0081] By performing the above-described process, steps S302 to S305 are repeated until the threshold value changes from 255 to 0. As a result, as shown in Fig. 16, if the reagent pad is in a normal state, the smallest rectangle in which the proportion of black pixels is equal to or greater than a preset value at any threshold value is detected. When this smallest rectangle is detected, the abnormality detection unit 23 determines that this smallest rectangle is the outer shape of the reagent pad and determines that the reagent pad is not in a dropped state.

[0082] An example of a cut-out image of a reagent pad in which the reagent pad has fallen off the urine test strip is shown in Figure 17. In the example of a cut-out image of a reagent pad shown in Figure 17, it can be seen that the reagent pad is not present in the image, and the urine sample has been directly applied to the urine test strip.

[0083] FIG. 18 shows the change in the binary image when the above-described processes of steps S302 to S305 are repeated for the reagent pad cutout image shown in FIG. 17. Referring to FIG. 18, it can be seen that no matter how the threshold value is changed, a minimum rectangle in which the proportion of black pixels is equal to or greater than a predetermined value is not detected. In other words, if the reagent pad has fallen off the urine test strip, no rectangular shape will be detected from the reagent pad cutout image. Therefore, the abnormality detection unit 23 determines that the reagent pad has fallen off the urine test strip if no rectangular shape is detected from the reagent pad cutout image no matter how the threshold value is changed during the binarization process.

[0084] In this manner, in this embodiment, the presence or absence of a rectangular shape in the cut-out image of the reagent pad is determined by performing binarization processing by varying the threshold value between 255 and 0, rather than using a fixed threshold value. Therefore, according to this embodiment, it is possible to reliably determine whether the reagent pad 80, which has various original colors and changes to various colors due to a color reaction, has fallen off the urine test strip 8 or is properly attached.

[0085] The disclosure of Japanese Patent Application No. 2024-126067, filed on August 1, 2024, is incorporated herein by reference in its entirety. All documents, patent applications, and technical standards mentioned herein are incorporated herein by reference to the same extent as if each individual document, patent application, and technical standard was specifically and individually indicated to be incorporated by reference.

Claims

1. A specimen fluid testing device comprising: a camera that photographs a thin test paper having a predetermined width and length, and on which a plurality of rectangular reagent pads having a height dimension that approximately matches the width in the width direction are placed at intervals in the length direction; an image processing unit that generates, for each reagent pad, a reagent pad image of an area larger than the shape of the reagent pad and including the outer area of ​​the reagent pad by cutting out a partial area of ​​the test paper image photographed by the camera; and an abnormality detection unit that generates a reagent pad cut-out image by cutting out only the test paper area from the reagent pad image, binarizes the generated reagent pad cut-out image using the maximum or minimum value of a predetermined brightness range as a threshold, determines whether a rectangular shape can be detected, and if a rectangular shape cannot be detected, raises or lowers the threshold and repeats the binarization process until a rectangular shape is detected or until all brightness values ​​in the predetermined brightness range are set as the threshold, and determines that the reagent pad has not fallen off if a rectangular shape is detected at any of the thresholds, and determines that the reagent pad has fallen off if a rectangular shape cannot be detected even when all brightness values ​​in the predetermined brightness range are set as the threshold.

2. The specimen fluid testing device according to claim 1, wherein the abnormality detection unit determines that a rectangular shape has been detected when the proportion of white or black pixels in the smallest rectangle surrounding the area of ​​white or black pixels detected while changing the threshold value is equal to or greater than a preset value.

3. The specimen liquid testing device according to claim 1, wherein the image processing unit extracts a reagent pad image for each reagent pad from the test strip image captured by the camera by dividing the test strip image longitudinally based on the assumed position of each reagent pad on the test strip, and the abnormality detection unit converts the reagent pad image into a monochrome image and generates the reagent pad extraction image by extracting only the area sandwiched between the upper and lower bases of the reagent pad from the reagent pad image converted into the monochrome image.

4. The specimen liquid testing device according to claim 3, wherein the abnormality detection unit binarizes the reagent pad image converted into a monochrome image using the maximum value of a predetermined brightness range as a threshold, detects the smallest rectangle enclosing an area of ​​white pixels in the binarized image, determines whether or not two smallest rectangles with a ratio of white pixels equal to or greater than a predetermined value can be detected within the detected smallest rectangles, lowers the threshold and repeats the binarization process until two smallest rectangles with a ratio of white pixels equal to or greater than the predetermined value can be detected if two smallest rectangles with a ratio of white pixels equal to or greater than the predetermined value are detected, and determines that the two smallest rectangles are areas of a test paper on which no reagent pad is placed, and generates the reagent pad cut-out image by cutting out only the area sandwiched between the upper and lower bases of the reagent pad in the reagent pad image converted into a monochrome image.

5. A program for causing a computer to execute the following steps:

5. A program for causing a computer to execute the following steps:

1. A test paper image is taken of a thin test paper, the test paper having a predetermined width and length, and a plurality of rectangular reagent pads placed at intervals in the length direction, and the image is cut out from the test paper image taken by a camera. The test paper image is an image of an area larger than the shape of the reagent pad and includes an outer area of ​​the outer edge of the reagent pad; 2. A program for causing a computer to execute the following steps:

1. A test paper image is taken of a thin test paper having a predetermined width and length, the image is a test paper having a height dimension approximately equal to the width in the width direction, the image is a test paper image of an area larger than the shape of the reagent pad and includes an outer area of ​​the outer edge of the reagent pad; 3. A program for causing a computer to execute the following steps:

1. A test paper image is taken of a thin test paper, the image is taken of a test paper having a predetermined width and length, the image is a test paper image of an area larger than the shape of the reagent pad and includes an outer area of ​​the outer edge of the reagent pad; 2. A program for causing a computer to execute the following steps:

1. A test paper image is taken of a thin test paper, the image is a test paper image of an area larger than the shape of the reagent pad and includes an outer area of ​​the outer edge of the reagent pad; 6. A non-transitory recording medium having recorded thereon a program for causing a computer to execute the steps of: ... Cutting out a part of a test paper image taken by a camera that photographs an elongated test paper having a plurality of rectangular reagent pads placed at intervals in the length direction and including an outer region of the reagent pad, the image being an image of an area larger than the shape of the reagent pad and including an outer region of the reagent pad; 6. A non-transitory recording medium having recorded thereon a program for causing a computer to execute the steps of:

6. Cutting out a part of a test paper image taken by a camera that photographs an elongated test paper having a plurality of rectangular reagent pads placed at intervals in the length direction and including an outer region of the reagent pad, the image being an image of an area larger than the shape of the reagent pad;

Citation Information

Patent Citations

  • Analyzer and analysis method

    JP2013024797A

  • Test piece analysis device and test piece analysis method

    JP2017072567A

  • Inspection method of affix and inner packaging method of semiconductor wafer

    JP2020088218A