A cabinet grouping method, device, computer equipment and medium

Through dual-perspective image acquisition and clustering methods, express lockers are grouped, which solves the problems of low grouping efficiency, high error rate and incomplete coverage in existing technologies, and achieves higher accuracy and more comprehensive advertising statistics.

CN114170492BActive Publication Date: 2025-09-16SHENZHEN HIVE BOX NETWORK TECH LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111452464.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-01
Publication Date
2025-09-16
Estimated Expiration
2041-12-01

AI Technical Summary

Technical Problem

In the existing technology, the express locker advertisement grouping method has problems such as low grouping efficiency, high error rate, high missed detection ratio and incomplete coverage, especially the manual inspection and monitoring image clustering grouping methods are lacking.

Method used

A dual-view image acquisition and clustering method is adopted. First, clustering is performed under the first view. Then, a second clustering is performed on the unclustered target cabinets under the second view. Finally, grouping is performed based on the two clustering results to improve grouping accuracy and coverage.

Benefits of technology

Through dual-view image acquisition and clustering, the accuracy and coverage of cabinet grouping have been significantly improved, the error rate and missed detection ratio have been reduced, and the accuracy and efficiency of advertising statistics have been improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114170492B_ABST
    Figure CN114170492B_ABST
Patent Text Reader

Abstract

Embodiments of the present invention disclose a cabinet grouping method, apparatus, computer device, and medium. The method includes: obtaining surface images of each cabinet collected from two viewing angles, and clustering each cabinet based on its first surface image from the first viewing angle to obtain a primary clustering result; if the primary clustering result indicates the presence of at least two unclustered target cabinets, clustering each target cabinet based on its second surface image from the second viewing angle to obtain a secondary clustering result; and grouping each cabinet based on the primary and secondary clustering results to obtain a cabinet grouping result. The technical solution of the embodiments of the present invention can efficiently and accurately perform cabinet grouping.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to computer data processing technology, and in particular to a cabinet grouping method, apparatus, computer equipment and medium. Background Art

[0002] Large outdoor paper advertisements can be placed on the surface of express lockers, generating economic benefits for both advertisers and locker companies. However, during daily operations, we've observed a significant number of illegal advertisements being posted or overdue for publication. This necessitates regular statistics on the number of lockers displaying the same advertisement. Specifically, we're counting the number of lockers displaying the same advertisement.

[0003] In the prior art, the above statistical process can be completed through manual on-site inspections or by clustering and grouping using the cabinet monitoring images of the express cabinet.

[0004] During the invention process, the inventors discovered that the existing technology has at least the following defects: the method of relying on manual on-site inspections has problems such as low grouping efficiency, high error rate, high missed detection rate and incomplete coverage; the method of relying on cabinet monitoring images for clustering and grouping, due to the limitations of the monitoring perspective, also has problems such as high grouping error rate, high missed detection rate and incomplete coverage. Summary of the Invention

[0005] The embodiments of the present invention provide a cabinet grouping method, apparatus, computer equipment, and medium to provide a new way of cabinet grouping, thereby improving the accuracy and coverage of cabinet grouping.

[0006] In a first aspect, an embodiment of the present invention provides a method for grouping cabinets, which includes:

[0007] Obtaining the body surface images of each cabinet collected under two viewing angles, and clustering each cabinet based on the first body surface image of each cabinet under the first viewing angle to obtain a clustering result;

[0008] If it is determined according to the primary clustering result that there are at least two unclustered target cabinets, performing secondary clustering on each target cabinet according to the second body surface image of each target cabinet at the second viewing angle and obtaining a secondary clustering result;

[0009] The cabinets are grouped according to the first clustering result and the second clustering result to obtain a cabinet grouping result.

[0010] Optionally, based on the first body surface image of each cabinet at the first perspective, each cabinet is clustered once and a clustering result is obtained, including: obtaining first image feature vectors corresponding to the first body surface images of each cabinet; calculating the similarity between any two obtained first image feature vectors, and based on the similarity calculation result, performing a first clustering on each cabinet and obtaining a first clustering result; based on the second body surface image of each target cabinet at the second perspective, each target cabinet is clustered twice and a secondary clustering result is obtained, including: obtaining second image feature vectors corresponding to the second body surface images of each target cabinet; calculating the similarity between any two obtained second image feature vectors, and based on the similarity calculation result, performing a second clustering on each target cabinet and obtaining a secondary clustering result.

[0011] Optionally, the cabinets are grouped according to the first clustering result and the second clustering result to obtain cabinet grouping results, including: if it is determined that the first clustering result includes at least one first cabinet clustering cluster, and the second clustering result includes at least one second cabinet clustering cluster, then the first cabinet clustering cluster and the second cabinet clustering cluster are clustered again to obtain cabinet grouping results corresponding to the cabinets.

[0012] Optionally, the first cabinet cluster and the second cabinet cluster are clustered again to obtain cabinet grouping results corresponding to each cabinet, including: calculating the first group mean vector corresponding to each first cabinet cluster according to the second image feature vector of the second body surface image of each first cabinet in the first cabinet cluster under the second perspective; calculating the second group mean vector corresponding to each second cabinet cluster according to the second image feature vector of the second body surface image of each second cabinet in the second cabinet cluster under the second perspective; calculating the similarity between each first group mean vector and each second group mean vector, and obtaining the cabinet grouping results corresponding to each cabinet based on the similarity calculation result.

[0013] Optionally, the cabinets are grouped according to the primary clustering result and the secondary clustering result to obtain a cabinet grouping result, including: if it is determined that the primary clustering result does not include any first cabinet cluster cluster, then the secondary clustering result is used as the cabinet grouping result corresponding to each cabinet.

[0014] Optionally, the cabinets are grouped according to the first clustering result and the second clustering result to obtain a cabinet grouping result, including: if it is determined that the first clustering result includes at least one first cabinet clustering cluster, and the second clustering result does not include any second cabinet clustering cluster, then the first clustering result is used as the cabinet grouping result corresponding to each cabinet.

[0015] Optionally, after clustering each cabinet once and obtaining a clustering result based on the first body surface image of each cabinet at the first perspective, it also includes: if it is determined according to the first clustering result that there are not at least two unclustered target cabinets, then the first clustering result is used as the cabinet grouping result corresponding to each cabinet.

[0016] In a second aspect, an embodiment of the present invention further provides a cabinet grouping device, the cabinet grouping device comprising:

[0017] A primary clustering module is used to obtain the body surface images of each cabinet collected under two viewing angles, and to cluster each cabinet based on the first body surface image of each cabinet under the first viewing angle to obtain a primary clustering result;

[0018] a secondary clustering module configured to, if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, perform secondary clustering on each target cabinet based on the second body surface image of each target cabinet at the second viewing angle and obtain a secondary clustering result;

[0019] The cabinet grouping result module is used to group the cabinets according to the first clustering result and the second clustering result to obtain a cabinet grouping result.

[0020] In a third aspect, an embodiment of the present invention further provides a computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the cabinet grouping method as described in any embodiment of the present invention is implemented.

[0021] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the cabinet grouping method as described in any embodiment of the present invention is implemented.

[0022] The technical solution provided by the embodiment of the present invention obtains the body surface images of each cabinet collected under two viewing angles, and clusters each cabinet once based on the first body surface image of each cabinet under the first viewing angle to obtain a primary clustering result; if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, then the target cabinets are secondary clustered based on the second body surface image of each target cabinet under the second viewing angle to obtain a secondary clustering result; based on the primary clustering result and the secondary clustering result, the cabinets are grouped to obtain a cabinet grouping result. The new grouping method of secondary clustering using the body surface images under two viewing angles solves the problems of high grouping error rate, high missed detection rate, and incomplete coverage existing in the prior art, and improves the accuracy and coverage of cabinet grouping. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 This is a flow chart of a cabinet grouping method provided in Example 1 of the present invention;

[0024] Figure 2 A flowchart of another cabinet grouping method provided in the second embodiment of the present invention;

[0025] Figure 3a This is a flowchart of another cabinet grouping method provided in Example 3 of the present invention;

[0026] Figure 3b A schematic diagram of the structure of each cabinet collecting a cabinet surface image in another cabinet grouping method provided in the third embodiment of the present invention;

[0027] Figure 3c A schematic diagram of a clustering result structure in another cabinet grouping method provided in the third embodiment of the present invention;

[0028] Figure 3d A schematic diagram of the secondary clustering result structure in another cabinet grouping method provided in the third embodiment of the present invention;

[0029] Figure 3e A schematic diagram of the structure of a right grouping feature vector in another cabinet grouping method provided in the third embodiment of the present invention;

[0030] Figure 3f A schematic diagram of the structure of grouping clustering results in another cabinet grouping method provided in the third embodiment of the present invention;

[0031] Figure 3g A schematic diagram illustrating the structure of each cabinet grouping in another cabinet grouping method provided in the third embodiment of the present invention;

[0032] Figure 4 This is a structural diagram of a cabinet grouping device provided by the fourth embodiment of the present invention;

[0033] Figure 5 This is a structural diagram of a computer device provided in Example 5 of the present invention. DETAILED DESCRIPTION

[0034] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention.

[0035] It should also be noted that, for ease of description, only the part relevant to the present invention, rather than all of the content, is shown in the accompanying drawings. Before discussing exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processing or methods depicted as flow charts. Although flow charts describe various operations (or steps) as sequential processing, many operations therein can be implemented in parallel, concurrently or simultaneously. In addition, the order of various operations can be rearranged. When its operation is completed, the processing can be terminated, but can also have additional steps not included in the accompanying drawings. The processing can correspond to methods, functions, procedures, subroutines, subprograms, etc.

[0036] The terms "first," "second," and so on, in the description, claims, and drawings of the embodiments of the present invention are used to distinguish between different items, not to describe a specific order. Furthermore, the terms "including," "having," and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or elements is not limited to the listed steps or elements and may include steps or elements that are not listed.

[0037] Example 1

[0038] Figure 1 This is a flow chart of a method for cabinet grouping provided in Example 1 of the present invention. This embodiment is applicable to grouping cabinets based on the correlation of cabinet surface images of express cabinets, and is particularly applicable to classifying and counting paper advertisements affixed to the cabinet surfaces. The method of this embodiment can be executed by a cabinet grouping device, which can be implemented in software and / or hardware and can be configured in a server or terminal device with data processing capabilities.

[0039] Accordingly, the method specifically includes the following steps:

[0040] S110 , obtaining the body surface images of each cabinet respectively collected under two viewing angles, and clustering each cabinet according to the first body surface image of each cabinet under the first viewing angle to obtain a clustering result.

[0041] The cabinet surface of each cabinet can be imaged from two viewing angles to obtain cabinet surface images from both viewing angles. Typically, a camera located on the right side of the cabinet can be used to capture the cabinet surface image from the right viewing angle, while another camera located on the left side of the cabinet can be used to capture another cabinet surface image from the left viewing angle. This overcomes the limitations of existing single-view image acquisition for image clustering.

[0042] The body surface image may include images of the body surfaces of various cabinets. Typically, a cabinet surface may have an advertising poster of a certain manufacturer attached to it, or may not have any advertising poster attached to it.

[0043] The first fuselage surface image can be collected by each cabinet at the same viewing angle (first viewing angle). The primary clustering can be performed after extracting image feature vectors from each first fuselage surface image at the first viewing angle, and then performing a cabinet clustering operation based on the correlation between different image feature vectors.

[0044] The primary clustering result may be a clustering result obtained by clustering the first body surface image of each cabinet at the first viewing angle. The primary clustering result may specifically include four situations: a first cabinet cluster consisting of clustered target cabinets; a first cabinet cluster and one unclustered target cabinet; a first cabinet cluster and at least two unclustered target cabinets; and a target cabinet in which all cabinets are unclustered.

[0045] For example, clustering is performed on each cabinet, and the clustering algorithm adopted here can be a common basic clustering algorithm K-means clustering, mean shift clustering, and density-based clustering method, etc. The present invention can use any basic clustering algorithm, which is not limited here.

[0046] S120: If it is determined according to the primary clustering result that there are at least two unclustered target lockers, perform secondary clustering on each target locker according to the second body surface image of each target locker at the second viewing angle and obtain a secondary clustering result.

[0047] The second fuselage surface image may be a fuselage surface image captured from a second perspective in the dual perspectives. The secondary clustering may be a clustering operation performed after extracting feature vectors from the second fuselage surface image from the second perspective.

[0048] The secondary clustering result may be a clustering result obtained by clustering the second cabinet surface image at the second viewing angle in which at least two target cabinets that were not clustered are determined to exist based on the primary clustering result. Specifically, the secondary clustering result may include four situations: a second cabinet cluster consisting of clustered target cabinets; a second cabinet cluster and one unclustered target cabinet; a second cabinet cluster and at least two unclustered target cabinets; and a target cabinet in which all cabinets are not clustered.

[0049] In this embodiment, after clustering the first body surface image of each cabinet at the first perspective, based on the first clustering result, if it is determined that there are at least two unclustered target cabinets, the second body surface image of each unclustered target cabinet at the second perspective can be clustered twice to obtain a secondary clustering result.

[0050] Specifically, after the first clustering, there may be at least two unclustered target cabinets, but this does not mean that the unclustered target cabinets do not belong to the same cluster. Therefore, it is necessary to collect a second body surface image of the unclustered target cabinets from a second viewing angle and perform a second clustering on them. This can make the clustering operation more comprehensive and accurate.

[0051] S130. Group the cabinets according to the first clustering result and the second clustering result to obtain a cabinet grouping result.

[0052] The cabinet grouping result may be a grouping result obtained by grouping the cabinets corresponding to the primary clustering result and the secondary clustering result.

[0053] Specifically, due to the primary and secondary clustering, we can obtain the first cabinet cluster in the primary clustering results and the second cabinet cluster in the secondary clustering results. Because the first cabinet cluster and the second cabinet cluster are fuselage surface images captured at different viewing angles, the first cabinet cluster and the second cabinet cluster can also belong to the same cluster. Therefore, it is necessary to group and cluster the cabinets corresponding to the first cabinet cluster and the second cabinet cluster to obtain the cabinet grouping results.

[0054] In this embodiment, the cabinet grouping results are obtained by clustering the first body surface image of each cabinet at the first perspective, and the secondary clustering results are obtained by clustering the second body surface image of each unclustered target cabinet in the first clustering result at the second perspective.

[0055] The technical solution provided by the embodiment of the present invention obtains the body surface images of each cabinet collected separately under two viewing angles, and clusters each cabinet once based on the first body surface image of each cabinet under the first viewing angle to obtain a primary clustering result; if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, then secondary clusters each target cabinet based on the second body surface image of each target cabinet under the second viewing angle to obtain a secondary clustering result; and based on the primary clustering result and the secondary clustering result, the cabinets are grouped to obtain cabinet grouping results. The new grouping method of secondary clustering using the body surface images under two viewing angles solves the problems of high grouping error rate, high missed detection ratio, and incomplete coverage in the prior art, and improves the accuracy and coverage of cabinet grouping.

[0056] Optionally, after clustering each cabinet based on the first body surface image of each cabinet at the first perspective and obtaining a clustering result, it also includes: if it is determined based on the clustering result that there are not at least two unclustered target cabinets, then the clustering result is used as the cabinet grouping result corresponding to each cabinet.

[0057] In this embodiment, after clustering the first body surface image of each cabinet at the first viewing angle, if it is determined that the clustering result does not contain at least two unclustered target cabinets, it can be determined that the cabinet grouping result is a clustering result.

[0058] This arrangement offers the advantage of determining that, after a single clustering operation, if there are no at least two unclustered target cabinets, the first cabinet surface images from the first viewing angle can be determined to be divided into multiple first cabinet clusters, or that there is one unclustered target cabinet. This allows the clustering results to be directly used as the cabinet grouping results, thereby improving the efficiency of statistically analyzing and classifying cabinet surface images.

[0059] Example 2

[0060] Figure 2 This is a flowchart of another cabinet grouping method provided by an embodiment of the present invention. This embodiment is based on and refines the above embodiments. Specifically, in this embodiment, the operations of clustering each cabinet once based on the first cabinet surface image at the first viewing angle and obtaining the first clustering result, and clustering each target cabinet twice based on the second cabinet surface image at the second viewing angle and obtaining the second clustering result, are refined.

[0061] Accordingly, the method of the embodiment of the present invention may specifically include:

[0062] S210: Obtaining the surface images of each cabinet collected from two viewing angles.

[0063] S220: Obtain first image feature vectors corresponding to the first body surface images of the respective cabinets.

[0064] The first image feature vector may be obtained by extracting feature vectors from the first body surface image of each cabinet. Each first body surface image corresponds to a first image feature vector, and the first image feature vector is a multi-dimensional space vector.

[0065] Exemplarily, the first image feature vector is extracted from the first body surface image of each cabinet, and a trained CNN (Convolutional Neural Networks) model can be used to extract image features. The CNN here includes various main structures and their variant models. Common main structures include but are not limited to VGG (Visual Geometry Group Network), ResNet (Residual Network), EfficientNet, etc. The present invention is not limited to the use of any suitable type of CNN model to extract features from the first body surface image of each cabinet.

[0066] S230: Calculate the similarity between any two acquired first image feature vectors, and cluster each cabinet based on the similarity calculation result to obtain a clustering result.

[0067] The similarity can be calculated by calculating the similarity between the two first image feature vectors. Specifically, common similarity calculation methods may be Euclidean distance or cosine similarity, and the similarity calculation method is not limited.

[0068] Specifically, the similarity between any two first image feature vectors obtained by calculating the similarity may be that the similarity needs to be calculated for every two first image feature vectors.

[0069] For example, the first image feature vector is extracted from the first body surface image of each cabinet.

[0070] Assume that the eigenvectors corresponding to the first fuselage surface images are The corresponding eigenvector is expressed as follows:

[0071]

[0072] Therefore, there are many ways to calculate the similarity between the two first image feature vectors. Here, the common Euclidean distance similarity calculation method is used. For example, it can be calculated by using the dot product formula of the Euclidean distance similarity, as shown in formula (2):

[0073]

[0074] The common cosine similarity calculation method is used, which is calculated by dot product and vector length, as shown in the following formula (3):

[0075]

[0076] Therefore, the present invention is not limited to using any suitable similarity calculation method.

[0077] The advantage of this arrangement is that by calculating the similarity between the first image feature vectors of each pair and clustering each cabinet based on the similarity calculation results, the first body surface images of each cabinet can be clustered more accurately and quickly, improving accuracy and work efficiency.

[0078] S240: Determine whether there are at least two unclustered target cabinets based on the first clustering result. If yes, execute S250; if not, execute S260.

[0079] S250 , obtaining second image feature vectors corresponding to the second body surface images of each target cabinet, and executing S270 .

[0080] The second image feature vector may be obtained by extracting feature vectors from the second body surface image of each cabinet. Each second body surface image corresponds to a second image feature vector, and the second image feature vector is a multi-dimensional space vector.

[0081] S260: Use the first clustering result as the cabinet grouping result corresponding to each cabinet.

[0082] S270: Calculate the similarity between any two acquired second image feature vectors, and perform secondary clustering on each target cabinet based on the similarity calculation result to obtain a secondary clustering result.

[0083] Specifically, the similarity between any two acquired second image feature vectors may be calculated by calculating the similarity between every two second image feature vectors and obtaining a secondary clustering result.

[0084] S280: Group the cabinets according to the first clustering result and the second clustering result to obtain a cabinet grouping result.

[0085] The technical solution provided by the embodiment of the present invention obtains the body surface images of each cabinet collected under dual viewing angles, obtains the first image feature vectors corresponding to the first body surface images of each cabinet; calculates the similarity between any two first image feature vectors, and clusters each cabinet once according to the similarity calculation result; if it is determined according to the first clustering result that there are at least two unclustered target cabinets, obtains the second image feature vectors corresponding to the second body surface images of each target cabinet; calculates the similarity between any two second image feature vectors, and clusters each target cabinet twice according to the similarity calculation result; and groups each cabinet according to the first clustering result and the second clustering result to obtain the cabinet grouping result. This solves the problem of classifying and counting paper advertisements on the cabinet surface, and achieves the improvement of the work efficiency, missed detection ratio and advertising coverage of counting and classifying body surface images, and the reduction of error rate.

[0086] Example 3

[0087] Figure 3a This is a flowchart of another cabinet grouping method provided by an embodiment of the present invention. This embodiment is based on the above embodiments and is refined. Specifically, in this embodiment, the cabinets are grouped according to the first clustering result and the second clustering result to obtain the cabinet grouping result.

[0088] Accordingly, the method of the embodiment of the present invention may specifically include:

[0089] S310: Obtain the body surface images of each cabinet collected under two viewing angles, and cluster each cabinet according to the first body surface image of each cabinet under the first viewing angle to obtain a clustering result.

[0090] S320: If it is determined according to the primary clustering result that there are at least two unclustered target lockers, perform secondary clustering on each target locker according to the second body surface image of each target locker at the second viewing angle and obtain a secondary clustering result.

[0091] S330: Determine whether the primary clustering result does not include any first cabinet cluster. If yes, execute S340; otherwise, execute S350.

[0092] The first cabinet cluster may be a first body surface image of each cabinet at the first viewing angle, and a corresponding cluster may be obtained by clustering once.

[0093] S340: Use the secondary clustering result as the cabinet grouping result corresponding to each cabinet.

[0094] S350: Determine whether the first clustering result includes at least one first cabinet cluster, and determine whether the second clustering result does not include any second cabinet cluster. If yes, execute S360; otherwise, execute S370.

[0095] The second cabinet cluster may be a corresponding cluster obtained by performing secondary clustering on the second body surface image of each cabinet at the second viewing angle.

[0096] S360: Use the first clustering result as the cabinet grouping result corresponding to each cabinet.

[0097] S370: Cluster the first cabinet cluster and the second cabinet cluster again to obtain cabinet grouping results corresponding to the cabinets.

[0098] Optionally, the first cabinet cluster and the second cabinet cluster are clustered again to obtain the cabinet grouping result, including: calculating the first group mean vector corresponding to each first cabinet cluster according to the second image feature vector of the second body surface image of each first cabinet in the first cabinet cluster under the second perspective; calculating the second group mean vector corresponding to each second cabinet cluster according to the second image feature vector of the second body surface image of each second cabinet in the second cabinet cluster under the second perspective; obtaining the cabinet grouping result according to the similarity between each first group mean vector and each second group mean vector, and according to the similarity calculation result.

[0099] The first group mean vector may be obtained by extracting a second image feature vector from the second body surface image of each first cabinet in the first cabinet cluster at the second viewing angle, and calculating a group mean vector for the extracted second image feature vector. The second group mean vector may be obtained by extracting a second image feature vector from the second body surface image of each second cabinet in the second cabinet cluster at the second viewing angle, and calculating a group mean vector for the extracted second image feature vector.

[0100] For example, assume that the first cabinet cluster contains m image feature vectors, which are Then the first group mean vector The calculation method of is shown in the following formula (4):

[0101]

[0102] Therefore, the first group mean vector corresponding to each first cabinet cluster and the second group mean vector corresponding to each second cabinet cluster can be calculated accordingly.

[0103] In this embodiment, by calculating the first group mean vector corresponding to each first cabinet cluster and the second group mean vector corresponding to each second cabinet cluster, and further calculating the similarity between each first group mean vector and each second group mean vector, the cabinet grouping results are obtained based on the similarity calculation results. This allows the fuselage surface images from the first and second perspectives to be clustered again, thereby improving the accuracy of classification and statistics.

[0104] The technical solution provided by the embodiment of the present invention obtains the body surface images of each cabinet collected under two viewing angles, and clusters each cabinet based on the first body surface image of each cabinet under the first viewing angle. If the result of the first clustering determines that there are at least two unclustered target cabinets, the target cabinets are clustered again based on the second body surface image of each target cabinet under the second viewing angle. Depending on whether the first clustering result includes the first cabinet cluster and the second clustering result includes the second cabinet cluster, corresponding operations are performed to obtain the corresponding cabinet grouping results. This solves the problem of classifying and counting paper advertisements on the cabinet surfaces, and improves the work efficiency, missed detection rate, and accuracy of counting and classifying the cabinet surface images.

[0105] Specific application scenarios

[0106] Assume that each cabinet collects body surface images under dual viewing angles, and collects body surface images of multiple cabinets. Here we take the collection of body surface images of 14 cabinets as an example. The first body surface image of each cabinet under the first viewing angle is the left image. The trained CNN model is used to extract image features. After one clustering, the first cabinet cluster is the left cluster, and the unclustered target cabinet is the left isolated point. Similarly, the second body surface image of each cabinet under the second viewing angle is the right image. After image feature extraction, after the second clustering, the second cabinet cluster is the right cluster, and the unclustered target cabinet is the right isolated point. The first group mean vector and each second group mean vector are the right group feature vectors. The specific steps are as follows:

[0107] 1) First, obtain the left and right images of each cabinet, and use the trained CNN model to perform feature extraction on the left and right images of all cabinets. Each image will obtain a feature vector of the same length. Figure 3b This is a schematic diagram of the structure for collecting the surface image of each cabinet, where the "left image" and "right image" can represent the image itself or the feature vector of the image.

[0108] 2) All left image feature vectors are clustered. The clustering results are divided into two categories: one is "clusters", which are cabinets with two or more similar left images; the other is "isolated points", which are cabinets without any similar left images. Figure 3c Figure 1 is a schematic diagram of the clustering result structure. Specifically, the left images corresponding to cabinets 1, 2, and 3 are cluster 1; the left images corresponding to cabinets 6 and 7 are cluster 2; the left images corresponding to cabinets 10, 11, and 12 are cluster 3; and the left images corresponding to cabinets 4, 5, 8, 9, 13, and 14 are isolated points 1, 2, 3, 4, 5, and 6, respectively.

[0109] 3) Perform secondary clustering on the right images corresponding to left isolated point 1, left isolated point 2, left isolated point 3, left isolated point 4, left isolated point 5 and left isolated point 6, and the secondary clustering results also have two types: "right cluster" and "right isolated point". Figure 3d Schematic diagram of the secondary clustering result structure. Specifically, the right images corresponding to cabinets 4 and 5 are right cluster 1; the right images corresponding to cabinets 8 and 9 are right cluster 2; and the right images corresponding to cabinets 13 and 14 are right isolated points 1 and 2, respectively.

[0110] 4) For each cabinet corresponding to the left cluster in the first clustering result, collect the right image corresponding to each cabinet and calculate the right group feature vector; for the right cluster in the second clustering result, calculate the right group feature vector. Figure 3e The figure shows a schematic diagram of the right grouping vector structure.

[0111] 5) According to the right grouping feature vector, group clustering is performed. The results also have two types: "cluster clusters" and "isolated points". The groups in the same "cluster cluster" are merged to obtain new groups, while the "isolated point" group remains unchanged, such as Figure 3f Specifically, cabinets 1, 2, 3, 4, and 5 form right group 1; cabinets 6 and 7 form right group 2; cabinets 8, 9, 10, 11, and 12 form right group 3; cabinet 13 forms right isolated point 1; and cabinet 14 forms right isolated point 2.

[0112] 6) If Figure 3g The following table shows the grouping of cabinets and the specific cabinet numbers in each group.

[0113] It is important to note that under special circumstances, the algorithm of the present invention can terminate early. For example, if the results of step 2) contain no isolated points, the clustering results of the left image of the cabinet can be directly applied to the final result, and the algorithm terminates early. For another example, if the results of step 3) contain no right clusters but only right isolated points, the results of steps 2) and 3) can be combined (the combined result will be consistent with the result of step 2) and directly applied to the final grouping result without the need for further grouping and clustering.

[0114] Example 4

[0115] Figure 4 This is a structural diagram of a cabinet grouping device provided by the fourth embodiment of the present invention. The cabinet grouping device provided by this embodiment can be implemented by software and / or hardware, and can be configured in a server or terminal device to implement a cabinet grouping method in the embodiment of the present invention. Figure 4 As shown, the device may specifically include: a primary clustering module 410 , a secondary clustering module 420 and a cabinet grouping result module 430 .

[0116] The primary clustering module 410 is configured to obtain the surface images of each cabinet collected under two viewing angles, and to perform a primary clustering on each cabinet based on the first surface image of each cabinet under the first viewing angle to obtain a primary clustering result.

[0117] A secondary clustering module 420 is configured to, if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, perform secondary clustering on each target cabinet based on the second body surface image of each target cabinet at the second viewing angle and obtain a secondary clustering result;

[0118] The cabinet grouping result module 430 is configured to group the cabinets according to the first clustering result and the second clustering result to obtain a cabinet grouping result.

[0119] The technical solution provided by the embodiment of the present invention obtains the body surface images of each cabinet collected separately under two viewing angles, and clusters each cabinet once based on the first body surface image of each cabinet under the first viewing angle to obtain a primary clustering result; if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, then secondary clusters each target cabinet based on the second body surface image of each target cabinet under the second viewing angle to obtain a secondary clustering result; and based on the primary clustering result and the secondary clustering result, the cabinets are grouped to obtain cabinet grouping results. The new grouping method of secondary clustering using the body surface images under two viewing angles solves the problems of high grouping error rate, high missed detection ratio, and incomplete coverage in the prior art, and improves the accuracy and coverage of cabinet grouping.

[0120] Based on the above embodiments, the primary clustering module 410 can be specifically used to: obtain the first image feature vectors corresponding to the first body surface images of each cabinet; calculate the similarity between any two obtained first image feature vectors, and based on the similarity calculation result, perform a primary clustering on each cabinet and obtain a primary clustering result; the secondary clustering module 420 can be specifically used to: obtain the second image feature vectors corresponding to the second body surface images of each target cabinet; calculate the similarity between any two obtained second image feature vectors, and based on the similarity calculation result, perform a secondary clustering on each target cabinet and obtain a secondary clustering result.

[0121] Based on the above embodiments, the cabinet grouping result module 430 can be specifically used: if it is determined that the first clustering result includes at least one first cabinet clustering cluster, and the second clustering result includes at least one second cabinet clustering cluster, then the first cabinet clustering cluster and the second cabinet clustering cluster are clustered again to obtain the cabinet grouping results corresponding to each cabinet.

[0122] On the basis of the above embodiments, the first cabinet cluster and the second cabinet cluster are clustered again to obtain the cabinet grouping results corresponding to the each cabinet, which can be specifically used for: calculating the first group mean vector corresponding to each first cabinet cluster according to the second image feature vector of the second body surface image of each first cabinet in the first cabinet cluster under the second perspective; calculating the second group mean vector corresponding to each second cabinet cluster according to the second image feature vector of the second body surface image of each second cabinet in the second cabinet cluster under the second perspective; calculating the similarity between each first group mean vector and each second group mean vector, and obtaining the cabinet grouping results corresponding to each cabinet according to the similarity calculation result.

[0123] Based on the above embodiments, the cabinet grouping result module 430 can be specifically configured to: if it is determined that the primary clustering result does not include any first cabinet cluster, use the secondary clustering result as the cabinet grouping result corresponding to each cabinet.

[0124] Based on the above embodiments, the cabinet grouping result module 430 can be specifically used: if it is determined that the first clustering result includes at least one first cabinet clustering cluster, and the second clustering result does not include any second cabinet clustering cluster, then the first clustering result will be used as the cabinet grouping result corresponding to each cabinet.

[0125] On the basis of the above embodiments, it can also include a cabinet grouping result judgment module, which can be specifically used for: after clustering each cabinet based on the first body surface image of each cabinet under the first perspective and obtaining a clustering result, if it is determined according to the clustering result that there are no at least two unclustered target cabinets, then the clustering result will be used as the cabinet grouping result corresponding to each cabinet.

[0126] The above-mentioned cabinet grouping device can execute the cabinet grouping method provided by any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0127] Example 5

[0128] Figure 5 This is a schematic diagram of the structure of a computer device provided by the fifth embodiment of the present invention. Figure 5 As shown, the device includes a processor 510, a memory 520, an input device 530, and an output device 540; the number of processors 510 in the device can be one or more. Figure 5 In the embodiment, a processor 510 is used as an example; the processor 510, the memory 520, the input device 530 and the output device 540 in the device can be connected via a bus or other means. Figure 5 The bus connection is taken as an example.

[0129] The memory 520, as a computer-readable storage medium, can be used to store software programs, computer executable programs, and modules, such as program instructions / modules corresponding to the cabinet grouping method in the embodiment of the present invention (for example, the primary clustering module 410, the secondary clustering module 420, and the cabinet grouping result module 430). The processor 510 executes various functional applications and data processing of the device by running the software programs, instructions, and modules stored in the memory 520, that is, implements the above-mentioned cabinet grouping method, which includes: obtaining body surface images of each cabinet respectively captured under two viewing angles, and clustering each cabinet based on the first body surface image of each cabinet under the first viewing angle to obtain a primary clustering result; if it is determined that there are at least two unclustered target cabinets according to the primary clustering result, clustering each target cabinet based on the second body surface image of each target cabinet under the second viewing angle to obtain a secondary clustering result; and grouping each cabinet based on the primary clustering result and the secondary clustering result to obtain a cabinet grouping result.

[0130] The memory 520 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and at least one application required for a function; the data storage area may store data created based on the use of the terminal, etc. In addition, the memory 520 may include a high-speed random access memory and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some instances, the memory 520 may further include a memory remotely located relative to the processor 510, and these remote memories may be connected to the device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0131] The input device 530 may be used to receive input digital or character information and generate key signal input related to user settings and function control of the device. The output device 540 may include a display device such as a display screen.

[0132] Example 6

[0133] Embodiment 6 of the present invention also provides a method comprising a computer-readable storage medium, wherein the computer-executable instructions are used to execute a cabinet grouping method when executed by a computer processor, the method comprising: obtaining body surface images of each cabinet respectively captured under dual perspectives, and clustering each cabinet once based on the first body surface image of each cabinet under the first perspective and obtaining a primary clustering result; if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, then secondary clustering is performed on each target cabinet based on the second body surface image of each target cabinet under the second perspective and obtaining a primary clustering result; and grouping the cabinets according to the primary clustering result and the secondary clustering result to obtain a cabinet grouping result.

[0134] Of course, the computer-readable storage medium provided in the embodiment of the present invention has computer-executable instructions that are not limited to the method operations described above, and can also execute related operations in the cabinet grouping method provided in any embodiment of the present invention.

[0135] Through the above description of the implementation methods, those skilled in the art can clearly understand that the present invention can be implemented with the help of software and necessary general-purpose hardware, and of course it can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as a computer floppy disk, read-only memory (ROM), random access memory (RAM), flash memory (FLASH), hard disk or optical disk, etc., including a number of instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute the methods described in each embodiment of the present invention.

[0136] It is worth noting that in the embodiment of the above-mentioned cabinet grouping device, the various units and modules included are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention.

[0137] Note that the above are only preferred embodiments of the present invention and the technical principles employed. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and that various obvious changes, readjustments, and substitutions can be made by those skilled in the art without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments and may include many other equivalent embodiments without departing from the concept of the present invention. The scope of the present invention is determined by the scope of the appended claims.

Claims

1. A cabinet grouping method, characterized in that: include: Obtaining the body surface images of each cabinet collected under two viewing angles, and clustering each cabinet based on the first body surface image of each cabinet under the first viewing angle to obtain a clustering result; If it is determined according to the primary clustering result that there are at least two unclustered target cabinets, performing secondary clustering on each target cabinet according to the second body surface image of each target cabinet at the second viewing angle and obtaining a secondary clustering result; Grouping the cabinets according to the first clustering result and the second clustering result to obtain a cabinet grouping result; The cabinets are grouped according to the first clustering result and the second clustering result to obtain cabinet grouping results, including: If it is determined that the first clustering result includes at least one first cabinet cluster, and the second clustering result includes at least one second cabinet cluster, clustering the first cabinet cluster and the second cabinet cluster again to obtain cabinet grouping results corresponding to the cabinets; Clustering the first cabinet cluster and the second cabinet cluster again to obtain cabinet grouping results corresponding to the cabinets includes: Calculating a first group mean vector corresponding to each of the first cabinet clusters according to the second image feature vector of the second body surface image of each first cabinet in the first cabinet cluster at the second viewing angle; Calculating a second group mean vector corresponding to each of the second cabinet clusters based on the second image feature vector of the second body surface image of each second cabinet in the second cabinet cluster at the second viewing angle; The similarity between each of the first grouping mean vectors and each of the second grouping mean vectors is calculated, and based on the similarity calculation result, a cabinet grouping result corresponding to each of the cabinets is obtained.

2. The cabinet grouping method according to claim 1, characterized in that: Clustering each cabinet unit according to the first body surface image of each cabinet unit at the first viewing angle and obtaining a clustering result includes: Obtaining first image feature vectors corresponding to the first body surface images of each cabinet; Calculating the similarity between any two acquired first image feature vectors, and clustering the cabinets according to the similarity calculation result to obtain a clustering result; Performing secondary clustering on each target cabinet based on the second body surface image of each target cabinet at the second viewing angle and obtaining a secondary clustering result includes: Acquire second image feature vectors corresponding to the second body surface images of each target cabinet; The similarity between any two acquired second image feature vectors is calculated, and based on the similarity calculation result, the target cabinets are secondary clustered to obtain a secondary clustering result.

3. The cabinet grouping method according to claim 2, characterized in that: The cabinets are grouped according to the first clustering result and the second clustering result to obtain cabinet grouping results, including: If it is determined that the primary clustering result does not include any first cabinet cluster, the secondary clustering result is used as the cabinet grouping result corresponding to each cabinet.

4. The cabinet grouping method according to claim 2, characterized in that: The cabinets are grouped according to the first clustering result and the second clustering result to obtain cabinet grouping results, including: If it is determined that the primary clustering result includes at least one first cabinet cluster and the secondary clustering result does not include any second cabinet cluster, the primary clustering result is used as the cabinet grouping result corresponding to each cabinet.

5. The cabinet grouping method according to any one of claims 1 to 4, characterized in that: After clustering each cabinet unit based on the first body surface image of each cabinet unit at the first viewing angle and obtaining a clustering result, the method further includes: If it is determined according to the primary clustering result that there are no at least two unclustered target cabinets, the primary clustering result is used as the cabinet grouping result corresponding to each cabinet.

6. A cabinet grouping device, characterized in that: include: A primary clustering module is used to obtain the body surface images of each cabinet collected under two viewing angles, and to cluster each cabinet based on the first body surface image of each cabinet under the first viewing angle to obtain a primary clustering result; a secondary clustering module configured to, if it is determined according to the primary clustering result that there are at least two unclustered target cabinets, perform secondary clustering on each target cabinet based on the second body surface image of each target cabinet at the second viewing angle and obtain a secondary clustering result; A cabinet grouping result module is used to group the cabinets according to the first clustering result and the second clustering result to obtain a cabinet grouping result; The cabinet grouping result module is specifically used to: If it is determined that the first clustering result includes at least one first cabinet cluster, and the second clustering result includes at least one second cabinet cluster, clustering the first cabinet cluster and the second cabinet cluster again to obtain cabinet grouping results corresponding to the cabinets; Calculating a first group mean vector corresponding to each of the first cabinet clusters according to the second image feature vector of the second body surface image of each first cabinet in the first cabinet cluster at the second viewing angle; Calculating a second group mean vector corresponding to each of the second cabinet clusters based on the second image feature vector of the second body surface image of each second cabinet in the second cabinet cluster at the second viewing angle; The similarity between each of the first grouping mean vectors and each of the second grouping mean vectors is calculated, and based on the similarity calculation result, a cabinet grouping result corresponding to each of the cabinets is obtained.

7. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the cabinet grouping method according to any one of claims 1 to 5 is implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the cabinet grouping method as described in any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • Picture clustering method and device

    CN103390165A

  • Image processing method and device, computer readable storage medium and mobile terminal

    CN107729391A