图像识别方法、装置、电子设备及存储介质

By encoding and comparing character histograms of physical examination report images using adaptive scaling and information digest algorithms, the problems of high cost and low recall rate of manual review are solved, and efficient identification of fake physical examination reports is achieved.

CN115909382BActive Publication Date: 2026-05-19WUBA
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
WUBA
Filing Date
2022-11-28
Publication Date
2026-05-19

AI Technical Summary

Technical Problem

In the current technology, the verification of the authenticity of medical examination reports mainly relies on manual methods, which results in high costs, low recall rates, and the inability to identify false reports in a timely manner.

Method used

By adaptively scaling the physical examination report image, the target image encoding value is obtained, and the authenticity of the image is identified by comparing it with a preset information digest algorithm and character histogram.

Benefits of technology

It enables efficient identification of fake medical examination reports with less resource consumption, improving recall rate and identification accuracy, and reducing labor costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115909382B_ABST
    Figure CN115909382B_ABST
Patent Text Reader

Abstract

本申请提供一种图像识别方法、装置、电子设备及存储介质,该方法包括:对待识别的原体检报告图像进行自适应缩放,获取可表征原体检报告图像的图像信息的目标图像;在数据库中存储有与目标图像对应的目标编码值相同的第一编码值时,基于预设信息摘要算法检测原体检报告图像和第一编码值对应的第一体检报告图像是否相同;在基于预设信息摘要算法确定两个图像不同时,获取两个图像分别对应的字符直方图并进行比较;在基于比较结果确定字符差异满足预设条件的情况下,确定原体检报告图像为真实体检报告图像。本申请可以实现对虚假体检报告图像的有效召回,有效节省了人力审核成本、提高了虚假体检报告的治理效率。
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to an image recognition method, apparatus, electronic device and storage medium. Background Technology

[0002] With increasing health awareness, physical examinations have become a routine annual event for many. However, because physical examination reports are often template-based, fake reports resembling genuine ones can be quickly created by altering information on a single report. Therefore, it is necessary to review user-uploaded physical examination reports.

[0003] Currently, the authenticity of medical examination reports is mainly verified manually. However, manual verification has the following drawbacks:

[0004] 1. Because the identification of medical examination reports based on template modifications is low, relying solely on manual review is costly, and the recall rate of fake medical examination reports is low.

[0005] 2. Due to the low efficiency and difficulty of manual review, it is impossible to review the medical examination reports uploaded by users in a timely and accurate manner, resulting in a large number of fake medical examination reports. Summary of the Invention

[0006] This application provides an image recognition method, apparatus, electronic device, and storage medium to address the problems of high review costs, low recall rate of false medical examination reports, and inability to identify false medical examination reports in a timely manner when using manual review methods in the prior art.

[0007] In a first aspect, embodiments of this application provide an image recognition method, including:

[0008] Adaptively scale the original physical examination report image to be identified to obtain a target image that can characterize the image information of the original physical examination report image;

[0009] If a first encoding value that is identical to the target encoding value corresponding to the target image is stored in the database, a preset information digest algorithm is used to detect whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are identical.

[0010] If the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, the character histograms corresponding to the original physical examination report image and the first physical examination report image are obtained respectively, and the character histograms corresponding to the original physical examination report image and the first physical examination report image are compared.

[0011] If the character differences are determined to meet preset conditions based on the comparison results, the original physical examination report image is determined to be the real physical examination report image.

[0012] Secondly, embodiments of this application provide an image recognition device, comprising:

[0013] The first acquisition module is used to adaptively scale the original physical examination report image to be identified and acquire a target image that can characterize the image information of the original physical examination report image.

[0014] The first detection module is used to detect, based on a preset information digest algorithm, whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are the same when a first encoding value with the same target encoding value as the target image is stored in the database.

[0015] The comparison module is used to obtain character histograms corresponding to the original physical examination report image and the first physical examination report image respectively when the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, and to compare the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively.

[0016] The determination module is used to determine that the original physical examination report image is a real physical examination report image when the character differences are determined to meet preset conditions based on the comparison results.

[0017] Thirdly, embodiments of this application provide an electronic device, including a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the image recognition method as described in the first aspect above.

[0018] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the image recognition method described in the first aspect above.

[0019] The technical solution of this application adopts an adaptive scaling method to obtain a target image that can characterize the image information of the original medical examination report image. The target encoding value corresponding to the target image is compared with the encoding value in the database, which can perform preliminary identification of fake medical examination reports in the image encoding dimension. When the database stores a first encoding value that is the same as the target encoding value corresponding to the target image, a preset information digest algorithm is used to detect whether the original medical examination report image and the first medical examination report image corresponding to the first encoding value are the same. In different cases, the character histograms corresponding to the original medical examination report image and the first medical examination report image are compared. The authenticity of the original medical examination report image is determined according to the comparison result, thereby realizing the identification of fake medical examination reports in the character dimension. This application adopts image encoding and character comparison methods, which can effectively recall fake medical examination report images with less deployment resources. It has the characteristics of stable features, high recognition accuracy, and high robustness, effectively saving manpower review costs and improving the governance efficiency of fake medical examination reports. Attached Figure Description

[0020] Figure 1 A schematic diagram illustrating the image recognition method provided in an embodiment of this application;

[0021] Figure 2 This diagram illustrates a specific implementation flow of the image recognition method provided in this application.

[0022] Figure 3 This is a schematic diagram illustrating the image recognition device provided in an embodiment of this application;

[0023] Figure 4 This is a schematic diagram of the electronic device structure provided in the embodiments of this application. Detailed Implementation

[0024] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0025] It should be understood that the phrase "one embodiment" or "an embodiment" throughout the specification means that a specific feature, structure, or characteristic related to the embodiment is included in at least one embodiment of this application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. Furthermore, these specific features, structures, or characteristics can be combined in any suitable manner in one or more embodiments.

[0026] In the various embodiments of this application, it should be understood that the sequence number of each process described below does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0027] This application provides an image recognition method, see [link to relevant documentation]. Figure 1 As shown, the method includes:

[0028] Step 101: Adaptively scale the original physical examination report image to be identified to obtain a target image that can characterize the image information of the original physical examination report image.

[0029] In this embodiment, the format of the obtained medical examination report file is first determined. If the medical examination report file is in PDF format, it needs to be converted into an image format to obtain the original medical examination report image to be identified. If the medical examination report file is in image format, it can be directly identified as the original medical examination report image to be identified.

[0030] After acquiring the original medical examination report image to be identified, the original medical examination report image is adaptively scaled based on a scaling factor to obtain a target image that can represent the image information of the original medical examination report image. In this embodiment, adaptive scaling is actually an adaptive reduction of the original image. The purpose of adaptive scaling is to reduce the image size while preserving the image content. Compared to a fixed-size scaling method, adaptive scaling allows the scaled image to better reflect the information of the original image.

[0031] The scaling factor is set according to the specific scaling dimension used. In this embodiment, the scaling factor is actually a reduction factor, and the scaling factors corresponding to height and width can be the same or different. For example, if the scaling factor Factor is set to 20, SrcHight and SrcWidth represent the height and width of the original physical examination report image, respectively, and DstHight and DstWidth represent the height and width after scaling, then:

[0032]

[0033]

[0034] Alternatively, different scaling factors can be used for height and width. For example, the scaling factor for height is 10 and the scaling factor for width is 12. By adaptively scaling the original physical examination report image, a target image that can represent the information of the original image can be obtained.

[0035] Step 102: If a first encoding value with the same target encoding value as the target image is stored in the database, detect whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are the same based on a preset information digest algorithm.

[0036] After adaptively scaling the original medical examination report image to obtain the target image, the target image is encoded to obtain the corresponding target encoded value. During encoding, hash algorithms with similar functions such as dhash, ahash, and phash can be used, but it is not limited to hash algorithms.

[0037] If the target encoding value corresponding to the target image is obtained, it is necessary to check whether there is a first encoding value that is the same as the target encoding value among the multiple encoding values ​​stored in the database. If the first encoding value exists in the database, it is necessary to continue to detect the original physical examination report image to determine the authenticity of the original physical examination report image.

[0038] When further examining the original medical examination report image, a preset information digest algorithm can be used to determine whether the original medical examination report image and the first medical examination report image corresponding to the first encoded value are the same. The preset information digest algorithm can be MD5 or other algorithms, but MD5 is typically used.

[0039] Step 103: If the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, obtain the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively, and compare the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively.

[0040] If the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, the detection is further performed on the original physical examination report image and the first physical examination report image from the image content dimension. Specifically, the character histograms corresponding to the original physical examination report image and the first physical examination report image are obtained respectively, the two obtained character histograms are compared, and the comparison result is obtained.

[0041] Step 104: If the character differences are determined to meet the preset conditions based on the comparison results, the original physical examination report image is determined to be the real physical examination report image.

[0042] When the character differences between the character histogram corresponding to the original physical examination report image and the character histogram corresponding to the first physical examination report image meet the preset conditions based on the comparison results, the original physical examination report image is determined to be the real physical examination report image.

[0043] The above-described implementation process of this application adaptively scales the original medical examination report image to obtain a target image that can characterize the image information of the original medical examination report image. The target encoding value corresponding to the target image is compared with the encoding value in the database, enabling preliminary identification of fake medical examination reports at the image encoding dimension. If the database stores a first encoding value that is identical to the target encoding value corresponding to the target image, a preset information digest algorithm is used to detect whether the original medical examination report image and the first medical examination report image corresponding to the first encoding value are the same. In different cases, the character histograms corresponding to the original medical examination report image and the first medical examination report image are compared. Based on the comparison results, the authenticity of the original medical examination report image is determined, achieving identification of fake medical examination reports at the character dimension. This application uses image encoding and character comparison methods, achieving effective recall of fake medical examination report images with relatively low deployment resource consumption. It features stable features, high recognition accuracy, and high robustness, effectively saving manpower review costs and improving the efficiency of fake medical examination report governance.

[0044] In an optional embodiment of this application, after acquiring the target image, the method further includes:

[0045] The target image is encoded to obtain the target encoding value corresponding to the target image;

[0046] Detect whether the database stores a first encoded value that is identical to the target encoded value;

[0047] If the first encoded value is not stored in the database, the target encoded value, the Uniform Resource Locator URL corresponding to the original physical examination report image, the hash value corresponding to the original physical examination report image, and the user identifier corresponding to the original physical examination report image are stored in the database, and a first prompt message indicating that the original physical examination report image is a real physical examination report image is output; the hash value corresponding to the original physical examination report image is determined based on the preset message digest algorithm.

[0048] After adaptively scaling the original physical examination report image to obtain the target image, the target image can be encoded. Specifically, hash algorithms such as dhash, ahash, and phash can be used to encode the scaled target image to obtain the target encoding value corresponding to the target image.

[0049] The database stores the encoding values ​​corresponding to scaled images of multiple physical examination report images. After obtaining the target encoding value corresponding to the target image, the target encoding value is compared with the encoding value in the database to detect whether the database stores a first encoding value that is the same as the target encoding value. If the database stores a first encoding value, the original physical examination report image and the first physical examination report image corresponding to the first encoding value are detected based on a preset information digest algorithm to perform detection based on the original image.

[0050] If the first encoding value does not exist in the database, confirming that the original medical examination report image is a genuine medical examination report image, the target encoding value, the Uniform Resource Locator (URL) corresponding to the original medical examination report image, the hash value corresponding to the original medical examination report image, and the user identifier corresponding to the original medical examination report image can be stored in the database. A first prompt message indicating that the original medical examination report image is genuine can then be output, allowing the user to understand that the original medical examination report image is authentic based on this prompt. Storing the image's URL facilitates tracing the original image during manual review.

[0051] The hash value corresponding to the original physical examination report image is determined by processing the original physical examination report image using a preset information digest algorithm. The user identifier corresponding to the original physical examination report image can be the user's name, user number, etc. The target encoding value corresponding to the target image can be understood as the encoding value corresponding to the original physical examination report image.

[0052] In the above implementation process of this application, if the first encoding value is stored in the database, the original image can continue to be used to identify fake medical examination report images; if the first encoding value is not stored in the database, the original medical examination report image is determined to be a real medical examination report image, the data associated with the original medical examination report image is stored in the database, the database is updated, and the first prompt information is output so that the user can understand that the original medical examination report image is a real medical examination report image.

[0053] In an optional embodiment of this application, the step of detecting whether the original physical examination report image and the first physical examination report image corresponding to the first encoded value are the same based on a preset information digest algorithm includes:

[0054] The hash value corresponding to the original physical examination report image is obtained based on the preset information digest algorithm;

[0055] Obtain the hash value corresponding to the first encoded value from the database. The database stores the encoded values, hash values, image URLs, and user identifiers corresponding to multiple physical examination report images.

[0056] Based on the hash value corresponding to the original medical examination report image and the hash value corresponding to the first encoded value, it is determined whether the original medical examination report image and the first medical examination report image are the same.

[0057] When detecting whether the original medical examination report image and the first medical examination report image are the same based on a preset information digest algorithm, the hash value corresponding to the original medical examination report image can be obtained based on the preset information digest algorithm. The database stores the encoded values ​​corresponding to the scaled images of multiple medical examination report images, as well as the hash values, image URLs, and user identifiers corresponding to multiple medical examination report images. The encoded value corresponding to the medical examination report image is the encoded value corresponding to the scaled image of the medical examination report image.

[0058] After obtaining the hash value corresponding to the original physical examination report image, the hash value corresponding to the first encoded value is obtained from the database. The encoded value can be used as an index. Each encoded value corresponds to a hash value, an image URL, and a user identifier. That is, the hash value, the image URL, and the user identifier are stored as related content to the encoded value.

[0059] After obtaining the hash value corresponding to the first encoded value, the original medical examination report image and the first medical examination report image are compared based on their respective hash values. If the hash value of the original medical examination report image and the hash value of the first encoded value (first medical examination report image) are the same, then the original medical examination report image and the first medical examination report image are determined to be the same based on a preset information digest algorithm; if the hash value of the original medical examination report image and the hash value of the first encoded value (first medical examination report image) are different, then the original medical examination report image and the first medical examination report image are determined to be different based on a preset information digest algorithm.

[0060] In the above implementation process of this application, when identifying fake medical examination reports based on a preset information digest algorithm, the hash values ​​corresponding to the original medical examination report image and the first medical examination report image are compared, so as to determine whether the original medical examination report image and the first medical examination report image are the same based on the comparison results of the hash values.

[0061] In an optional embodiment of this application, if the original medical examination report image and the first medical examination report image are determined to be the same based on the preset information digest algorithm, the method further includes:

[0062] Detect whether the first encoded value belongs to the encoded value in the blacklist list;

[0063] When the first encoded value belongs to an encoded value in the blacklist, the original medical examination report image is determined to be a fake medical examination report image, and a second prompt message is output;

[0064] When the first encoded value does not belong to the encoded value in the blacklist, it is detected whether the user identifier corresponding to the original physical examination report image is the same as the user identifier corresponding to the first physical examination report image;

[0065] If two user identifiers are identical, the original physical examination report image is determined to be a duplicate uploaded image, and a third prompt message is output.

[0066] If the two user identifiers are different, the original physical examination report image is determined to be a stolen image, and a fourth prompt message is output.

[0067] When the original medical examination report image and the first medical examination report image are determined to be the same through a preset information digest algorithm, it can be checked whether the first encoding value corresponding to the first medical examination report image belongs to the encoding value in the blacklist. If it belongs to the encoding value in the blacklist, the original medical examination report image can be directly identified as a fake medical examination report image, and a second prompt message indicating that the original medical examination report image is a fake medical examination report image can be output. If the first encoding value does not belong to the encoding value in the blacklist, it can be further checked whether the user identifier corresponding to the original medical examination report image is the same as the user identifier corresponding to the first medical examination report image. If the user identifiers corresponding to the two medical examination report images are the same, it can be determined that the original medical examination report image is a duplicate uploaded image, and a third prompt message indicating that the original medical examination report image is a duplicate uploaded image by the relevant user can be output. If the user identifiers corresponding to the two medical examination report images are different, it can be determined that the original medical examination report image is a stolen image, and a fourth prompt message indicating that the original medical examination report image is a stolen image from another user can be output.

[0068] The above-described implementation process of this application can identify fake medical examination report images based on a blacklist when two images are determined to be identical based on a preset information digest algorithm. When a fake medical examination report image cannot be identified, the user identifiers of the two images are used to determine whether the original medical examination report image is a duplicate posting behavior by the same user or a theft behavior by different users, thereby realizing the identification of fake medical examination report images in two dimensions: blacklist and user identifier.

[0069] In an optional embodiment of this application, obtaining the character histograms corresponding to the original medical examination report image and the first medical examination report image respectively includes:

[0070] Extract the text information corresponding to the original physical examination report image and the first physical examination report image respectively;

[0071] Based on the text information corresponding to the original medical examination report image and the first medical examination report image, calculate the character histograms corresponding to the original medical examination report image and the first medical examination report image, respectively.

[0072] If the original medical examination report image and the first medical examination report image are determined to be different based on the preset information digest algorithm, the original medical examination report image and the first medical examination report image are further detected from the character dimension. Specifically, the text information of the two images is further extracted using Optical Character Recognition (OCR) technology, and the character histogram is calculated based on the extracted image text information to obtain the character histograms corresponding to the original medical examination report image and the first medical examination report image, respectively.

[0073] After obtaining the character histograms corresponding to the original medical examination report image and the first medical examination report image, the differences between the two character histograms are compared to obtain the comparison results. If the character differences meet the preset conditions based on the comparison results, the original medical examination report image is determined to be the real medical examination report image. If the character differences do not meet the preset conditions based on the comparison results, further manual review is required.

[0074] Specifically, determining that the original physical examination report image is a real physical examination report image when the character difference meets the preset conditions based on the comparison results includes: when the character difference between the character histogram corresponding to the original physical examination report image and the character histogram corresponding to the first physical examination report image is greater than the preset threshold based on the comparison results, determining that the original physical examination report image is a real physical examination report image, and outputting a first prompt message.

[0075] When the difference between two character histograms is determined to be greater than a preset threshold, the original medical examination report image is identified as the authentic medical examination report image, and a first prompt message is output to inform the user that the original medical examination report image is the authentic one. The preset threshold can be pre-set or an empirical value.

[0076] When the character differences are determined not to meet the preset conditions based on the comparison results, the method further includes: determining that the original physical examination report image is a fake physical examination report image, and outputting a fifth prompt message prompting manual review; obtaining the manual review result, and feeding the manual review result back to the database.

[0077] When the character difference is determined to be no greater than a preset threshold based on the comparison results of the two character histograms, the original physical examination report image is determined to be a fake physical examination report image, and a fifth prompt message prompting manual review is output. After the relevant reviewers review the original physical examination report image, the manual review result is obtained, the manual review result is taken as the final result, and the manual review result is stored in the database.

[0078] Specifically, if the manual review result indicates that the original medical examination report image is a fake medical examination report image, the relevant information corresponding to the first medical examination report image can be directly marked in the database to indicate that a fake medical examination report image with the same encoding value, different hash value, and similar character histogram has been detected, thus realizing the feedback of the manual review result to the database; if the manual review result indicates that the original medical examination report image is a real medical examination report image, the relevant information corresponding to the original medical examination report image is stored in the database, thus realizing the feedback of the manual review result to the database.

[0079] The following example illustrates the process of character-based identification. For instance, the preset threshold can be 30%. If the character difference between the histograms of two characters is greater than 30%, the original medical examination report image is determined to be a genuine medical examination report image. Otherwise, the original medical examination report image is determined to be a fake medical examination report image, and the original medical examination report image is further reviewed manually.

[0080] By extracting text information from the original medical examination report image and the first medical examination report image, calculating a character histogram based on the text information, and determining whether the original medical examination report image is a fake medical examination report image based on the comparison results of the character histograms, image recognition is achieved in the dimension of image text information.

[0081] In this embodiment, text similarity verification is used to further identify fake medical examination reports at the character level, which greatly improves the drawback of invalidating identical medical examination reports.

[0082] The overall implementation process provided in this application is illustrated below with a specific example. (See attached image.) Figure 2 As shown, it includes the following steps:

[0083] Step 201: Determine the format of the original medical examination report. If the original medical examination report is in PDF format, proceed to step 202. If the original medical examination report is in image format, proceed to step 203.

[0084] Step 202: Convert the original physical examination report in PDF format into an image format, and then proceed to step 203.

[0085] Step 203: Obtain the scaled image corresponding to the original physical examination report in image format, and obtain the image encoding value corresponding to the scaled image.

[0086] Step 204: Check if there is a duplicate image encoding value in the database. If not, proceed to step 205; otherwise, proceed to step 206.

[0087] Step 205: Store the information associated with the original physical examination report in the database.

[0088] Step 206: Compare the MD5 values ​​of the original physical examination report and the first physical examination report with the same image encoding value. If they are the same, proceed to steps 207 to 209; otherwise, proceed to steps 210 to 213.

[0089] Step 207: Check if the original physical examination report is a black sample. If it is, proceed to step 208; otherwise, proceed to step 209.

[0090] Step 208: Determine that the original medical examination report is a false medical examination report.

[0091] Step 209: Based on the user identifiers corresponding to the original physical examination report and the first physical examination report, determine whether the original physical examination report is a stolen report or a report repeatedly sent by the user.

[0092] Step 210: Compare the character histograms of the original physical examination report and the first physical examination report to obtain the character differences.

[0093] Step 211: Detect whether the character difference exceeds a preset threshold. If it does, proceed to step 212; otherwise, proceed to step 213.

[0094] Step 212: Confirm the original medical examination report as the authentic medical examination report.

[0095] Step 213: Output the fifth prompt message for manual review, obtain the manual review result, and send the manual review result back to the database.

[0096] The above implementation process, which identifies fake medical examination reports based on image encoding values, MD5 values, and character histograms, can effectively recall fake images with relatively low deployment resource consumption, effectively saving manpower review costs and improving the efficiency of combating fake medical examination reports.

[0097] The solution provided in this application is based on the characteristic that tampering with medical examination reports involves small-area modifications to the image (occurring in key information such as names and various physical indicators). By appropriately scaling the image, a target image that can represent the image information of the original medical examination report is obtained. Based on the encoded value of the target image, suspected fake medical examination reports are recalled. By introducing hash value comparison and text recognition to construct an overall inspection process, the efficiency of combating fake medical examination reports is improved.

[0098] Furthermore, by performing adaptive image scaling, compared to fixed-size scaling, the scaled image can better reflect the information of the original image, which can improve the effective recall of fake images.

[0099] This application also provides an image recognition device, see [link to relevant documentation]. Figure 3 As shown, the device includes:

[0100] The first acquisition module 301 is used to adaptively scale the original physical examination report image to be identified and acquire a target image that can characterize the image information of the original physical examination report image.

[0101] The first detection module 302 is used to detect, based on a preset information digest algorithm, whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are the same when a first encoding value with the same target encoding value as the target image is stored in the database.

[0102] The comparison module 303 is used to obtain character histograms corresponding to the original physical examination report image and the first physical examination report image respectively when the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, and to compare the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively.

[0103] The determination module 304 is used to determine that the original physical examination report image is a real physical examination report image when the character differences are determined to meet the preset conditions based on the comparison results.

[0104] Optionally, the device further includes:

[0105] The second acquisition module is used to encode the target image after the first acquisition module acquires the target image, and obtain the target encoding value corresponding to the target image;

[0106] The second detection module is used to detect whether the database stores a first encoding value that is the same as the target encoding value;

[0107] The storage output module is used to store the target encoding value, the Uniform Resource Locator URL corresponding to the original physical examination report image, the hash value corresponding to the original physical examination report image, and the user identifier corresponding to the original physical examination report image into the database when the first encoding value is not stored in the database, and output a first prompt message that the original physical examination report image is a real physical examination report image.

[0108] The hash value corresponding to the original physical examination report image is determined based on the preset information digest algorithm.

[0109] Optionally, the first detection module includes:

[0110] The first acquisition submodule is used to acquire the hash value corresponding to the original physical examination report image based on the preset information digest algorithm;

[0111] The second acquisition submodule is used to acquire the hash value corresponding to the first encoded value from the database. The database stores the encoded values, hash values, image URLs, and user identifiers corresponding to multiple physical examination report images.

[0112] The detection submodule is used to detect whether the original physical examination report image and the first physical examination report image are the same based on the hash value corresponding to the original physical examination report image and the hash value corresponding to the first encoded value.

[0113] Optionally, the device further includes:

[0114] The third detection module is used to detect whether the first encoded value belongs to the encoded value in the blacklist when the original physical examination report image and the first physical examination report image are determined to be the same based on the preset information digest algorithm.

[0115] The first output module is used to determine that the original medical examination report image is a fake medical examination report image when the first encoded value belongs to the encoded value in the blacklist list, and output a second prompt message.

[0116] The fourth detection module is used to detect whether the user identifier corresponding to the original physical examination report image and the user identifier corresponding to the first physical examination report image are the same when the first encoded value does not belong to the encoded value in the blacklist list.

[0117] The second output module is used to determine that the original physical examination report image is a duplicate uploaded image when two user identifiers are the same, and to output a third prompt message.

[0118] The third output module is used to determine that the original physical examination report image is a stolen image when the two user identifiers are different, and to output a fourth prompt message.

[0119] Optionally, the comparison module includes:

[0120] The extraction submodule is used to extract the text information corresponding to the original physical examination report image and the first physical examination report image, respectively.

[0121] The calculation submodule is used to calculate the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively, based on the text information corresponding to the original physical examination report image and the first physical examination report image respectively.

[0122] Optionally, the determining module is further configured to:

[0123] When the character difference between the character histogram corresponding to the original physical examination report image and the character histogram corresponding to the first physical examination report image is greater than a preset threshold based on the comparison result, the original physical examination report image is determined to be a real physical examination report image, and a first prompt message is output.

[0124] Optionally, when it is determined based on the comparison result that the character difference does not meet a preset condition, the device further includes:

[0125] The fourth output module is used to determine that the original medical examination report image is a fake medical examination report image, and output a fifth prompt message suggesting manual review;

[0126] The feedback module is used to obtain the results of manual review and feed them back to the database.

[0127] As the device embodiment is basically similar to the method embodiment, the description is relatively simple, and relevant parts can be found in the description of the method embodiment.

[0128] This application also provides an electronic device, including: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, it implements the various processes of the above-described image recognition method embodiments and achieves the same technical effect. To avoid repetition, it will not be described again here.

[0129] For example, Figure 4 A schematic diagram of the physical structure of an electronic device is shown. (For example...) Figure 4As shown, the electronic device may include: a processor 410, a communication interface 420, a memory 430, and a communication bus 440, wherein the processor 410, the communication interface 420, and the memory 430 communicate with each other through the communication bus 440. The processor 410 can call logical instructions in the memory 430. The processor 410 is used to perform the following steps: adaptively scaling the original physical examination report image to be identified to obtain a target image that can characterize the image information of the original physical examination report image; if a first encoding value with the same target encoding value as the target image is stored in the database, detecting whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are the same based on a preset information digest algorithm; if the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, obtaining the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively, and comparing the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively; if the character difference is determined to meet a preset condition based on the comparison result, determining that the original physical examination report image is a real physical examination report image. The processor 410 can also execute other schemes in the embodiments of this application, which will not be further described here.

[0130] Furthermore, the logical instructions in the aforementioned memory 430 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application.

[0131] This application also provides a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it implements the various processes of the above-described image recognition method embodiments and achieves the same technical effects. To avoid repetition, it will not be described again here. The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc.

[0132] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0133] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0134] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

[0135] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed in this application can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0136] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0137] In the embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0138] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0139] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0140] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.

[0141] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. An image recognition method, characterized in that, include: Adaptively scale the original physical examination report image to be identified to obtain a target image that can characterize the image information of the original physical examination report image; The adaptive scaling is based on a scaling factor to scale the original physical examination report image; If a first encoding value that is identical to the target encoding value corresponding to the target image is stored in the database, a preset information digest algorithm is used to detect whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are identical. If the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, the character histograms corresponding to the original physical examination report image and the first physical examination report image are obtained respectively, and the character histograms corresponding to the original physical examination report image and the first physical examination report image are compared. If the character differences meet the preset conditions based on the comparison results, the original physical examination report image is determined to be the real physical examination report image; The step of detecting whether the original medical examination report image and the first medical examination report image corresponding to the first encoded value are the same based on a preset information digest algorithm includes: The hash value corresponding to the original physical examination report image is obtained based on the preset information digest algorithm; Obtain the hash value corresponding to the first encoded value from the database. The database stores the encoded values, hash values, image URLs, and user identifiers corresponding to multiple physical examination report images. Based on the hash value corresponding to the original physical examination report image and the hash value corresponding to the first encoded value, it is determined whether the original physical examination report image and the first physical examination report image are the same; The step of obtaining the character histograms corresponding to the original medical examination report image and the first medical examination report image respectively includes: Extract the text information corresponding to the original physical examination report image and the first physical examination report image respectively; Based on the text information corresponding to the original medical examination report image and the first medical examination report image, calculate the character histograms corresponding to the original medical examination report image and the first medical examination report image, respectively.

2. The method according to claim 1, characterized in that, After acquiring the target image, the process also includes: The target image is encoded to obtain the target encoding value corresponding to the target image; Detect whether the database stores a first encoded value that is identical to the target encoded value; If the first encoded value is not stored in the database, the target encoded value, the Uniform Resource Locator URL corresponding to the original physical examination report image, the hash value corresponding to the original physical examination report image, and the user identifier corresponding to the original physical examination report image are stored in the database, and a first prompt message indicating that the original physical examination report image is a real physical examination report image is output. The hash value corresponding to the original physical examination report image is determined based on the preset information digest algorithm.

3. The method according to claim 1, characterized in that, If, based on the preset information digest algorithm, it is determined that the original physical examination report image and the first physical examination report image are the same, the method further includes: Detect whether the first encoded value belongs to the encoded value in the blacklist list; When the first encoded value belongs to an encoded value in the blacklist, the original medical examination report image is determined to be a fake medical examination report image, and a second prompt message is output; When the first encoded value does not belong to the encoded value in the blacklist, it is detected whether the user identifier corresponding to the original physical examination report image is the same as the user identifier corresponding to the first physical examination report image; If two user identifiers are identical, the original physical examination report image is determined to be a duplicate uploaded image, and a third prompt message is output. If the two user identifiers are different, the original physical examination report image is determined to be a stolen image, and a fourth prompt message is output.

4. The method according to claim 1, characterized in that, The step of determining the original medical examination report image as the real medical examination report image when the character differences meet preset conditions based on the comparison results includes: When the character difference between the character histogram corresponding to the original physical examination report image and the character histogram corresponding to the first physical examination report image is greater than a preset threshold based on the comparison result, the original physical examination report image is determined to be a real physical examination report image, and a first prompt message is output.

5. The method according to claim 1, characterized in that, When it is determined, based on the comparison result, that the character difference does not meet the preset conditions, the method further includes: The system determines that the original medical examination report image is a fake medical examination report image and outputs a fifth prompt message asking for manual review. Obtain the results of manual review and then feed them back to the database.

6. An image recognition device, characterized in that, include: The first acquisition module is used to adaptively scale the original physical examination report image to be identified and acquire a target image that can characterize the image information of the original physical examination report image. The adaptive scaling is based on a scaling factor to scale the original physical examination report image; The first detection module is used to detect, based on a preset information digest algorithm, whether the original physical examination report image and the first physical examination report image corresponding to the first encoding value are the same when a first encoding value with the same target encoding value as the target image is stored in the database. The comparison module is used to obtain character histograms corresponding to the original physical examination report image and the first physical examination report image respectively when the original physical examination report image and the first physical examination report image are determined to be different based on the preset information digest algorithm, and to compare the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively. The determination module is used to determine that the original physical examination report image is a real physical examination report image when the character differences are determined to meet preset conditions based on the comparison results. The first detection module includes: The first acquisition submodule is used to acquire the hash value corresponding to the original physical examination report image based on the preset information digest algorithm; The second acquisition submodule is used to acquire the hash value corresponding to the first encoded value from the database. The database stores the encoded values, hash values, image URLs, and user identifiers corresponding to multiple physical examination report images. The detection submodule is used to detect whether the original physical examination report image and the first physical examination report image are the same based on the hash value corresponding to the original physical examination report image and the hash value corresponding to the first encoded value; The comparison acquisition module includes: The extraction submodule is used to extract the text information corresponding to the original physical examination report image and the first physical examination report image, respectively. The calculation submodule is used to calculate the character histograms corresponding to the original physical examination report image and the first physical examination report image respectively, based on the text information corresponding to the original physical examination report image and the first physical examination report image respectively.

7. An electronic device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the image recognition method as described in any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that, A computer program is stored on the computer-readable storage medium, which, when executed by a processor, implements the steps of the image recognition method as described in any one of claims 1 to 5.