An intelligent drug classification system

Through the intelligent drug classification system, the drug identification and detailed data are automatically determined using image and text recognition technology, which solves the problem of time-consuming and labor-consuming classification of traditional Chinese medicines in the existing technology, and achieves efficient and accurate drug classification.

CN119649134BActive Publication Date: 2025-07-11SECOND MEDICAL CENT OF CHINESE PLA GENERAL HOSPITAL
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411795973.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-09
Publication Date
2025-07-11
Estimated Expiration
2044-12-09

AI Technical Summary

Technical Problem

The existing technology lacks unified drug classification standards and representative product selection standards, which makes manual review time-consuming and labor-intensive, and it is difficult to ensure the systemicity and integrity of classification, affecting the drug selection of clinicians and patients.

Method used

The intelligent drug classification system is adopted to obtain the outer packaging images of the drug through the image acquisition device, and the image feature recognition model and text recognition model are used to automatically determine the drug identification and detailed data, and drug classification is carried out based on user-defined classification basis.

Benefits of technology

It improves the efficiency and accuracy of drug classification, reduces the time and errors of manual review, and ensures the systemicity and integrity of classification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119649134B_ABST
    Figure CN119649134B_ABST
Patent Text Reader

Abstract

The present invention relates to an intelligent drug classification system, which relates to the field of artificial intelligence technology. The system mainly includes: obtaining the outer packaging image of the drug to be classified through the graphic acquisition device; determining whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer packaging image; if a drug identifier uniquely corresponding to the drug to be classified can be obtained, obtaining the detailed drug data corresponding to the drug identifier according to the drug database; if a drug identifier uniquely corresponding to the drug to be classified cannot be obtained, obtaining the instruction manual image of the drug to be classified; determining the corresponding detailed drug data according to the instruction manual image; processing the detailed drug data based on the user-defined classification basis to obtain the classification result corresponding to the drug to be classified.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to an intelligent drug classification system. Background Art

[0002] At present, there is no unified standard for drug classification and representative product selection in the industry. At the same time, due to the large number of drug categories, manual review and classification is time-consuming and labor-intensive, and it is difficult to ensure the systematicness and integrity of the classification. The classification of drugs and the selection of representative products are crucial to payment standards, affecting the prescription choices of clinicians and the medication choices of patients, and thus affecting their effective value in clinical practice. Summary of the invention

[0003] The present invention is intended to provide an intelligent drug classification system to solve the deficiencies in the prior art. The technical problem to be solved by the present invention is achieved through the following technical solutions.

[0004] An embodiment of the present invention provides an intelligent drug classification system, the system comprising: an image acquisition device, a drug database, and a drug classification device, the drug classification device comprising: a memory and at least one processor, the memory storing a computer program, the at least one processor being configured to implement the following steps when executing the computer program:

[0005] Acquire the outer packaging image of the drug to be classified by the image acquisition device;

[0006] Determining whether a drug identification uniquely corresponding to the drug to be classified can be obtained according to the outer packaging image;

[0007] If a drug identification uniquely corresponding to the drug to be classified can be obtained, then obtaining drug detailed data corresponding to the drug identification according to the drug database;

[0008] If the drug identification uniquely corresponding to the drug to be classified cannot be obtained, then obtaining the instruction image of the drug to be classified;

[0009] Determine the corresponding detailed data of the drug according to the instruction image;

[0010] The detailed data of the drug is processed based on the classification basis defined by the user to obtain the classification result corresponding to the drug to be classified.

[0011] In an optional embodiment, determining whether a drug identification uniquely corresponding to the drug to be classified can be obtained according to the outer packaging image includes:

[0012] Input the outer packaging image into an image feature recognition model to obtain the image recognition features corresponding to the outer packaging image; the image recognition features at least include color features, texture features, graphic structure features, and edge features;

[0013] By calculating the similarity between the image recognition features and the drug image features in the drug database, determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained.

[0014] In an optional embodiment, the step of calculating the similarity between the image recognition features and the drug image features in the drug database to determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained includes:

[0015] Calculate the color similarity, texture similarity, graphic structure similarity, and edge similarity respectively by calculating the similarity between the color features, texture features, graphic structure features, and edge features in the image recognition features and the color features, texture features, graphic structure features, and edge features in each drug image feature in the drug database;

[0016] Perform a weighted calculation on the color similarity, the texture similarity, the graphic structure similarity, and the edge similarity to obtain the similarity of each drug image feature in the drug database;

[0017] Determine the drug identifier corresponding to the drug image feature in the drug database with a similarity exceeding a preset value and the highest similarity as the drug identifier uniquely corresponding to the drug to be classified.

[0018] In an optional embodiment, the step of inputting the outer packaging image into an image feature recognition model to obtain the image recognition features corresponding to the outer packaging image includes:

[0019] Input the outer packaging image into an image feature recognition model, and obtain initial image data features through the feature extraction layer in the image feature recognition model;

[0020] Input the initial image data features into a color feature extraction module, a texture feature extraction module, a graphic structure extraction module, and an edge detection module respectively to obtain the color features, texture features, graphic structure features, and edge features corresponding to the outer packaging image.

[0021] In an optional embodiment, the step of determining the corresponding drug detailed data according to the instruction manual image includes:

[0022] Perform image recognition on the instruction manual image through image recognition technology to obtain initial drug instruction data;

[0023] Input the instruction manual image and the initial drug data into a text recognition model to determine the intermediate drug description data corresponding to the initial drug data;

[0024] Determine the detailed drug data corresponding to the instruction manual image according to the initial drug description data and the intermediate drug description data.

[0025] In an alternative embodiment, the determining the detailed drug data corresponding to the instruction manual image according to the initial drug description data and the intermediate drug description data includes:

[0026] Determine the data difference position between the initial drug description data and the intermediate drug description data;

[0027] Perform text analysis on the context of the data difference position to determine the final data text content of the data difference position to obtain the final intermediate drug description data;

[0028] Determine the final intermediate drug description data as the detailed drug data corresponding to the instruction manual image.

[0029] In an alternative embodiment, the inputting the instruction manual image and the initial drug data into a text recognition model to determine the intermediate drug description data corresponding to the initial drug data includes:

[0030] Input the instruction manual image and the initial drug data into a text recognition model, and obtain an instruction manual image vector and an initial drug data vector through the convolutional layer in the text recognition model;

[0031] Input the instruction manual image vector into a first prediction module to obtain a first predicted text result; input the initial drug data vector into a second prediction module to obtain a second predicted text result;

[0032] Determine the intermediate drug description data corresponding to the initial drug data by comparing the first predicted text result and the second predicted text result.

[0033] In an alternative embodiment, the processing the detailed drug data based on a user-defined classification criterion to obtain a classification result corresponding to the drug to be classified includes:

[0034] Obtain a user-defined classification criterion, and determine corresponding data fields according to the classification criterion;

[0035] Extract text from the detailed drug data according to the data fields to obtain corresponding data content;

[0036] Determine the classification result corresponding to the drug to be classified according to the data content.

[0037] In an optional embodiment, the step of extracting text from the drug detailed data according to the data field to obtain corresponding data content includes:

[0038] Determine the field set corresponding to the data field, where the fields in the field set are synonyms and / or near-synonyms of the data field;

[0039] Match the field set with the drug detailed data to determine the position of the corresponding data field in the drug detailed data;

[0040] Extract the data content related to the data field position from the drug detailed data.

[0041] An embodiment of the present invention provides an intelligent drug classification method, and the method includes:

[0042] Obtain the outer packaging image of the drug to be classified through a graphic acquisition device;

[0043] Determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer packaging image;

[0044] If a drug identifier uniquely corresponding to the drug to be classified can be obtained, obtain the drug detailed data corresponding to the drug identifier according to the drug database;

[0045] If a drug identifier uniquely corresponding to the drug to be classified cannot be obtained, obtain the instruction manual image of the drug to be classified;

[0046] Determine the corresponding drug detailed data according to the instruction manual image;

[0047] Process the drug detailed data based on the user-defined classification basis to obtain the classification result corresponding to the drug to be classified.

[0048] The embodiments of the present invention have the following advantages:

[0049] An intelligent drug classification system provided by an embodiment of the present invention, the system includes: an image acquisition device, a drug database, and a drug classification device, the drug classification device includes: a memory and at least one processor, the memory stores a computer program, and the at least one processor is configured to implement the following steps when executing the computer program: First, obtain an outer package image of the drug to be classified through the graphic acquisition device; then determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer package image; if a drug identifier uniquely corresponding to the drug to be classified can be obtained, obtain drug detailed data corresponding to the drug identifier according to the drug database; if a drug identifier uniquely corresponding to the drug to be classified cannot be obtained, obtain an instruction manual image of the drug to be classified; determine corresponding drug detailed data according to the instruction manual image; process the drug detailed data based on the classification basis defined by the user to obtain a classification result corresponding to the drug to be classified. Compared with the current manual verification and classification of drugs, the present application automatically determines the classification result of the drug to be classified based on the outer package image of the drug to be classified, thereby improving the efficiency and accuracy of drug classification through the present application. Brief Description of the Drawings

[0050] Figure 1 is a flowchart of an intelligent drug classification method provided by an embodiment of the present invention;

[0051] Figure 2 is a flowchart for determining drug detailed data provided by an embodiment of the present invention;

[0052] Figure 3 is a schematic structural diagram of an intelligent drug classification device provided by an embodiment of the present invention. Detailed Description of the Embodiment

[0053] It should be noted that, without conflict, the embodiments in the present application and the features in the embodiments can be combined with each other. The present invention will be described in detail below with reference to the drawings and in combination with the embodiments.

[0054] An intelligent drug classification system provided by an embodiment of the present invention, the system includes: an image acquisition device, a drug database, and a drug classification device, the drug classification device includes: a memory and at least one processor, the memory stores a computer program. Please refer to Figure 1 For the flowchart of an intelligent drug classification method provided by this embodiment, the at least one processor is configured to implement the following steps when executing the computer program:

[0055] S101, obtain an outer package image of the drug to be classified through the graphic acquisition device.

[0056] In this embodiment, the image acquisition device may be a device capable of capturing images, such as a mobile phone or a handheld scanner. Specifically, in this embodiment, the outer packaging of the medicine to be classified can be photographed by a mobile phone to obtain an outer packaging image, so as to classify the medicine to be classified according to the outer packaging image.

[0057] It should be noted that in this embodiment, the outer packaging image of any one or more sides of the medicine to be classified can be photographed. Preferably, in this embodiment, the front image (an image with obvious features) of the medicine to be classified can be photographed, and then the photographed front image is used as the outer packaging image of the medicine to be classified.

[0058] S102. Determine whether a medicine identifier uniquely corresponding to the medicine to be classified can be obtained according to the outer packaging image.

[0059] Among them, the medicine identifier can uniquely identify the corresponding medicine to be classified. The medicine identifier can be composed of numbers and letters, and the corresponding medicine to be classified can be uniquely determined through the medicine identifier.

[0060] In an optional embodiment provided by the present application, the determining whether a medicine identifier uniquely corresponding to the medicine to be classified can be obtained according to the outer packaging image includes:

[0061] S1021. Input the outer packaging image into an image feature recognition model to obtain the image recognition features corresponding to the outer packaging image.

[0062] Among them, the image recognition features at least include color features, texture features, graphic structure features, and edge features.

[0063] Specifically, the inputting the outer packaging image into an image feature recognition model to obtain the image recognition features corresponding to the outer packaging image includes: inputting the outer packaging image into the image feature recognition model, and obtaining initial image data features through the feature extraction layer in the image feature recognition model; respectively inputting the initial image data features into a color feature extraction module, a texture feature extraction module, a graphic structure extraction module, and an edge detection module to obtain the color features, texture features, graphic structure features, and edge features corresponding to the outer packaging image.

[0064] Among them, the color feature extraction module is used to extract the surface properties corresponding to an image or an image region. Based on the features of pixel points, it reflects the global distribution of colors in the image, such as color histograms, color sets, color moments, etc.; the texture feature extraction module is used to extract the surface properties corresponding to an image or an image region. Different from color features, texture features are not based on the features of pixel points, but need to be statistically calculated in a region containing multiple pixel points; the graphic structure extraction module is for the outer boundary of an object, while the regional features of an image are related to the entire shape region and the mutual spatial positions or relative orientation relationships among multiple objects segmented from the image. These relationships can also be divided into connection / adjacency relationships, overlap / overlap relationships, inclusion / containment relationships, etc.; the edge detection module is used to extract the positions where the brightness changes sharply in an image, and usually uses edge detection algorithms (such as Canny, Sobel, Laplace, etc.) to extract.

[0065] In this embodiment, the feature extraction layer in the image feature recognition model is used to extract the initial image data features in an image. This feature extraction model can adopt an existing model structure. During the training of this image feature recognition model, it is necessary to input the sample image into this image feature recognition model, and then obtain the initial image data features corresponding to the sample image. After that, the initial image data features are respectively input into the color feature extraction module, texture feature extraction module, graphic structure extraction module, and edge detection module to obtain the predicted color features, texture features, graphic structure features, and edge features. Then, according to the actual color features, texture features, graphic structure features, and edge features of the sample image, the loss value of the image feature recognition model is calculated. When the loss value is less than a certain value, the training of this image feature recognition model is completed.

[0066] Among them, the actual color features of the sample image can be determined according to methods such as color histograms, color sets, color moments, etc.; the actual texture features and graphic structure features of the sample image can be determined through a convolutional network model; the actual edge features of the sample image can be determined through an edge detection algorithm. This embodiment does not make specific limitations on this.

[0067] S1022, by calculating the similarity between the image recognition features and the drug image features in the drug database, determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained.

[0068] Among them, the drug database stores drug image features and drug identifiers corresponding to various drugs respectively. In this embodiment, by calculating the similarity between the image recognition features and the drug image features in the drug database, the drug identifier uniquely corresponding to the drug to be classified can be determined. That is, when the image recognition features match the drug image features in the drug database successfully, the drug identifier corresponding to the successfully matched drug image features is determined as the drug identifier uniquely corresponding to the drug to be classified. In this embodiment, the successful matching of drug image features can be that the similarity exceeds a preset value, or the similarity is the highest, etc.

[0069] Specifically, the method for determining whether the drug identifier uniquely corresponding to the drug to be classified can be obtained by calculating the similarity between the image recognition features and the drug image features in the drug database includes: calculating the color similarity, texture similarity, graphic structure similarity, and edge similarity respectively by calculating the similarity between the color features, texture features, graphic structure features, and edge features in the image recognition features and the color features, texture features, graphic structure features, and edge features in each drug image feature in the drug database; performing weighted calculation on the color similarity, the texture similarity, the graphic structure similarity, and the edge similarity to obtain the similarity of each drug image feature in the drug database; and determining the drug identifier corresponding to the drug image feature in the drug database whose similarity exceeds the preset value and is the highest as the drug identifier uniquely corresponding to the drug to be classified. Among them, various distance measurement methods can be used in this embodiment to calculate the similarity of drug image features, such as Euclidean distance, cosine similarity, Hamming distance, etc.

[0070] S103. If the drug identifier uniquely corresponding to the drug to be classified can be obtained, then obtain the drug detailed data corresponding to the drug identifier according to the drug database.

[0071] Among them, in addition to storing the drug image features and drug identifiers corresponding to various drugs respectively, the drug database also stores the corresponding drug detailed data, and the classification of the drug to be classified can be realized through the drug detailed data.

[0072] S104. If the drug identifier uniquely corresponding to the drug to be classified cannot be obtained, then obtain the instruction manual image of the drug to be classified.

[0073] Among them, the instruction manual image of the drug to be classified can be the instruction image inside the drug package, or the outer package image of other sides of the drug to be classified. This embodiment does not make specific limitations on this.

[0074] S105. Determine the corresponding drug detailed data according to the instruction manual image.

[0075] Such as Figure 2The following is a flowchart for determining detailed drug data provided by this embodiment. In this embodiment, corresponding detailed drug data is determined based on the instruction manual image, including:

[0076] S1051, performing image recognition on the instruction manual image through image recognition technology to obtain initial drug description data.

[0077] Specifically, in this embodiment, the input instruction manual image can be preprocessed first to improve the quality of the instruction manual image and reduce the difficulty of subsequent processing. The preprocessing includes operations such as denoising, binarization, and grayscale conversion. Then, image processing techniques (such as edge detection and contour analysis) are used to locate the text area in the image. After that, the text in the text area is segmented into individual characters or words, and features of each character are extracted, such as shape, angle, texture, etc. The extracted character features are compared with a pre-trained model to identify the corresponding characters, thereby obtaining the initial drug description data corresponding to the instruction manual image.

[0078] S1052, inputting the instruction manual image and the initial drug data into a character recognition model to determine intermediate drug description data corresponding to the initial drug data.

[0079] Specifically, the step of inputting the instruction manual image and the initial drug data into a character recognition model to determine intermediate drug description data corresponding to the initial drug data includes: inputting the instruction manual image and the initial drug data into the character recognition model, and obtaining an instruction manual image vector and an initial drug data vector through the convolutional layer in the character recognition model; inputting the instruction manual image vector into a first prediction module to obtain a first predicted text result; inputting the initial drug data vector into a second prediction module to obtain a second predicted text result; and determining the intermediate drug description data corresponding to the initial drug data by comparing the first predicted text result and the second predicted text result.

[0080] In this embodiment, the first predicted text result and the second predicted text result are compared to determine whether the two results are consistent. If they are consistent, the result is directly used as the intermediate drug description data corresponding to the initial drug data; if they are inconsistent, the specific content at the position where the content in the predicted text results is different is determined through context analysis, and then the re-determined predicted text result is determined as the intermediate drug description data corresponding to the initial drug description data.

[0081] Preferably, in this embodiment, the intermediate drug description data corresponding to the initial drug data can also be determined according to the weight values of the first prediction module and the second prediction module. Among them, the weight values can be determined according to the accuracy rates of the first prediction module and the second prediction module, and the higher the accuracy rate, the greater the corresponding weight value.

[0082] In this embodiment, the training process of the text recognition model may be as follows:

[0083] 1. Obtain sample data (the sample data includes sample images and sample drug data) and the corresponding actual drug description data; the sample drug data is obtained in the same way as in step S1051;

[0084] 2. Input the sample images and sample drug data into the text recognition model, obtain a first prediction result according to the sample images, and obtain a second prediction result according to the sample drug data;

[0085] 3. Calculate a loss value according to the first prediction result, the second prediction result, and the actual drug description data; the calculation formula of the loss value is as follows:

[0086]

[0087] where n is the number of sample data, x i is the first prediction result in the i-th sample data, y i is the second prediction result in the i-th sample data, z i is the actual drug description data corresponding to the i-th sample data, (x i , z i ) is the similarity between the first prediction result and the actual drug description data, (y i , z i ) is the similarity between the second prediction result and the actual drug description data.

[0088] 4. When the loss value is less than a predetermined value, complete the training of the text recognition model.

[0089] S1053. Determine the drug detailed data corresponding to the instruction manual image according to the initial drug description data and the intermediate drug description data.

[0090] Specifically, the determining the drug detailed data corresponding to the instruction manual image according to the initial drug description data and the intermediate drug description data includes: determining the data difference position between the initial drug description data and the intermediate drug description data; performing text analysis on the context of the data difference position to determine the final data text content of the data difference position to obtain the final intermediate drug description data; and determining the final intermediate drug description data as the drug detailed data corresponding to the instruction manual image.

[0091] S106. Process the drug detailed data based on the user-defined classification criteria to obtain the classification result corresponding to the drug to be classified.

[0092] In this embodiment, drugs can be classified based on the principles of drug safety and effectiveness, as well as their different characteristics such as variety, specification, indication, dosage, and administration route. For example, according to the principles of drug safety and effectiveness, drugs can be classified into prescription drugs and over-the-counter drugs, classified according to the indications and functions, or classified according to the site of action, therapeutic use, and chemical structure.

[0093] In addition, this application can also classify scarce drugs according to five characteristics of scarce drugs, namely, originally available in the market, clinically necessary, irreplaceable, high price and small quantity, and raw material dependence, as follows:

[0094] The first category, emergency level 0: Drugs that are originally available in the market but not clinically necessary.

[0095] The second category, emergency level 2: Drugs that are originally available in the market, clinically necessary, and can be replaced.

[0096] The third category, emergency level 2: Drugs that are originally available in the market, clinically necessary, irreplaceable, and have a large quantity.

[0097] The fourth category, emergency level 3: Drugs that are originally available in the market, clinically necessary, irreplaceable, high price and small quantity.

[0098] The fifth category, emergency level 4: Drugs that are originally available in the market, clinically necessary, irreplaceable, high price and small quantity, and raw material dependent.

[0099] It should be noted that the classification of scarce drugs in this embodiment requires not only detailed drug data, but also corresponding market data, clinical data, sales data, etc. to determine the classification of scarce drugs for drugs.

[0100] In an alternative embodiment provided by this application, the processing of the drug detailed data based on the user-defined classification basis to obtain the classification result corresponding to the drug to be classified includes:

[0101] S1061, obtaining the user-defined classification basis, and determining the corresponding data fields according to the classification basis.

[0102] S1062, extracting text from the drug detailed data according to the data fields to obtain the corresponding data content.

[0103] Specifically, the extracting text from the drug detailed data according to the data fields to obtain the corresponding data content includes: determining the field set corresponding to the data fields, where the fields in the field set are synonyms and / or near-synonyms of the data fields; matching the field set with the drug detailed data to determine the position of the corresponding data fields in the drug detailed data; and extracting the data content related to the position of the data fields from the drug detailed data.

[0104] S1063. Determine the classification result corresponding to the drug to be classified according to the said data content.

[0105] This embodiment provides an intelligent drug classification method. First, obtain the outer package image of the drug to be classified through a graphic acquisition device; then determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer package image; if a drug identifier uniquely corresponding to the drug to be classified can be obtained, obtain the detailed drug data corresponding to the drug identifier according to the drug database; if a drug identifier uniquely corresponding to the drug to be classified cannot be obtained, obtain the instruction manual image of the drug to be classified; determine the corresponding detailed drug data according to the instruction manual image; process the detailed drug data based on the user-defined classification basis to obtain the classification result corresponding to the drug to be classified. Compared with the current manual verification and classification of drugs, this application automatically determines the classification result of the drug to be classified based on the outer package image of the drug to be classified, so that the efficiency and accuracy of drug classification can be improved through this application.

[0106] It should be understood that the magnitudes of the sequence numbers of the steps in the above embodiments do not mean the order of execution is prior or subsequent. The order of execution of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.

[0107] In one embodiment, an intelligent drug classification device is provided. As Figure 3 shown, the detailed description of each functional module of this intelligent drug classification device is as follows:

[0108] An acquisition module 31, configured to obtain the outer package image of the drug to be classified through a graphic acquisition device;

[0109] A determination module 32, configured to determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer package image;

[0110] The acquisition module 31 is further configured to, if a drug identifier uniquely corresponding to the drug to be classified can be obtained, obtain the detailed drug data corresponding to the drug identifier according to the drug database;

[0111] The acquisition module 31 is further configured to, if a drug identifier uniquely corresponding to the drug to be classified cannot be obtained, obtain the instruction manual image of the drug to be classified;

[0112] The determination module 32 is further configured to determine the corresponding detailed drug data according to the instruction manual image;

[0113] A classification module 33, configured to process the detailed drug data based on a user-defined classification criterion to obtain a classification result corresponding to the drug to be classified.

[0114] In an optional embodiment, the determination module 32 is specifically configured to:

[0115] Input the outer packaging image into an image feature recognition model to obtain image recognition features corresponding to the outer packaging image; the image recognition features at least include color features, texture features, graphic structure features, and edge features;

[0116] By calculating the similarity between the image recognition features and the drug image features in the drug database, determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained.

[0117] In an optional embodiment, the determination module 32 is specifically configured to:

[0118] Perform similarity calculations on the color features, texture features, graphic structure features, and edge features in the image recognition features and the color features, texture features, graphic structure features, and edge features in each drug image feature in the drug database respectively to obtain color similarity, texture similarity, graphic structure similarity, and edge similarity;

[0119] Perform weighted calculation on the color similarity, the texture similarity, the graphic structure similarity, and the edge similarity to obtain the similarity of each drug image feature in the drug database;

[0120] Determine the drug identifier corresponding to the drug image feature in the drug database with a similarity exceeding a preset value and the highest similarity as the drug identifier uniquely corresponding to the drug to be classified.

[0121] In an optional embodiment, the determination module 32 is specifically configured to:

[0122] Input the outer packaging image into an image feature recognition model, and obtain initial image data features through the feature extraction layer in the image feature recognition model;

[0123] Input the initial image data features into a color feature extraction module, a texture feature extraction module, a graphic structure extraction module, and an edge detection module respectively to obtain the color features, texture features, graphic structure features, and edge features corresponding to the outer packaging image.

[0124] In an optional embodiment, the determination module 32 is specifically configured to:

[0125] Perform image recognition on the instruction manual image through image recognition technology to obtain initial drug instruction data;

[0126] Input the instruction manual image and the initial drug data into a text recognition model to determine the intermediate drug description data corresponding to the initial drug data;

[0127] Determine the detailed drug data corresponding to the instruction manual image according to the initial drug description data and the intermediate drug description data.

[0128] In an optional embodiment, the determining module 32 is specifically configured to:

[0129] Determine the data difference position between the initial drug description data and the intermediate drug description data;

[0130] Perform text analysis on the context of the data difference position to determine the final data text content of the data difference position to obtain the final intermediate drug description data;

[0131] Determine the final intermediate drug description data as the detailed drug data corresponding to the instruction manual image.

[0132] In an optional embodiment, the determining module 32 is specifically configured to:

[0133] Input the instruction manual image and the initial drug data into a text recognition model, and obtain an instruction manual image vector and an initial drug data vector through the convolutional layer in the text recognition model;

[0134] Input the instruction manual image vector into the first prediction module to obtain a first predicted text result; input the initial drug data vector into the second prediction module to obtain a second predicted text result;

[0135] Determine the intermediate drug description data corresponding to the initial drug data by comparing the first predicted text result and the second predicted text result.

[0136] In an optional embodiment, the classification module 33 is specifically configured to:

[0137] Obtain a user-defined classification basis, and determine corresponding data fields according to the classification basis;

[0138] Extract text from the detailed drug data according to the data fields to obtain corresponding data content;

[0139] Determine the classification result corresponding to the drug to be classified according to the data content.

[0140] In an optional embodiment, the classification module 33 is specifically configured to:

[0141] Determine the set of fields corresponding to the data field, where the fields in the set of fields are synonyms and / or near-synonyms of the data field;

[0142] Match the set of fields with the detailed drug data to determine the positions of the corresponding data fields in the detailed drug data;

[0143] Extract the data content related to the positions of the data fields from the detailed drug data.

[0144] It should be noted that the above detailed description is exemplary and is intended to provide further illustration of the present application. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which the present application belongs.

[0145] For the specific limitations on the intelligent drug classification device, reference can be made to the limitations on the intelligent drug classification method in the above text, which will not be elaborated here. Each module in the above device can be implemented in whole or in part by software, hardware, and their combination. The above modules can be embedded in the processor of the computer device in hardware form or be independent of it, or can be stored in the memory of the computer device in software form so that the processor can call and execute the operations corresponding to the above modules.

[0146] Those skilled in the art can clearly understand that, for the sake of convenience and brevity of description, only the above division of each functional unit and module is used as an example. In actual applications, the above functions can be assigned to different functional units and modules according to needs, that is, the internal structure of the system can be divided into different functional units or modules to complete all or part of the functions described above.

[0147] The above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and all should be included in the protection scope of the present invention.

Claims

1. An intelligent drug classification system, characterized in that, The system includes: an image acquisition device, a drug database, and a drug classification device. The drug classification device includes: a memory and at least one processor. The memory stores a computer program, and the at least one processor is configured to implement the following steps when executing the computer program: Obtain the outer packaging image of the drug to be classified through the image acquisition device; Determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer packaging image; If a drug identifier uniquely corresponding to the drug to be classified can be obtained, obtain the drug detailed data corresponding to the drug identifier according to the drug database; If a drug identifier uniquely corresponding to the drug to be classified cannot be obtained, obtain the instruction manual image of the drug to be classified; Determine the corresponding drug detailed data according to the instruction manual image; Process the drug detailed data based on the classification criteria defined by the user to obtain the classification result corresponding to the drug to be classified.

2. The system according to claim 1, wherein The determining whether a drug identifier uniquely corresponding to the drug to be classified can be obtained according to the outer packaging image includes: Input the outer packaging image into an image feature recognition model to obtain the image recognition features corresponding to the outer packaging image; the image recognition features at least include color features, texture features, graphic structure features, and edge features; Determine whether a drug identifier uniquely corresponding to the drug to be classified can be obtained by calculating the similarity between the image recognition features and the drug image features in the drug database.

3. The system according to claim 2, characterized in that, The determining whether a drug identifier uniquely corresponding to the drug to be classified can be obtained by calculating the similarity between the image recognition features and the drug image features in the drug database includes: Calculate the similarity of color, texture, graphic structure, and edge respectively between the color features, texture features, graphic structure features, and edge features in the image recognition features and the color features, texture features, graphic structure features, and edge features in each drug image feature in the drug database to obtain color similarity, texture similarity, graphic structure similarity, and edge similarity; Perform weighted calculation on the color similarity, the texture similarity, the graphic structure similarity, and the edge similarity to obtain the similarity of each drug image feature in the drug database; Determine the drug identifier corresponding to the drug image feature in the drug database with a similarity exceeding the preset value and the highest similarity as the drug identifier uniquely corresponding to the drug to be classified.

4. The system according to claim 2, wherein The inputting the outer packaging image into an image feature recognition model to obtain the image recognition features corresponding to the outer packaging image includes: Input the outer packaging image into an image feature recognition model, and obtain initial image data features through the feature extraction layer in the image feature recognition model; Input the initial image data features into a color feature extraction module, a texture feature extraction module, a graphic structure extraction module, and an edge detection module respectively to obtain the color features, texture features, graphic structure features, and edge features corresponding to the outer packaging image.

5. The system according to claim 1, characterized in that, The determining the corresponding drug detailed data according to the instruction manual image includes: Performing image recognition on the said instruction manual image through image recognition technology to obtain initial drug data; Inputting the said instruction manual image and the said initial drug data into a character recognition model to determine intermediate drug description data corresponding to the said initial drug data; Determining drug detailed data corresponding to the said instruction manual image according to the said initial drug data and the said intermediate drug description data.

6. The system according to claim 5, wherein The determining of the drug detailed data corresponding to the said instruction manual image according to the said initial drug data and the said intermediate drug description data includes: Determining the data difference position between the said initial drug data and the said intermediate drug description data; Performing text analysis on the context of the said data difference position to determine the final data text content of the said data difference position to obtain the final intermediate drug description data; Determining the said final intermediate drug description data as the drug detailed data corresponding to the said instruction manual image.

7. The system according to claim 5, wherein The inputting of the said instruction manual image and the said initial drug data into a character recognition model to determine intermediate drug description data corresponding to the said initial drug data includes: Inputting the said instruction manual image and the said initial drug data into a character recognition model, and obtaining an instruction manual image vector and an initial drug data vector through the convolutional layer in the said character recognition model; Inputting the said instruction manual image vector into a first prediction module to obtain a first predicted text result; inputting the said initial drug data vector into a second prediction module to obtain a second predicted text result; Determining intermediate drug description data corresponding to the said initial drug data by comparing the said first predicted text result and the said second predicted text result.

8. The system according to any one of claims 1-7, characterized in that, The processing of the said drug detailed data based on a user-defined classification basis to obtain a classification result corresponding to the said drug to be classified includes: Obtaining a user-defined classification basis, and determining corresponding data fields according to the said classification basis; Performing text extraction from the said drug detailed data according to the said data fields to obtain corresponding data content; Determining a classification result corresponding to the said drug to be classified according to the said data content.

9. The system according to claim 8, wherein The performing of text extraction from the said drug detailed data according to the said data fields to obtain corresponding data content includes: Determining a field set corresponding to the said data fields, where the fields in the said field set are synonyms and / or near-synonyms of the said data fields; Matching the said field set with the said drug detailed data to determine the data field positions corresponding in the said drug detailed data; Extracting data content related to the said data field positions from the said drug detailed data.

10. An intelligent drug classification method, characterized in that, The said method includes: Obtaining an outer packaging image of a drug to be classified through an image acquisition device; Determining whether a drug identifier uniquely corresponding to the said drug to be classified can be obtained according to the said outer packaging image; If a drug identifier uniquely corresponding to the said drug to be classified can be obtained, then obtaining drug detailed data corresponding to the said drug identifier according to a drug database; If a drug identifier uniquely corresponding to the said drug to be classified cannot be obtained, then obtaining an instruction manual image of the drug to be classified; Determining corresponding drug detailed data according to the said instruction manual image; Processing the detailed drug data based on user-defined classification criteria to obtain the classification result corresponding to the drug to be classified.

Citation Information

Patent Citations

  • Drug identification method and device based on distributed system

    CN113488194A

  • Medicine classification method and device based on weight distribution, equipment and storage medium

    CN113821641A