Drug sensitivity identification method, device and equipment for drug sensitivity card and readable storage medium

Through the drug-sensitivity pore detection and identification model, combined with deep learning technology, the problem of human and environmental factors in the drug-sensitivity card identification method is solved, and the identification accuracy is improved.

CN118570434APending Publication Date: 2024-08-30AUTOBIO LABTEC INSTR CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202410714704.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-04
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

The existing drug susceptibility identification methods using drug susceptibility cards are easily affected by human factors and environmental factors, resulting in low identification accuracy.

Method used

The drug-sensitivity pore detection model and the drug-sensitivity pore drug-sensitivity identification result model are used to detect and identify drug-sensitive pores on sample pictures of drug-sensitivity cards. The position information of drug-sensitive pores is obtained through cropping, sorting, and the minimum circumscribed rectangle algorithm, and deep learning technology is used to determine drug sensitivity. Identify and avoid the effects of human and environmental factors.

Benefits of technology

Significantly improves the accuracy of drug sensitivity identification on drug sensitivity cards, reduces human errors and environmental interference, and achieves more efficient identification results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570434A
    Figure CN118570434A
Patent Text Reader

Abstract

The invention discloses a drug susceptibility identification method for a drug susceptibility card. The method comprises the following steps: collecting an initial drug susceptibility card sample picture of a to-be-identified drug susceptibility card; performing drug sensitive hole detection on the initial drug sensitive card sample picture by using a drug sensitive hole detection model to obtain position information of each drug sensitive hole; cutting the initial drug sensitive card sample picture according to the position information of each drug sensitive hole to obtain a sample image of each drug sensitive hole; and identifying each drug sensitivity hole sample image by using the drug sensitivity hole drug sensitivity identification result model to obtain a drug sensitivity identification result. By applying the drug sensitivity identification method of the drug sensitivity card provided by the invention, the influence of human factors and environmental factors is avoided, and the identification accuracy is greatly improved. The invention further discloses a drug sensitivity identification device and equipment for the drug sensitivity card and a storage medium, which have corresponding technical effects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of artificial intelligence technology, and in particular to a drug sensitivity card drug sensitivity identification method, device, equipment and computer-readable storage medium. Background Art

[0002] In large hospitals, the task of drug sensitivity identification on drug sensitivity cards is a heavy and error-prone task. Currently, there are two main methods for drug sensitivity identification on drug sensitivity cards. One is traditional manual observation and analysis to read drug sensitivity cards. The other is automatic reading of drug sensitivity cards based on traditional machine vision.

[0003] Traditional manual observation and analysis for drug susceptibility card interpretation, different people have different standards for color judgment, and long-term interpretation can easily cause visual fatigue and lead to misjudgment, which is inefficient and easily affected by human factors, thus affecting the accuracy of the results. Traditional machine vision-based drug susceptibility card interpretation usually relies on color thresholds or specific color spaces to identify antibiotic sensitivity. Due to the influence of environmental factors such as light, shadows, and color changes, and the many transition colors between antibiotic sensitive colors and non-sensitive colors, misjudgment or missed judgment may occur, resulting in low recognition accuracy.

[0004] In summary, how to effectively solve the problem that the existing drug sensitivity card drug sensitivity identification method is easily affected by human factors and environmental factors and has a low identification accuracy is an issue that technicians in this field urgently need to solve. Summary of the invention

[0005] The purpose of this application is to provide a drug sensitivity card drug sensitivity identification method, which avoids the influence of human factors and environmental factors and greatly improves the identification accuracy; another purpose of this application is to provide a drug sensitivity card drug sensitivity identification device, equipment and computer-readable storage medium.

[0006] In order to solve the above technical problems, this application provides the following technical solutions:

[0007] A drug sensitivity identification method using a drug sensitivity card, comprising:

[0008] Collect the initial sample pictures of the drug sensitivity cards to be identified;

[0009] Using the drug sensitivity hole detection model to perform drug sensitivity hole detection on the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole;

[0010] The initial drug sensitivity card sample image is cropped according to the position information of each drug sensitivity well to obtain sample images of each drug sensitivity well;

[0011] The drug sensitivity well drug sensitivity identification result model is used to identify each of the drug sensitivity well sample images to obtain a drug sensitivity identification result.

[0012] In a specific embodiment of the present application, the drug sensitivity well drug sensitivity identification result model is used to identify each of the drug sensitivity well sample images to obtain a drug sensitivity identification result, including:

[0013] The drug sensitivity well drug sensitivity identification result model is used to identify each of the drug sensitivity well sample images to obtain the drug sensitivity result type and score probability value.

[0014] In a specific embodiment of the present application, after obtaining the drug sensitivity result type and the score probability value, it also includes:

[0015] Determine whether the score probability value is greater than a preset threshold;

[0016] If not, the drug sensitivity result type is set to an intermediate abnormal value to perform a secondary confirmation of the drug sensitivity result.

[0017] In a specific embodiment of the present application, after obtaining the position information of each drug-sensitive well, the method further includes:

[0018] Adding the position information of each drug-sensitive well to a preset array to obtain an initial drug-sensitive well position information array;

[0019] Obtain the horizontal coordinate and the vertical coordinate of the center point of the first element of the drug sensitivity well position information in the initial drug sensitivity well position information array;

[0020] Taking the abscissa and ordinate of the center point of the first element of the drug sensitivity well position information as the starting elements, the drug sensitivity well position information in the initial drug sensitivity well position information array is sorted by the bubbling method to obtain a target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right;

[0021] The minimum circumscribed rectangle algorithm is used to obtain the minimum circumscribed matrix containing the center point positions of all drug sensitivity wells in the target drug sensitivity well position information array, and the minimum circumscribed matrix is ​​determined as the drug sensitivity card position information.

[0022] In a specific implementation of the present application, after determining the minimum circumscribed matrix as the drug sensitivity card location information, it also includes:

[0023] Obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information;

[0024] Calibrate the coordinate system of the initial drug sensitivity card sample image according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card to obtain a calibrated drug sensitivity card sample image;

[0025] The calibrated drug sensitivity card sample image is cropped through a preset cropping region of interest to obtain a barcode paper region image;

[0026] The barcode paper area image is identified to obtain barcode information.

[0027] In a specific embodiment of the present application, after obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information, it also includes:

[0028] Determine a mapping matrix according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card;

[0029] Sparsely map the positions of the center points of the drug sensitivity wells according to the mapping matrix to obtain the target positions of the center points of the drug sensitivity wells in the calibrated drug sensitivity card sample image after mapping;

[0030] The drug sensitivity identification results are drawn at each of the target positions to obtain a drug sensitivity identification result map of the drug sensitivity card.

[0031] In a specific embodiment of the present application, after drawing the drug sensitivity identification results at each of the target positions to obtain a drug sensitivity identification result map of the drug sensitivity card, it also includes:

[0032] The drug sensitivity card drug sensitivity identification result chart and the barcode information are uploaded to the laboratory information management system.

[0033] In a specific embodiment of the present application, before sorting the drug sensitivity well position information in the initial drug sensitivity well position information array by using the bubbling method, it also includes:

[0034] Traversing the initial drug-sensitive well position information array to obtain the length value and width value of the minimum circumscribed rectangle of the drug-sensitive well in each of the drug-sensitive well position information;

[0035] Calculate the mean of each length value and each width value to obtain a target mean;

[0036] The target mean is determined as the standard drug-sensitive pore diameter;

[0037] Correspondingly, the bubbling method is used to sort the drug-sensitive well position information in the initial drug-sensitive well position information array, including:

[0038] Calculating the difference between the ordinates of two adjacent drug-sensitive well position information in the initial drug-sensitive well position information array to obtain a target difference;

[0039] Determining whether the absolute value of the target difference is greater than the standard drug-sensitive pore diameter;

[0040] If so, it is determined that the two drug sensitivity well position information belong to different rows in the drug sensitivity card, and the drug sensitivity well position information with a smaller ordinate is sorted first and then the drug sensitivity well position information with a larger ordinate is sorted;

[0041] If not, it is determined that the two drug sensitivity well position information belong to the same row in the drug sensitivity card, and the drug sensitivity well position information with a smaller horizontal coordinate is sorted first and then the drug sensitivity well position information with a larger horizontal coordinate is sorted;

[0042] Among them, the ordinate and abscissa of the position information of each drug sensitivity hole are coordinates in a coordinate system established with the upper left corner of the drug sensitivity card as the coordinate origin, the right as the positive direction of the horizontal axis, and the downward as the positive direction of the vertical axis.

[0043] In a specific embodiment of the present application, after obtaining the target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right, before using the minimum circumscribed rectangle algorithm to obtain the minimum circumscribed matrix containing the positions of the center points of all drug sensitivity wells in the target drug sensitivity well position information array, it also includes:

[0044] Obtaining the array size of the target drug sensitivity well position information array;

[0045] Determining whether the array size is equal to the preset number of drug sensitivity wells;

[0046] If yes, then executing the step of using the minimum bounding rectangle algorithm to obtain the minimum bounding matrix containing the positions of the center points of all drug-sensitive wells in the target drug-sensitive well position information array;

[0047] If not, repeat the step of collecting the initial drug sensitivity card sample picture of the drug sensitivity card to be identified.

[0048] A drug sensitivity card drug sensitivity identification device, comprising:

[0049] An image collection module is used to collect the initial drug sensitivity card sample image of the drug sensitivity card to be identified;

[0050] A drug sensitivity hole position acquisition module is used to perform drug sensitivity hole detection on the initial drug sensitivity card sample image using a drug sensitivity hole detection model to obtain the position information of each drug sensitivity hole;

[0051] A drug sensitivity well image acquisition module, used to crop the initial drug sensitivity card sample image according to the position information of each drug sensitivity well to obtain sample images of each drug sensitivity well;

[0052] The drug sensitivity identification result obtaining module is used to identify each of the drug sensitivity well sample images using the drug sensitivity well drug sensitivity identification result model to obtain the drug sensitivity identification result.

[0053] A drug sensitivity card drug sensitivity identification device, comprising:

[0054] Memory for storing computer programs;

[0055] A processor is used to implement the steps of the drug sensitivity identification method of the drug sensitivity card as described above when executing the computer program.

[0056] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the drug sensitivity identification method of the drug sensitivity card as described above.

[0057] The drug sensitivity card drug sensitivity identification method provided in the present application collects an initial drug sensitivity card sample image of the drug sensitivity card to be identified; uses a drug sensitivity well detection model to perform drug sensitivity well detection on the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity well; crops the initial drug sensitivity card sample image according to the position information of each drug sensitivity well to obtain a sample image of each drug sensitivity well; uses a drug sensitivity well drug sensitivity identification result model to identify each drug sensitivity well sample image to obtain a drug sensitivity identification result.

[0058] It can be seen from the above technical solution that by pre-training the drug sensitivity hole detection model and the drug sensitivity hole drug sensitivity identification result model, the drug sensitivity hole detection model is used to perform drug sensitivity hole detection on the collected initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole, and the initial drug sensitivity card sample image is cropped according to the position information of each drug sensitivity hole to obtain each drug sensitivity hole sample image, and the drug sensitivity hole drug sensitivity identification result model is used to identify each drug sensitivity hole sample image to obtain the drug sensitivity identification result. By combining the pre-trained drug sensitivity hole detection model and the drug sensitivity hole drug sensitivity identification result model to perform drug sensitivity identification on the drug sensitivity card, compared with manual observation and drug sensitivity identification methods based on traditional machine vision, the influence of human factors and environmental factors is avoided, and the recognition accuracy is greatly improved.

[0059] Correspondingly, the present application also provides a drug sensitivity card drug sensitivity identification device, equipment and computer-readable storage medium corresponding to the above-mentioned drug sensitivity card drug sensitivity identification method, which has the above-mentioned technical effects and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the drawings required for use in the embodiments or the related technical descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0061] Figure 1 This is an implementation flow chart of the drug sensitivity identification method of the drug sensitivity card in the embodiment of the present application;

[0062] Figure 2 Another implementation flow chart of the drug sensitivity identification method of the drug sensitivity card in the embodiment of the present application;

[0063] Figure 3 This is a schematic diagram of the position of a drug sensitivity card in an embodiment of the present application;

[0064] Figure 4 This is a structural block diagram of a drug sensitivity card drug sensitivity identification device in an embodiment of the present application;

[0065] Figure 5 This is a structural block diagram of a drug sensitivity card drug sensitivity identification device in an embodiment of the present application;

[0066] Figure 6 A schematic diagram of the specific structure of a drug sensitivity card drug sensitivity identification device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0067] Mycoplasma is a type of prokaryotic organism that is the smallest and has no cell wall structure, between independent life and intracellular parasitic life. It often causes respiratory and reproductive tract infections. Drug sensitivity testing for mycoplasma is an important step in clinical diagnosis, which can guide doctors to choose the most effective antibiotic treatment plan.

[0068] At present, there are two main methods for drug sensitivity card identification. One is traditional manual observation and analysis to read the drug sensitivity card. The other is automatic reading of drug sensitivity cards based on traditional machine vision. Traditional manual observation and analysis for drug sensitivity card reading is easily affected by human factors, thus affecting the accuracy of the results. The reading of drug sensitivity cards based on traditional machine vision may be affected by environmental factors such as light, shadow, color changes, and there are many transition colors between the sensitive color and the non-sensitive color of antibiotics, which may cause misjudgment or missed judgment, resulting in low recognition accuracy.

[0069] To this end, the drug sensitivity card drug sensitivity identification method provided in this application avoids the influence of human factors and environmental factors, and greatly improves the identification accuracy.

[0070] In order to enable those skilled in the art to better understand the present application, the present application is further described in detail below in conjunction with the accompanying drawings and specific implementation methods. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application.

[0071] See also Figure 1 , Figure 1 This is an implementation flow chart of the drug sensitivity identification method of the drug sensitivity card in the embodiment of the present application. The method may include the following steps:

[0072] S101: Collecting an initial sample image of the drug sensitivity card to be identified.

[0073] When it is necessary to perform drug sensitivity identification on the drug sensitivity card to be identified, collect the initial drug sensitivity card sample image of the drug sensitivity card to be identified. For example, computer vision technology can be used to use an industrial camera to digitally collect the image of the drug sensitivity card to be identified against a white or black board background, as well as under the current actual lighting conditions, to obtain the initial drug sensitivity card sample image of the drug sensitivity card to be identified. Through feature extraction and analysis, richer and more accurate information can be extracted from the image.

[0074] The collected initial drug sensitivity card sample image of the drug sensitivity card to be identified is an image collected after the drug sensitivity card to be identified is placed into the camera's field of view and remains stable.

[0075] The drug sensitivity card to be identified can be any drug sensitivity card to be identified, such as any mycoplasma drug sensitivity card, Gram-positive bacteria drug sensitivity card, Gram-negative bacteria drug sensitivity card, etc. to be identified.

[0076] S102: Use the drug sensitivity hole detection model to perform drug sensitivity hole detection on the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole.

[0077] Pre-train the drug susceptibility hole detection model, such as collecting 1,000 sample photos of drug susceptibility cards under white and black backgrounds and various lighting conditions, and then annotating the positions of the drug susceptibility holes in these sample photos. Finally, the annotated data set is trained using the YoloAuto model to obtain a drug susceptibility hole detection model for drug susceptibility hole position detection. The drug susceptibility hole detection model is based on the YoloV5 model, and the backbone network is replaced with GhostNet, so that the model becomes lighter and the detection speed is faster without affecting the detection accuracy, thereby improving the success rate and accuracy of drug susceptibility hole position information recognition. The recognition algorithm of the drug susceptibility hole detection model has strong generalization ability, strong robustness, unified recognition standards, and the system can run stably for a long time. It can be compatible with various industrial cameras, high-speed scanners, and cameras, with good hardware compatibility and low cost. By collecting sample photos of drug susceptibility cards under white and black backgrounds and various lighting conditions as training samples, it is not interfered by the surrounding external ambient light and can be compatible with the recognition of drug susceptibility card samples on white and black and white background boards. The problem that the white transparent plastic material of the drug sensitivity card is easily affected by the environment and the diversity of the actual use environment of the equipment is solved.

[0078] After collecting the initial drug sensitivity card sample image of the drug sensitivity card to be identified, the drug sensitivity hole detection model is used to detect the drug sensitivity holes of the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole. The drug sensitivity hole position information may include the center position of the drug sensitivity hole and the rectangular information surrounding the drug sensitivity hole. The embodiment of the present application uses the drug sensitivity hole detection model to detect the drug sensitivity hole position information. Compared with the drug sensitivity hole position detection method based on traditional machine vision using template matching, it avoids matching only the features of a single or several groups of samples and avoids interference from the external environment.

[0079] S103: cropping the initial drug sensitivity card sample image according to the position information of each drug sensitivity well to obtain sample images of each drug sensitivity well.

[0080] After obtaining the position information of each drug sensitivity well, the initial drug sensitivity card sample image is cropped according to the position information of each drug sensitivity well to obtain the sample image of each drug sensitivity well.

[0081] S104: Using the drug sensitivity well drug sensitivity identification result model, identify the sample image of each drug sensitivity well to obtain a drug sensitivity identification result.

[0082] Following the example in step S102, after collecting 1000 drug sensitivity card sample photos, the drug sensitivity hole detection model is used to obtain the location information of the drug sensitivity holes in each drug sensitivity card sample photo. Assuming that each drug sensitivity card contains 30 drug sensitivity holes, 30,000 drug sensitivity hole sample photos are obtained by cropping each drug sensitivity card sample photo, and all drug sensitivity hole sample photos are classified according to sensitive and non-sensitive to obtain a drug sensitivity hole sample data set. The drug sensitivity hole sample data set is trained using the AutoNet model through machine learning and deep learning technology. The model is based on ResNet, compresses the network depth, improves the BottleNeck residual block, modifies the parameters of some convolutional layers, and adds side branches and compression and excitation (Squeeze-and-Excitation, SE) modules. The activation function between each layer of the model uses the Gaussian Error Linear Units (GELU) function, and the model training loss function selects the Focal Loss function. Finally, a drug sensitivity well drug sensitivity recognition result model for drug sensitivity well drug sensitivity result identification is obtained. By training and optimizing on a large number of data sets, the recognition accuracy and generalization ability of the drug sensitivity well drug sensitivity recognition result model are improved.

[0083] After the sample images of each drug sensitivity well are obtained by cropping, the sample images of each drug sensitivity well are identified using the drug sensitivity well drug sensitivity identification result model to obtain the drug sensitivity identification result, that is, the drug sensitivity judgment results corresponding to each drug sensitivity well can be obtained.

[0084] In a specific implementation of the present application, step S104 may include the following steps:

[0085] The drug sensitivity well drug sensitivity recognition result model is used to identify the sample image of each drug sensitivity well to obtain the drug sensitivity result type and score probability value.

[0086] The drug sensitivity well drug sensitivity identification result model infers the drug sensitivity well sample image to obtain the model recognition result. In addition to being able to classify the drug sensitivity result type, the model recognition result can also judge its score probability value. The drug sensitivity well drug sensitivity identification result model is used to identify each drug sensitivity well sample image to obtain the drug sensitivity result type and score probability value. By simultaneously identifying the drug sensitivity result type and score probability value, the drug sensitivity result of the drug sensitivity card can be obtained intuitively and accurately.

[0087] In a specific embodiment of the present application, after obtaining the drug sensitivity result type and the score probability value, the method may further include the following steps:

[0088] Step 1: Determine whether the score probability value is greater than the preset threshold. If not, execute step 2. If yes, do nothing.

[0089] Step 2: Set the drug sensitivity result type to an intermediate abnormal value to perform a second confirmation of the drug sensitivity result.

[0090] For the convenience of description, the above two steps can be combined for explanation.

[0091] A threshold is set in advance. After obtaining the drug sensitivity result type and the score probability value, it is determined whether the score probability value is greater than the preset threshold. If the score probability value is greater than or equal to the preset threshold, the recognition result is used as the sensitivity and non-sensitivity result of drug sensitivity. If the score probability value is less than or equal to the preset threshold, the drug sensitivity result type of the drug sensitivity well is set as an intermediate abnormal value, and the drug sensitivity result needs to be reconfirmed later. By reconfirming the drug sensitivity result when the score probability value is not greater than the preset threshold, the probability of misjudgment of the drug sensitivity result is further reduced, and the accuracy of the drug sensitivity result is improved.

[0092] It can be seen from the above technical solution that by pre-training the drug sensitivity hole detection model and the drug sensitivity hole drug sensitivity identification result model, the drug sensitivity hole detection model is used to perform drug sensitivity hole detection on the collected initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole, and the initial drug sensitivity card sample image is cropped according to the position information of each drug sensitivity hole to obtain each drug sensitivity hole sample image, and the drug sensitivity hole drug sensitivity identification result model is used to identify each drug sensitivity hole sample image to obtain the drug sensitivity identification result. By combining the pre-trained drug sensitivity hole detection model and the drug sensitivity hole drug sensitivity identification result model to perform drug sensitivity identification on the drug sensitivity card, compared with manual observation and drug sensitivity identification methods based on traditional machine vision, the influence of human factors and environmental factors is avoided, and the recognition accuracy is greatly improved.

[0093] It should be noted that, based on the above embodiments, the embodiments of the present application also provide corresponding improved solutions. In the subsequent embodiments, the same steps or corresponding steps as those in the above embodiments can be referenced to each other, and the corresponding beneficial effects can also be referenced to each other, which will not be repeated one by one in the following improved embodiments.

[0094] See also Figure 2 , Figure 2 This is another implementation flow chart of the drug sensitivity identification method of the drug sensitivity card in the embodiment of the present application. The method may include the following steps:

[0095] S201: Collecting an initial sample image of the drug sensitivity card to be identified.

[0096] S202: Use the drug sensitivity hole detection model to perform drug sensitivity hole detection on the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole.

[0097] S203: Add the position information of each drug sensitivity well to a preset array to obtain an initial drug sensitivity well position information array.

[0098] A preset array is established. After the position information of each drug sensitivity well is detected and obtained, the position information of each drug sensitivity well is added to the preset array. For example, the ordinate and abscissa of the center point of each drug sensitivity well are added as an element to the preset array to obtain an initial drug sensitivity well position information array.

[0099] S204: Obtain the horizontal coordinate and the vertical coordinate of the center point of the first element of the drug sensitivity well position information in the initial drug sensitivity well position information array.

[0100] After obtaining the initial drug sensitivity well position information array, the abscissa and ordinate of the center point of the drug sensitivity well position information of the first element in the initial drug sensitivity well position information array are obtained.

[0101] S205: Taking the horizontal coordinate and the vertical coordinate of the center point of the first element of the drug sensitivity well position information as the starting elements, the drug sensitivity well position information in the initial drug sensitivity well position information array is sorted by the bubbling method to obtain a target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right.

[0102] The order in which the drug sensitivity well detection model outputs the drug sensitivity well position information is random, and the drug sensitivity well position information output by the model needs to be sorted in a specific order. The drug sensitivity card generally contains two rows of drug sensitivity wells, one above the other. After obtaining the horizontal coordinate and the vertical coordinate of the center point of the drug sensitivity well position information of the first element in the initial drug sensitivity well position information array, the horizontal coordinate and the vertical coordinate of the center point of the drug sensitivity well position information of the first element in the initial drug sensitivity well position information array are used as the starting elements, and the drug sensitivity well position information in the initial drug sensitivity well position information array is sorted using the bubbling method to obtain the target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right. By sorting the drug sensitivity well position information, the one-to-one correspondence between the drug sensitivity well position information output by the drug sensitivity well detection model and the actual drug sensitivity well position in the drug sensitivity card is achieved.

[0103] Bubble Sort, also known as bubble sort or foam sort, is a simple sorting algorithm. Its basic idea is to achieve sorting by repeatedly exchanging the positions of two adjacent elements.

[0104] The specific steps of the bubbling method are as follows:

[0105] (1) Starting from the first element of the sequence, compare the sizes of two adjacent elements. If the previous element is larger, swap their positions, that is, move the larger element to the back.

[0106] (2) Repeat the above comparison and exchange steps for the first pair of adjacent elements in the sequence until the last pair of adjacent elements in the sequence are compared and exchanged.

[0107] (3) Repeat the above steps, moving the largest element of the unsorted part to the end each time.

[0108] (4) Repeat steps (2) and (3) until all elements are sorted.

[0109] S206: Obtain the array size of the target drug sensitivity well position information array.

[0110] After obtaining the target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right, the array size of the target drug sensitivity well position information array is obtained to obtain the total number of elements contained in the target drug sensitivity well position information array.

[0111] S207: Determine whether the array size is equal to the preset number of drug sensitivity wells, if so, execute step S208, if not, return to execute step S201.

[0112] After obtaining the array size of the target drug sensitivity well position information array, determine whether the array size is equal to the preset number of drug sensitivity wells. If so, it means that the drug sensitivity well position detection is successful, and execute step S208. If not, it means that the drug sensitivity well position detection fails, and return to execute step S201.

[0113] S208: Using a minimum bounding rectangle algorithm, obtain a minimum bounding matrix containing the center points of all drug sensitivity wells in the target drug sensitivity well position information array, and determine the minimum bounding matrix as the drug sensitivity card position information.

[0114] When it is determined that the array size is equal to the preset number of drug sensitivity holes, it means that the drug sensitivity hole position detection is successful, and the minimum circumscribed rectangle algorithm is used to obtain the minimum circumscribed matrix containing the center point positions of all drug sensitivity holes in the target drug sensitivity hole position information array, and the minimum circumscribed matrix is ​​determined as the drug sensitivity card position information. The drug sensitivity card position information includes the center point position, angle, and length and width information of the drug sensitivity card.

[0115] The minimum enclosing rectangle algorithm is an algorithm used to find the minimum enclosing rectangle of a point set or contour. It can be used to calculate the minimum rectangle that contains a point set or contour and return the position, size and rotation angle of the rectangle.

[0116] S209: Obtain the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card location information.

[0117] See also Figure 3 , Figure 3 This is a schematic diagram of the position of a drug sensitivity card in an embodiment of the present application. The position of the drug sensitivity card in the picture is not necessarily horizontal. After the minimum circumscribed matrix is ​​determined as the drug sensitivity card position information, the drug sensitivity card position detection algorithm is called to obtain the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information.

[0118] S210: Calibrate the coordinate system of the initial drug sensitivity card sample image according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card to obtain a calibrated drug sensitivity card sample image.

[0119] After obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the location information of the drug sensitivity card, the coordinate system of the initial drug sensitivity card sample image is calibrated according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card. For example, the initial drug sensitivity card image is rotated counterclockwise with the coordinates of the center point of the drug sensitivity card as the center, and the rotation angle is the angle of the drug sensitivity card to obtain the calibrated drug sensitivity card sample image.

[0120] like Figure 3 As shown, the current angle of the drug sensitivity card is a negative value. Counterclockwise rotation of the negative angle is equivalent to rotating the initial drug sensitivity card image clockwise by the angle of the absolute value of the drug sensitivity card angle, so that the major axis of the minimum circumscribed rectangle of the drug sensitivity card coincides with the horizontal axis.

[0121] S211: cropping the calibrated drug sensitivity card sample image through a preset cropping region of interest to obtain a barcode paper region image.

[0122] like Figure 3 As shown, the relative position of the barcode paper area and the entire drug sensitivity card is fixed, the relative position of the barcode paper area and the entire drug sensitivity card is pre-stored, and the cropping region of interest is set. After obtaining the calibrated drug sensitivity card sample image, the calibrated drug sensitivity card sample image is cropped by the preset cropping region of interest (ROI) to obtain the barcode paper area image.

[0123] S212: Identify the barcode paper area image to obtain barcode information.

[0124] After obtaining the barcode paper area image, the barcode paper area image is identified to obtain the barcode information. The barcode paper area image is obtained by cropping the barcode paper area image according to the preset cropping area of ​​interest, and only the barcode paper area image is identified. Compared with the method of scanning and identifying the barcode through the entire image, the recognition speed and recognition accuracy are greatly improved.

[0125] S213: cropping the initial drug sensitivity card sample image according to the position information of each drug sensitivity well to obtain sample images of each drug sensitivity well.

[0126] S214: Using the drug sensitivity well drug sensitivity identification result model, identify the sample image of each drug sensitivity well to obtain a drug sensitivity identification result.

[0127] S215: Determine a mapping matrix according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card.

[0128] After obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the location information of the drug sensitivity card, a coordinate system centered on the drug sensitivity card can be established, and a mapping matrix can be determined according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card. The mapping matrix can be expressed by the following formula:

[0129]

[0130] Among them, α = scale·cos angle, β = scale·sin angle, scale represents the scaling factor, and takes the default value of 1.0. represents the horizontal coordinate of the center point, Represents the ordinate of the center point, angle represents the rotation angle, where the counterclockwise direction is the positive angle direction, α represents the product of the scaling factor scale and the cosine value of the rotation angle angle, and β represents the product of the scaling factor scale and the sin value of the rotation angle angle.

[0131] S216: Sparsely map the center point positions of each drug sensitivity well according to the mapping matrix to obtain the target positions of the center points of each drug sensitivity well in the calibrated drug sensitivity card sample image after mapping.

[0132] After determining the mapping matrix according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card, sparse mapping is performed on the center point positions of each drug sensitivity well according to the mapping matrix to obtain the target positions of the center points of each drug sensitivity well in the calibrated drug sensitivity card sample image after mapping.

[0133] S217: Draw the drug sensitivity identification results at each target position to obtain a drug sensitivity identification result map of the drug sensitivity card.

[0134] After obtaining the target position of the center point of each drug sensitivity well in the calibrated drug sensitivity card sample image after mapping, the drug sensitivity identification results are drawn at each target position to obtain the drug sensitivity identification result map of the drug sensitivity card. By calibrating the position of the center point of the drug sensitivity well, it is ensured that the drug sensitivity identification results of the drug sensitivity wells correspond to the corresponding drug sensitivity wells one by one, further improving the accuracy of drug sensitivity identification.

[0135] S218: Upload the drug sensitivity identification result chart and barcode information of the drug sensitivity card to the laboratory information management system.

[0136] After obtaining the drug sensitivity identification result map and barcode information of the drug sensitivity card, upload the drug sensitivity identification result map and barcode information of the drug sensitivity card to the laboratory information management system (Laboratory Information System, LIS). Through compatibility with the laboratory information management system, the automatic uploading of the drug sensitivity identification results of the drug sensitivity card is realized. By automatically triggering the drug sensitivity hole detection and identification function when the drug sensitivity card enters the camera field of view, drug sensitivity card barcode identification, and merging drug sensitivity information and barcode information and automatically uploading to the laboratory information management system, the speed of drug sensitivity card sample identification and the efficiency of information entry can be significantly improved.

[0137] The embodiment of the present application utilizes advanced technologies such as computer vision, machine learning, and deep learning, and realizes efficient and accurate identification of drug susceptibility card results through steps such as image acquisition and processing, feature extraction and analysis, model training and optimization, result prediction and verification, and real-time application and feedback. Through this method, the automation and intelligence of drug susceptibility card interpretation can be realized, which improves efficiency and accuracy, reduces the risk of human error, and provides a more reliable diagnostic tool for hospital medical staff.

[0138] In a specific embodiment of the present application, before sorting the drug sensitivity well position information in the initial drug sensitivity well position information array using the bubbling method, the method may further include the following steps:

[0139] Step 1: traverse the initial drug-sensitive well position information array to obtain the length and width of the minimum circumscribed rectangle of each drug-sensitive well position information;

[0140] Step 2: Calculate the mean of each length value and each width value to obtain the target mean;

[0141] Step 3: Determine the target mean as the standard drug sensitivity well diameter;

[0142] Accordingly, sorting the drug sensitivity well position information in the initial drug sensitivity well position information array using the bubbling method may include the following steps:

[0143] Step 4: Calculate the difference between the vertical coordinates of two adjacent drug sensitivity well position information in the initial drug sensitivity well position information array to obtain a target difference;

[0144] Step 5: Determine whether the absolute value of the target difference is greater than the standard drug sensitivity well diameter, if so, execute step 6, if not, execute step 7;

[0145] Step 6: Determine that the two drug sensitivity well position information belong to different rows in the drug sensitivity card, and sort them in the order of drug sensitivity well position information with a smaller ordinate first and drug sensitivity well position information with a larger ordinate later;

[0146] Step 7: Determine that the two drug sensitivity well position information belong to the same row in the drug sensitivity card, and sort them according to the drug sensitivity well position information with a smaller horizontal coordinate first and the drug sensitivity well position information with a larger horizontal coordinate later;

[0147] Among them, the ordinate and abscissa of the position information of each drug sensitivity well are the coordinates in a coordinate system established with the upper left corner of the drug sensitivity card as the coordinate origin, rightward as the positive direction of the horizontal axis, and downward as the positive direction of the vertical axis.

[0148] For the convenience of description, the above steps can be combined for explanation.

[0149] Before sorting the drug sensitivity well position information in the initial drug sensitivity well position information array, the initial drug sensitivity well position information array is traversed to obtain the length and width of the minimum circumscribed rectangle of each drug sensitivity well position information, and the average of each length value and each width value is calculated to obtain the target average, and the target average is determined as the standard drug sensitivity well diameter. A coordinate system is established with the upper left corner of the drug sensitivity card as the coordinate origin, the right as the positive direction of the horizontal axis, and the downward as the positive direction of the vertical axis, and the vertical and horizontal coordinates of each drug sensitivity well position information in the coordinate system are obtained. When sorting, the vertical coordinates of two adjacent drug-sensitive well position information in the initial drug-sensitive well position information array are calculated to obtain the target difference, and it is determined whether the absolute value of the target difference is greater than the standard drug-sensitive well diameter. If so, it is determined that the two drug-sensitive well position information belong to different rows in the drug-sensitive card, and the drug-sensitive well position information with a small vertical coordinate is sorted first and then the drug-sensitive well position information with a large vertical coordinate is sorted. If not, it is determined that the two drug-sensitive well position information belong to the same row in the drug-sensitive card, and the drug-sensitive well position information with a small horizontal coordinate is sorted first and then the drug-sensitive well position information with a large horizontal coordinate. In this way, the arrangement order of each drug-sensitive well position information in the target drug-sensitive well position information array obtained after sorting corresponds to the order from left to right and from top to bottom in the drug-sensitive card.

[0150] The embodiment of the present application designs a web front-end page for the overall process control of the intelligent interpretation of drug sensitivity cards. The page mainly includes camera real-time image display, drug sensitivity identification result display, barcode recognition result display, identification result display and secondary confirmation, identification button and save test information button.

[0151] Real-time camera image display: Real-time display of the image content taken by the camera, allowing you to intuitively observe the drug sensitivity card images within the field of view;

[0152] Display of drug sensitivity identification results: automatically correct the direction, crop the image of the drug sensitivity card area, and display the drug sensitivity judgment results. Sensitivity is displayed with a green "circle" and a "+", insensitivity is displayed with a red "circle" and a "-", and the middle abnormal value is displayed with a yellow "circle" and a "?";

[0153] Barcode recognition result display: display the recognized barcode content;

[0154] Display of identification results and secondary confirmation: After identification is completed, the algorithm identification results are displayed, where yellow represents "sensitive", red represents "insensitive", and "?" represents intermediate abnormal values, which require secondary confirmation by personnel. If there is any objection to the identification result of any drug sensitivity well, the user can click to modify the identification result.

[0155] Identification button: Click to resend the camera photo and re-read the drug sensitivity card;

[0156] Save test information button: Click to upload the drug sensitivity identification results and barcode information to the laboratory information management system.

[0157] The overall implementation process of intelligent drug sensitivity interpretation is as follows:

[0158] (1) The camera collects pictures in real time, displays them in the "Camera Real-time Picture Display" area, and calls the drug sensitivity card position detection function;

[0159] (2) There is no drug sensitivity card sample in the image, and the result returned indicates that the drug sensitivity card is not recognized. The delay is 500 milliseconds, the camera collects a picture, and the drug sensitivity card position detection function is continued to be called;

[0160] (3) Place the drug sensitivity card within the field of view of the camera to collect images;

[0161] (4) When a drug sensitivity card sample appears in the camera image, the drug sensitivity card position detection function is called to obtain the location information of the current drug sensitivity card. After a delay of 200 milliseconds, the camera captures a picture.

[0162] (5) calling the drug sensitivity card location detection function again to obtain the current drug sensitivity card location information and compare it with the drug sensitivity card location information obtained last time;

[0163] (6) Setting a threshold value. If the Euclidean distance deviation between the positions of the two drug sensitivity cards is greater than or equal to the set threshold value, it means that the drug sensitivity card is still moving. The current drug sensitivity card position information is saved, a delay of 200 milliseconds is applied, and the camera captures a picture.

[0164] (7) Calling the drug sensitivity card position detection function again, if the Euclidean distance between the two drug sensitivity card positions is less than the set threshold, it means that the drug sensitivity card has been stably placed within the camera's field of view;

[0165] (8) calling the drug sensitivity card drug sensitivity hole position detection function to obtain the location information of the drug sensitivity card and the location information of all drug sensitivity holes;

[0166] (9) Using the position information of all drug sensitivity wells, cropping the image to obtain images of all drug sensitivity wells;

[0167] (10) calling the drug sensitivity identification function of the drug sensitivity wells for all drug sensitivity well images to obtain the drug sensitivity identification results of all drug sensitivity wells;

[0168] (11) using the center position and rotation angle information of the drug sensitivity card position information obtained, establishing a coordinate system centered on the drug sensitivity card to obtain a mapping matrix;

[0169] (12) rotating and calibrating the drug sensitivity card image to obtain a calibrated drug sensitivity card image;

[0170] (13) Crop the image according to the set cropping area of ​​interest, obtain the calibrated drug sensitivity card area image, use the mapping matrix to calibrate the position information in the drug sensitivity identification result, and obtain the drug sensitivity identification result map of the drug sensitivity card;

[0171] (14) Using the drug sensitivity card image to call the drug sensitivity card barcode recognition function to obtain the drug sensitivity card barcode information;

[0172] (15) Displaying the obtained drug sensitivity identification result diagram of the drug sensitivity card in the "drug sensitivity identification result display" area;

[0173] (16) Displaying the drug sensitivity identification results of all drug sensitivity wells obtained in the "Identification Result Display and Secondary Confirmation" area;

[0174] (17) Display the obtained drug sensitivity card barcode information in the "barcode recognition result display" area;

[0175] (18) Delay 500 milliseconds, the camera collects a picture, and calls the drug sensitivity card position detection function. If a drug sensitivity card is detected, delay 500 milliseconds, the camera collects a picture again and calls the drug sensitivity card position detection function, until no drug sensitivity card is detected, the current round of drug sensitivity card intelligent interpretation ends, and the next round of identification starts again;

[0176] (19) If there is a problem with the automatically triggered drug sensitivity card recognition result, you can click the "Recognize" button to manually trigger the drug sensitivity card recognition and obtain the drug sensitivity card recognition result and barcode recognition result;

[0177] (20) The results of intelligent identification of the drug susceptibility card identification algorithm are displayed in the "Identification Result Display and Secondary Confirmation" area. Personnel will confirm and correct the problematic identification results. For the results of the drug susceptibility well identification as "intermediate outliers", they must be manually corrected to "sensitive" or "insensitive" types before they can be saved and uploaded to the laboratory information management system;

[0178] (21) Click the "Save Test Information" button to automatically upload the current drug sensitivity card drug sensitivity identification results and barcode identification results to the laboratory information management system to complete the identification of the current drug sensitivity card sample;

[0179] (22) Take out the current drug sensitivity card and end the identification of the current drug sensitivity card sample.

[0180] Corresponding to the above method embodiment, the present application also provides a drug sensitivity card drug sensitivity identification device. The drug sensitivity card drug sensitivity identification device described below and the drug sensitivity card drug sensitivity identification method described above can be referenced to each other.

[0181] See also Figure 4 , Figure 4 This is a structural block diagram of a drug sensitivity card drug sensitivity identification device in an embodiment of the present application, and the device may include:

[0182] The image acquisition module 41 is used to acquire the initial sample image of the drug sensitivity card to be identified;

[0183] The drug sensitivity hole position acquisition module 42 is used to perform drug sensitivity hole detection on the initial drug sensitivity card sample image using the drug sensitivity hole detection model to obtain the position information of each drug sensitivity hole;

[0184] The drug sensitivity well image acquisition module 43 is used to crop the initial drug sensitivity card sample image according to the position information of each drug sensitivity well to obtain the sample image of each drug sensitivity well;

[0185] The drug sensitivity identification result obtaining module 44 is used to identify each drug sensitivity well sample image using the drug sensitivity well drug sensitivity identification result model to obtain a drug sensitivity identification result.

[0186] It can be seen from the above technical solution that by pre-training the drug sensitivity hole detection model and the drug sensitivity hole drug sensitivity identification result model, the drug sensitivity hole detection model is used to perform drug sensitivity hole detection on the collected initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole, and the initial drug sensitivity card sample image is cropped according to the position information of each drug sensitivity hole to obtain each drug sensitivity hole sample image, and the drug sensitivity hole drug sensitivity identification result model is used to identify each drug sensitivity hole sample image to obtain the drug sensitivity identification result. By combining the pre-trained drug sensitivity hole detection model and the drug sensitivity hole drug sensitivity identification result model to perform drug sensitivity identification on the drug sensitivity card, compared with manual observation and drug sensitivity identification methods based on traditional machine vision, the influence of human factors and environmental factors is avoided, and the recognition accuracy is greatly improved.

[0187] In a specific embodiment of the present application, the drug sensitivity identification result obtaining module 44 is specifically a module that uses the drug sensitivity well drug sensitivity identification result model to identify each drug sensitivity well sample image to obtain the drug sensitivity result type and score probability value.

[0188] In a specific embodiment of the present application, the device may further include:

[0189] The first judgment module is used to judge whether the score probability value is greater than a preset threshold after obtaining the drug sensitivity result type and the score probability value;

[0190] The secondary confirmation module is used to set the drug sensitivity result type to an intermediate abnormal value when it is determined that the score probability value is not greater than a preset threshold value, so as to perform secondary confirmation of the drug sensitivity result.

[0191] In a specific embodiment of the present application, the device may further include:

[0192] An initial array acquisition module is used to add the position information of each drug sensitivity well to a preset array after obtaining the position information of each drug sensitivity well, so as to obtain an initial drug sensitivity well position information array;

[0193] A coordinate acquisition module, used to obtain the horizontal coordinate and the vertical coordinate of the center point of the first element of the drug sensitivity well position information in the initial drug sensitivity well position information array;

[0194] The target array acquisition module is used to use the abscissa and ordinate of the center point of the first element of the drug sensitivity well position information as the starting element, and use the bubbling method to sort the drug sensitivity well position information in the initial drug sensitivity well position information array to obtain a target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right;

[0195] The drug sensitivity card position determination module is used to use the minimum circumscribed rectangle algorithm to obtain the minimum circumscribed matrix containing the center point positions of all drug sensitivity holes in the target drug sensitivity hole position information array, and determine the minimum circumscribed matrix as the drug sensitivity card position information.

[0196] In a specific embodiment of the present application, the device may further include:

[0197] The drug sensitivity card coordinate and angle acquisition module is used to obtain the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information after the minimum circumscribed matrix is ​​determined as the drug sensitivity card position information;

[0198] A module for obtaining a calibrated image is used to calibrate the coordinate system of the initial drug sensitivity card sample image according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card to obtain a calibrated drug sensitivity card sample image;

[0199] The barcode paper area image acquisition module is used to crop the calibrated drug sensitivity card sample image through a preset cropping area of ​​interest to obtain a barcode paper area image;

[0200] The barcode information acquisition module is used to identify the barcode paper area image and obtain the barcode information.

[0201] In a specific embodiment of the present application, the device may further include:

[0202] A mapping matrix determination module is used to determine a mapping matrix according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card after obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information;

[0203] The target position acquisition module is used to perform sparse mapping on the center point of each drug sensitivity well according to the mapping matrix, and obtain the target position of the center point of each drug sensitivity well in the calibrated drug sensitivity card sample image after mapping;

[0204] The recognition result map acquisition module is used to draw the drug sensitivity recognition results at each target position to obtain the drug sensitivity recognition result map of the drug sensitivity card.

[0205] In a specific embodiment of the present application, the device may further include:

[0206] The information uploading module is used to upload the drug sensitivity card drug sensitivity identification result map and barcode information to the laboratory information management system after drawing the drug sensitivity identification results at each target position to obtain the drug sensitivity card drug sensitivity identification result map.

[0207] In a specific embodiment of the present application, the device may further include:

[0208] A length value and width value obtaining module, used for traversing the initial drug sensitivity well position information array to obtain the length value and width value of the minimum circumscribed rectangle of each drug sensitivity well position information before sorting each drug sensitivity well position information in the initial drug sensitivity well position information array by using the bubbling method;

[0209] A mean calculation module is used to calculate the mean of each length value and each width value to obtain a target mean;

[0210] A drug sensitivity pore diameter determination module, used to determine the target mean as the standard drug sensitivity pore diameter;

[0211] The target array acquisition module includes:

[0212] A target difference obtaining submodule is used to calculate the difference between the ordinates of two adjacent drug sensitivity well position information in the initial drug sensitivity well position information array to obtain a target difference;

[0213] A judgment submodule is used to judge whether the absolute value of the target difference is greater than the standard drug sensitivity well diameter;

[0214] The first sorting submodule is used to determine that the two drug sensitivity well position information belong to different rows in the drug sensitivity card when the absolute value of the target difference is greater than the standard drug sensitivity well diameter, and sort the drug sensitivity well position information with the smaller ordinate first and the larger ordinate later;

[0215] The second sorting submodule is used to determine that the two drug sensitivity well position information belong to the same row in the drug sensitivity card when the absolute value of the target difference is determined to be no greater than the standard drug sensitivity well diameter, and to sort the two drug sensitivity well position information in the order of drug sensitivity well position information with a smaller horizontal coordinate first and drug sensitivity well position information with a larger horizontal coordinate later;

[0216] Among them, the ordinate and abscissa of the position information of each drug sensitivity well are the coordinates in a coordinate system established with the upper left corner of the drug sensitivity card as the coordinate origin, rightward as the positive direction of the horizontal axis, and downward as the positive direction of the vertical axis.

[0217] In a specific embodiment of the present application, the device may further include:

[0218] An array size acquisition module is used to obtain the array size of the target drug sensitivity well position information array after obtaining the target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right, and before obtaining the minimum circumscribed matrix containing the positions of the center points of all drug sensitivity wells in the target drug sensitivity well position information array using a minimum circumscribed rectangle algorithm;

[0219] The second judgment module is used to judge whether the array size is equal to the preset number of drug sensitivity wells;

[0220] The drug sensitivity card position determination module is specifically a module that uses a minimum bounding rectangle algorithm to obtain the minimum bounding matrix of the center points of all drug sensitivity wells in the target drug sensitivity well position information array when the array size is equal to the preset number of drug sensitivity wells;

[0221] The repeated execution module is used to repeatedly execute the step of collecting the initial drug sensitivity card sample image of the drug sensitivity card to be identified when it is determined that the array size is not equal to the preset number of drug sensitivity holes.

[0222] Corresponding to the above method embodiment, see Figure 5 , Figure 5 This is a schematic diagram of the drug sensitivity card drug sensitivity identification device provided in this application, which may include:

[0223] A memory 332, for storing computer programs;

[0224] The processor 322 is used to implement the steps of the drug sensitivity card drug sensitivity identification method of the above method embodiment when executing the computer program.

[0225] For details, please refer to Figure 6 , Figure 6 A schematic diagram of the specific structure of a drug sensitivity card drug sensitivity identification device provided in this embodiment, which may have relatively large differences due to different configurations or performances, may include a processor (central processing units, CPU) 322 (for example, one or more processors) and a memory 332, and the memory 332 stores one or more computer programs 342 or data 344. Among them, the memory 332 can be a temporary storage or a permanent storage. The program stored in the memory 332 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations in the data processing device. Furthermore, the processor 322 can be configured to communicate with the memory 332 to execute a series of instruction operations in the memory 332 on the drug sensitivity card drug sensitivity identification device 301.

[0226] The drug sensitivity card drug sensitivity identification device 301 may also include one or more power supplies 326 , one or more wired or wireless network interfaces 350 , one or more input and output interfaces 358 , and / or one or more operating systems 341 .

[0227] The steps in the drug sensitivity card drug sensitivity identification method described above can be implemented by the structure of the drug sensitivity card drug sensitivity identification device.

[0228] Corresponding to the above method embodiment, the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the following steps can be implemented:

[0229] Collect the initial drug sensitivity card sample image of the drug sensitivity card to be identified; use the drug sensitivity hole detection model to perform drug sensitivity hole detection on the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole; crop the initial drug sensitivity card sample image according to the position information of each drug sensitivity hole to obtain the sample image of each drug sensitivity hole; use the drug sensitivity hole drug sensitivity identification result model to identify each drug sensitivity hole sample image to obtain the drug sensitivity identification result.

[0230] The computer-readable storage medium may include: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program codes.

[0231] For an introduction to the computer-readable storage medium provided in this application, please refer to the above method embodiment, and this application will not go into details here.

[0232] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the devices, equipment and computer-readable storage media disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the method part description.

[0233] Specific examples are used herein to illustrate the principles and implementation methods of the present application, and the description of the above embodiments is only used to help understand the technical solution and core ideas of the present application. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the present application.

Claims

1. A drug sensitivity identification method using a drug sensitivity card, characterized in that: include: Collect the initial sample pictures of the drug sensitivity cards to be identified; Using the drug sensitivity hole detection model to perform drug sensitivity hole detection on the initial drug sensitivity card sample image to obtain the position information of each drug sensitivity hole; The initial drug sensitivity card sample image is cropped according to the position information of each drug sensitivity well to obtain sample images of each drug sensitivity well; The drug sensitivity well drug sensitivity identification result model is used to identify each of the drug sensitivity well sample images to obtain a drug sensitivity identification result.

2. The drug sensitivity identification method of drug sensitivity card according to claim 1, characterized in that: The drug sensitivity well drug sensitivity identification result model is used to identify each of the drug sensitivity well sample images to obtain drug sensitivity identification results, including: The drug sensitivity well drug sensitivity identification result model is used to identify each of the drug sensitivity well sample images to obtain the drug sensitivity result type and score probability value.

3. The drug sensitivity identification method of drug sensitivity card according to claim 2, characterized in that: After obtaining the drug sensitivity result type and score probability value, it also includes: Determine whether the score probability value is greater than a preset threshold; If not, the drug sensitivity result type is set to an intermediate abnormal value to perform a secondary confirmation of the drug sensitivity result.

4. The drug sensitivity identification method of drug sensitivity card according to any one of claims 1 to 3, characterized in that: After obtaining the location information of each drug sensitivity well, it also includes: Adding the position information of each drug-sensitive well to a preset array to obtain an initial drug-sensitive well position information array; Obtain the horizontal coordinate and the vertical coordinate of the center point of the first element of the drug sensitivity well position information in the initial drug sensitivity well position information array; Taking the abscissa and ordinate of the center point of the first element of the drug sensitivity well position information as the starting elements, the drug sensitivity well position information in the initial drug sensitivity well position information array is sorted by the bubbling method to obtain a target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right; The minimum circumscribed rectangle algorithm is used to obtain the minimum circumscribed matrix containing the center point positions of all drug sensitivity wells in the target drug sensitivity well position information array, and the minimum circumscribed matrix is ​​determined as the drug sensitivity card position information.

5. The drug sensitivity identification method of drug sensitivity card according to claim 4, characterized in that: After determining the minimum circumscribed matrix as the drug sensitivity card location information, the method further includes: Obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information; Calibrate the coordinate system of the initial drug sensitivity card sample image according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card to obtain a calibrated drug sensitivity card sample image; The calibrated drug sensitivity card sample image is cropped through a preset cropping region of interest to obtain a barcode paper region image; The barcode paper area image is identified to obtain barcode information.

6. The drug sensitivity identification method of drug sensitivity card according to claim 5, characterized in that: After obtaining the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card in the drug sensitivity card position information, the method further includes: Determine a mapping matrix according to the coordinates of the center point of the drug sensitivity card and the angle of the drug sensitivity card; Sparsely map the positions of the center points of the drug sensitivity wells according to the mapping matrix to obtain the target positions of the center points of the drug sensitivity wells in the calibrated drug sensitivity card sample image after mapping; The drug sensitivity identification results are drawn at each of the target positions to obtain a drug sensitivity identification result map of the drug sensitivity card.

7. The drug sensitivity identification method of drug sensitivity card according to claim 6, characterized in that: After drawing the drug sensitivity identification results at each of the target positions to obtain a drug sensitivity identification result map of the drug sensitivity card, the method further includes: The drug sensitivity card drug sensitivity identification result chart and the barcode information are uploaded to the laboratory information management system.

8. The drug sensitivity identification method of drug sensitivity card according to claim 4, characterized in that: Before sorting the drug-sensitive well position information in the initial drug-sensitive well position information array by using the bubbling method, the method further includes: Traversing the initial drug-sensitive well position information array to obtain the length value and width value of the minimum circumscribed rectangle of the drug-sensitive well in each of the drug-sensitive well position information; Calculate the mean of each length value and each width value to obtain a target mean; The target mean is determined as the standard drug-sensitive pore diameter; Correspondingly, the bubbling method is used to sort the drug-sensitive well position information in the initial drug-sensitive well position information array, including: Calculating the difference between the ordinates of two adjacent drug-sensitive well position information in the initial drug-sensitive well position information array to obtain a target difference; Determining whether the absolute value of the target difference is greater than the standard drug-sensitive pore diameter; If so, it is determined that the two drug sensitivity well position information belong to different rows in the drug sensitivity card, and the drug sensitivity well position information with a smaller ordinate is sorted first and then the drug sensitivity well position information with a larger ordinate is sorted; If not, it is determined that the two drug sensitivity well position information belong to the same row in the drug sensitivity card, and the drug sensitivity well position information with a smaller horizontal coordinate is sorted first and then the drug sensitivity well position information with a larger horizontal coordinate is sorted; Among them, the ordinate and abscissa of the position information of each drug sensitivity hole are coordinates in a coordinate system established with the upper left corner of the drug sensitivity card as the coordinate origin, the right as the positive direction of the horizontal axis, and the downward as the positive direction of the vertical axis.

9. The drug sensitivity identification method of drug sensitivity card according to claim 4, characterized in that: After obtaining the target drug sensitivity well position information array in which the drug sensitivity wells are sorted from top to bottom and from left to right, and before using the minimum circumscribed rectangle algorithm to obtain the minimum circumscribed matrix containing the positions of the center points of all drug sensitivity wells in the target drug sensitivity well position information array, the method further includes: Obtaining the array size of the target drug sensitivity well position information array; Determining whether the array size is equal to the preset number of drug sensitivity wells; If yes, then executing the step of using the minimum bounding rectangle algorithm to obtain the minimum bounding matrix containing the positions of the center points of all drug-sensitive wells in the target drug-sensitive well position information array; If not, repeat the step of collecting the initial drug sensitivity card sample picture of the drug sensitivity card to be identified.

10. A drug sensitivity card drug sensitivity identification device, characterized in that: include: An image collection module is used to collect the initial drug sensitivity card sample image of the drug sensitivity card to be identified; A drug sensitivity hole position acquisition module is used to perform drug sensitivity hole detection on the initial drug sensitivity card sample image using a drug sensitivity hole detection model to obtain the position information of each drug sensitivity hole; A drug sensitivity well image acquisition module, used to crop the initial drug sensitivity card sample image according to the position information of each drug sensitivity well to obtain sample images of each drug sensitivity well; The drug sensitivity identification result obtaining module is used to identify each of the drug sensitivity well sample images using the drug sensitivity well drug sensitivity identification result model to obtain the drug sensitivity identification result.

11. A drug sensitivity card drug sensitivity identification device, characterized in that: include: Memory for storing computer programs; A processor is used to implement the steps of the drug sensitivity identification method of the drug sensitivity card as described in any one of claims 1 to 9 when executing the computer program.

12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the drug sensitivity identification method of the drug sensitivity card as claimed in any one of claims 1 to 9 are implemented.

Citation Information

Patent Citations

  • Methods and systems for determining optical regions of interest

    CN107889521A

  • Biological reagent position identification method, device and system based on image acquisition

    CN111121622A

  • Colloidal gold detection card identification method and system, electronic equipment and storage medium

    CN113112453A

  • Quality detection method of qPCR (quantitative polymerase chain reaction) pore plate and related equipment

    CN115950888A

  • Micro-fluidic chip reaction hole image recognition method and system based on image matching

    CN116051557A