Image automatic recognition method and device, computer device and readable storage medium

By establishing an image processing algorithm model and utilizing machine learning and computer algorithms to automatically identify calligraphy and painting artworks, the problem of strong subjectivity, complexity, and difficulty in scaling up the screening process of calligraphy and painting artworks for industrial products has been solved, achieving efficient and accurate automated screening.

CN114596327BActive Publication Date: 2026-04-07FULIAN YITONG TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-30
Publication Date
2026-04-07

AI Technical Summary

Technical Problem

In existing technologies, the industrial screening process for calligraphy and painting artworks is highly subjective, complex, and difficult to scale up, resulting in high costs and low efficiency.

Method used

By establishing an image processing algorithm model and utilizing machine learning and computer algorithms, the authenticity of calligraphy and painting artworks can be automatically identified. This includes acquiring training data and building the model, combining microscopic image feature recognition and processing algorithms to determine whether an image is an industrial product.

Benefits of technology

It has achieved automated screening of calligraphy and painting artworks, reduced the subjectivity of manual identification, improved screening efficiency and accuracy, reduced costs, and is suitable for large-scale operation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114596327B_ABST
    Figure CN114596327B_ABST
Patent Text Reader

Abstract

This invention discloses an automatic image recognition method, apparatus, computer device, and readable storage medium. The method includes: acquiring an actual image of a target object to be tested; inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result, wherein the preset image processing algorithm model is constructed based on training data; and determining whether the target object to be tested is an industrial product based on the recognition result. By implementing this invention, the problems of strong subjectivity, high cost, and complex process that are difficult to scale up due to manual recognition are solved, thereby improving screening efficiency and accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of digital image processing technology, and specifically to an automatic image recognition method, apparatus, computer device, and readable storage medium. Background Technology

[0002] During the exhibition, transportation, and transaction of calligraphy and painting artworks, it is necessary to identify whether the works are original hand-painted pieces by the artist or machine-made imitations. This process is known as industrial product screening. Currently, industrial product screening relies entirely on expert experience, which presents numerous problems such as strong subjectivity, complex processes, high costs, and difficulty in scaling up operations. Summary of the Invention

[0003] Therefore, the technical problem to be solved by the present invention is to overcome the defects of strong subjectivity, complex process and difficulty in large-scale operation in the existing industrial product screening process, thereby providing an automatic image recognition method, device, computer equipment and readable storage medium.

[0004] According to a first aspect, embodiments of the present invention disclose an automatic image recognition method, the method comprising: acquiring an actual image of a target object to be tested; inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result, wherein the preset image processing algorithm model is constructed based on training data; and determining whether the target object to be tested is an industrial product based on the recognition result.

[0005] Optionally, the process of training and constructing the preset image processing algorithm model includes: acquiring screening rules and image processing algorithm parameters corresponding to the screening rules; establishing an image processing neural network model corresponding to the screening rules; acquiring training data and industrial product judgment results corresponding to the training data; inputting the training data into the image processing neural network model to obtain a predicted value; comparing the predicted value with the industrial product judgment result; when the predicted value is the same as the industrial product judgment result, determining the image processing algorithm parameters, and determining the corresponding image processing neural network model as the preset image processing algorithm model.

[0006] Optionally, the step of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result includes: acquiring the color dot matrix distribution of the microscopic image of the actual image and a preset first contour data range; when the color dot matrix of the microscopic image is uniformly distributed, performing histogram equalization processing on the microscopic image to obtain a monochrome image of the microscopic image; and performing closing and opening operations on the monochrome image of the microscopic image to obtain the contour data of the closed shape.

[0007] Optionally, the step of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result includes: acquiring the color distribution of the solid color pattern edges in the microscopic image of the actual image and a preset second contour data range; when there are other color scattered points on the solid color pattern edges in the microscopic image, drawing a black contour on the microscopic image and performing two binarization processes, setting the two colors with the highest proportion to white; performing closing and opening operations on the monochrome image of the microscopic image to obtain the contour data of the closed shape; when the contour data is within the preset contour data range, the image is confirmed to be an industrial product.

[0008] Optionally, the step of obtaining the screening rules and the image processing algorithm parameters corresponding to the screening rules further includes: obtaining the boundary color distribution of the microscopic image of the actual image and a preset number of contour lines; when the boundaries between different colors in the microscopic image are blurred, performing histogram equalization on the microscopic image to obtain the color distribution ratio of the microscopic image and sorting the color distribution ratios of the microscopic image to obtain the top three colors with the highest distribution ratios; performing binarization on the top three colors with the highest distribution ratios to obtain the number of contour lines for the top three colors; when the number of contour lines for the top three colors exceeds the preset number of contour lines, the image is an industrial product.

[0009] Optionally, the contour data includes one or more of the following features: opening and closing operation kernel value, number of closed shapes, set of aspect ratios of closed shapes, set of areas of closed shapes, set of adjacent areas of closed shapes, and set of color value proportions.

[0010] Optionally, the automatic image recognition method further includes: modifying the image processing algorithm parameters when the predicted value differs from the industrial product judgment result.

[0011] According to a second aspect, embodiments of the present invention also disclose an automatic image recognition device, comprising: an image acquisition module for acquiring an actual image of a target object to be tested; an image recognition module for inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result, wherein the preset image processing algorithm model is constructed based on training data; and a judgment module for judging whether the target object to be tested is an industrial product based on the recognition result.

[0012] According to a third aspect, embodiments of the present invention also disclose a computer device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to cause the at least one processor to perform the steps of the image automatic recognition method as described in the first aspect or any optional embodiment of the first aspect.

[0013] According to a fourth aspect, embodiments of the present invention also disclose a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the automatic image recognition method as described in the first aspect or any optional embodiment of the first aspect.

[0014] The technical solution of this invention has the following advantages:

[0015] The automatic image recognition method provided by this invention establishes and trains an image processing algorithm model, inputs the actual image into the image processing algorithm model, and obtains the recognition result to determine whether the actual image is an industrial product. The computer algorithm realizes the screening of calligraphy and painting artworks as industrial products, eliminating the adverse effects of strong subjectivity, high cost and complex process that are difficult to scale up due to manual recognition, and improving the screening efficiency and accuracy. Attached Figure Description

[0016] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0017] Figure 1 This is a flowchart illustrating the automatic image recognition method in an embodiment of the present invention;

[0018] Figure 2 This is a specific flowchart of the automatic image recognition method in an embodiment of the present invention;

[0019] Figures 3-11 This is a recognition example of the automatic image recognition method in the embodiments of the present invention;

[0020] Figure 12 This is a schematic diagram of the structure of the automatic image recognition device in an embodiment of the present invention;

[0021] Figure 13 This is a specific example diagram of a computer device in an embodiment of the present invention. Detailed Implementation

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

[0023] In the description of this invention, it should be noted that the term "and / or" as used in this application specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.

[0024] Furthermore, the technical features involved in the different embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0025] This invention discloses an automatic image recognition method, such as... Figure 1 As shown, the method includes the following steps:

[0026] Step 101: Obtain the actual image of the target object to be tested.

[0027] For example, in the art and calligraphy trading industry, it is necessary to identify whether the art and calligraphy is an original hand-painted work by an artist or a machine imitation. The target object to be tested can be the art and calligraphy that needs to be screened, or it can be a known industrial product or hand-painted work used to train the image processing algorithm model of this invention. Then, the actual image of the target object to be tested can be obtained through an image acquisition device.

[0028] Step 102: Input the actual image into a preset image processing algorithm model for image recognition and obtain the recognition result. The preset image processing algorithm model is constructed based on training data.

[0029] For example, in some embodiments of the present invention, the process of training and constructing the preset image processing algorithm model mainly includes:

[0030] The process involves obtaining screening rules and corresponding image processing algorithm parameters, establishing an image processing neural network model corresponding to the screening rules, acquiring training data and corresponding industrial product judgment results, inputting the training data into the image processing neural network model to obtain predicted values, comparing the predicted values ​​with the industrial product judgment results, determining the image processing algorithm parameters when the predicted values ​​match, and defining the corresponding image processing neural network model as the preset image processing algorithm model; when the predicted values ​​differ from the industrial product judgment results, modifying the image processing algorithm parameters, and repeating the above process of training and constructing the preset image processing algorithm model.

[0031] Optionally, in some embodiments of the present invention, the process of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result can be feature recognition of the microscopic image of the actual image, thereby obtaining the corresponding recognition result. Furthermore, different features can be extracted from the microscopic image in various ways, such as recognizing the color dot matrix distribution of the microscopic image, recognizing the color distribution of the edges of solid color patterns in the microscopic image, and recognizing the boundary color distribution of the microscopic image, etc.

[0032] Optionally, in some embodiments of the present invention, the process of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result includes:

[0033] a. Obtain the color dot matrix distribution of the microscopic image of the actual image and the preset first contour data interval; in this embodiment, the first contour data interval refers to the number of contours of the closed shape with an aspect ratio between 0.8 and 1 and an area ratio between 0.8 and 1. By comparing the color dot matrix distribution with the number of contours in the first contour data interval, it is determined whether the color dot matrix of the microscopic image is uniformly distributed.

[0034] When the color dot matrix of the micro-image is uniformly distributed, the micro-image is subjected to histogram equalization processing to obtain a monochrome image of the micro-image.

[0035] The monochrome image of the microscopic image is subjected to closing and opening operations to obtain the contour data of the closed shape.

[0036] Optionally, in some embodiments of the present invention, the process of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result includes:

[0037] b. Obtain the color distribution of the solid color pattern edge in the microscopic image of the actual image and a preset second contour data range; in this embodiment, the second contour data range refers to the number of regular closed shapes near the solid color pattern contour line being, for example, more than 10 or 5-10. For example, when the number of regular closed shapes near the solid color pattern contour line exceeds 10, it can be concluded that there are other color scattered points on the edge of the solid color pattern in the microscopic image; when the number of regular closed shapes near the solid color pattern contour line is between 5 and 10, it is necessary to make a judgment based on other conditions. The other conditions can be the aforementioned rule a.

[0038] When there are other colored scattered points on the edge of the solid color pattern in the microscopic image, a black outline is drawn on the microscopic image and binarized twice, and the two colors with the highest proportion are set to white.

[0039] The monochrome image of the microscopic image is subjected to closing and opening operations to obtain the contour data of the closed shape.

[0040] Optionally, in some embodiments of the present invention, the process of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result includes:

[0041] c. Obtain the boundary color distribution of the microscopic image of the actual image and the preset number of contour lines; when the number of contour lines exceeds the preset value, it proves that the color distribution is chaotic, thus indicating that the boundaries between different colors are blurred.

[0042] When the boundaries between different colors in the microscopic image are blurred, the microscopic image is subjected to histogram equalization to obtain the color distribution ratio of the microscopic image, and the color distribution ratio of the microscopic image is sorted to obtain the top three colors with the highest distribution ratio.

[0043] The top three colors with the highest distribution ratio are binarized to obtain the number of outlines of the top three colors.

[0044] The contour data includes one or more of the following features: opening and closing operation kernel value, number of closed shapes, set of aspect ratios of closed shapes, set of areas of closed shapes, set of adjacent areas of closed shapes, and set of color value proportions.

[0045] Step 103: Based on the identification result, determine whether the target object to be tested is an industrial product.

[0046] For example, in some embodiments of the present invention, in process a above, when the contour data of the closed shape is not in a preset first contour data range, the closed shape can be determined to be an industrial product; in process b above, when the contour data of the closed shape is not in a preset second contour data range, the closed shape can be determined to be an industrial product; in process c above, when the number of contour lines of the first three colors of the closed shape exceeds a preset number of contour lines, the closed shape can be determined to be an industrial product.

[0047] The automatic image recognition method of this invention uses a computer to model the artwork screening rules algorithmically. The objectively describable recognition process is completed using computer algorithms, and further training with a large amount of real-world data through machine learning effectively improves the accuracy of image recognition. Furthermore, it avoids the influence of factors such as ambient lighting, viewing angle, and image magnification equipment on manual expert recognition, and solves problems such as an expert being able to process only one artwork at a time and the fatigue that can occur from prolonged microscopic recognition work.

[0048] Exemplary examples, in some embodiments of the present invention, such as Figure 2 As shown, Figure 2 A specific training and recognition process of the automatic image recognition method of this invention involves: first, experts defining screening rules; algorithm engineers modeling an image processing neural network based on these rules; then, acquiring training data and inputting it into the image processing neural network model for training to obtain a preset image processing algorithm model; finally, acquiring an actual image of the target object to be tested and inputting it into the image processing algorithm model to obtain a recognition result; and then judging this recognition result. If the recognition result is certain, a screening result is obtained; if uncertain, it is handed over to experts for processing. After obtaining the recognition result, the algorithm is trained again. The specific method is as follows:

[0049] 1) First, industrial product screening experts define natural language screening rules based on their screening experience, for example:

[0050] Screening rules for machine-printed artwork:

[0051] a. When the color of the microscopic image is uniformly distributed in a matrix (the focus of this judgment process is on detecting CMYK), it can be determined to be an industrial product;

[0052] b. When there are scattered points of other colors at the edge of the solid color pattern in the microscopic image (the focus of this judgment process is to detect CMYK), it can be determined to be an industrial product;

[0053] c. In a microscopic image, if the boundaries between different colors are blurred, it is likely an industrial product. Conversely, if the boundaries are clear and there is color bleeding, it is more likely a hand-drawn artwork.

[0054] 2) Furthermore, algorithm engineers can model and set algorithm parameters based on the machine-printed artwork screening rules formulated by the experts mentioned above.

[0055] For example, when detecting a uniform distribution of color dots in a microscopic image:

[0056] a. Perform histogram equalization on the microscopic image to improve image quality and amplify color differences.

[0057] b. Convert the microscopic image to HSV mode, extract the CMYK (Cyan, Magenta, Yellow, Black) colors, and filter out all other colors.

[0058] c. Take four monochrome sheets Figure 2 Value it and perform closing and opening operations to merge the smaller interfering terms.

[0059] d. Extract the outlines of all closed shapes, and calculate the number of outlines, area, aspect ratio, distance, etc.

[0060] e. If the number of contours with aspect ratios between 0.8 and 1 and area ratios between 0.8 and 1 exceeds a certain proportion, it can be determined as a direct hit, and no other detection steps are needed to determine that the image belongs to an industrial product.

[0061] For example, when dealing with the presence of scattered points of other colors at the edges of a solid-color pattern in a microscopic image:

[0062] a. Convert the microscopic image to HSV mode and detect the color distribution. If the proportion of the two colors (color value range) with the highest percentage is greater than 10% and the sum of the two colors is greater than 50%, then it meets the requirements of this test.

[0063] b. Draw a black outline on the microscopic image.

[0064] c. Perform binarization on the image twice, setting the two colors (ranges) with the highest proportion to white.

[0065] Perform closing and opening operations on the image to merge smaller shapes and eliminate interference.

[0066] d. Extract the outlines of all closed shapes, and calculate the number of outlines, area, and aspect ratio.

[0067] e. Calculate the number of regular closed shapes near the black outline. If the number exceeds a certain number (e.g., 10), it can be determined as a hit. If the number is between 5 and 10, other detection methods are needed to confirm it.

[0068] Furthermore, when dealing with unclear boundaries between different colors in a microscopic image:

[0069] a. Perform histogram equalization on the microscopic image to improve image quality and amplify color differences.

[0070] b. Convert the micrograph to HSV mode, detect the color (color value range) distribution, and sort them from high to low according to the distribution ratio.

[0071] c. Perform binarization on the top three colors in terms of distribution ratio and draw the outline of each color.

[0072] d. Calculate the number of outlines. If the number exceeds 10, it indicates that the color distribution is messy, and it is likely an industrial product.

[0073] Histogram equalization, a process used in microscopic image processing, is a method to enhance image contrast. Its main idea is to transform the histogram distribution of an image into an approximately uniform distribution, thereby enhancing image contrast. Although histogram equalization is only a basic method in digital image processing, it is a powerful and classic algorithm.

[0074] The HSV model used in converting microscopic images to HSV mode is a color space created by A.S. Smith in 1978 based on the intuitive characteristics of color, also known as the hexagonal pyramid model. The parameters for color in this model are: hue (H), saturation (S), and value (V).

[0075] Binarizing an image involves setting the grayscale value of each pixel to 0 or 255, effectively giving the entire image a clear black and white effect. Binary images play a crucial role in digital image processing, as binarization significantly reduces the amount of data in an image, thus highlighting the outline of the target.

[0076] Closing an image can smooth its contours, but unlike opening, it can bridge narrow gaps and long, thin grooves, eliminate small holes, and fill cracks in the contour lines. Opening an image can smooth its contours, break up narrow necks, and eliminate fine protrusions.

[0077] Exemplary examples, in some embodiments of the present invention, such as Figure 3 The image shown is the original hand-drawn artwork. Figure 3 Histogram equalization is performed to obtain Figure 4 Filter separately Figure 4 The CMYK colors in the dataset, taking yellow as an example, yield the following results: Figure 5 This indicates that yellow was selected. Then... Figure 6 For example, among which Figure 6 For the Figure 3 Digital output of hand-drawn artwork, for Figure 6 Histogram equalization is performed to obtain Figure 7 Filter separately Figure 7 The CMYK colors in the dataset, taking yellow as an example, yield the following results: Figure 8 ,right Figure 8 Binarization is performed to obtain Figure 9 And then Figure 9 Performing closing and opening operations yields Figure 10 Extract again Figure 10 The graphic outline is obtained Figure 11 Thus, it can be seen that a large number of closed shapes with similar areas can be detected in the digital output work, and they are evenly distributed, indicating that there are many uniform yellow shapes in the original image. The same applies to other colors.

[0078] Since the images processed by this target are all magnified 200 times, the images seen above are actually only a few square millimeters in size, so they can be identified as digital output works.

[0079] 3) Further, organize the actual screening data, set the data format according to the rules to form training data, and train the algorithm. Using the microscopic image processing algorithm in the previous example, process the two sets of determined hand-drawn works and digital output works. The program records the key indicator values ​​of the processing process to form a knowledge base of rules for hand-drawn works and rules for digital output works. The indicators include, but are not limited to: kernelCount: kernel value of opening and closing operations, circleCount: number of closed shapes, circleLWR: set of aspect ratios of closed shapes, circleArea: set of areas of closed shapes, circleABR: set of adjacent ratios of areas of closed shapes, and coc: set of color value proportions.

[0080] 4) The trained algorithm is then used to identify new target data. The target image is processed by the algorithm, and the obtained key indicator values ​​are compared with the knowledge base to find the data 'a' with the closest similarity. The industrial product judgment result of data 'a' is used as the industrial product judgment result of the target image.

[0081] 5) Determine the identification result. If it can be determined that it is a hand-drawn work or an industrial product, the screening process ends. Otherwise, experts need to screen the target and obtain the screening result. Then, repeat steps 2) and 3) with this set of data, and train the algorithm to improve the expert knowledge base.

[0082] Furthermore, after judging the recognition results, when the algorithm reaches a preset number of errors after recognizing new target data, it will be handed over to experts for evaluation. Based on the experts' experience, it will be determined whether the algorithm needs to be modified. If modification is required, the algorithm engineer will modify the algorithm parameters. In this way, the non-fully automatic algorithm can reduce the number of modifications when the feature data of the target image is exactly at the critical point of the algorithm's recognition ability, thereby eliminating outliers in the target image data, reducing the number of algorithm modifications due to outliers, and reducing the algorithm's error.

[0083] Furthermore, algorithm engineers can modify algorithm parameters in several ways. For example, after identifying an "unreasonable" number of color dots, *n*, when recognizing a target image, if the number of color dots is 0, the target image can be determined to be a hand-drawn artwork; if the number of color dots is greater than *n*, the target image can be determined to be an industrial product; if the number of color dots is greater than 0 and less than *n*, and this situation occurs multiple times, then expert intervention is needed to determine new algorithm parameters. Algorithm engineers then modify the algorithm based on these new parameters.

[0084] The "unreasonable" color dots are identified primarily by obtaining microscopic images and CMYK color distribution maps. This process filters out irregular shapes (the dots in inkjet printing should be circular or nearly circular) and larger shapes. The remaining dots are considered "unreasonable." The presence of "unreasonable" color dots indicates an inkjet-printed artwork (industrial product), while their absence indicates a hand-painted artwork. Theoretically, a count greater than 0 "unreasonable" color dots should indicate an industrial product. However, in practice, issues with image processing or calculation precision can lead to the presence of some "unreasonable" color dots. Therefore, the number of "unreasonable" color dots needs adjustment based on the actual situation. Only those exceeding this threshold are considered industrial products; those with 0 or less than or equal to this threshold are hand-painted artworks.

[0085] Currently, artwork data feature recognition in the industry primarily relies on manual methods by experts. However, the theories and methods for expert feature recognition are objectively defined and could be entirely implemented using computer algorithms. Furthermore, manual expert recognition is affected by numerous factors such as ambient lighting, viewing angle, and image magnification equipment, increasing the difficulty. Additionally, an expert can only process one artwork at a time, and prolonged microscopic recognition work can lead to fatigue, thus limiting the concurrent processing capacity of expert recognition methods. In contrast, an objectively describable recognition process can be accomplished by computer algorithms, and training these algorithms on large amounts of real-world data through machine learning can effectively improve their accuracy. When encountering target samples that the algorithm cannot recognize, experts conduct manual identification to enrich the expert knowledge base.

[0086] This invention also discloses an automatic image recognition device, such as... Figure 12 As shown, the device includes:

[0087] Image acquisition module 31 is used to acquire the actual image of the target object to be tested, as detailed in step 101;

[0088] The image recognition module 32 is used to input the actual image into a preset image processing algorithm model for image recognition and obtain the recognition result. The preset image processing algorithm model is constructed based on training data. For details, please refer to step 102.

[0089] The judgment module 33 determines whether the target object to be tested is an industrial product based on the recognition result. For details, please refer to step 103.

[0090] When in use, this device designs an algorithm model for the objectively describable recognition process in automatic image recognition using a computer, and trains this algorithm model with a large amount of actual data to improve the accuracy of automatic image recognition.

[0091] This invention also provides a computer device, such as... Figure 13 As shown, the computer device may include a processor 401 and a memory 402, wherein the processor 401 and the memory 402 may be connected via a bus or other means. Figure 13 Taking the example of a connection between China and Israel via a bus.

[0092] Processor 401 may be a central processing unit (CPU). Processor 401 may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or combinations thereof.

[0093] The memory 402, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs, non-transitory computer-executable programs, and modules, such as the program instructions / modules corresponding to the automatic image recognition method in the embodiments of the present invention. The processor 401 executes various functional applications and data processing of the processor by running the non-transitory software programs, instructions, and modules stored in the memory 402, thereby realizing the automatic image recognition method in the above method embodiments.

[0094] The memory 402 may include a program storage area and a data storage area. The program storage area may store the operating system and applications required for at least one function; the data storage area may store data created by the processor 401, etc. Furthermore, the memory 402 may include high-speed random access memory and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, the memory 402 may optionally include memory remotely located relative to the processor 401, and these remote memories may be connected to the processor 401 via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0095] The one or more modules are stored in the memory 402, and when executed by the processor 401, they perform actions such as... Figure 1 The automatic image recognition method in the illustrated embodiment.

[0096] For specific details regarding the aforementioned computer equipment, please refer to the relevant documentation. Figure 1The relevant descriptions and effects in the illustrated embodiments are for understanding purposes only and will not be repeated here.

[0097] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. The storage medium can be a magnetic disk, optical disk, read-only memory (ROM), random access memory (RAM), flash memory, hard disk drive (HDD), or solid-state drive (SSD), etc.; the storage medium can also include combinations of the above types of memory.

[0098] Although embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations all fall within the scope defined by the appended claims.

Claims

1. An automatic image recognition method, characterized in that, include: Obtain the actual image of the target object to be tested; The actual image is input into a preset image processing algorithm model for image recognition to obtain a recognition result. The preset image processing algorithm model is constructed based on training data. The image recognition involves feature recognition of the microscopic image of the actual image, including: recognizing the color dot matrix distribution of the microscopic image, recognizing the color distribution of the edges of solid color patterns in the microscopic image, or recognizing the boundary color distribution of the microscopic image. Recognizing the color dot matrix distribution of the microscopic image includes: acquiring the color dot matrix distribution of the microscopic image of the actual image and a preset first contour data range; when the color dot matrix of the microscopic image is uniformly distributed, histogram equalization processing is performed on the microscopic image to obtain a monochrome image of the microscopic image; closing and opening operations are performed on the monochrome image of the microscopic image to obtain the contour data of the closed shape. Based on the identification results, it is determined whether the target object to be tested is an industrial product.

2. The method according to claim 1, characterized in that, The process of training and constructing the preset image processing algorithm model includes: Obtain the screening rules and the image processing algorithm parameters corresponding to the screening rules, and establish an image processing neural network model corresponding to the screening rules; Obtain training data and the judgment results of industrial products corresponding to the training data; The training data is input into the image processing neural network model to obtain the predicted value; The predicted value is compared with the judgment result of the industrial product; When the predicted value is the same as the judgment result of the industrial product, the image processing algorithm parameters are determined, and the corresponding image processing neural network model is determined as the preset image processing algorithm model.

3. The method according to claim 1, characterized in that, The step of inputting the actual image into a preset image processing algorithm model for image recognition to obtain the recognition result includes: Obtain the color distribution of the solid color pattern edge in the microscopic image of the actual image and the preset second contour data range; When there are other colored scattered points on the edge of the solid color pattern in the microscopic image, a black outline is drawn on the microscopic image and binarized twice, and the two colors with the highest proportion are set to white. The monochrome image of the microscopic image is subjected to closing and opening operations to obtain the contour data of the closed image.

4. The method according to claim 1, characterized in that, The step of inputting the actual image into a preset image processing algorithm model for image recognition to obtain a recognition result further includes: Obtain the boundary color distribution and the preset number of contour lines of the microscopic image of the actual image; When the boundaries between different colors in the microscopic image are blurred, the microscopic image is subjected to histogram equalization to obtain the color distribution ratio of the microscopic image, and the color distribution ratio of the microscopic image is sorted to obtain the top three colors with the highest distribution ratio. The top three colors with the highest distribution ratio are binarized to obtain the number of outlines of the top three colors.

5. The method according to claim 1 or 3, characterized in that, The contour data includes one or more of the following features: opening and closing operation kernel value, number of closed shapes, set of aspect ratios of closed shapes, set of areas of closed shapes, set of adjacent areas of closed shapes, and set of color value proportions.

6. The method according to claim 2, characterized in that, Also includes: When the predicted value differs from the judgment result of the industrial product, the image processing algorithm parameters are modified.

7. An automatic image recognition device, characterized in that, include: Image acquisition module: used to acquire the actual image of the target object under test; Image recognition module: used to input the actual image into a preset image processing algorithm model for image recognition, and obtain recognition results. The preset image processing algorithm model is constructed based on training data. The image recognition involves feature recognition of the microscopic image of the actual image, including: recognizing the color dot matrix distribution of the microscopic image, recognizing the color distribution of the edges of solid color patterns in the microscopic image, or recognizing the boundary color distribution of the microscopic image; recognizing the color dot matrix distribution of the microscopic image includes: acquiring the color dot matrix distribution of the microscopic image of the actual image and a preset first contour data interval; when the color dot matrix of the microscopic image is uniformly distributed, performing histogram equalization processing on the microscopic image to obtain a monochrome image of the microscopic image; performing closing and opening operations on the monochrome image of the microscopic image to obtain the contour data of the closed shape; Judgment module: Based on the recognition result, determine whether the target object to be tested is an industrial product.

8. A computer device, characterized in that, include: At least one processor; The at least one processor is also connected in communication with a memory, wherein the memory stores instructions that can be executed by the at least one processor to cause the at least one processor to perform the steps of the automatic image recognition method as described in any one of claims 1-6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it performs the steps of automatic image recognition as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Text image area identification method and system, and related device

    CN110399867A

  • Collection identification method and system

    CN112115960A