Image recognition method, image recognition device, material sorting equipment and storage medium

By obtaining image size and bump layout information in the material sorting equipment, and determining the target position of bump images, the problem of bump interference in material recognition is solved, and the accuracy and reliability of recognition are improved.

CN119360311BActive Publication Date: 2025-02-28BEIJING HONEST TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411908237.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-24
Publication Date
2025-02-28
Estimated Expiration
2044-12-24

AI Technical Summary

Technical Problem

In material sorting equipment, the bumps on the conveyor belt may affect the accuracy of material identification, especially during the plastic transmission process. If the plastic is small in size or too thin in thickness and is stuck to the bumps on the conveyor belt, it is easy to misidentify that the bumps are part of the plastic.

Method used

By acquiring the image to be processed and its image size information, obtaining the bump detection template and bump layout information, determining the target position information of each bump image based on this information, and then updating the outline information of the material, eliminating the interference of bumps on material identification.

Benefits of technology

It improves the accuracy and reliability of material identification, reduces the impact of convex points on material identification results, and improves the identification performance of material sorting equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

The present disclosure relates to the field of image recognition technology, and specifically to an image recognition method, an image recognition device, a material sorting device and a storage medium. The present disclosure provides an image recognition method, which is applied to a material sorting device, and includes: obtaining an image to be processed for material recognition and image size information of the image to be processed; obtaining a convex point detection template and convex point layout information of multiple convex point images in the image to be processed; based on the image size information and the convex point layout information, respectively determining the target position information of each convex point image in the image to be processed through the convex point detection template; determining the first contour information of the material in the image to be processed; based on the matching result of the first contour information and the multiple target position information, updating the first contour information, obtaining the target contour information of the material, and identifying the material through the target contour information. The accuracy and reliability of material recognition can be improved, thereby facilitating the improvement of the material recognition performance of the material sorting device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image recognition technology, and in particular to an image recognition method, an image recognition device, a material sorting device and a computer-readable storage medium. Background Art

[0002] When the material sorting equipment is transmitting materials, in order to ensure the stability of material transmission and prevent the materials from rolling during the transmission process, some evenly distributed convex points are arranged on the conveyor belt to control the relative movement state of the materials on the conveyor belt through multiple convex points.

[0003] In the process of material transmission, the currently transmitted material can generally be determined by performing image recognition processing on the collected images, but the convex points on the conveyor belt may affect the accuracy of material recognition and the recognition results of the materials. For example, in the process of plastic transmission, if the plastic is small in size or too thin, and it adheres to the convex points on the conveyor belt during the transmission process, the convex points are easily mistakenly recognized as part of the plastic during the image recognition processing, thereby affecting the recognition results of the plastic. Summary of the invention

[0004] In order to overcome the problems existing in the related art, an exemplary embodiment of the present disclosure provides an image recognition method, which is applied to material sorting equipment, and the method includes: obtaining an image to be processed for material identification and image size information of the image to be processed, wherein the image to be processed includes multiple salient point images; obtaining a salient point detection template and salient point layout information of the multiple salient point images in the image to be processed; based on the image size information and the salient point layout information, determining the target position information of each salient point image in the image to be processed through the salient point detection template; determining the first contour information of the material in the image to be processed; based on the matching result of the first contour information and the multiple target position information, updating the first contour information to obtain the target contour information of the material, so as to identify the material through the target contour information.

[0005] In some embodiments, based on the image size information and the salient point layout information, the target position information of each salient point image in the image to be processed is determined respectively through a salient point detection template, including: based on the image size information and the salient point layout information, the initial position information of each salient point image in the image to be processed is determined respectively through a salient point detection template; based on the initial position information of multiple adjacent salient point images and the salient point layout information, the initial position information of each salient point image is corrected respectively to determine the target position information of each salient point image in the image to be processed.

[0006] In some embodiments, the salient point detection template includes multiple detection templates, and the detection templates correspond to the image columns of salient point images in the image to be processed one by one; based on the image size information and the salient point layout information, the initial position information of each salient point image in the image to be processed is determined respectively through the salient point detection template, including: based on the salient point layout information, determining the first to-be-matched area of ​​the target salient point image in the image to be processed; in the first to-be-matched area, determining the first position information of the target salient point image through the detection template corresponding to the target salient point image; based on the first position information and the salient point layout information, determining the candidate position information corresponding to each salient point image; based on the image size information, the salient point layout information and the candidate position information corresponding to each salient point image, determining the second to-be-matched area corresponding to each salient point image; based on the detection template corresponding to the image column where each salient point image is located, determining the initial position information of each salient point image in the image to be processed from the corresponding second to-be-matched area.

[0007] In some embodiments, based on the salient point layout information, determining the first area to be matched of the target salient point image in the image to be processed includes: determining the total number of image columns of the salient point images in the image to be processed; determining the salient point size information and expandable size information of the salient point image according to the salient point layout information; determining the coordinate position of the first salient point image in the first image column in the image to be processed; and determining the first area to be matched of the target salient point image in the image to be processed based on the coordinate position, the total number of image columns, the salient point size information, and the expandable size information.

[0008] In some embodiments, the coordinate position includes the horizontal coordinate of the first salient point image; the expandable size information includes expandable width information and expandable height information; the salient point size information includes pixel width information; based on the coordinate position, the total number of image columns, the salient point size information and the expandable size information, determining the first to-be-matched area of ​​the target salient point image in the image to be processed, including: determining the sequence value corresponding to the image column where the target salient point image is located; determining the first horizontal coordinate information according to the horizontal coordinate of the first salient point image, the product between the sequence value and the preset height, and the expandable width information; determining the first vertical coordinate information, and determining the first position coordinate information of the first to-be-matched area in the image to be processed in combination with the first horizontal coordinate information; determining the area width information of the first to-be-matched area according to the pixel width information and the expandable width information; determining the first to-be-matched area of ​​the target salient point image in the image to be processed according to the first position coordinate information, the area width information and the preset height.

[0009] In some embodiments, the target salient point image is the first salient point image in the image column, and the image column where the target salient point image is located is a middle column of the plurality of image columns.

[0010] In some embodiments, based on the first position information and the salient point layout information, candidate position information corresponding to each salient point image is determined respectively, including: determining the horizontal spacing information and the vertical spacing information between two adjacent salient point images according to the salient point layout information; based on the first position information, the total number of image columns, the salient point size information, the horizontal spacing information and the vertical spacing information, determining the candidate position information corresponding to each salient point image respectively.

[0011] In some embodiments, the candidate position information includes candidate horizontal coordinate information and candidate vertical coordinate information; the salient point size information also includes pixel height information; the image size information includes image width information and image height information; based on the image size information, the salient point layout information and the candidate position information corresponding to each salient point image, determine the second area to be matched corresponding to each salient point image, including: determining the area size information of the second area to be matched corresponding to the salient point image according to the salient point size information and the expandable size information; determining the second horizontal coordinate information of the second area to be matched based on the first difference between the candidate horizontal coordinate information and the pixel width information and the second difference between the image width information and the pixel width information; determining the second vertical coordinate information of the second area to be matched based on the third difference between the candidate vertical coordinate information and the pixel height information and the fourth difference between the image height information and the pixel height information; determining the second area to be matched corresponding to the salient point image according to the area size information, the second horizontal coordinate information and the second vertical coordinate information of the second area to be matched.

[0012] In some embodiments, based on the detection template corresponding to the image column where each salient point image is located, the initial position information of each salient point image in the image to be processed is determined from the corresponding second area to be matched, including: extracting multiple candidate images that meet the salient point size information from the second area to be matched according to the salient point size information of the salient point image in the salient point layout information and the specified step size; determining reference gradient information of the target detection template and the gradient information of each of the candidate images, the target detection template being the detection template of the salient point image corresponding to the second area to be matched; matching the multiple gradient information with the reference gradient information respectively, and determining the target candidate image with the highest similarity to the target detection template among the multiple candidate images; and determining the initial position information of the salient point image in the image to be processed based on the target candidate image.

[0013] In some embodiments, based on the target candidate image, the initial position information of the salient point image in the image to be processed is determined, including: if the number of target candidate images is unique, the position information of the target candidate image in the image to be processed is used as the initial position information of the salient point image in the image to be processed; if the number of target candidate images is multiple, the grayscale co-occurrence matrix of each target candidate image and the reference grayscale co-occurrence matrix of the target detection template are determined respectively; and the target grayscale co-occurrence matrix with the highest matching degree with the reference grayscale co-occurrence matrix among multiple grayscale co-occurrence matrices is determined, and the position information of the target candidate image in the image to be processed corresponding to the target grayscale co-occurrence matrix is ​​used as the initial position information of the salient point image in the image to be processed.

[0014] In some embodiments, the initial position information includes initial horizontal coordinate information and initial vertical coordinate information of the salient point image; based on the initial position information of multiple adjacent salient point images and the salient point layout information, the initial position information of each salient point image is corrected respectively, and the target position information of each salient point image in the image to be processed is determined, including: determining the horizontal difference between the initial horizontal coordinate information of the salient point image and the initial horizontal coordinate information of the first adjacent salient point image in the horizontal direction; determining the vertical difference between the initial vertical coordinate information of the salient point image and the initial vertical coordinate information of the second adjacent salient point image in the vertical direction; based on a first comparison result of the horizontal difference and a preset horizontal tolerance interval, and a second comparison result of the vertical difference and a preset vertical tolerance interval, the initial position information of the salient point image is corrected to obtain the target position information of the salient point image.

[0015] In some embodiments, based on a first comparison result of a horizontal difference value and a preset horizontal tolerance interval, and a second comparison result of a vertical difference value and a preset vertical tolerance interval, correcting the initial position information of the salient point image to obtain the target position information of the salient point image includes: if the first comparison result indicates that the horizontal difference value is not within the horizontal tolerance interval, adjusting the initial horizontal coordinate information of the salient point image based on initial horizontal coordinate information of the first adjacent salient point image and horizontal interval information between two adjacent salient point images in the salient point layout information to obtain the corrected initial horizontal coordinate information; if the second comparison result indicates that the vertical difference value is not within the vertical tolerance interval, adjusting the initial vertical coordinate information of the salient point image based on initial vertical coordinate information of the second adjacent salient point image and vertical interval information between two adjacent salient point images in the salient point layout information to obtain the corrected initial vertical coordinate information; if the first comparison result indicates that the horizontal difference value is within the horizontal tolerance interval, and the second comparison result indicates that the vertical difference value is within the vertical tolerance interval, determining the initial position information of the salient point image as the target position information of the salient point image.

[0016] In some embodiments, based on the matching results of the first contour information and multiple target position information, the first contour information is updated to obtain the target contour information of the material, including: if there is target position information that partially overlaps with the first contour information, the contour information in the first contour information that corresponds to the overlapping target position information is removed to obtain the target contour information of the material.

[0017] In a second aspect, the present disclosure further provides an image recognition device, which is applied to material sorting equipment, and the device includes: a first acquisition module, which is used to acquire an image to be processed for material identification and image size information of the image to be processed, wherein the image to be processed includes multiple salient point images; a second acquisition module, which is used to acquire a salient point detection template and salient point layout information of multiple salient point images in the image to be processed; a first processing module, which is used to determine the target position information of each salient point image in the image to be processed based on the image size information and the salient point layout information and through the salient point detection template; a second processing module, which is used to determine the first contour information of the material in the image to be processed; and an update module, which is used to update the first contour information based on the matching result of the first contour information and the multiple target position information, and obtain the target contour information of the material, so as to identify the material through the target contour information.

[0018] In a third aspect, the present disclosure further provides a material sorting device, comprising: a memory and a processor, the memory and the processor are communicatively connected to each other, computer instructions are stored in the memory, and the processor executes the image recognition method provided in any of the above aspects by executing the computer instructions.

[0019] In a fourth aspect, the present disclosure further provides a computer-readable storage medium, which stores the following program, and the program is used to execute the image recognition method provided by any of the above aspects.

[0020] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure.

[0021] The technical solution provided by the embodiments of the present disclosure may include the following beneficial effects: According to the image recognition method provided by the present disclosure, the target position information of multiple convex point images distributed in the image to be processed can be determined by template matching based on the image size information of the image to be processed and the convex point layout information of the convex point image, and then after obtaining the first contour information of the material, the interference of the target position information of the convex point image on the first contour information can be eliminated or reduced by information matching, and the target contour information of the material can be obtained, which can effectively improve the validity of the target contour information, and then when the material is subsequently identified and processed, the accuracy and reliability of material identification can be improved, which is beneficial to improving the material identification performance of the material sorting equipment. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] The present invention may be better understood by describing exemplary embodiments of the present invention in conjunction with the accompanying drawings, in which:

[0023] Figure 1 This is a schematic diagram of the structure of a material sorting device shown in an exemplary embodiment of the present disclosure;

[0024] Figure 2 A flowchart of an image recognition method according to an exemplary embodiment of the present disclosure is shown;

[0025] Figure 3 A flowchart of another image recognition method shown in an exemplary embodiment of the present disclosure;

[0026] Figure 4 The figure is a schematic diagram of the distribution of a salient point image in an image to be processed, shown as an exemplary embodiment of the present disclosure.

[0027] Figure 5 A schematic diagram of a first area to be matched according to an exemplary embodiment of the present disclosure;

[0028] Figure 6 A schematic diagram of image position distribution is shown in an exemplary embodiment of the present disclosure;

[0029] Figure 7 Another schematic diagram of image position distribution is shown as an exemplary embodiment of the present disclosure;

[0030] Figure 8 A schematic diagram showing an exemplary embodiment of the present disclosure;

[0031] Fig. 9 Another schematic diagram showing an exemplary embodiment of the present disclosure;

[0032] Fig.10 A schematic diagram of the structure of an image recognition device according to an exemplary embodiment of the present disclosure;

[0033] Fig.11 It is a schematic structural diagram of another material sorting equipment shown as an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION

[0034] The specific embodiments of the present invention will be described below. It should be noted that in the specific description of these embodiments, in order to provide a concise description, it is impossible for this specification to provide a detailed description of all the features of the actual embodiments. It should be understood that in the actual implementation of any embodiment, just as in the process of any engineering project or design project, in order to achieve the specific goals of the developer and to meet system-related or business-related restrictions, various specific decisions are often made, and this will also change from one embodiment to another. In addition, it can also be understood that although the efforts made in this development process may be complex and lengthy, for ordinary technicians in the field related to the content disclosed by the present invention, some changes such as design, manufacturing or production based on the technical content disclosed in this disclosure are just conventional technical means, and should not be understood as insufficient content of this disclosure.

[0035] Unless otherwise defined, the technical terms or scientific terms used in this disclosure shall have the usual meanings understood by persons of ordinary skill in the technical field to which the invention belongs. The words "first", "second" and similar terms used in this disclosure do not indicate any order, quantity or importance, but are only used to distinguish different components. Words such as "one" or "one" and the like do not indicate a quantitative limitation, but rather indicate the presence of at least one. Words such as "include" or "comprise" and the like mean that the elements or objects appearing before "include" or "comprise" cover the elements or objects listed after "include" or "comprise" and their equivalents, and do not exclude other elements or objects. Words such as "connect" or "connected" and the like are not limited to physical or mechanical connections, nor are they limited to direct or indirect connections.

[0036] When the material sorting equipment is transmitting materials, in order to ensure the stability of material transmission and prevent the materials from rolling during the transmission process, some evenly distributed convex points are arranged on the conveyor belt to control the relative movement state of the materials on the conveyor belt through multiple convex points.

[0037] In the process of material transmission, the currently transmitted material can generally be determined by performing image recognition processing on the collected images. However, in the actual transmission process, part of the material may adhere to the convex points, and then in the process of image recognition, the convex points on the conveyor belt may be recognized as part of the material, causing interference, which in turn affects the accuracy of material recognition and affects the material recognition results.

[0038] For example, the material sorting device is a plastic sorting device. The structure of the plastic sorting device 100 can be as follows: Figure 1As shown, it includes a feeding mechanism 110, a transmission mechanism 120, a detection mechanism 130, a sorting device 140 and a collecting device 150. The feeding mechanism 110 is used to feed the plastic to be sorted into the transmission mechanism 120. The transmission mechanism 120 at least includes a conveyor belt for conveying the plastic fed by the feeding mechanism 110, and a detection mechanism 130 for detecting the plastic conveyed on the transmission mechanism 120 to identify the plastic currently being conveyed. Among them, the detection mechanism 130 can be a device that uses near-infrared plastic recognition technology to detect the plastic conveyed on the transmission mechanism 120. For example, an infrared camera is used to collect an image to be processed of the plastic currently being conveyed by the conveyor belt, and then the image recognition processing is performed on the image to be processed to determine the contour of the plastic currently being conveyed by the conveyor belt, and then the plastic currently being conveyed is identified based on the obtained contour result. The sorting device 140 is used to remove impurities in the plastic. The collecting device 150 is used to collect the plastic that needs to be retained and the impurities in the plastic.

[0039] During the plastic transmission process, the plastic can be transmitted in the form of particles or sheets. If the plastic is small in size or too thin, and it adheres to the bumps on the conveyor belt during the transmission process, the bumps are easily misidentified as part of the plastic during the image recognition process, thereby affecting the accuracy of plastic recognition and the plastic recognition results. The situation of adhesion may include but is not limited to: plastic particles are arranged vertically above the bumps, or plastic sheets partially cover the bumps on the conveyor belt, etc.

[0040] To solve the above problems, the exemplary embodiments of the present disclosure provide an image recognition method applied to a material sorting device, such as Figure 2 As shown, the image recognition method may include the following steps S210 to S250:

[0041] Step S210, obtaining an image to be processed for material identification and image size information of the image to be processed.

[0042] The image to be processed refers to the image collected by the material sorting equipment during the material transmission through the conveyor belt. By obtaining the image to be processed, the current material transmission status can be clarified, and then the currently transmitted material can be specifically identified.

[0043] The image to be processed includes a plurality of convex point images, which are images obtained by collecting convex points on the conveyor belt. In order to facilitate the subsequent prediction of the position information of each convex point in the image to be processed and the distribution of the material, the image size information of the image to be processed is obtained while obtaining the image to be processed, so as to locate the position of each convex point and the position of the material in a targeted manner through the image size information. The image size information may include the image width information and image height information of the image to be processed.

[0044] Step S220, obtaining a salient point detection template and salient point layout information of a plurality of salient point images in the image to be processed.

[0045] The salient point detection template is used to identify the image detection template corresponding to the salient point in the image to be processed. Through the salient point detection template, the pixel block area matching the salient point image feature in the image to be processed can be identified, and then the distribution position of the salient point can be determined.

[0046] The salient point layout information is used to determine the distribution of the salient point images corresponding to the salient points in the image to be processed and the size information of the salient point images, so that when the distribution of multiple salient point images in the image to be processed is determined in combination with the salient point detection template, the determination efficiency and accuracy can be improved.

[0047] Step S230, based on the image size information and the salient point layout information, the target position information of each salient point image in the image to be processed is determined by using a salient point detection template.

[0048] The size of the image to be processed can be determined through the image size information. For example, the image width and image height of the image to be processed can be determined. The distribution of the convex point images in the image to be processed and the size of each convex point image can be determined through the convex point layout information. For example, the number of pixels involved in a convex point image, the width and height of the convex point image, the horizontal interval between two adjacent convex point images, and the vertical interval between two adjacent convex point images can be determined.

[0049] Under the condition of clear image size information and salient point layout information, salient point detection is performed through a salient point detection template, which can make the salient point image determination process more targeted and specific, thereby determining the target position information of each salient point image in the image to be processed, which can effectively improve the determination efficiency.

[0050] Step S240: determining first contour information of the material in the image to be processed.

[0051] In order to determine the distribution of the material on the conveyor belt, the image to be processed is subjected to material recognition processing, thereby obtaining the first contour information of the material in the image to be processed, wherein the first contour information can be understood as preliminary recognition information.

[0052] The first contour information may be obtained by performing contour extraction algorithm processing on the image to be processed, for example, a semantic segmentation algorithm, an edge detection algorithm, a connected region marking algorithm, etc. The specific contour extraction algorithm used may be determined according to actual needs.

[0053] Step S250: based on the matching result between the first contour information and the plurality of target position information, the first contour information is updated to obtain the target contour information of the material, so as to identify the material through the target contour information.

[0054] Since the convex points are fixed on the conveyor belt, and during the process of conveying the material, the material may be adhered to the convex points, and when the contour of the image to be processed is extracted, the convex point image may be regarded as part of the material, which may cause the first contour information to deviate from the actual contour information of the material.

[0055] Therefore, in order to improve the accuracy of material identification, the first contour information is matched with multiple target position information to determine whether there is a situation where the contour is misidentified due to the presence of the convex point image based on the obtained matching results. Updating the first contour information based on the matching results can make the update process more targeted, and can effectively eliminate the influence of the convex point image on material identification, thereby helping to improve the accuracy and reliability of contour extraction, so that the obtained target contour information can be more consistent with the real contour of the material, so that when the target contour information is used to identify the material in the future, the recognition efficiency can be improved, which helps to improve the material recognition performance of the material sorting equipment.

[0056] According to the image recognition method provided by the present disclosure, the target position information of multiple convex point images distributed in the image to be processed can be determined by template matching based on the image size information of the image to be processed and the convex point layout information of the convex point image. After obtaining the first contour information of the material, the interference of the target position information of the convex point image on the first contour information can be eliminated or reduced by information matching to obtain the target contour information of the material. The validity of the target contour information can be effectively improved, and the accuracy and reliability of material identification can be improved during subsequent identification processing of the material, which is beneficial to improving the material identification performance of the material sorting equipment.

[0057] In some embodiments, Figure 3 As shown, the above step S230:

[0058] Step S231, based on the image size information and the salient point layout information, the initial position information of each salient point image in the image to be processed is determined by using a salient point detection template.

[0059] According to the salient point layout information, the positional relationship between adjacent salient point images can be clarified. Furthermore, when the image size information of the image to be processed is determined, the distribution of multiple salient point images in the image to be processed can be estimated. Furthermore, with the assistance of the salient point detection template, the initial position information of each salient point image in the image to be processed can be obtained.

[0060] In some embodiments, the salient point detection template is a single detection template corresponding to the salient point image, thereby effectively saving template storage costs and improving the detection efficiency of the salient point image.

[0061] In other embodiments, the salient point detection template includes a plurality of detection templates, and the detection templates correspond to the image columns of the salient point images in the image to be processed one by one. Since the image acquisition device may be affected by factors such as the environment, light source, or its own hardware during the actual image acquisition process, the pixel brightness distribution in the image to be processed may be uneven. Therefore, the background image used to create the salient point detection template can be acquired by the image acquisition device in advance during the transmission process without placing any objects on the conveyor belt. The schematic diagram of the background image can be as follows: Figure 4 As shown, each solid box in the background image is a convex point reference image corresponding to the convex point. Since the convex points are evenly distributed on the conveyor belt, it can be clearly observed on the background image that each convex point image is evenly distributed in each row and column. In order to improve the detection accuracy and reduce the influence of factors such as the environment, light source or hardware itself, a corresponding detection template is created for each image column corresponding to each column of convex point images, so that the detection accuracy of the convex point image can be improved during subsequent detection. The image column may include at least one pixel column. Each image column corresponds to a detection template, and then all convex point images in the corresponding image column can be targetedly detected by the detection template. In one example, the convex point images corresponding to multiple detection templates can be multiple convex point images in the same row in the background image, so that the creation process of the detection template can be simplified and the creation efficiency can be improved. In another example, the convex point images corresponding to multiple detection templates can be multiple convex point images that are not in the same row in the background image, and can be the convex point images in the corresponding image column that best represent the image features of the image column, so that when template matching is performed later, each convex point image in the corresponding image column can be quickly determined.

[0062] The above step S231 may include the following steps:

[0063] Step a1: determining a first to-be-matched area of ​​a target salient point image in an image to be processed based on the salient point layout information.

[0064] The target salient point image is a basic salient point image used to locate the distribution positions of all salient point images in the image to be processed. In order to quickly find the position of the target salient point image in the image to be processed, based on the salient point layout information, the first matching area of ​​the target salient point position in the image to be processed is narrowed down by local matching to determine the target salient point image range, thereby possibly reducing the search cost of template matching.

[0065] In some examples, the target salient point image may be the first salient point image of any image column among the plurality of image columns, thereby simplifying the difficulty of determining the initial position information of each salient point image subsequently.

[0066] In other examples, the image column where the target salient point image is located may be the middle column of multiple image columns, and the target salient point image is the first salient point image in the image column, so that when the initial position information of each salient point image is subsequently determined, the positioning error can be reduced and the effectiveness and accuracy of determining the initial position information can be improved.

[0067] In some examples, the above step a1 may include the following steps:

[0068] Step a11, determining the total number of image columns of salient point images in the image to be processed.

[0069] The total number of image columns refers to the sum of all image columns that contain salient point images in the image to be processed. By determining the total number of image columns, the distribution and arrangement pattern of salient point images in the image to be processed can be clarified, and then when the initial position information is subsequently determined, the matching process can be simplified, and the search space and the amount of calculation can be reduced.

[0070] Step a12, determining the salient point size information and expandable size information of the salient point image according to the salient point layout information.

[0071] The convex dot layout information refers to the information that can clarify the arrangement and position of the convex dot images in the image in the image processing and recognition tasks. The convex dot layout information may include but is not limited to the following information: convex dot quantity information, convex dot arrangement information, convex dot spacing information, convex dot shape information, convex dot size information, convex dot direction information, convex dot relative position information, etc.

[0072] Therefore, the convex dot size information and the expandable size information of the convex dot image can be determined through the convex dot layout information. The convex dot size information may include width information, height information and other geometric feature information of the convex dot image. The expandable size information may refer to the allowable range of variation of the convex dot image size during the search and matching process. The expandable size information may be determined in advance based on the distribution of multiple convex dots on the conveyor belt, thereby avoiding the occurrence of over-expansion.

[0073] By determining the salient point size information, the accuracy of identifying and locating each salient point image can be improved. By determining the extensible size information, the flexibility of subsequent template matching detection can be improved, thereby improving the matching success rate of the salient point image.

[0074] Step a13, determining the coordinate position of the first salient point image of the first image column in the image to be processed.

[0075] The first image column refers to the first image column in the image to be processed that contains a salient image. For example, it can be Figure 3 The leftmost image column where the salient image is located. The first salient image refers to the salient image in the first row of the first image column. The coordinate position of the first salient image can be pre-defined known information. By determining the coordinate position of the first salient image, a position reference can be provided for subsequent salient image matching.

[0076] Step a14, based on the coordinate position, the total number of image columns, the salient point size information and the expandable size information, determine the first to-be-matched area of ​​the target salient point image in the to-be-processed image.

[0077] The distribution of each salient point image can be clarified according to the total number of image columns. Then, when the image column where the target salient point image is located is clarified, the search space can be narrowed based on the coordinate position, salient point size information and expandable size information of the first salient point image, and unnecessary calculations can be reduced, so that the predicted area where the target salient point image may exist in the image to be processed can be more reasonably located, thereby obtaining a reliable first area to be matched.

[0078] By determining the first to-be-matched area of ​​the target salient point image in the image to be processed in the above manner, the reliability and accuracy of the determination of the first to-be-matched area can be guaranteed, and a reliable data basis can be provided for the subsequent determination of the first position information.

[0079] In some examples, the coordinate position includes the horizontal coordinate of the first salient point image; the expandable size information includes expandable width information and expandable height information; the salient point size information includes pixel width information; the above step a14 may include the following steps:

[0080] Step a141, determining the sequence value corresponding to the image column where the target salient point image is located;

[0081] Step a142, determining first horizontal coordinate information according to the horizontal coordinate of the first salient point image, the product of the sequence value and the preset height, and the expandable width information;

[0082] Step a143, determining the first ordinate information, and combining the first abscissa information, determining the first position coordinate information of the first to-be-matched area in the to-be-processed image;

[0083] Step a144, determining the area width information of the first to-be-matched area according to the pixel width information and the expandable width information;

[0084] Step a145, determining a first to-be-matched area of ​​the target salient point image in the image to be processed according to the first position coordinate information, the area width information and the preset height.

[0085] Specifically, to facilitate the distinction between the image columns, a sequence value is assigned to each image column from left to right, and then the sequence value corresponding to the image column where the target salient image is located can be determined. The sequence value is an integer starting from 1. The horizontal coordinate of the first salient image is used as the reference point of the starting position, and then the first horizontal coordinate of the target salient image is calculated in combination with the sequence value of the image column where the target salient image is located, and the preset height and expandable width information, which can help determine the horizontal position where the target salient image may appear.

[0086] The first ordinate information refers to the vertical position where the target salient point image may appear. In one example, the first ordinate information can be determined as the first row position in the corresponding coordinate system, so that the position information of the target salient point image can be quickly located, reducing the error when locating the target image.

[0087] According to the first horizontal coordinate information and the first vertical coordinate information, the first position coordinates that can characterize the position of the first to-be-matched area can be determined, and then the first position coordinate information of the first to-be-matched area in the image to be processed can be obtained.

[0088] Through the pixel width information and the expandable width information, it is possible to reasonably infer the area range that can cover the target salient image and does not affect the position determination of other salient images, and then the area width information of the first area to be matched that can reasonably search for the target salient image can be obtained. The height information of the first area to be matched is a preset height specified in advance, and then combined with the determined area width information, the size information of the first area to be matched can be obtained, so that combined with the determined first position coordinate information, the position of the first area to be matched in the image to be processed can be effectively located, so that the position information of the target salient image can be accurately identified later. In some examples, the selection range of the preset height can be between (pixel height plus one expandable height) and (pixel height plus two expandable heights), so that when searching for the target salient image, it can avoid covering all or part of the other salient images adjacent to the target salient image in the vertical direction, thereby improving the rationality of determining the first area to be matched.

[0089] In some examples, the image column corresponding to the target salient image may be a middle column among multiple image columns. If the total number of image columns of the multiple image columns is an odd number, the image column corresponding to the target salient image is the middle column among the multiple image columns. For example, if the total number of image columns of the multiple image columns is 7, the image column corresponding to the target salient image is image column 4. If the total number of image columns of the multiple image columns is an even number, the image column corresponding to the target salient image is one of the two middle columns among the multiple image columns. Whether to specifically select the middle column with a small sequence value as the image column corresponding to the target salient image or the middle column with a large sequence value as the image column corresponding to the target salient image can be determined according to demand. For example, if the total number of image columns of the multiple image columns is 8, the image column corresponding to the target salient image is 4 or 5. Whether to specifically select image column 4 as the middle column as the image column corresponding to the target salient image or to select image column 5 as the middle column as the image column corresponding to the target salient image can be determined according to demand.

[0090] In some optional implementation scenarios, the pixel width information of the salient image is BW and the expandable width information is EW, the horizontal coordinate of the first salient image is X, the image column corresponding to the target salient image is the middle column of the multiple image columns, and the total number of image columns of the multiple image columns is m. The determination process of the first area to be matched can be expressed by the following formula: The first horizontal coordinate Fx of the first area to be matched is X+ *H-EW, where is the rounding symbol. The first ordinate Fy=1 of the first area to be matched indicates the pixel starting row of the image to be processed. The area width information Fw=BW+2*EW of the first area to be matched. The preset height Fh=h. Combining the first position coordinate information, the area width information and the preset height, the following can be obtained: Figure 5 The first area to be matched is shown (the dotted box in the figure).

[0091] Step a2: in the first area to be matched, determine the first position information of the target salient point image by using the detection template corresponding to the target salient point image.

[0092] Since there is a one-to-one correspondence between the detection template and the image column, and the image column corresponding to the target salient point image is predetermined, when the first area to be matched is determined, the detection template corresponding to the target salient point image can be used in the first area to be matched to search for a pixel block that can match the detection template, and then the position of the pixel block that best matches the detection template is determined as the first position information of the target salient point image.

[0093] In some examples, the matching process of determining the target salient point image by detecting the template may be determined by image feature matching. For example, by gradient information matching, in the first area to be matched, according to the size information of the salient point image, pixel by pixel, it is determined whether the corresponding gradient information can match the gradient information of the detection template, and then the pixel block with the highest matching degree is selected as the pixel block corresponding to the target salient point image, and the position information of the pixel block is used as the first position information of the target salient point image, thereby improving the reliability of the first position information.

[0094] In other examples, if there are multiple pixel blocks whose gradient information matches the gradient information of the detection template most closely, then based on the matching results between the grayscale co-occurrence matrix of the detection module and the corresponding grayscale co-occurrence matrices of the multiple pixel blocks whose gradient information matches the detection template most closely, the pixel block with the highest matching degree with the grayscale co-occurrence matrix of the detection module is used as the pixel block corresponding to the target salient point image, and the position information of the pixel block is used as the first position information of the target salient point image, thereby improving the accuracy of the first position information.

[0095] Step a3: Based on the first position information and the salient point layout information, candidate position information corresponding to each salient point image is determined respectively.

[0096] When the first position information is clear, the possible position of each salient point image in the image to be processed can be predicted respectively through the local information of the salient points, and then the candidate position information corresponding to each salient point image can be obtained.

[0097] In some examples, the above step a3 may include the following steps:

[0098] Step a31, determining horizontal spacing information and vertical spacing information between two adjacent salient point images according to the salient point layout information;

[0099] Step a32, based on the first position information, the total number of image columns, the salient point size information, the horizontal spacing information and the vertical spacing information, respectively determine the candidate position information corresponding to each salient point image.

[0100] Specifically, the horizontal spacing information refers to the spacing distance between two adjacent salient point images in the horizontal direction. The vertical spacing information refers to the distance between two adjacent salient point images in the vertical direction. Through the horizontal spacing information and the vertical spacing information, the arrangement pattern of the salient point images in the image to be processed can be understood.

[0101] The total number of image columns can be used to determine the number of columns in which the salient point images are expected to be arranged in the image to be processed. The salient point size information can be used to determine the width and height of the salient point images. When the first position information is clear, the position of each salient point image in the image to be processed can be predicted in a targeted manner by combining the total number of image columns, the salient point size information, the horizontal spacing information, and the vertical spacing information, thereby obtaining the candidate position of each salient point image.

[0102] For example, if the image column corresponding to the target salient point image is the middle column, the candidate positions of two adjacent salient point images in the horizontal direction of the target salient point image can be determined respectively according to the first position information, the salient point size information and the horizontal spacing information, and then the candidate positions of each row of salient point images can be determined column by column according to the first position information, the total number of image columns, the salient point size information, the horizontal spacing information and the vertical spacing information. Alternatively, the candidate positions of all salient point images in the image column corresponding to the target salient point image can be determined first according to the first position information, the salient point size information and the vertical spacing information, and then the candidate positions of each salient point image in other image columns can be determined respectively in combination with the first position information, the total number of image columns, the salient point size information and the horizontal spacing information.

[0103] Step a4: Based on the image size information, the salient point layout information and the candidate position information corresponding to each salient point image, determine the second to-be-matched area corresponding to each salient point image.

[0104] The second candidate position information belongs to estimated position information, and through the second candidate position information, it can be determined that a salient point image may exist at the position.

[0105] In order to improve the effectiveness of the salient point image position information, the image size information and the salient point layout information are combined to determine the second area to be matched corresponding to each candidate position information, so as to further refine the candidate position information and narrow the search range. Then, reliable salient point images can be searched from each second area to be matched, which can reduce mismatches and improve the detection accuracy of salient point images, thereby helping to improve the efficiency of determining position information.

[0106] In some examples, the candidate position information includes candidate abscissa information and candidate ordinate information; the salient point size information also includes pixel height information; the image size information includes image width information and image height information; the above step a4 may include the following steps:

[0107] Step a41, determining the area size information of the second area to be matched corresponding to the salient point image according to the salient point size information and the expandable size information;

[0108] Step a42, determining second horizontal coordinate information of the second to-be-matched area based on a first difference between the candidate horizontal coordinate information and the pixel width information and a second difference between the image width information and the pixel width information;

[0109] Step a43, determining the second ordinate information of the second to-be-matched area based on the third difference between the candidate ordinate information and the pixel height information and the fourth difference between the image height information and the pixel height information;

[0110] Step a44, determining that the salient point image corresponds to the second area to be matched according to the area size information, the second horizontal coordinate information and the second vertical coordinate information of the second area to be matched.

[0111] Specifically, in order to obtain reliable initial position information of the salient point image and reduce unnecessary matching calculations, the area width and area height suitable for searching the corresponding salient point image are determined according to the salient point size information and the expandable size information, and then the area size information of the second area to be matched corresponding to the salient point image is obtained. In one example, the area width of the second area to be matched in the area size information can be the sum of the pixel width plus the two expandable widths, and the area height of the second area to be matched in the area size information can be the sum of the pixel height plus the two expandable heights, so that the area of ​​the second area to be matched can cover various possible deformations or offsets of the salient point image.

[0112] In order to make the position positioning of the second area to be matched more reasonable and have a one-to-one correspondence with the salient image, the second abscissa information of the second area to be matched is determined based on the first difference between the candidate abscissa information and the pixel width information and the second difference between the image width information and the pixel width information, thereby improving the accuracy of the second abscissa, so that the position of the second abscissa meets the width requirement of the salient image, but does not exceed the width of the image to be processed, and there is no partial overlap with other second areas to be matched. For example, the determination process of the second abscissa information Ax can be expressed by the following formula: Ax=min(max(1,cx-EW),IW-EW). Among them, (cx-EW) represents the first difference between the candidate horizontal coordinate information and the pixel width information, (IW-EW) represents the second difference between the image width information and the pixel width information, max(1,cx-EW) represents the maximum value between 1 and the first difference, and Ax represents the minimum value between max(1,cx-EW) and the second difference. When the candidate position of the current salient image is adjacent to the image edge side in the horizontal direction of the image to be processed, the corresponding second to-be-matched area will not exceed the image edge side in the horizontal direction of the image to be processed. Among them, the unit corresponding to each value in the second horizontal coordinate information Ax is pixel.

[0113] Similarly, in order to make the position positioning of the second area to be matched more reasonable and have a one-to-one correspondence with the salient point image, the fourth ordinate information of the fourth area to be matched is determined based on the third difference between the candidate ordinate information and the pixel width information and the fourth difference between the image width information and the pixel height information, thereby improving the accuracy of the fourth ordinate, so that the position of the fourth ordinate meets the height requirement of the salient point image, but does not exceed the height of the image to be processed, and there is no partial overlap with other fourth areas to be matched. For example, the determination process of the fourth ordinate information Ay can be expressed by the following formula: Ay=min(max(1,cy-EH),IH-EH). Among them, (cy-EH) represents the third difference between the candidate ordinate information and the pixel height information, (IH-EH) represents the fourth difference between the image height information and the pixel height information, max(1,cy-EH) represents the maximum value between 1 and the third difference, Ay represents the minimum value between max(1,cy-EH) and the fourth difference, and then when the candidate position of the current salient image is adjacent to the edge side of the image to be processed in the vertical direction, the corresponding fourth to-be-matched area will not exceed the image edge side in the vertical direction of the image to be processed. Among them, the unit corresponding to each value in the fourth ordinate information Ay is pixel.

[0114] By combining the area size information, the second horizontal coordinate information and the second vertical coordinate information, the second to-be-matched area corresponding to the salient point image can be accurately defined, and then the initial position information of the corresponding salient point image can be subsequently determined, which can provide a reliable basis for position determination.

[0115] In some optional implementation scenarios, such as Figure 6 As shown in FIG. 1 , the second to-be-matched region is represented by a frame with relatively thin lines, and the distribution of multiple second to-be-matched regions in the image to be processed can be as follows: Figure 6 This is shown in the distribution of the boxes with relatively thin lines in the middle.

[0116] Step a5: Based on the detection template corresponding to the image column where each salient point image is located, determine the initial position information of each salient point image in the image to be processed from the corresponding second area to be matched.

[0117] In the present disclosure, the implementation process of determining the initial position information of the salient point image in each second area to be matched is the same. Therefore, for ease of understanding, the following will take one of the second areas to be matched as an example to illustrate the process of determining the initial position information of the corresponding salient point image therein.

[0118] The second area to be matched is a pixel area whose pixel area is larger than the salient point image. In order to determine the position of the salient point image in the second area to be matched, a detection template for image detection is determined according to the image column corresponding to the salient point image contained in the second area to be matched, and then the detection template is used to search for pixel blocks matching the salient point image in the second area to be matched, so that the position information of the matched pixel blocks corresponding to the image to be processed is used as the initial position information of the corresponding salient point image, so as to improve the accuracy of the initial position information.

[0119] In some examples, step a5 above may include the following steps:

[0120] Step a51, extracting a plurality of candidate images that meet the salient point size information from the second area to be matched according to the salient point size information of the salient point image in the salient point layout information and the specified step size.

[0121] The second area to be matched is a local image that is relatively larger than the salient point image, so there are interference pixels in the second area to be matched. In order to improve the search efficiency, a dynamic matching method is adopted. In the second area to be matched, according to a preset specified step size, pixel blocks whose area size can match the salient point size information of the salient point image in the salient point layout information are extracted, and then multiple candidate images that meet the salient point size information are obtained.

[0122] Step a52, determining the reference gradient information of the target detection template and the gradient information of each candidate image.

[0123] In order to determine which of the multiple candidate images is the desired salient point image, image screening is performed by gradient information matching. The target detection template is a detection template of the salient point image corresponding to the second to-be-matched area. The gradient information of the target detection template is used as reference gradient information, so that the brightness distribution corresponding to the salient point image can be determined through the reference gradient information, and then when screening multiple candidate images, the pertinence of the screening can be improved.

[0124] Step a53, matching the multiple gradient information with the reference gradient information respectively, and determining the target candidate image with the highest similarity to the target detection template among the multiple candidate images.

[0125] The gradient information of each candidate image is matched with the reference gradient information to determine the reference gradient information with the highest matching degree with the target reference gradient information. The higher the matching degree between the two gradient information, the closer the two images are. The matching degree between the two gradient information can be calculated in a variety of ways, such as using cross-correlation, normalized cross-correlation, square difference or similarity coefficient, etc., which can be selected according to needs.

[0126] The candidate image whose gradient information matches the target reference gradient information the most is taken as the target candidate image, which helps to improve the reliability of the determination of the initial position information. Among them, the candidate image whose gradient information matches the target reference gradient information the most is characterized as the candidate image that is most similar to the target detection template among multiple candidate images.

[0127] Step a54, based on the target candidate image, determining the initial position information of the salient point image in the image to be processed.

[0128] The position of the target candidate image in the image to be processed is used as the initial position of the salient point image in the image to be processed, thereby obtaining the initial position information of the salient point image in the image to be processed, wherein the initial position information may include but is not limited to the coordinate information and size information of the salient point image in the image to be processed.

[0129] In some optional implementation scenarios, such as Figure 6 As shown, according to the initial position information of each salient point image, the distribution of each salient point image in the corresponding second area to be matched can be shown as the solid line frame in the figure.

[0130] In some other examples, the above step a54 may include the following steps:

[0131] Step a541, if the number of target candidate images is unique, the position information of the target candidate images in the image to be processed is used as the initial position information of the salient point images in the image to be processed;

[0132] Step a542, if there are multiple target candidate images, then determine the gray level co-occurrence matrix of each target candidate image and the reference gray level co-occurrence matrix of the target detection template respectively; and

[0133] Step a543, determine the target grayscale co-occurrence matrix that has the highest matching degree with the reference grayscale co-occurrence matrix among multiple grayscale co-occurrence matrices, and use the position information of the target candidate image corresponding to the target grayscale co-occurrence matrix in the image to be processed as the initial position information of the salient point image in the image to be processed.

[0134] Specifically, if there is only one target candidate image that has the highest similarity to the target detection template, then this target candidate image is the only target candidate image.

[0135] If there are multiple target candidate images with high similarity to the target detection template, we need to further process them to determine the most appropriate salient point location. Therefore, we can select the image that best matches the target detection template from multiple target candidate images by matching the gray level co-occurrence matrix. The gray level co-occurrence matrix is ​​a statistical matrix that describes the spatial relationship between the gray levels of an image and can be used to measure the similarity of image textures.

[0136] The gray level co-occurrence matrix of each target candidate image and the gray level co-occurrence matrix corresponding to the target detection template are determined respectively. By comparing the similarity of each target gray level co-occurrence matrix with the reference gray level co-occurrence matrix, the target gray level co-occurrence matrix with the highest matching degree is found, and the position information of the target candidate image corresponding to the target gray level co-occurrence matrix with the highest matching degree in the image to be processed is used as the initial position information of the salient point image in the image to be processed, thereby effectively reducing the occurrence of misidentification and helping to improve the accuracy of determining the salient point image position information.

[0137] Step S232, based on the initial position information of the adjacent multiple salient point images and the salient point layout information, respectively correct the initial position information of each salient point image, and determine the target position information of each salient point image in the image to be processed.

[0138] Since the initial position information of the salient point image is the initial result estimated based on the overall distribution, there may be misidentification in the process of determining the initial position information, resulting in abnormal initial position information of one or more salient point images. Figure 7 The abnormal initial position information is shown.

[0139] Therefore, in order to improve the reliability of the determination of the position information of each convex point image, the initial position information of the convex point image is combined with the initial position information of multiple convex point images adjacent to the convex point image and the convex point layout information to determine whether the initial position information of each convex point image conforms to the distribution of the corresponding convex points on the conveyor belt. When it is determined that the initial position information of the convex point image is abnormal, the initial position information of the convex point image is corrected in a targeted manner to obtain the target position information of the convex point image in the image to be processed, thereby improving the positioning reliability and accuracy of the convex point image, so that when the material is subsequently identified, the interference of the convex point image in the material identification process can be reduced, and the identification performance of the material sorting equipment can be improved.

[0140] In some embodiments, the initial position information includes initial horizontal coordinate information and initial vertical coordinate information of the salient point image, and the above step S232 may include the following steps:

[0141] Step b1, determining a horizontal difference between initial horizontal coordinate information of a salient point image and initial horizontal coordinate information of a first adjacent salient point image in a horizontal direction;

[0142] Step b2, determining a vertical difference between the initial ordinate information of the salient point image and the initial ordinate information of the second adjacent salient point image in the vertical direction;

[0143] Step b3, based on a first comparison result between the horizontal difference and a preset horizontal tolerance interval, and a second comparison result between the vertical difference and a preset vertical tolerance interval, correct the initial position information of the salient point image to obtain the target position information of the salient point image.

[0144] Specifically, in order to improve the recognition accuracy of salient point images, based on the relative position relationship between each salient point image and the adjacent salient point images, it is detected whether the initial position information of each salient point image is reliable information, so that when a salient point image with a positional abnormality is detected, its initial position information can be corrected in a targeted manner to obtain corresponding reliable target position information.

[0145] In order to determine whether the initial position of the salient image in the horizontal direction is reliable, the horizontal difference between the initial horizontal coordinate information of the salient image and the initial horizontal coordinate information of the first adjacent salient image in the horizontal direction is determined, so as to characterize the relative position difference between the salient image and the first adjacent salient image in the horizontal direction through the horizontal difference. Wherein, if the image column where the salient image is located is adjacent to the image edge sides on the left and right sides of the image to be processed, the number of the first adjacent salient image is one. For example, if the image column where the salient image is located is adjacent to the left side of the image edge of the image to be processed, the first adjacent salient image is the next salient image of the salient image in the horizontal direction. If the image column where the salient image is located is adjacent to the right side of the image edge of the image to be processed, the first adjacent salient image is the previous salient image of the salient image in the horizontal direction. If the image column where the salient image is located is any middle column among multiple image columns, the number of the first adjacent salient images is two, which are the previous salient image and the next salient image of the salient image in the horizontal direction.

[0146] Based on a principle similar to that of determining the horizontal difference, the vertical difference between the initial ordinate information of the salient point image and the initial ordinate information of the second adjacent salient point image in the vertical direction is determined. The vertical difference can be used to characterize the relative position difference between the salient point image and the second adjacent salient point image in the vertical direction.

[0147] The horizontal tolerance interval is a pre-set allowable range, indicating the acceptable deviation of the position of the convex image in the horizontal direction. The vertical tolerance interval is a pre-set allowable range, indicating the acceptable deviation of the position of the convex image in the vertical direction.

[0148] The horizontal difference value is compared with the horizontal tolerance interval to determine whether the horizontal difference value is within an acceptable deviation range according to the first comparison result obtained. For example, if the first comparison result indicates that the horizontal difference value is within the horizontal tolerance interval, then the relative position difference between the salient point image and the first adjacent salient point image in the horizontal direction is acceptable. If the first comparison result indicates that the horizontal difference value is not within the horizontal tolerance interval, then the relative position difference between the salient point image and the first adjacent salient point image in the horizontal direction is unacceptable, and it is necessary to perform targeted correction on the position of the salient point image in the horizontal direction, thereby obtaining the target position information of the salient point image. In one example, the horizontal tolerance interval can be [horizontal interval-tolerance threshold, horizontal interval+tolerance threshold], thereby improving the robustness of position determination, reducing the occurrence of misidentification, and thereby improving the flexibility of position information correction.

[0149] Similarly, the vertical difference is compared with the vertical tolerance interval to determine whether the vertical difference is within an acceptable deviation range based on the second comparison result obtained. For example, if the second comparison result indicates that the vertical difference is within the vertical tolerance interval, then the relative position difference between the salient point image and the second adjacent salient point image in the vertical direction is acceptable. If the second comparison result indicates that the vertical difference is not within the vertical tolerance interval, then the relative position difference between the salient point image and the second adjacent salient point image in the vertical direction is unacceptable, and it is necessary to perform targeted correction on the position of the salient point image in the vertical direction, thereby obtaining the target position information of the salient point image. In one example, the vertical tolerance interval can be [vertical interval-tolerance threshold, vertical interval+tolerance threshold], thereby improving the robustness of position determination, reducing the occurrence of misidentification, and thereby improving the flexibility of position information correction.

[0150] In some examples, the above step b3 may include the following steps:

[0151] Step b31, if the first comparison result indicates that the horizontal difference is not within the horizontal tolerance interval, adjusting the initial horizontal coordinate information of the salient point image based on the initial horizontal coordinate information of the first adjacent salient point image and the horizontal interval information between two adjacent salient point images in the salient point layout information to obtain corrected initial horizontal coordinate information;

[0152] Step b32: if the second comparison result indicates that the vertical difference is not within the vertical tolerance interval, adjusting the initial vertical coordinate information of the salient point image based on the initial vertical coordinate information of the second adjacent salient point image and the vertical interval information between two adjacent salient point images in the salient point layout information to obtain corrected initial vertical coordinate information;

[0153] Step b33: if the first comparison result indicates that the horizontal difference is within the horizontal tolerance interval, and the second comparison result indicates that the vertical difference is within the vertical tolerance interval, then the initial position information of the salient point image is determined as the target position information of the salient point image.

[0154] Specifically, if the first comparison result indicates that the horizontal difference is not within the horizontal tolerance interval, then the relative position difference between the salient image and the first adjacent salient image in the horizontal direction is unacceptable, and the position of the salient image in the horizontal direction needs to be specifically corrected, and then the initial horizontal coordinate information of the salient image is specifically adjusted using the initial horizontal coordinate information and the horizontal interval information of the first adjacent salient image, so that the horizontal difference between the corrected initial horizontal coordinate information and the initial horizontal coordinate information of the first adjacent salient image in the horizontal direction is within the horizontal tolerance interval. In one example, if the number of the first adjacent salient images is one, the initial horizontal coordinate information of the salient image after correction is determined according to the initial horizontal coordinate information of the first adjacent salient image, the relative position relationship between the first adjacent salient image and the salient image in the horizontal direction, and the horizontal interval. For example, if the initial horizontal coordinate information of the first adjacent salient image is x, the first adjacent salient image is the next salient image of the salient image in the horizontal direction, and the horizontal interval is v, then the initial horizontal coordinate information of the salient image after correction is (xv). If the initial horizontal coordinate information of the first adjacent salient point image is x, the first adjacent salient point image is the previous salient point image in the horizontal direction, and the horizontal interval is v, then the initial horizontal coordinate information of the salient point image after correction is (x+v). In another example, if the number of the first adjacent salient point images is two, the initial horizontal coordinate information of the salient point image after correction is determined according to the initial horizontal coordinate information, pixel width, and horizontal interval of the first adjacent salient point images on the left and right sides in the horizontal direction.

[0155] If the second comparison result indicates that the vertical difference is not within the vertical tolerance interval, it indicates that the relative position difference between the salient image and the second adjacent salient image in the vertical direction is unacceptable, and the position of the salient image in the vertical direction needs to be specifically corrected, and then the initial ordinate information of the salient image and the vertical interval information of the second adjacent salient image are used to specifically adjust the initial ordinate information of the salient image, so that the vertical difference between the corrected initial ordinate information and the initial ordinate information of the second adjacent salient image in the vertical direction is within the vertical tolerance interval. In one example, if the number of the second adjacent salient images is one, the initial ordinate information of the salient image after correction is determined according to the initial ordinate information of the second adjacent salient image, the relative position relationship between the second adjacent salient image and the salient image in the vertical direction, and the vertical interval. For example, if the initial ordinate information of the second adjacent salient image is y, the second adjacent salient image is the next salient image of the salient image in the vertical direction, and the vertical interval is v, then the initial ordinate information of the salient image after correction is (yv). If the initial ordinate information of the second adjacent salient point image is y, the second adjacent salient point image is the previous salient point image in the vertical direction, and the vertical interval is v, then the initial ordinate information of the salient point image after correction is (y+v). In another example, if the number of the second adjacent salient point images is two, the initial ordinate information of the salient point image after correction is determined according to the initial ordinate information, pixel height, and vertical interval of the second adjacent salient point images on the left and right sides in the vertical direction.

[0156] If the first comparison result indicates that the horizontal difference is within the horizontal tolerance interval, and the second comparison result indicates that the vertical difference is within the vertical tolerance interval, then the initial position information representing the salient point image is valid position information and does not need to be corrected, and can be directly used as the target position information of the salient point image.

[0157] By determining the target position information of each salient point image in the above manner, the robustness and accuracy of the position information determination can be improved, so that when the material is subsequently identified, the interference of the salient point image can be effectively eliminated, thereby improving the performance of material identification.

[0158] In some embodiments, the process of updating the first contour information may include: if there is target position information that partially overlaps with the first contour information, then the contour information in the first contour information that overlaps with the target position information is removed to obtain the target contour information of the material. Through the matching results of the first contour information and multiple target position information, it can be determined whether there is a situation in which the convex point image is mistakenly regarded as part of the material during the process of identifying the material contour. If it is determined based on the matching results that there is target position information that partially overlaps with the first contour information, then the contour information in the first contour information that overlaps with the target position information is removed to reduce image noise and eliminate the influence of the convex point image on material identification, thereby obtaining target contour information that can better fit the actual contour of the material and improve the accuracy of the target contour information. For example, the first contour information of the material obtained is as follows: Figure 8 When it is determined that there is target position information partially overlapping with the first contour information, the contour information corresponding to the target position information in the first contour information is removed, and the target contour information obtained can be as follows: Fig. 9 shown.

[0159] In other embodiments, if there are multiple first contour information and there is first contour information that partially overlaps with the target position information, the first contour information is discarded to avoid the influence of the existence of the first contour information on material identification, thereby simplifying the difficulty of material identification, and effectively improving the accuracy of material identification and ensuring the quality of material identification.

[0160] In some optional implementation scenarios, the process of identifying the material (plastic) currently transmitted by the material sorting device through the collected image to be processed can be as follows:

[0161] The convex point layout information of the convex point image in the image to be processed is pre-determined, which may include but is not limited to the following information: the pixel width and pixel height of the convex point image, the coordinate position of the first convex point image in the first image column in the image to be processed, and the horizontal interval and vertical interval between two adjacent convex point images. The preset height of the first area to be matched is pre-determined, and the expandable size information that expands outward based on the convex point position is determined. The expandable size information includes expandable width information and expandable height information.

[0162] According to the distribution of convex points on the conveyor belt and the total number of image columns of convex point images in the image to be processed, multiple detection templates are created. The detection templates correspond to the image columns of convex point images in the image to be processed one by one.

[0163] An image to be processed for plastic identification and image size information of the image to be processed are obtained.

[0164] Based on the image size information and the above-mentioned salient point layout information, the initial position information of each salient point image in the image to be processed is determined respectively through the detection templates of each column of salient point images, and based on the initial position information of multiple adjacent salient point images and the salient point layout information, the initial position information of each salient point image is corrected respectively, so as to determine the target position information of each salient point image in the image to be processed.

[0165] Determine the first contour information of the plastic in the image to be processed. The first contour information of the plastic in the image to be processed may be obtained through infrared image detection.

[0166] Based on the matching results of the first contour information and the multiple target position information, if there is Figure 8 The target position information partially overlaps with the first contour information as shown, then the contour information corresponding to the overlap with the target position information in the first contour information is removed, and the following is obtained: Fig. 9 Target profile information for the plastics shown.

[0167] The above-mentioned image recognition method can ensure the accuracy of the matching process by obtaining the pixel size and position information of the convex point image, using the template matching algorithm to achieve high-precision convex point positioning, and building a convex point detection template as a matching reference. In addition, by dynamically adjusting the area to be matched and the sliding step length for image matching, the precision and adaptability of the matching can be effectively improved, providing important support for subsequent image processing, plastic identification, position measurement and other applications.

[0168] Moreover, in the process of template matching, the present disclosure adopts preset matching parameters and dynamic adjustment strategies, which can reduce unnecessary matching calculations and improve matching efficiency. In particular, in the region-by-region convex point matching stage, image blocks consistent with the size of the convex points are extracted for matching to avoid the high cost of global search, and the sliding step size is set to speed up the matching speed, making the entire positioning process more efficient and fast. Moreover, in the matching process, the present disclosure can identify and correct erroneous matching results by setting a matching error detection and correction mechanism, thereby improving the reliability of positioning. In addition, in the case where the target object is adhered to the convex point, the target contour information and the convex point position information are used for adhesion processing, which effectively eliminates the interference of the adhesion convex point on target recognition. This error handling and adhesion processing capability has significant advantages in complex scenarios.

[0169] Based on the same inventive concept, the present disclosure also provides an image recognition device applied to material sorting equipment. Fig.10 As shown, the image recognition device 300 includes: a first acquisition module 310 , a second acquisition module 320 , a first processing module 330 , a second processing module 340 and an updating module 350 .

[0170] A first acquisition module 310 is used to acquire an image to be processed for material identification and image size information of the image to be processed, wherein the image to be processed includes a plurality of convex point images;

[0171] A second acquisition module 320 is used to acquire salient point detection templates and salient point layout information of multiple salient point images in the image to be processed;

[0172] The first processing module 330 is used to determine the target position information of each salient point image in the image to be processed by using a salient point detection template based on the image size information and the salient point layout information;

[0173] The second processing module 340 is used to determine the first contour information of the material in the image to be processed;

[0174] The updating module 350 is used to update the first profile information based on the matching result between the first profile information and the multiple target position information, and obtain the target profile information of the material, so as to identify the material through the target profile information.

[0175] In some embodiments, the first processing module 330 includes: a first processing unit, which is used to determine the initial position information of each salient point image in the image to be processed based on the image size information and the salient point layout information through the salient point detection template; and a second processing unit, which is used to correct the initial position information of each salient point image based on the initial position information of multiple adjacent salient point images and the salient point layout information, and determine the target position information of each salient point image in the image to be processed.

[0176] In some embodiments, the salient point detection template includes multiple detection templates, and the detection templates correspond one-to-one to the image columns of the salient point images in the image to be processed; the first processing unit includes: a first determination unit, which is used to determine the first to-be-matched area of ​​the target salient point image in the image to be processed based on the salient point layout information; a second determination unit, which is used to determine the first position information of the target salient point image in the first to-be-matched area through the detection template corresponding to the target salient point image; a third determination unit, which is used to determine the candidate position information corresponding to each salient point image based on the first position information and the salient point layout information; a fourth determination unit, which is used to determine the second to-be-matched area corresponding to each salient point image based on the image size information, the salient point layout information and the candidate position information corresponding to each salient point image; and a fifth determination unit, which is used to determine the initial position information of each salient point image in the image to be processed from the corresponding second to-be-matched area based on the detection template corresponding to the image column where each salient point image is located.

[0177] In some embodiments, the first determination unit includes: a quantity determination unit, used to determine the total number of image columns of salient point images in the image to be processed; a first information determination unit, used to determine the salient point size information and expandable size information of the salient point image based on the salient point layout information; a first position determination unit, used to determine the coordinate position of the first salient point image in the first image column in the image to be processed; and a first area determination unit, used to determine the first area to be matched of the target salient point image in the image to be processed based on the coordinate position, the total number of image columns, the salient point size information and the expandable size information.

[0178] In some embodiments, the coordinate position includes the horizontal coordinate of the first salient point image; the expandable size information includes expandable width information and expandable height information; the salient point size information includes pixel width information; the first area determination unit includes: a first execution unit, used to determine the sequence value corresponding to the image column where the target salient point image is located; a second execution unit, used to determine the first horizontal coordinate information according to the horizontal coordinate of the first salient point image, the product between the sequence value and the preset height, and the expandable width information; a third execution unit, used to determine the first vertical coordinate information, and determine the first position coordinate information of the first to-be-matched area in the to-be-processed image in combination with the first horizontal coordinate information; a fourth execution unit, used to determine the area width information of the first to-be-matched area according to the pixel width information and the expandable width information; a fifth execution unit, used to determine the first to-be-matched area of ​​the target salient point image in the to-be-processed image according to the first position coordinate information, the area width information and the preset height.

[0179] In some embodiments, the target salient point image is the first salient point image in the image column, and the image column where the target salient point image is located is a middle column of the plurality of image columns.

[0180] In some embodiments, the third determination unit includes: a second information determination unit, used to determine the horizontal spacing information and vertical spacing information between two adjacent salient point images according to the salient point layout information; a third information determination unit, used to determine the candidate position information corresponding to each salient point image based on the first position information, the total number of image columns, the salient point size information, the horizontal spacing information and the vertical spacing information.

[0181] In some embodiments, the candidate position information includes candidate horizontal coordinate information and candidate vertical coordinate information; the salient point size information also includes pixel height information; the image size information includes image width information and image height information; the fourth determination unit includes: a sixth execution unit, used to determine the area size information of the second area to be matched corresponding to the salient point image based on the salient point size information and the expandable size information; a seventh execution unit, used to determine the second horizontal coordinate information of the second area to be matched based on the first difference between the candidate horizontal coordinate information and the pixel width information and the second difference between the image width information and the pixel width information; an eighth execution unit, used to determine the second vertical coordinate information of the second area to be matched based on the third difference between the candidate vertical coordinate information and the pixel height information and the fourth difference between the image height information and the pixel height information; a ninth execution unit, used to determine the second area to be matched corresponding to the salient point image based on the area size information, the second horizontal coordinate information and the second vertical coordinate information of the second area to be matched.

[0182] In some embodiments, the fifth determination unit includes: a screening unit, which is used to extract multiple candidate images that meet the salient point size information from the second area to be matched according to the salient point size information of the salient point image in the salient point layout information and the specified step size; a fourth information determination unit, which is used to determine the reference gradient information of the target detection template and the gradient information of each of the candidate images, and the target detection template is the detection template of the salient point image corresponding to the second area to be matched; an information matching unit, which is used to match the multiple gradient information with the reference gradient information respectively, and determine the target candidate image with the highest similarity to the target detection template among the multiple candidate images; a fifth information determination unit, which is used to determine the initial position information of the salient point image in the image to be processed based on the target candidate image.

[0183] In some embodiments, the fifth information determination unit includes: a first information determination subunit, which is used to use the position information of the target candidate image in the image to be processed as the initial position information of the salient point image in the image to be processed if the number of target candidate images is unique; a second information determination subunit, which is used to determine the grayscale co-occurrence matrix of each target candidate image and the reference grayscale co-occurrence matrix of the target detection template respectively if the number of target candidate images is multiple; an image matching unit, which is used to determine the target grayscale co-occurrence matrix with the highest matching degree with the reference grayscale co-occurrence matrix among multiple grayscale co-occurrence matrices, and use the position information of the target candidate image in the image to be processed corresponding to the target grayscale co-occurrence matrix as the initial position information of the salient point image in the image to be processed.

[0184] In some embodiments, the initial position information includes initial horizontal coordinate information and initial vertical coordinate information of the salient point image; the second processing unit includes: a sixth information determination unit, used to determine the horizontal difference between the initial horizontal coordinate information of the salient point image and the initial horizontal coordinate information of the first adjacent salient point image in the horizontal direction; a seventh information determination unit, used to determine the vertical difference between the initial vertical coordinate information of the salient point image and the initial vertical coordinate information of the second adjacent salient point image in the vertical direction; a correction unit, used to correct the initial position information of the salient point image based on a first comparison result of the horizontal difference and a preset horizontal tolerance interval, and a second comparison result of the vertical difference and a preset vertical tolerance interval, so as to obtain the target position information of the salient point image.

[0185] In some embodiments, the correction unit includes: a first correction processing unit, which is used to adjust the initial horizontal coordinate information of the salient point image based on the initial horizontal coordinate information of the first adjacent salient point image and the horizontal spacing information between the two adjacent salient point images in the salient point layout information to obtain the corrected initial horizontal coordinate information if the first comparison result indicates that the horizontal difference value is not within the horizontal tolerance interval; a second correction processing unit, which is used to adjust the initial vertical coordinate information of the salient point image based on the initial vertical coordinate information of the second adjacent salient point image and the vertical spacing information between the two adjacent salient point images in the salient point layout information to obtain the corrected initial vertical coordinate information if the second comparison result indicates that the vertical difference value is not within the vertical tolerance interval; and a third correction processing unit, which is used to determine that the initial position information of the salient point image is the target position information of the salient point image if the first comparison result indicates that the horizontal difference value is within the horizontal tolerance interval and the second comparison result indicates that the vertical difference value is within the vertical tolerance interval.

[0186] In some embodiments, the updating module 350 includes: an updating submodule for removing the contour information corresponding to the overlapping target position information in the first contour information if there is target position information partially overlapping with the first contour information, so as to obtain the target contour information of the material.

[0187] Regarding the image recognition device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0188] Based on the same inventive concept, Fig.11As shown, one embodiment of the present disclosure provides a material sorting device 400. The material sorting device 400 includes a memory 410, a processor 420, and an input / output (I / O) interface 430. The memory 410 is used to store instructions. The processor 420 is used to call the instructions stored in the memory 410 to execute the image recognition method of the embodiment of the present disclosure. The processor 420 is connected to the memory 410 and the I / O interface 430, respectively, for example, through a bus system and / or other forms of connection mechanisms (not shown). The memory 410 can be used to store programs and data, including the program of the image segmentation method involved in the embodiment of the present disclosure. The processor 420 executes various functional applications and data processing of the material sorting device 400 by running the program stored in the memory 410.

[0189] In the embodiment of the present disclosure, the processor 420 can be implemented in at least one hardware form of a digital signal processor (Digital Signal Processing, DSP), a field programmable gate array (Field-Programmable Gate Array, FPGA), and a programmable logic array (Programmable Logic Array, PLA). The processor 420 can be a central processing unit (Central Processing Unit, CPU) or one or a combination of other forms of processing units with data processing capabilities and / or instruction execution capabilities.

[0190] The memory 410 in the embodiment of the present disclosure may include one or more computer program products, and the computer program product may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and / or cache memory. Non-volatile memory may include, for example, read-only memory (ROM), flash memory, hard disk drive (HDD) or solid-state drive (SSD).

[0191] In the embodiment of the present disclosure, the I / O interface 430 may be used to receive input instructions (such as digital or character information, and key signal input related to user settings and function control of the material sorting device 400, etc.), and may also output various information to the outside (such as images or sounds, etc.). In the embodiment of the present disclosure, the I / O interface 430 may include one or more of a physical keyboard, a function key (such as a volume control key, a switch key, etc.), a mouse, a joystick, a trackball, a microphone, a speaker, and a touch panel.

[0192] Based on the same inventive concept, the present disclosure further provides a computer-readable storage medium, which stores the following program, and the program is used to execute the image recognition method of any of the aforementioned embodiments.

[0193] The present application uses specific words to describe the embodiments of the present application. For example, "one embodiment", "an embodiment", and / or "some embodiments" refer to a certain feature, structure or characteristic related to at least one embodiment of the present application. Therefore, it should be emphasized and noted that "one embodiment" or "an embodiment" or "an alternative embodiment" mentioned twice or multiple times in different positions in this specification does not necessarily refer to the same embodiment. In addition, some features, structures or characteristics in one or more embodiments of the present application can be appropriately combined.

[0194] In the context of this application, unless the context clearly indicates an exception, the words "a", "an", "a kind" and / or "the" do not refer to the singular, but may also include the plural. Generally speaking, the terms "include" and "comprise" only indicate the inclusion of the steps and elements that have been clearly identified, and these steps and elements do not constitute an exclusive list, and the method or device may also include other steps or elements.

[0195] Similarly, it should be noted that in order to simplify the description of the disclosure of this application and thus help understand one or more application embodiments, in the above description of the embodiments of this application, multiple features are sometimes merged into one embodiment, figure or description thereof. However, this disclosure method does not mean that the features required by the object of this application are more than the features mentioned in the request for protection. In fact, the features of the embodiment are less than all the features of the single embodiment disclosed above.

[0196] The basic concepts have been described above. Obviously, for those skilled in the art, the above disclosure is only for example and does not constitute a limitation of the present application. Although not explicitly stated herein, those skilled in the art may make various modifications, improvements and amendments to the present application. Such modifications, improvements and amendments are suggested in the present application, so such modifications, improvements and amendments still belong to the spirit and scope of the embodiments of the present application.

Claims

1. An image recognition method, characterized in that: Applied to material sorting equipment, the method comprises: Acquire an image to be processed for material identification and image size information of the image to be processed, wherein the image to be processed includes a plurality of convex point images; Acquire a salient point detection template and salient point layout information of a plurality of salient point images in the image to be processed; Based on the image size information and the salient point layout information, respectively determining target position information of each salient point image in the image to be processed by using the salient point detection template; Determining first contour information of the material in the image to be processed; Based on the matching result between the first profile information and the plurality of target position information, the first profile information is updated to obtain the target profile information of the material, so as to identify the material through the target profile information.

2. The image recognition method according to claim 1, characterized in that: The step of determining target position information of each salient point image in the image to be processed based on the image size information and the salient point layout information by using the salient point detection template comprises: Based on the image size information and the salient point layout information, respectively determine the initial position information of each salient point image in the image to be processed by using the salient point detection template; Based on the initial position information of the adjacent plurality of salient point images and the salient point layout information, the initial position information of each salient point image is corrected respectively, and the target position information of each salient point image in the image to be processed is determined.

3. The image recognition method according to claim 2, characterized in that: The salient point detection template includes a plurality of detection templates, and the detection templates correspond to image columns of the salient point images in the image to be processed one by one; and determining the initial position information of each salient point image in the image to be processed by the salient point detection template based on the image size information and the salient point layout information, respectively, including: Based on the salient point layout information, determining a first to-be-matched area of ​​a target salient point image in the to-be-processed image; In the first to-be-matched area, determining first position information of the target salient point image by using a detection template corresponding to the target salient point image; Based on the first position information and the salient point layout information, respectively determine candidate position information corresponding to each of the salient point images; Based on the image size information, the salient point layout information, and the candidate position information corresponding to each of the salient point images, respectively determine a second to-be-matched area corresponding to each of the salient point images; Based on the detection template corresponding to the image column where each salient point image is located, the initial position information of each salient point image in the image to be processed is determined from the corresponding second area to be matched.

4. The image recognition method according to claim 3, characterized in that: The step of determining a first to-be-matched area of ​​a target salient point image in the image to be processed based on the salient point layout information includes: Determine the total number of image columns of the salient point images in the image to be processed; Determining convex dot size information and expandable size information of the convex dot image according to the convex dot layout information; Determine the coordinate position of the first salient point image of the first image column in the image to be processed; Based on the coordinate position, the total number of image columns, the salient point size information, and the expandable size information, a first to-be-matched area of ​​the target salient point image in the to-be-processed image is determined.

5. The image recognition method according to claim 4, characterized in that: The coordinate position includes the horizontal coordinate of the first salient point image; the expandable size information includes expandable width information and expandable height information; the salient point size information includes pixel width information; and determining the first to-be-matched area of ​​the target salient point image in the to-be-processed image based on the coordinate position, the total number of image columns, the salient point size information, and the expandable size information, comprises: Determine the sequence value corresponding to the image column where the target salient point image is located; Determine first horizontal coordinate information according to the horizontal coordinate of the first salient point image, the product of the sequence value and the preset height, and the expandable width information; Determine first ordinate information, and determine first position coordinate information of the first to-be-matched area in the to-be-processed image in combination with the first abscissa information; Determining area width information of the first area to be matched according to the pixel width information and the expandable width information; According to the first position coordinate information, the area width information and the preset height, a first to-be-matched area of ​​the target salient point image in the to-be-processed image is determined.

6. The image recognition method according to claim 5, characterized in that: The target salient point image is the first salient point image in the image column, and the image column where the target salient point image is located is a middle column of the plurality of image columns.

7. The image recognition method according to claim 6, characterized in that: The determining, based on the first position information and the salient point layout information, candidate position information corresponding to each salient point image includes: Determine horizontal spacing information and vertical spacing information between two adjacent convex point images according to the convex point layout information; Based on the first position information, the total number of image columns, the salient point size information, the horizontal spacing information, and the vertical spacing information, candidate position information corresponding to each of the salient point images is determined respectively.

8. The image recognition method according to claim 7, characterized in that: The candidate position information includes candidate abscissa information and candidate ordinate information; the salient point size information also includes pixel height information; the image size information includes image width information and image height information; and based on the image size information, the salient point layout information and the candidate position information corresponding to each salient point image, determining the second to-be-matched area corresponding to each salient point image, respectively, includes: Determine, according to the salient point size information and the expandable size information, area size information of the salient point image corresponding to the second area to be matched; Determine second horizontal coordinate information of the second to-be-matched area based on a first difference between the candidate horizontal coordinate information and the pixel width information and a second difference between the image width information and the pixel width information; Determine second ordinate information of the second to-be-matched area based on a third difference between the candidate ordinate information and the pixel height information and a fourth difference between the image height information and the pixel height information; According to the area size information, the second horizontal coordinate information and the second vertical coordinate information of the second area to be matched, it is determined that the salient point image corresponds to the second area to be matched.

9. The image recognition method according to claim 3, characterized in that: The determining, based on the detection template corresponding to the image column where each salient point image is located, from the corresponding second to-be-matched area, initial position information of each salient point image in the image to be processed includes: Extracting, from the second to-be-matched area, a plurality of candidate images that meet the salient point size information according to the salient point size information of the salient point image in the salient point layout information and a specified step size; Determine reference gradient information of a target detection template and gradient information of each of the candidate images, wherein the target detection template is the detection template of the second area to be matched corresponding to the salient point image; Matching the plurality of gradient information with the reference gradient information respectively, and determining a target candidate image having the highest similarity with the target detection template among the plurality of candidate images; Based on the target candidate image, initial position information of the salient point image in the image to be processed is determined.

10. The image recognition method according to claim 9, characterized in that: The determining, based on the target candidate image, the initial position information of the salient point image in the image to be processed comprises: If the number of the target candidate images is unique, using the position information of the target candidate images in the image to be processed as the initial position information of the salient point images in the image to be processed; If there are multiple target candidate images, respectively determine the gray level co-occurrence matrix of each target candidate image and the reference gray level co-occurrence matrix of the target detection template; and Determine a target grayscale co-occurrence matrix that has the highest matching degree with the reference grayscale co-occurrence matrix among the multiple grayscale co-occurrence matrices, and use the position information of the target candidate image corresponding to the target grayscale co-occurrence matrix in the image to be processed as the initial position information of the salient point image in the image to be processed.

11. The image recognition method according to claim 2, characterized in that: The initial position information includes initial horizontal coordinate information and initial vertical coordinate information of the salient point image; based on the initial position information of the adjacent plurality of salient point images and the salient point layout information, respectively correcting the initial position information of each salient point image, and determining the target position information of each salient point image in the image to be processed, comprises: Determine a horizontal difference between the initial horizontal coordinate information of the salient point image and the initial horizontal coordinate information of a first adjacent salient point image in a horizontal direction; Determine a vertical difference between the initial ordinate information of the salient point image and the initial ordinate information of a second adjacent salient point image in a vertical direction; Based on a first comparison result between the horizontal difference and a preset horizontal tolerance interval, and a second comparison result between the vertical difference and a preset vertical tolerance interval, the initial position information of the salient point image is corrected to obtain the target position information of the salient point image.

12. The image recognition method according to claim 11, characterized in that: The method of correcting the initial position information of the salient point image based on a first comparison result between the horizontal difference value and a preset horizontal tolerance interval, and a second comparison result between the vertical difference value and the preset vertical tolerance interval, to obtain the target position information of the salient point image includes: If the first comparison result indicates that the horizontal difference is not within the horizontal tolerance interval, adjusting the initial horizontal coordinate information of the salient point image based on the initial horizontal coordinate information of the first adjacent salient point images and the horizontal interval information between two adjacent salient point images in the salient point layout information to obtain corrected initial horizontal coordinate information; If the second comparison result indicates that the vertical difference is not within the vertical tolerance interval, adjusting the initial vertical coordinate information of the salient point image based on the initial vertical coordinate information of the second adjacent salient point images and the vertical interval information between two adjacent salient point images in the salient point layout information to obtain corrected initial vertical coordinate information; If the first comparison result indicates that the horizontal difference is within the horizontal tolerance interval, and the second comparison result indicates that the vertical difference is within the vertical tolerance interval, the initial position information of the salient point image is determined to be the target position information of the salient point image.

13. The image recognition method according to claim 1, characterized in that: The updating of the first profile information based on the matching result between the first profile information and the plurality of target position information to obtain the target profile information of the material includes: If there is target position information partially overlapping with the first contour information, the contour information corresponding to and overlapping with the target position information in the first contour information is removed to obtain the target contour information of the material.

14. An image recognition device, characterized in that: Applied to material sorting equipment, the device comprises: A first acquisition module is used to acquire an image to be processed for material identification and image size information of the image to be processed, wherein the image to be processed includes a plurality of convex point images; A second acquisition module is used to acquire a salient point detection template and salient point layout information of a plurality of salient point images in the image to be processed; A first processing module, configured to determine target position information of each salient point image in the image to be processed respectively through the salient point detection template based on the image size information and the salient point layout information; A second processing module, used for determining first contour information of the material in the image to be processed; An updating module is used to update the first profile information based on the matching result between the first profile information and the plurality of target position information, so as to obtain the target profile information of the material, so as to identify the material through the target profile information.

15. A material sorting device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the image recognition method according to any one of claims 1 to 13 by executing the computer instructions.

16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores the following program, which is used to execute the image recognition method according to any one of claims 1 to 13.

Citation Information

Patent Citations

  • Material counting method and device based on image recognition

    CN115619775A

  • Method and device for segmenting ore based on ore image, and storage medium

    CN117576135A