A rips complex-based clothing image topological feature extraction method

By using a topological feature extraction method for clothing images based on Rips complexes, the problem of inaccurate retrieval caused by background interference and occlusion in clothing images is solved, thereby improving the retrieval accuracy of clothing image databases.

CN116719965BActive Publication Date: 2026-04-17HARBIN UNIV OF COMMERCE
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HARBIN UNIV OF COMMERCE
Filing Date
2023-05-18
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

In existing technologies, clothing images suffer from background interference and occlusion, making it impossible to extract deeper information and resulting in inaccurate search results.

Method used

A topological feature extraction method for clothing images based on Rips complexes is adopted. The pixel matrix of the image is obtained and converted into a five-dimensional matrix. The persistence graph is constructed using Rips complexes and the feature values ​​are calculated. A histogram is drawn as the topological feature of the image.

Benefits of technology

The accuracy of image retrieval has been improved, especially in clothing image databases, with retrieval accuracy for Top 5, Top 10 and Top 20 images increasing by 9.5%, 7% and 7.1% respectively.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116719965B_ABST
    Figure CN116719965B_ABST
Patent Text Reader

Abstract

A method for extracting topological features from clothing images based on Rips complexes is disclosed, relating to the field of image retrieval technology. Addressing the problem that existing technologies cannot extract deeper information from clothing images due to background interference and occlusion, leading to inaccurate retrieval results, this application introduces a novel feature form. This feature utilizes the characteristics of Rips complexes to focus on the distance relationships between pixels rather than calculating the pixels themselves, thereby uncovering deeper information in the image and improving the accuracy of image retrieval.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image retrieval technology, specifically to a method for extracting topological features from clothing images based on Rips complexes. Background Technology

[0002] With the rapid development of e-commerce and convenient logistics, online shopping has become increasingly popular. Among these, clothing has seen a significant increase in online transactions, leading to a rapid growth in clothing image data. Accurately and quickly matching desired clothing styles from massive datasets has become a research goal for many scholars and companies. Traditional text-based clothing image retrieval methods suffer from high costs, time consumption, unclear descriptions, and strong subjectivity due to the need for image annotation. Traditional content-based clothing retrieval methods, however, are hampered by background interference and occlusion, failing to extract deeper information from clothing images, resulting in inaccurate search results. While deep learning methods can address these issues, they also present challenges, such as the need for large-scale data support and the rapid increase in algorithm complexity and time required due to the large number of parameters in complex deep learning network models. Applying continuous homology to analyze various large datasets is currently a highly effective research method.

[0003] Since 2004, Carlsson and other scholars, based on their in-depth understanding of topology and geometry, have begun to study the application of continuous homology methods in practice. For example, they have used this method to conduct qualitative research on different types of data, achieving certain research results. They have also elucidated methods for constructing different simple complex structures. Zhang Jingliang et al. applied the continuous homology method to construct a series of simple complexes with continuous parameters to approximate image space, then calculated the homology information of these complexes and wrote them into "barcodes." Experiments have shown that in this continuous approximation process, not only can the topologically invariant features of the image be obtained, but also some geometric features related to the topological structure of the image space. Through experiments with simple geometric images and simple natural images, it is shown that we can use the topologically invariant features of images to analyze the similarity between images, and use the geometric features of images to analyze the differences between images. In particular, by comparing the similarity and difference in the topological and geometric structures of images taken from different angles, it can be concluded that topologically invariant features can ideally determine the similarity between an image that has undergone a certain degree of deformation and the original image. Summary of the Invention

[0004] The purpose of this invention is to address the problem in existing technologies where background interference and occlusion in clothing images prevent the extraction of deeper information, leading to inaccurate retrieval results. This invention proposes a method for extracting topological features from clothing images based on Rips complexes.

[0005] The technical solution adopted by the present invention to solve the above-mentioned technical problems is as follows:

[0006] A method for extracting topological features from clothing images based on Rips complexes includes the following steps:

[0007] Step 1: Obtain the image of the garment to be processed and extract the image pixel matrix of the garment image;

[0008] Step 2: Convert the image pixel matrix extracted in Step 1 into a five-dimensional matrix by combining the R, G, and B channels;

[0009] Step 3: Use the Rips complex construction method to perform persistent homology calculation on the five-dimensional matrix to obtain the persistence graph, and calculate the eigenvalues ​​of the five-dimensional matrix based on the persistence graph;

[0010] Step 4: Repeat steps 1 to 3 to obtain the feature values ​​of the five-dimensional matrix corresponding to the pixel matrix of all images in the clothing image to be processed, and draw a histogram;

[0011] Step 5: Use histograms as topological features of the image.

[0012] The specific steps for extracting the image pixel matrix of the clothing image are as follows:

[0013] By scanning the clothing image sequentially through a 3×3 window with a step size of 3, an image pixel matrix of RGB three channels in a 3×3 window is obtained, that is, a 3×3×3 image pixel matrix.

[0014] The specific steps of step two are as follows:

[0015] Based on the position of each pixel in the image pixel matrix within the window, i.e. (x, y), and the three components R, G, and B, a five-dimensional vector is constructed. Then, x and y are magnified to obtain a 5×9 matrix, i.e., a five-dimensional matrix.

[0016] The magnification factor for amplifying x and y is selected as 100.

[0017] The specific steps of step three are as follows:

[0018] Step 31: Use the Rips complex construction method to perform persistent homology calculation on the 5×9 matrix to obtain the persistence graph;

[0019] Step 32: Obtain the coordinates of the persistence graph and calculate the eigenvalues ​​of the five-dimensional matrix based on the coordinates of the persistence graph.

[0020] The eigenvalues ​​of the five-dimensional matrix calculated based on the coordinates of the persistence graph are expressed as follows:

[0021]

[0022] Where (x0, y0) are the pixel coordinates of the window center, dx i and dy i Let m be the x and y coordinates of the i-th coordinate of the barcode image obtained using Rips complex calculation, where m is a constant.

[0023] The specific steps of step five are as follows:

[0024] Step 51: Obtain histograms H1 and H2 from the image to be retrieved and the database image respectively through the above steps;

[0025] Step 52: Obtain the count of all eigenvalues ​​in histograms H1 and H2 respectively, and compare the count of all eigenvalues ​​in H1 with the count of all eigenvalues ​​in H2.

[0026] If the total number of eigenvalues ​​in H1 is greater than the total number of eigenvalues ​​in H2, then the total number of eigenvalues ​​in H1 is split into two parts, namely H1 and H2. 1a and H 1b H 1a The number of all eigenvalues ​​in H2 is equal to the number of eigenvalues ​​in H2, then H is calculated. 1a The Wasserstein distance from H2 is L1, H 1b The distance from H2 is L2. Finally, L1 and L2 are summed to obtain the final distance, which is expressed as:

[0027]

[0028] Where, x i H represents 1b The eigenvalues ​​of H2 are denoted by mean(H2), where mean(H2) is the median of H2.

[0029] If the number of all eigenvalues ​​in H1 is less than the number of all eigenvalues ​​in H2, then the number of all eigenvalues ​​in H2 is split into two parts, i.e., H 2a and H 2b H 2a The number of all eigenvalues ​​in H1 is equal to the number of eigenvalues ​​in H1, then H is calculated. 2a The Wasserstein distance from H1 is L1, H 2b The distance from H1 is L2. Finally, L1 and L2 are summed to obtain the final distance, which is expressed as:

[0030]

[0031] Where, x i H represents 2b The eigenvalues ​​are the median of H1;

[0032] If the number of all eigenvalues ​​in H1 is equal to the number of all eigenvalues ​​in H2, then the Wasserstein distance between H1 and H2 is directly calculated as the final distance.

[0033] Step 51 also includes the step of simplifying histograms H1 and H2.

[0034] The steps for simplifying histograms H1 and H2 are expressed as follows:

[0035] H 1,2 (x n )=H 1,2 (x n )-min(H1(x n H2(x) n ))

[0036] Where, x n Indicates the same characteristic value.

[0037] The beneficial effects of this invention are:

[0038] This application introduces a new feature form that leverages the characteristics of rips complexes to focus on the distance relationships between pixels rather than calculating the pixels themselves, thereby uncovering deeper information in the image and improving the accuracy of image retrieval. Attached Figure Description

[0039] Figure 1 This is a flowchart of the application;

[0040] Figure 2 Illustration of extracted image pixel blocks;

[0041] Figure 3 Convert pixel blocks into a five-dimensional matrix diagram;

[0042] Figure 4 The images are shown after the topological features of the images at different magnifications have been normalized to 0-255.

[0043] Figure 5 Illustration of the topological histogram extracted from the image;

[0044] Figure 6 This is a diagram illustrating the effect of histogram simplification. Detailed Implementation

[0045] It should be noted that, where there is no conflict, the various embodiments disclosed in this application can be combined with each other.

[0046] Specific implementation method one: Refer to Figure 1 This embodiment describes a method for extracting topological features from clothing images based on Rips complexes. The method includes the following steps:

[0047] Step 1: Obtain the image of the clothing to be processed and extract the image pixel matrix of the clothing image, as shown in the extracted image pixel block image. Figure 2 As shown;

[0048] Step 2: Convert the pixel matrix extracted in Step 1 into a five-dimensional matrix, as shown in the figure. Figure 3 As shown;

[0049] Step 3: Use the Rips complex construction method to perform continuous homology calculation on the five-dimensional matrix to obtain the barcode image, and calculate the eigenvalues ​​of the five-dimensional matrix;

[0050] Step 4: Calculate and statistically analyze the topological feature values ​​of each block in the entire image based on Step 3, and draw a histogram.

[0051] Step 5: Using the histogram extracted in Step 4 as the image topological feature, calculate the distance between the two images using a similarity metric. The topological graph is shown below. Figure 5 As shown.

[0052] Specific Implementation Method Two: This implementation method is a further explanation of Specific Implementation Method One. The difference between this implementation method and Specific Implementation Method One is that the specific steps for extracting the image pixel matrix of the clothing image are as follows:

[0053] By scanning the clothing image sequentially through a 3×3 window with a step size of 3, an image pixel matrix of RGB three channels in a 3×3 window is obtained, that is, a 3×3×3 image pixel matrix.

[0054] Specific Implementation Method Three: This implementation method is a further explanation of Specific Implementation Method Two. The difference between this implementation method and Specific Implementation Method Two is that the specific steps of step two are as follows:

[0055] Based on the position of each pixel in the image pixel matrix within the window, i.e. (x, y), and the three components R, G, and B, a five-dimensional vector is constructed. Then, x and y are magnified to obtain a 5×9 matrix, i.e., a five-dimensional matrix.

[0056] Specific Implementation Method Four: This implementation method is a further explanation of Specific Implementation Method Three. The difference between this implementation method and Specific Implementation Method Three is that the magnification factor for magnifying x and y is selected as 100.

[0057] Specific Implementation Method Five: This implementation method is a further explanation of Specific Implementation Method Four. The difference between this implementation method and Specific Implementation Method Four is that the specific steps of step three are as follows:

[0058] Step 31: Use the Rips complex construction method to perform persistent homology calculation on the 5×9 matrix to obtain the persistence graph;

[0059] Step 32: Obtain the coordinates of the persistence graph and calculate the eigenvalues ​​of the five-dimensional matrix based on the coordinates of the persistence graph.

[0060] Specific Implementation Method Six: This implementation method is a further explanation of Specific Implementation Method Five. The difference between this implementation method and Specific Implementation Method Five is that the eigenvalues ​​of the five-dimensional matrix calculated based on the coordinates of the persistence graph are expressed as follows:

[0061]

[0062] Where (x0, y0) are the pixel coordinates of the window center, dx i and dy i Let m be the x and y coordinates of the i-th coordinate of the barcode image obtained using Rips complex calculation, where m is a constant, m = 4.

[0063] Specific Implementation Method Seven: This implementation method is a further explanation of Specific Implementation Method Six. The difference between this implementation method and Specific Implementation Method Six is ​​that the specific steps of step five are as follows:

[0064] Step 51: Obtain histograms H1 and H2 from the image to be retrieved and the database image respectively through the above steps;

[0065] Step 52: Obtain the count of all eigenvalues ​​in histograms H1 and H2 respectively, and compare the count of all eigenvalues ​​in H1 with the count of all eigenvalues ​​in H2.

[0066] If the total number of eigenvalues ​​in H1 is greater than the total number of eigenvalues ​​in H2, then the total number of eigenvalues ​​in H1 is split into two parts, namely H1 and H2. 1a and H 1b H 1a The number of all eigenvalues ​​in H2 is equal to the number of eigenvalues ​​in H2, then H is calculated. 1a The Wasserstein distance from H2 is L1, H 1b The distance from H2 is L2. Finally, L1 and L2 are summed to obtain the final distance, which is expressed as:

[0067]

[0068] Where, x i H represents 1bThe eigenvalues ​​of H2 are denoted by mean(H2), where mean(H2) is the median of H2.

[0069] If the number of all eigenvalues ​​in H1 is less than the number of all eigenvalues ​​in H2, then the number of all eigenvalues ​​in H2 is split into two parts, i.e., H 2a and H 2b H 2a The number of all eigenvalues ​​in H1 is equal to the number of eigenvalues ​​in H1, then H is calculated. 2a The Wasserstein distance from H1 is L1, H 2b The distance from H1 is L2. Finally, L1 and L2 are summed to obtain the final distance, which is expressed as:

[0070]

[0071] Where, x i H represents 2b The eigenvalues ​​are the median of H1;

[0072] If the number of all eigenvalues ​​in H1 is equal to the number of all eigenvalues ​​in H2, then the Wasserstein distance between H1 and H2 is directly calculated as the final distance.

[0073] Specific Implementation Method Eight: This implementation method is a further explanation of Specific Implementation Method Seven. The difference between this implementation method and Specific Implementation Method Seven is that step five-one also includes the step of simplifying histograms H1 and H2.

[0074] Specific Implementation Method Nine: This implementation method is a further explanation of Specific Implementation Method Eight. The difference between this implementation method and Specific Implementation Method Eight is that the step of simplifying histograms H1 and H2 is expressed as follows:

[0075] H 1,2 (x n )=H 1,2 (x n )-min(H1(x n H2(x) n ))

[0076] Where, x n This indicates the same eigenvalue. The simplified result is as follows: Figure 6 As shown.

[0077] Based on the general image retrieval system framework, this application proposes a new image feature extraction method and a similarity measurement algorithm for the features. The method of this invention uses a pre-configured computer program to retrieve clothing images and fuses depth image features, with the aim of improving the accuracy of image retrieval.

[0078] The experiment used a subset of the DeepFashion open clothing image database from the Chinese University of Hong Kong: In-shop Clothes Retrieval Benchmark. Because the images in the selected dataset have simple backgrounds, peaks appeared when calculating pixel block features and histograms. Therefore, to simplify subsequent calculations, these peaks were removed.

[0079] The experimental results compared with those using MobileNetV2 for image depth feature extraction show that the retrieval accuracy of Top5 (%), Top10 (%) and Top20 (%) improved by 9.5%, 7%, and 7.1%, respectively, after incorporating the features of this invention.

[0080] This paper conducts experiments on the magnification factors of x and y in a five-dimensional vector, taking 50, 100, and 150 respectively. The accuracy rate was highest with 100 magnification. The effects of different magnification factors are shown in the following figures. Figure 4 As shown.

[0081] It should be noted that the specific embodiments are merely explanations and illustrations of the technical solution of the present invention and should not be used to limit the scope of protection. Any modifications made in accordance with the claims and specification of the present invention that are only partial should still fall within the protection scope of the present invention.

Claims

1. A method for extracting topological features from clothing images based on Rips complexes, characterized in that... Includes the following steps: Step 1: Obtain the image of the garment to be processed and extract the image pixel matrix of the garment image; Step 2: Convert the image pixel matrix extracted in Step 1 into a five-dimensional matrix by combining the R, G, and B channels; Step 3: Use the Rips complex construction method to perform persistent homology calculation on the five-dimensional matrix to obtain the persistence graph, and calculate the eigenvalues ​​of the five-dimensional matrix based on the persistence graph; Step 4: Repeat steps 1 to 3 to obtain the feature values ​​of the five-dimensional matrix corresponding to the pixel matrix of all images in the clothing image to be processed, and draw a histogram; Step 5: Utilize histograms as topological features of the image; The specific steps of step three are as follows: Step 31: Use the Rips complex construction method to perform persistent homology calculation on the 5×9 matrix to obtain the persistence graph; Step 32: Obtain the coordinates of the persistence graph and calculate the eigenvalues ​​of the five-dimensional matrix based on the coordinates of the persistence graph; The specific steps of step five are as follows: Step 51: Obtain histograms from the image to be retrieved and the database image respectively through the above steps. , ; Step 52: Obtain histograms separately and histogram The number of all eigenvalues ​​in, and The number of all eigenvalues ​​and Compare the number of all eigenvalues. like The number of all eigenvalues ​​is greater than The number of all eigenvalues ​​in the matrix will then be The number of all eigenvalues ​​in the equation is split into two parts, namely... and ,in and If they are equal, then calculate. and The Wasserstein distance is , and The distance is ,at last and The sum is used as the final distance. Represented as: in, express eigenvalues, for the median; like The number of all eigenvalues ​​in the is less than The number of all eigenvalues ​​in, and The number of all eigenvalues and ,in and If they are equal, then calculate. and The Wasserstein distance is , and The distance is ,at last and The sum is used as the final distance. Represented as: in, express The eigenvalues, mean(H1) is the median of H1; like The number of all eigenvalues ​​in the equation is equal to The number of all eigenvalues ​​is calculated directly. and The Wasserstein distance is used as the final distance; Step 51 also includes histogram analysis. , The steps to simplify; The histogram , The steps for simplification are expressed as follows: in, Indicates the same characteristic value.

2. The method for extracting topological features of clothing images based on Rips complexes according to claim 1, characterized in that... The specific steps for extracting the image pixel matrix of the clothing image to be processed are as follows: By scanning the clothing image sequentially through a 3×3 window with a step size of 3, an image pixel matrix of 3×3 window with RGB three channels is obtained, that is, a 3×3×3 image pixel matrix.

3. The method for extracting topological features of clothing images based on Rips complexes according to claim 2, characterized in that... The specific steps of step two are as follows: Based on the position of each pixel in the image pixel matrix within the window, i.e. (x, y), and the three components R, G, and B, a five-dimensional vector is constructed. Then, x and y are magnified to obtain a 5×9 matrix, i.e., a five-dimensional matrix.

4. The method for extracting topological features of clothing images based on Rips complexes according to claim 3, characterized in that... The magnification factor for amplifying x and y is selected as 100.

5. The method for extracting topological features of clothing images based on Rips complexes according to claim 1, characterized in that... The eigenvalues ​​of the five-dimensional matrix calculated based on the coordinates of the persistence graph are expressed as follows: in, The coordinates of the center pixel of the window. and For use The horizontal and vertical coordinates of the i-th coordinate of the barcode image obtained by complex calculation, where m is a constant.