A method, device and storage medium for extracting image features and obtaining descriptors

By performing color block segmentation and multiple equal subdivisions on the image, the connection domain and line segment data of the image are obtained, and rough and fine feature descriptors are generated, which solves the problem of inconsistent measurement units of image shape feature points and improves image retrieval Effect and accuracy.

CN113554639BActive Publication Date: 2024-12-31HUBEI ZHONGQISHENG DIGITAL TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110875964.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-07-30
Publication Date
2024-12-31
Estimated Expiration
2041-07-30

AI Technical Summary

Technical Problem

In the prior art, the image shape feature descriptor acquisition method results in inconsistent unit of measurement of image shape feature point and incomplete comparability conditions of the two images, resulting in the same or similar images being unable to be retrieved in image retrieval, resulting in the search rate and search. The defects of low accuracy and unsatisfactory matching effect.

Method used

By extracting the effective area images of the image to be processed, perform color block segmentation and multiple equal segmentation, confirm the connection domain, identify line segments, and measure line lengths, and obtain rough and fine image feature descriptors, including horizontal, vertical and specific angle directions. The subdivided area data of the sequential area, combined with the number of line segments and line length values, generate image feature descriptors.

Benefits of technology

It effectively solves the missed detection problem of the same or similar images in image retrieval, improves the matching effect and accuracy of image retrieval, enhances the completeness and accuracy of image retrieval, and provides a more comprehensive and accurate image feature description.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113554639B_ABST
    Figure CN113554639B_ABST
Patent Text Reader

Abstract

A method for extracting image features and obtaining descriptors includes the following steps: Step A: extracting the effective area image and pixel color value data of the image to be processed and performing color block segmentation to obtain image data of the effective area image; Step B: subdividing the effective area image into multiple equal parts to obtain subdivided areas of the effective area image; Step C: confirming the connected domain, identifying line segments and measuring line lengths of the subdivided areas to obtain image feature data of the subdivided areas; Step D: performing statistics and combination processing on the image feature data of the subdivided areas to obtain image feature descriptors. Using image feature descriptors to describe image features can effectively solve the stability problem of common features and distinguishing feature descriptions of identical or similar images, make up for the defect that traditional image feature extraction technology methods may cause missed detection of identical or similar images in image retrieval, and improve the matching effect of identical or similar images in image recognition retrieval.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to an image feature extraction and descriptor acquisition method, device and storage medium. Background Art

[0002] Image descriptors are generally used to describe feature points in an image. A good set of descriptors should have distinctiveness and commonality. Distinctiveness means that the descriptor can reflect the feature points that distinguish one image from another, so that the descriptor is unique to the image; commonality means that the descriptor can reflect an image with other identical or similar images with the same feature points, so that the descriptor has common feature points for identical or similar images, thereby achieving good matching of identical and similar images.

[0003] However, the matching of identical or similar images needs to be based on certain conditions, such as the unification of the measurement units of feature points and the comparability of the two images.

[0004] The image descriptors disclosed in the prior art are generally a set of vectors, including the location, direction, scale and other information of feature points. Common feature points are some stable points in the image, such as corner points, edge points, bright spots in dark areas, dark spots in bright areas, etc. The existing feature descriptors are usually feature vectors extracted based on a certain standard, which can achieve the matching of identical or similar images within a certain range, but the measurement units and description conditions for feature points of different images may not be unified, resulting in many images that are considered identical or similar visually cannot be found in image retrieval, resulting in the defects of low recall and precision of identical or similar images and unsatisfactory matching effect. Summary of the invention

[0005] In view of the above defects, the purpose of the present invention is to provide an image feature extraction and descriptor acquisition method, device and storage medium. It is possible to obtain good image shape feature descriptors, effectively solve the problem of good description of image shape feature points, and overcome the defects of traditional image shape feature descriptor acquisition technology methods that may cause the unification of image shape feature point measurement units or incomplete comparability conditions of two images, resulting in the inability to retrieve some identical or similar images.

[0006] The present invention provides an image feature extraction and descriptor acquisition method, comprising the following steps:

[0007] Step A: extracting the effective area image and pixel color value data of the image to be processed and performing color block segmentation to obtain the effective area image and image data of the image to be processed;

[0008] Step B: using segmentation lines in the same direction to subdivide the effective area image into multiple equal parts, and obtaining segmented areas with the same cutting direction and a segmented area data set;

[0009] Step C: performing connected domain confirmation, line segment recognition and line length measurement on the subdivided area to obtain image feature data of the subdivided area;

[0010] Step D: performing statistics and combination processing on the image feature data of the subdivided area to obtain an image feature descriptor, wherein the image feature descriptor includes at least one or more of the following: a coarse image feature descriptor and a fine image feature descriptor.

[0011] Preferably, in step B, the same direction of the dividing line includes the following directions: horizontal direction, vertical direction, and specific angle direction;

[0012] The subdivided areas with the same cutting direction include at least one of the following: a horizontally divided subdivided area, a vertically divided subdivided area, and a specific angle divided subdivided area;

[0013] The subdivided area data set is a data set of subdivided areas in one direction or multiple directions, wherein the subdivided area data set includes at least one or a combination of the following: horizontal segmentation of subdivided areas, vertical segmentation of subdivided areas, and specific angle segmentation of subdivided areas;

[0014] The horizontal segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the horizontal direction;

[0015] The vertical segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the vertical direction;

[0016] The specific angle segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the preset specific angle direction, and the preset specific angle takes a value in the integer degree from 0° to 360°;

[0017] Preferably, the n equal parts are an integer greater than 3.

[0018] In the In step C, the image feature data of the subdivided area of ​​the effective area image includes: the number of connected domains of the subdivided area, the number of line segments of the subdivided area, and the line length value of the subdivided area.

[0019] Preferably, the step C of obtaining image feature data of the subdivided area of ​​the effective area image includes:

[0020] Step C1: confirm the connected domains in the subdivided area and obtain the number of connected domains in the subdivided area;

[0021] The connected region is a local area formed by a set of main color block pixels connected to each other in the subdivided area;

[0022] Step C2: Identify the line segments of the subdivided area and obtain the number of line segments of the subdivided area;

[0023] The line segments of the subdivided area are connected domains in the subdivided area that meet the preset valid connected domain conditions;

[0024] Get the number of line segments in the subdivision area:

[0025] First, judging and determining the validity of each connected domain in the subdivided area according to the preset valid connected domain condition, and obtaining the valid connected domain of the subdivided area; then, counting the number of valid connected domains in the subdivided area; finally, taking the number of valid connected domains in the subdivided area as the number of line segments in the subdivided area;

[0026] The preset valid connected domain condition includes: when the maximum height of the connected domain is equal to the height of the subdivided area, and / or the maximum length of the connected domain is greater than or equal to the unit line length standard of the subdivided area, the connected domain is identified as a valid connected domain in the subdivided area, otherwise, it is identified as an invalid connected domain;

[0027] Step C3: measuring the line length of the subdivided area to obtain the line length value of the subdivided area;

[0028] The line length of the subdivided area refers to the length of the main color block pixels of the effective connected area in the subdivided area in the direction of the dividing line of the subdivided area; the line length value of the subdivided area refers to the value of the number of main color block pixels of the effective connected area in the subdivided area in the direction of the dividing line of the subdivided area measured by the subdivided area unit line length standard; the subdivided area unit line length standard refers to the standard of the minimum unit for measuring the length of the subdivided area;

[0029] The method for obtaining the line length value of the subdivided area includes:

[0030] Step C31: Determine the unit line length standard of the subdivided area;

[0031] Step C32: obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area;

[0032] Step C33: rounding the line length value of each subdivided area;

[0033] In one embodiment, the method for obtaining the line length value of the subdivided area in step C3, step C31, includes determining the unit line length standard of the subdivided area using a fixed constant method and / or a maximum line segment number method;

[0034] The fixed constant method includes: taking the line length of the largest subdivided area of ​​the effective area image of the image to be processed as the reference, the preset fixed constant N is used as the number of equal parts, and the line length of each equal part is the minimum unit for measuring the length of the subdivided area, and the minimum unit for measuring the line length is used as the unit line length standard of the subdivided area. The fixed constant N takes a value in the range of greater than 3. The calculation formula is as follows:

[0035] L1=m / N;

[0036] L1 represents the unit line length standard of the subdivided area of ​​the fixed constant method, m represents the pixel length of the effective connected domain of the largest subdivided area in the effective area image to be processed, and N represents a preset fixed constant;

[0037] The maximum line segment number method includes: using the maximum line length of the subdivided area of ​​the valid area image to be processed as a reference, using the maximum number of line segments of the subdivided area of ​​the valid area image to be processed as the number of equal parts, and the line length of each equal part is the minimum unit for measuring the length of the subdivided area, and the minimum unit for measuring the line length is used as the unit line length standard of the subdivided area. The calculation formula is as follows:

[0038] L2=m / n1;

[0039] L2 represents the unit line length standard of the subdivided area of ​​the maximum line segment number method, m represents the pixel length of the effective connected domain of the largest subdivided area in the effective area image to be processed, and n1 represents the maximum number of line segments in the subdivided area of ​​the effective area image to be processed.

[0040] The step C32 of obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area specifically includes:

[0041] When the fixed constant method is used to determine the unit line length standard of the subdivided area, the line length value of each subdivided area is obtained according to the following formula:

[0042] H1=S / L1;

[0043] Wherein, H1 represents the line length value of the subdivided area using the fixed constant method, S represents the pixel length of the effective connected domain of the current subdivided area, and L1 represents the unit line length standard of the subdivided area using the fixed constant method;

[0044] When the maximum line segment method is used to determine the unit line length standard of the subdivided area, the line length value of each subdivided area is obtained according to the following formula:

[0045] H2=S / L2;

[0046] H2 represents the line length value of the subdivided area using the maximum line segment method, S represents the pixel length of the effective connected domain of the current subdivided area, and L2 represents the unit line length standard of the subdivided area using the maximum line segment number method.

[0047] In the In step D, the step of obtaining the image feature descriptor includes: step D1: obtaining a coarse image feature descriptor; step D2: obtaining a fine image feature descriptor.

[0048] Preferably, in step D1, the step of obtaining a coarse image feature descriptor comprises:

[0049] Step D11: combining the subdivided areas of the effective area image of the picture to be processed to obtain a combined partial area of ​​the effective area image of the picture to be processed;

[0050] Step D12: Counting the line length data of each of the combined partial areas;

[0051] Step D13: Counting the feature data of the length of the line segments in the entire range of the effective area image of the image to be processed;

[0052] Step D14: combining the line segment length data of each combined partial area and the feature data of the line segment length of the entire range to generate a rough image feature descriptor.

[0053] Among them, the rough image feature descriptor refers to a descriptor that roughly describes the common features of the image from a larger local range or / and overall range in the image; it includes: data information that roughly describes the common features of the image in a larger local range in the effective area image of the picture to be processed and data information that roughly describes the common features of the image in the overall range in the effective area image of the picture to be processed.

[0054] Preferably, in step D11, the method for obtaining the combined partial area of ​​the effective area image of the picture to be processed includes: combining at least two subdivided areas of the effective area image of the picture to be processed according to a combination rule according to adjacent or connected positions to form a local area, and the local area is the combined partial area of ​​the effective area image of the picture to be processed.

[0055] The combination rules include: (1) the subdivided areas of the same combined partial area should be connected or adjacent to each other; (2) the number of subdivided area combinations of each combined partial area should be equal to each other or the deviation is less than a preset deviation value, and the preset deviation value is greater than or equal to 1 and less than 10; (3) the number of subdivided area combinations of each combined partial area should be greater than or equal to 2.

[0056] Preferably, in step D12, the line segment length data of each combined partial area specifically includes: the average number of line segments of the combined partial area, the main number of line segments of the combined partial area, the average line length value of the combined partial area, and the main line length value of the combined partial area.

[0057] The average number of line segments of the combined partial region is obtained by dividing the sum of the number of line segments of each subdivided region of the current combined partial region by the number of subdivided regions of the current combined partial region.

[0058] The main line segment number of the combined partial area means: when a certain line segment number within the combined partial area has the largest number of subdivided areas and the ratio of the number of subdivided areas owned by the certain line segment number to the total number of subdivided areas of the combined partial area is greater than a preset value of the line segment number ratio, then the certain line segment number is the main line segment number of the combined partial area; wherein the preset value of the line segment number ratio is taken in the range of greater than 30% and less than or equal to 100%;

[0059] The average line length of the combined partial area is the sum of the line length values ​​of the subdivided areas of the current combined partial area divided by the number of subdivided areas of the current combined partial area;

[0060] The main line length value of the combined partial area means: when a certain line length value within the combined partial area has the largest number of subdivided areas and the ratio of the number of subdivided areas to the total number of subdivided areas of the combined partial area is greater than a preset value of the line length value ratio, then the certain line length value is the main line length value of the combined partial area; wherein the preset value of the line length value ratio is in the range of greater than 30% and less than or equal to 100%.

[0061] Preferably, in step D13, the line segment length feature data is the following data for the entire range of the effective area image of the image to be processed: the total number of line segments in each subdivided area, the total number of line length values ​​in each subdivided area, and the number of color block connected domains in the effective area image. The feature data for statistical line segment lengths includes:

[0062] Obtaining the number of color block connected domains of the effective area image of the image to be processed according to the image feature data of the subdivided area of ​​the effective area image of the image to be processed;

[0063] Obtain the sum of the number of line segments in each subdivided area in the valid area image of the image to be processed, and the sum is the total number of line segments in each subdivided area;

[0064] The sum of the line length values ​​of each subdivided area in the effective area image of the image to be processed is obtained, and the sum is the total number of line length values ​​of each subdivided area.

[0065] Preferably, in step D14, the coarse image feature descriptor includes: a combined descriptor of the average number of line segments in the combined partial area of ​​the image, a combined descriptor of the main number of line segments in the combined partial area of ​​the image, a combined descriptor of the average line length value in the combined partial area of ​​the image, a combined descriptor of the main line length value in the combined partial area of ​​the image and a descriptor of the number of connected domains of color blocks in the effective area image, and the coarse image feature descriptor can be represented by numbers or other characters.

[0066] The method for expressing the combined descriptor of the average number of line segments in the combined partial area of ​​the image is composed of the following combinations: (1) using numbers or other characters to represent the total number of line segments in all subdivided areas of the effective area image; (2) the average number of line segments in each combined partial area;

[0067] The method for expressing the combined descriptor of the number of main line segments in the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line segments in all subdivided areas of the effective area image; (2) the number of main line segments in each combined partial area;

[0068] The method for expressing the combined descriptor of the average line length value of the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line length values ​​of all subdivided areas of the effective area image; (2) the average line length value of each combined partial area;

[0069] The method for expressing the combined descriptor of the main line length values ​​of the combined partial areas of the image is composed of the following combinations: (1) the total number of line length values ​​of all subdivided areas of the effective area image represented by numbers or other characters; (2) the main line length values ​​of each combined partial area;

[0070] The method of expressing the descriptor of the number of connected domains of color blocks in the effective area image is as follows: using numbers or other characters to represent the number of connected domains of color blocks in the effective area image.

[0071] Preferably, in step D2, the fine image feature descriptor refers to a descriptor that finely describes the common features of the image from a relatively small local (subdivided area) range in the effective area image of the image to be processed, specifically including: a set of line segment numbers and a set of line length values ​​of each subdivided area in the effective area image of the image to be processed.

[0072] The line segment number set of each subdivided area refers to a set of numbers or character strings that record the line segment numbers of each subdivided area in the order of the subdivided area numbers. The method of expressing the set of line segment numbers of each subdivided area includes: 1) the number of groups of numbers or other characters is equal to the number of subdivided areas of the valid area image of the image to be processed; 2) each group of numbers should represent the number of the subdivided area and the number of line segments of the subdivided area;

[0073] The line length value set of each subdivision area refers to a set of numbers or character strings that record the line length values ​​of each subdivision area in the order of the subdivision area numbers. The representation method of the set of line length values ​​of each subdivision area includes: 1) the number of groups of numbers or other characters is equal to the number of subdivision areas of the valid area image of the image to be processed; 2) each group of numbers should represent the number of the subdivision area and the line length value of the subdivision area.

[0074] An image feature extraction and descriptor acquisition device, characterized in that it comprises: an image data acquisition module, a subdivision region processing module, a subdivision region data acquisition module and an image feature descriptor acquisition module;

[0075] The image data acquisition module is used to extract the effective area image and pixel color value data of the image to be processed and perform color block segmentation to obtain the effective area image and image data of the image to be processed;

[0076] The subdivided region processing module is used to subdivide the effective region image into multiple equal parts using segmentation lines in the same direction, and obtain subdivided regions with the same cutting direction and subdivided region data sets;

[0077] The subdivided area data acquisition module is used to confirm the connected domain, identify the line segments and measure the line length of the subdivided area to obtain the image feature data of the subdivided area;

[0078] The image feature descriptor acquisition module is used to perform statistics and combination processing on the image feature data of the subdivided area to obtain an image feature descriptor, including at least one of the following: a coarse image feature descriptor and a fine image feature descriptor.

[0079] A computer-readable storage medium stores a computer program, wherein the computer program is used by a processor to execute all or part of the steps of the above-mentioned image feature extraction and descriptor acquisition method.

[0080] An image data storage device, comprising:

[0081] A coarse image feature descriptor storage unit, used to store the coarse image feature descriptor of the above-mentioned image feature extraction and descriptor acquisition method obtained when the computer program is executed by the processor;

[0082] The fine image feature descriptor storage unit is used to store the fine image feature descriptors of the above-mentioned image feature extraction and descriptor acquisition method obtained when the computer program is executed by the processor.

[0083] Beneficial effects of the present invention:

[0084] The present invention identifies and describes the image features such as the average number of line segments, the main number of line segments, the average line length value, the main line length value, etc. of the image in the effective area to be processed from the multi-dimensional perspectives of the whole image, the subdivided area, the partial area obtained by the combination of the subdivided areas, and the whole image, thereby enriching the description of the image features. It can be applied to a wide range of trademark image retrievals, and can also be applied to the retrieval of other images, effectively enhancing the matching effect of image retrieval. The present invention adopts the rough image feature descriptor and the fine image feature descriptor of the image to describe the image features, which can effectively solve the stability problem of the description of the common features and the distinguishing features of the same or similar images, make up for the defect of missing the same or similar images in image retrieval caused by the traditional image feature extraction technology method, and improve the matching effect of the same or similar images in image recognition retrieval. The extraction technology method based on the rough image feature descriptor and the fine image feature descriptor of the image of the present invention can effectively make up for the defect of missing the same or similar images in image retrieval caused by the traditional image feature extraction technology method. The technical method has the advantages of more comprehensive and accurate description of image feature information, and can effectively improve the recall rate and precision rate of the image. BRIEF DESCRIPTION OF THE DRAWINGS

[0085] Figure 1 It is a flow chart of a method for extracting image features and obtaining descriptors according to the present invention;

[0086] Figure 2 is an exemplary picture to be processed;

[0087] Figure 3 An exemplary local color block connected domain segmentation data table of an image to be processed;

[0088] Figure 4 A schematic diagram of an exemplary image to be processed being divided into 15 equal parts horizontally;

[0089] Figure 5 The exemplary image to be processed is divided horizontally into 15 equal parts with a standard schematic diagram of the unit line length of the subdivided area. DETAILED DESCRIPTION

[0090] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and cannot be understood as limiting the present invention.

[0091] In the description of the present invention, it is to be understood that the terms “center”, “longitudinal”, “lateral”, “length”, “width”, “thickness”, “up”, “down”, “left”, “right”, “vertical”, “horizontal”, “top”, “bottom”, “inside”, “outside”, “axial”, “radial”, “circumferential”, etc., indicating orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.

[0092] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, unless otherwise specified, "plurality" means two or more.

[0093] In the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a direct connection, or an indirect connection through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.

[0094] like Figures 1 to 5 As shown, an image feature extraction and descriptor acquisition method includes the following steps:

[0095] Step A: extracting the effective area image and pixel color value data of the image to be processed and performing color block segmentation to obtain the effective area image and image data of the image to be processed;

[0096] The effective area image data of the picture to be processed includes: the effective area image of the picture to be processed and the coordinate position of each pixel point of the image, the color block connected domain, the main color pixel point, and the background color image point data.

[0097] The sources of the images to be processed may include: images acquired through computer equipment, mobile phones with camera functions, cameras, webcams, or other devices that have cameras or store images, all of which can be used as images to be processed in the present technical method.

[0098] Figure 2Exemplary pictures or images to be processed are listed. Generally, the pictures or images to be processed will have background colors. These background colors are not the main features of the images and are not the focus of the analysis of the present invention. The images composed of primary color pixels are the main content of the analysis of the present invention. Because the first step of the processing is to extract the effective area image of the picture to be processed, the effective area image of the picture to be processed refers to the image composed of the effective area in the picture to be processed, and the effective area refers to the internal area surrounded by the circumscribed graphics of the set of primary color pixels. The circumscribed graphics include: circumscribed square, circumscribed circle, and circumscribed geometric figure.

[0099] It is worth noting that the existing technology can be used to directly extract the pixel color value data of the effective area image of the picture to be processed, and perform color block segmentation to obtain the color block connected domain, main color pixel, and background color image point data. Therefore, the steps of how to extract the pixel color value data of the effective area image will not be described in detail here.

[0100] The color block segmentation refers to classifying the color values ​​of the pixels of the image, dividing the color values ​​within a certain range into a color level, and the image composed of pixels of each color level is called a color block. The color block segmentation can be performed by two-color segmentation method and multi-color segmentation method.

[0101] The two-color segmentation method includes classifying the color value reflecting the main color feature of the image as the main color level, and classifying the color value reflecting the image other than the main color feature as the background color level;

[0102] The multi-color segmentation method includes subdividing the color values ​​reflecting the main color features of the image into X color levels, X≥2, and these color levels are respectively called the first main color level, the second main color level,..., the Xth main color level, and the color values ​​reflecting the image except the main color features are classified as background color levels.

[0103] The color block connected domain refers to a set of pixels in the image that have the same color level and are connected to each other, and the set is regarded as a color block connected domain. The color level is a color value interval divided by similar color values ​​within a certain range. Specifically, the similar color values ​​within a certain range refer to a color value interval divided according to a high concentration of pixels. The color values ​​in the interval are relatively similar, and the color value interval is regarded as a color level.

[0104] The main color pixel refers to the pixel of the main color level other than the background color level, or the pixel reflecting the main color feature of the image;

[0105] The background color pixels include pixels reflecting the image other than the pixels of the main color level or pixels other than the main color features.

[0106] Figure 3The following table lists the local color block connected domain segmentation data of the image to be processed.

[0107] Figure 3 In the , each cell represents a pixel. The number in the cell that is not empty indicates that the pixel is the main color pixel. Different numbers are used to distinguish different color block connected domains, and empty cells represent pixels of the background color. The color block connected domain is the collection of cells (pixels) with the same number.

[0108] Step B: using segmentation lines in the same direction to subdivide the effective area image into multiple equal parts, and obtaining segmented areas with the same cutting direction and a segmented area data set;

[0109] In the embodiment of the present invention, in the step B, the same direction of the dividing line includes the following directions: horizontal direction, vertical direction, and specific angle direction;

[0110] The subdivided areas with the same cutting direction include at least one of the following: a horizontally divided subdivided area, a vertically divided subdivided area, and a specific angle divided subdivided area;

[0111] The subdivided area data set is a data set of subdivided areas in one direction or multiple directions, wherein the subdivided area data set includes at least one or a combination of the following: horizontal segmentation of subdivided areas, vertical segmentation of subdivided areas, and specific angle segmentation of subdivided areas;

[0112] The horizontal segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the horizontal direction;

[0113] The vertical segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the vertical direction;

[0114] The specific angle segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the preset specific angle direction, and the preset specific angle takes a value in the integer degree from 0° to 360°;

[0115] The n equal parts are an integer greater than 3.

[0116] In a specific embodiment, when obtaining the subdivided area of ​​the effective area image of the image to be processed, the directions of the multiple segmentation lines used to segment the effective area image must be in the same direction, wherein the cutting direction of the segmentation line can be: horizontal direction, vertical direction, and specific angle direction, so as to obtain the subdivided area segmented in one direction. Figure 4As shown: When horizontal is selected, the horizontal dividing line can only divide the subdivision area in the horizontal direction. Because the multiple equal subdivision areas in the same direction obtained by multiple equal subdivisions in the same direction can enhance the comparability between images.

[0117] In a specific embodiment, when obtaining a subdivided region data set, first obtain the subdivided region of the effective image, and use a segmentation line with the same direction to divide it in any direction among horizontal, vertical or a specific angle to obtain one or more subdivided regions in the desired segmentation direction, and then combine the subdivided regions in each cutting direction to obtain one or more subdivided region data sets segmented in different directions. For example, when horizontal and vertical are selected, the directions of the segmentation lines are horizontal and vertical, respectively, and the horizontal segmented subdivided regions and the vertical segmented subdivided regions are obtained respectively, and the combination of the horizontal segmented subdivided regions and the vertical segmented subdivided regions is used as a subdivided region set segmented in multiple directions.

[0118] Figure 4 The schematic diagram of dividing an exemplary image into 15 equal parts horizontally is listed. Figure 4 There are 15 subdivision areas in total, and the nth area from top to bottom is called the nth horizontal segmentation subdivision area.

[0119] Step C: performing connected domain confirmation, line segment recognition and line length measurement on the subdivided area to obtain image feature data of the subdivided area;

[0120] In an embodiment of the present invention, in step C, it is necessary to perform connected domain confirmation, line segment recognition and line length measurement on the subdivided area of ​​the effective area image of the image to be processed, so as to obtain image feature data of the subdivided area of ​​the effective area image of the image to be processed, wherein the image feature data of the subdivided area of ​​the effective area image includes: the number of connected domains of the subdivided area, the number of line segments of the subdivided area and the line length value of the subdivided area;

[0121] The specific steps include:

[0122] Step C1: confirm the connected domains in the subdivided area and obtain the number of connected domains in the subdivided area.

[0123] The connected domain is a local area formed by a set of main color block pixels that are connected to each other in the subdivided area. The connected domain can be a color block, a color line, or a color point.

[0124] Step C2: Identify the line segments of the subdivided area and obtain the number of line segments of the subdivided area.

[0125] In an embodiment of the present invention, a method for obtaining the number of line segments of a subdivided area includes:

[0126] First, the validity of each connected domain in the subdivided area is judged and determined according to the preset valid connected domain condition, and the valid connected domain of the subdivided area is obtained; then, the number of valid connected domains in the subdivided area is counted; finally, the number of valid connected domains in the subdivided area is used as the number of line segments in the subdivided area.

[0127] The line segment of the subdivided area is a connected area in the subdivided area that meets the preset valid connected area conditions. The connected areas in the subdivided area in the same subdivided direction are often arranged like on a line. From a rough perspective, the arrangement of multiple valid connected areas is similar to a line segment. Therefore, the present invention regards the connected area in the subdivided area that meets the preset valid connected area conditions as the line segment of the subdivided area.

[0128] The preset valid connected domain condition includes: when the maximum height of the connected domain is equal to the height of the subdivided area and / or the maximum length of the connected domain is greater than or equal to the unit line length standard of the subdivided area.

[0129] The method for identifying a connected domain that meets the preset valid connected domain conditions includes:

[0130] When the maximum height of the connected domain is equal to the height of the subdivided area, and / or the maximum length of the connected domain is greater than or equal to the unit line length standard of the subdivided area, the connected domain is identified as a valid connected domain in the subdivided area, otherwise, it is identified as an invalid connected domain;

[0131] In practical applications, the shape characteristics of the connected domain and the area characteristics of the connected domain may also be listed as the preset effective connected domain conditions according to application requirements.

[0132] Step C3: Measure the line length of the subdivided area and obtain the line length value of the subdivided area.

[0133] The line length of the subdivided area refers to the length of the main color block pixels of the effective connected area in the subdivided area in the direction of the dividing line of the subdivided area.

[0134] The line length value of the subdivided area described in the present invention refers to the value of the number of main color block pixels in the effective connected area of ​​the subdivided area in the direction of the dividing line of the subdivided area measured by the subdivided area unit line length standard. The subdivided area unit line length standard refers to the standard of the minimum unit for measuring the length of the subdivided area.

[0135] The method for obtaining the line length value of the subdivided area includes:

[0136] Step C31: Determine the unit line length standard of the subdivided area;

[0137] Step C32: obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area;

[0138] Step C33: rounding the line length value of each subdivided area.

[0139] Furthermore, in an embodiment of the present invention, a specific method for obtaining the line length value of the subdivided area includes:

[0140] Step C31: Determine the unit line length standard of the subdivided area;

[0141] In the embodiment of the present invention, the method of determining the unit line length standard of the subdivided area in step C31 includes: determining the unit line length standard of the subdivided area using a fixed constant method and / or a maximum line segment number method;

[0142] The fixed constant method includes: taking the line length of the largest subdivided area of ​​the effective area image of the image to be processed as the reference, the preset fixed constant N is used as the number of equal parts, and the line length of each equal part is the minimum unit for measuring the length of the subdivided area, and the minimum unit for measuring the line length is used as the unit line length standard of the subdivided area. The fixed constant N takes a value in the range of greater than 3. The calculation formula is as follows:

[0143] L1=m / N;

[0144] L1 represents the unit line length standard of the subdivided area of ​​the fixed constant method, m represents the pixel length of the effective connected domain of the largest subdivided area in the effective area image to be processed, and N represents a preset fixed constant.

[0145] Figure 5 The following is a schematic diagram of the standard unit line length of 15 equally divided horizontal subdivision areas of an exemplary image. Figure 5 In the figure, the outer frame line represents the maximum horizontal segmentation range of the valid area image of the image to be processed. Assuming that the fixed constant N is 15, the number of small squares inside the outer frame represents the number of equal parts of the segmented area. The length of each small square is equal to the unit line length standard of each segmented area. The number of small squares is also the line length value of the segmented area.

[0146] The maximum line segment number method includes: using the maximum line length of the subdivided area of ​​the valid area image to be processed as a reference, using the maximum number of line segments of the subdivided area of ​​the valid area image to be processed as the number of equal parts, and the line length of each equal part is the minimum unit for measuring the length of the subdivided area, and the minimum unit for measuring the line length is used as the unit line length standard of the subdivided area. The calculation formula is as follows:

[0147] L2=m / n1;

[0148] L2 represents the unit line length standard of the subdivided area of ​​the maximum line segment number method, m represents the pixel length of the effective connected domain of the largest subdivided area in the effective area image to be processed, and n1 represents the maximum number of line segments in the subdivided area of ​​the effective area image to be processed.

[0149] Step C32: obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area;

[0150] In an embodiment of the present invention, the step C32 of obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area specifically includes:

[0151] When the fixed constant method is used to determine the unit line length standard of the subdivided area, the line length value of each subdivided area is obtained according to the following formula:

[0152] H1=S / L1;

[0153] Wherein, H1 represents the line length value of the subdivided area using the fixed constant method, S represents the pixel length of the effective connected domain of the current subdivided area, and L1 represents the unit line length standard of the subdivided area using the fixed constant method;

[0154] When the maximum line segment method is used to determine the unit line length standard of the subdivided area, the line length value of each subdivided area is obtained according to the following formula:

[0155] H2=S / L2;

[0156] H2 represents the line length value of the subdivided area using the maximum line segment method, S represents the pixel length of the effective connected domain of the current subdivided area, and L2 represents the unit line length standard of the subdivided area using the maximum line segment number method.

[0157] Step C33: rounding the line length value of each subdivided area;

[0158] In the embodiment of the present invention, the line length values ​​H1 and H2 of the subdivided areas calculated by the above formula are often not integers. In order to facilitate the comparison of common features of the line length values ​​of the subdivided areas between images, the line length values ​​of the subdivided areas need to be rounded in practical applications.

[0159] Step D: performing statistics and combination processing on the image feature data of the subdivided area to obtain an image feature descriptor, wherein the image feature descriptor includes at least one or more of the following: a coarse image feature descriptor and a fine image feature descriptor.

[0160] The coarse image feature descriptor is optional data of the image feature descriptor of the subdivided area of ​​the image to be processed, and its purpose is to be used for coarse and fine filtering of image feature data retrieval, while the fine image feature descriptor is the main data of the image feature descriptor of the subdivided area of ​​the image to be processed, and is used for fine calculation and evaluation of the approximation degree of the retrieved image.

[0161] The steps of obtaining image feature descriptors include: step D1: obtaining a coarse image feature descriptor, and step D2: obtaining a fine image feature descriptor.

[0162] In an embodiment of the present invention, step D1, obtaining a rough image feature descriptor, specifically includes the following steps:

[0163] Step D11: combining the subdivided areas of the effective area image of the picture to be processed to obtain a combined partial area of ​​the effective area image of the picture to be processed;

[0164] Step D12: Counting the line length data of each of the combined partial areas;

[0165] Step D13: Counting the feature data of the length of the line segments in the entire range of the effective area image of the image to be processed;

[0166] Step D14: combining the line segment length data of each combined partial area and the feature data of the line segment length of the entire range to generate a rough image feature descriptor.

[0167] The rough image feature descriptor refers to a descriptor that roughly describes the common features of an image from a relatively large local range or / and an overall range in the image, including: data information that roughly describes the common features of an image from a relatively large local range in the effective area image of the image to be processed and data information that roughly describes the common features of an image from an overall range in the effective area image of the image to be processed.

[0168] In an embodiment of the present invention, the step D11 includes: combining at least two subdivided areas of the effective area image of the image to be processed according to a positional adjacent or connected relationship according to a combination rule to form a local area, wherein the local area is a combined partial area of ​​the effective area image of the image to be processed;

[0169] The combination rules include:

[0170] (1) The subdivided areas of the same combined part area should be connected or adjacent to each other;

[0171] (2) The number of subdivided area combinations of each combined partial area should be equal to each other or the deviation is less than a preset deviation value, and the preset deviation value is greater than or equal to 1 and less than 10;

[0172] (3) The number of subdivision area combinations of each combined partial area should be greater than or equal to 2.

[0173] The combined partial area can be called the Nth combined partial area in the horizontal direction or the Nth combined partial area in the vertical direction, the Nth combined partial area in the direction of angle C, etc. according to the subdivided area combination obtained by different segmentation methods, for example:

[0174] The subdivided area combinations obtained by the horizontal segmentation method can be called in order of arrangement: the first combined partial area in the horizontal direction, the second combined partial area in the horizontal direction, the third combined partial area in the horizontal direction, ..., the Nth combined partial area in the horizontal direction. Alternatively, they can be called: the upper combined partial area, ..., the middle combined partial area, ..., the lower combined partial area.

[0175] The subdivided region combinations obtained by the vertical segmentation method can be called in order of arrangement: the first combined partial region in the vertical direction, the second combined partial region in the vertical direction, the third combined partial region in the vertical direction, ..., the Nth combined partial region in the vertical direction. Alternatively, they can be called: the left combined partial region, ..., the middle combined partial region, ..., the right combined partial region.

[0176] The combination of subdivided areas obtained by using the specific angle segmentation method can be called in order of arrangement: the first combined partial area in the angle C direction, the second combined partial area in the angle C direction, the third combined partial area in the angle C direction,..., the Nth combined partial area in the angle C direction.

[0177] In an embodiment of the present invention, the step D12 counts the line segment length data of each of the combined partial regions, wherein the line segment length data of each of the combined partial regions specifically includes: the average number of line segments in the combined partial region, the main number of line segments in the combined partial region, the average line length value of the combined partial region, and the main line length value of the combined partial region;

[0178] The average number of line segments in the combined partial area is the sum of the number of line segments in each subdivided area of ​​the current combined partial area divided by the number of subdivided areas of the current combined partial area. The average number of line segments in the combined partial area reflects an image feature data of the concentration trend of the number of line segments in a larger local area of ​​the image.

[0179] The main line segment number of the combined partial area refers to when a certain line segment number within the combined partial area has the largest number of subdivided areas and the ratio of the number of subdivided areas to the total number of subdivided areas of the combined partial area is greater than the preset value of the line segment number ratio, then the certain line segment number is the main line segment number of the combined partial area, which reflects an image feature data that has the same line segment number feature in a larger local area. The preset value of the line segment number ratio is taken in the range of greater than 30% and less than or equal to 100%.

[0180] The average line length value of the combined partial area is obtained by dividing the sum of the line length values ​​of the subdivided areas of the current combined partial area by the number of subdivided areas of the current combined partial area. The average line length value of the combined partial area reflects an image feature data of the concentration trend of line length values ​​in a larger local area of ​​the image.

[0181] The main line length value of the combined partial area means that when a certain line length value within the combined partial area has the largest number of subdivided areas and the ratio of the number of subdivided areas to the total number of subdivided areas of the combined partial area is greater than the preset value of the line length value ratio, then the certain line length value is the main line length value of the combined partial area, which reflects an image feature data having the same line length value feature in a larger local area. Wherein, the preset value of the line length value ratio is taken in the range of greater than 30% and less than or equal to 100%.

[0182] In an embodiment of the present invention, the step D13 counts the feature data of the line lengths of the entire range of the effective area image of the image to be processed. The line length feature data is the following data for the entire range of the effective area image of the image to be processed: the total number of line segments in each subdivided area, the total number of line length values ​​in each subdivided area, and the number of color block connected domains in the effective area image;

[0183] Obtaining the number of color block connected domains of the effective area image of the image to be processed according to the image feature data of the subdivided area of ​​the effective area image of the image to be processed;

[0184] Obtain the sum of the number of line segments in each subdivided area in the valid area image of the image to be processed, and the sum is the total number of line segments in each subdivided area;

[0185] The sum of the line length values ​​of each subdivided area in the effective area image of the image to be processed is obtained, and the sum is the total number of line length values ​​of each subdivided area.

[0186] In the embodiment of the present invention, the step D14 combines the line segment length data of each of the combined partial areas with the feature data of the line segment length of the entire range to generate a rough image feature descriptor.

[0187] The rough image feature descriptor includes: an average line segment number combined descriptor of the combined partial area of ​​the image, a main line segment number combined descriptor of the combined partial area of ​​the image, an average line length value combined descriptor of the combined partial area of ​​the image, a main line length value combined descriptor of the combined partial area of ​​the image, and a color block connected domain number descriptor of the effective area image. The rough image feature descriptor can be represented by numbers or other characters.

[0188] The method of expressing the average number of line segments in the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line segments in all subdivided areas of the valid area image; (2) the average number of line segments in each combined partial area;

[0189] The method for expressing the combined descriptor of the number of main line segments in the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line segments in all subdivided areas of the effective area image; (2) the number of main line segments in each combined partial area;

[0190] The method for expressing the combined descriptor of the average line length value of the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line length values ​​of all subdivided areas of the effective area image; (2) the average line length value of each combined partial area;

[0191] The method for expressing the combined descriptor of the main line length values ​​of the combined partial areas of the image is composed of the following combinations: (1) the total number of line length values ​​of all subdivided areas of the effective area image represented by numbers or other characters; (2) the main line length values ​​of each combined partial area;

[0192] The method for expressing the number of connected domains of color blocks in the effective area image is as follows: using numbers or other characters to express the number of connected domains of color blocks in the effective area image;

[0193] Figure 2 A schematic diagram of an exemplary valid area image of an image to be processed is listed in Figure 5 Taking the exemplary pattern of as an example, the representation method of each coarse image feature descriptor is further described as follows:

[0194] Average number of line segments in the combined part of the image. Application example of combined descriptor:

[0195] Example 1: Assuming that the number of combined partial regions of an image is 2, the combined descriptor of the average number of line segments of the combined partial regions of the image is: 0370102;

[0196] Among them, the first three digits represent the total number of line segments in all subdivided areas of the valid area image, the fourth and fifth digits represent the average number of line segments in the first combined partial area, and the sixth and seventh digits represent the average number of line segments in the second combined partial area.

[0197] Example 2: Assuming that the number of combined partial regions of an image is 3, the combined descriptor of the average number of line segments of the combined partial regions of the image is: 037010102;

[0198] Among them, the first three digits represent the total number of line segments in all subdivided areas of the valid area image, the fourth and fifth digits represent the average number of line segments in the first combined partial area, the sixth and seventh digits represent the average number of line segments in the second combined partial area, and the eighth and ninth digits represent the average number of line segments in the third combined partial area.

[0199] And so on.

[0200] Application example of the main line segment number combination descriptor in the combined part of the image:

[0201] Example 3: Assuming that the number of combined partial regions of an image is 3, the combined descriptor of the number of main line segments of the combined partial regions of the image is: 037010102;

[0202] Among them, the first three digits represent the total number of line segments in all subdivided areas of the valid area image of the picture to be processed, the fourth and fifth digits represent the number of main line segments in the first combined partial area, the sixth and seventh digits represent the number of main line segments in the second combined partial area, and the eighth and ninth digits represent the number of main line segments in the third combined partial area.

[0203] And so on.

[0204] An example of the application of the combined descriptor of the average line length value of the combined part of the image:

[0205] Example 4: Assuming that the number of combined partial regions of the image is 3, the combined descriptor of the average line length value of the combined partial regions of the image is: 180151314;

[0206] Among them, the first three digits represent the total line length values ​​of all subdivided areas of the valid area image of the picture to be processed, the fourth and fifth digits represent the average line length value of the first combined partial area, the sixth and seventh digits represent the average line length value of the second combined partial area, and the eighth and ninth digits represent the average line length value of the third combined partial area.

[0207] And so on.

[0208] Application example of main line length value combination descriptor in the combined part of the image:

[0209] Example 5: Assuming that the number of combined partial regions of an image is 3, the combined descriptor of the main line length values ​​of the combined partial regions of the image is: 180151514;

[0210] Among them, the first three digits represent the total line length values ​​of all subdivided areas of the valid area image of the picture to be processed, the fourth and fifth digits represent the average line length value of the first combined partial area, the sixth and seventh digits represent the average line length value of the second combined partial area, and the eighth and ninth digits represent the average line length value of the third combined partial area.

[0211] And so on.

[0212] In an embodiment of the present invention, step D2, obtaining a fine image feature descriptor, specifically includes the following steps:

[0213] The fine image feature descriptor refers to a descriptor that finely describes the common features of the image from a relatively small local (subdivided area) range in the effective area image of the image to be processed. The relatively small local area is the subdivided area, which is the smallest segmentation unit of the image data of the technical solution and has fine features.

[0214] The fine image feature descriptor includes: a set of line segment numbers and a set of line length values ​​of each subdivided area in the effective area image of the image to be processed;

[0215] The set of a group of numbers or character strings recording the number of line segments of each subdivided area in the order of the number of the subdivided areas is the set of line segment numbers of each subdivided area. Specifically, the method for expressing the set of line segment numbers of each subdivided area includes:

[0216] (1) The number of groups of numbers or other characters is equal to the number of subdivided areas of the valid area image of the image to be processed;

[0217] (2) Each group of numbers should represent the number of the subdivision area and the number of line segments in the subdivision area.

[0218] A set of numbers or character strings recording the line length values ​​of each subdivided area in the order of the subdivided area numbers is a line length value set of each subdivided area. Specifically, the method for expressing the set of line length values ​​of each subdivided area includes:

[0219] (1) The number of groups of numbers or other characters is equal to the number of subdivided areas of the valid area image of the image to be processed;

[0220] (2) Each group of numbers should represent the number of the subdivision area and the line length value of the subdivision area.

[0221] by Figure 2 Taking the exemplary pattern of as an example, the representation method of the fine image feature descriptor is further explained as follows:

[0222] An example of the application of the descriptor of the set of line segments in each subdivision area of ​​the image:

[0223] Example 6: Assumption Figure 2 The exemplary pattern is divided into 25 subdivision areas, and the descriptor of the set of line segment numbers of each subdivision area of ​​the image can be recorded as:

[0224] 0102,0202,0302,0402,0502,0602,0702,0802,0902,1002,1102,1202,1300,1402,1502,1602,1702,1802,1902,2002,2102,2202,2302,2402,2502;

[0225] Among them, the numbers in each "," are a group of numbers, and 25 groups of numbers are used to represent the 25 subdivision areas of the image. Each group of numbers represents the number of the subdivision area and the number of line segments of the subdivision area corresponding to the number. The first two digits of each group of numbers represent the number of the subdivision area, and the third and fourth digits of each group of numbers represent the number of line segments of the subdivision area.

[0226] An example of the application of the descriptor of the set of line segments in each subdivision area of ​​the image:

[0227] Example 7: Assumption Figure 5 The exemplary pattern is divided into 25 subdivision areas, and the descriptor of the set of line length values ​​of each subdivision area of ​​the image can be recorded as:

[0228] 0115,0215,0315,0415,0515,0615,0715,0815,0915,1015,1115,1215,1303,1414,1514,1614,1714,1814,1914,2014,2114,2214,2314,2414,2514;

[0229] Among them, the numbers in each "," are a group of numbers, and 25 groups of numbers represent the 25 subdivision areas of the image. Each group of numbers represents the number of the subdivision area and the line length value of the subdivision area corresponding to the number. The first two digits of each group of numbers represent the number of the subdivision area, and the third and fourth digits of each group of numbers represent the line length value of the subdivision area. After the above steps, the coarse image feature descriptor and fine image feature descriptor of the image are obtained, which are used as the image feature descriptors of the image to be processed. The combined extraction and application of coarse image feature descriptors and fine image feature descriptors can effectively take into account the commonality and distinguishability of images.

[0230] In an embodiment of the present invention, it also relates to an image feature extraction and descriptor acquisition device, comprising: an image data acquisition module, a subdivided region processing module, a subdivided region data acquisition module and an image feature descriptor acquisition module;

[0231] The image data acquisition module is used to extract the effective area image and pixel color value data of the image to be processed and perform color block segmentation to obtain the effective area image and image data of the image to be processed;

[0232] The subdivided region processing module is used to subdivide the effective region image into multiple equal parts using segmentation lines in the same direction, and obtain subdivided regions with the same cutting direction and subdivided region data sets;

[0233] The subdivided area data acquisition module is used to confirm the connected domain, identify the line segments and measure the line length of the subdivided area to obtain the image feature data of the subdivided area;

[0234] The image feature descriptor acquisition module is used to perform statistics and combination processing on the image feature data of the subdivided area to obtain image feature descriptors, including at least one or more of the following: a coarse image feature descriptor and a fine image feature descriptor.

[0235] In an embodiment of the present invention, there is also provided a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the following steps are implemented:

[0236] Extract the valid area image and pixel color value data of the image to be processed and perform color block segmentation to obtain the valid area image and image data of the image to be processed;

[0237] Subdividing the effective area image into multiple equal parts in one direction or multiple directions to obtain subdivided areas of the effective area image;

[0238] Performing connected domain confirmation, line segment recognition and line length measurement on the subdivided area to obtain image feature data of the subdivided area;

[0239] The image feature data of the subdivided area are statistically processed and combined to obtain an image feature descriptor, wherein the image feature descriptor includes at least one or more of the following: a coarse image feature descriptor and a fine image feature descriptor.

[0240] In an embodiment of the present invention, an image data storage device is also provided, comprising:

[0241] A coarse image feature descriptor storage unit is used to store coarse image feature descriptors generated by a method implemented in any one of the following steps when the computer program is executed by a processor: extracting the effective area image and pixel color value data of the image to be processed and performing color block segmentation to obtain the effective area image and image data of the image to be processed; subdividing the effective area image into multiple equal parts in the same direction to obtain subdivided areas or a set of multiple subdivided areas segmented in the same direction of the effective area image of the image to be processed; confirming connected domains, identifying line segments and measuring line lengths of the subdivided areas to obtain image feature data of the subdivided areas; and performing statistical and combination processing on the image feature data of the subdivided areas to obtain coarse image feature descriptors.

[0242] A fine image feature descriptor storage unit is used to store fine image feature descriptors generated by a method implemented in any one of the following steps when the computer program is executed by a processor: extracting the effective area image and pixel color value data of the image to be processed and performing color block segmentation to obtain the effective area image and image data of the image to be processed; subdividing the effective area image into multiple equal parts in the same direction to obtain subdivided areas or a set of multiple subdivided areas segmented in the same direction of the effective area image of the image to be processed; confirming connected domains, identifying line segments and measuring line lengths of the subdivided areas to obtain image feature data of the subdivided areas; and performing statistical and combination processing on the image feature data of the subdivided areas to obtain fine image feature descriptors.

[0243] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0244] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0245] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "illustrative embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0246] Although the embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the claims and their equivalents.

Claims

1. A method for extracting image features and obtaining descriptors, characterized in that: The steps include: Step A: extracting the effective area image and pixel color value data of the image to be processed and performing color block segmentation to obtain the effective area image and image data of the image to be processed; Step B: using a segmentation line in the same direction to divide the effective area image into multiple equal parts, and obtaining segmented areas and segmented area data sets; wherein the cutting direction of the segmentation line can be: horizontal direction, vertical direction, and specific angle direction, so as to obtain segmented areas divided in one direction, wherein the specific angle direction is an angle direction other than horizontal direction and vertical direction; The subdivided region data set includes: using a segmentation line with the same direction to divide in any one of the horizontal direction, the vertical direction or the specific angle direction to obtain a subdivided region in a segmentation direction, combining the subdivided regions in each cutting direction to obtain a subdivided region data set divided in one or more directions; The horizontal segmentation subdivision area refers to a segmentation area obtained by dividing the effective area image into n equal parts along the horizontal direction, and the n equal parts are an integer greater than 3; The vertical segmentation subdivision area refers to a segmentation area obtained by dividing the effective area image into n equal parts along the vertical direction, and the n equal parts are an integer greater than 3; The specific angle segmentation subdivision area refers to the segmentation area obtained by dividing the effective area image into n equal parts along the preset specific angle direction, and the preset specific angle takes a value in the integer degree from 0° to 360°; Step C: performing connected domain confirmation, line segment recognition and line length measurement on the subdivided area to obtain image feature data of the subdivided area; the image feature data of the subdivided area includes: the number of connected domains of the subdivided area, the number of line segments of the subdivided area and the line length value of the subdivided area; Step D: performing statistics and combination processing on the image feature data of the subdivided area to obtain an image feature descriptor, wherein the image feature descriptor includes at least one or more of the following: a coarse image feature descriptor and a fine image feature descriptor; The steps of statistically analyzing and combining the image feature data of the subdivided areas include: combining the subdivided areas of the effective area image of the image to be processed to obtain the combined partial areas of the effective area image of the image to be processed; statistically analyzing the line segment length data of each of the combined partial areas; statistically analyzing the feature data of the line segment length of the entire range in the effective area image of the image to be processed; combining the line segment length data of each of the combined partial areas with the feature data of the line segment length of the entire range to generate a rough image feature descriptor; using the line segment number set of each subdivided area in the effective area image of the image to be processed and the line length value set of each subdivided area as a fine image feature descriptor; The rough image feature descriptor includes: an average line segment number combined descriptor of the combined partial area of ​​the image, a main line segment number combined descriptor of the combined partial area of ​​the image, an average line length value combined descriptor of the combined partial area of ​​the image, a main line length value combined descriptor of the combined partial area of ​​the image, and a color block connected domain number descriptor of the effective area image. The rough image feature descriptor is represented by numbers or other characters.

2. The method for extracting image features and obtaining descriptors according to claim 1, characterized in that: In step C, obtaining image feature data of the subdivided area includes the following steps: Step C1: confirm the connected domains in the subdivided area and obtain the number of connected domains in the subdivided area; The connected region is a local area formed by a set of main color block pixels connected to each other in the subdivided area; Step C2: Identify the line segments of the subdivided area and obtain the number of line segments of the subdivided area; The acquisition steps are as follows: Judging and determining the validity of each connected domain in the subdivided area according to a preset valid connected domain condition, and obtaining the valid connected domain of the subdivided area; Counting the number of valid connected domains in the subdivided area; The number of valid connected domains in the subdivided area is taken as the number of line segments in the subdivided area; The line segment of the subdivided area is a connected domain in the subdivided area that meets the preset valid connected domain conditions, and the preset valid connected domain conditions include: when the maximum height of the connected domain is equal to the height of the subdivided area and / or the maximum length of the connected domain is greater than or equal to the unit line length standard of the subdivided area; Step C3: measuring the line length of the subdivided area to obtain the line length value of the subdivided area; The line length of the subdivided area refers to the length of the main color block pixels of the effective connected area in the subdivided area in the direction of the dividing line of the subdivided area; the line length value of the subdivided area refers to the value of the number of main color block pixels of the effective connected area in the subdivided area in the direction of the dividing line of the subdivided area measured by the subdivided area unit line length standard; the subdivided area unit line length standard refers to the standard of the minimum unit for measuring the length of the subdivided area; The method for obtaining the line length value of the subdivided area includes: Step C31: Determine the unit line length standard of the subdivided area; Step C32: obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area; Step C33: rounding the line length value of each subdivided area.

3. The method for extracting image features and obtaining descriptors according to claim 2, characterized in that: Methods for determining the unit line length standard of the subdivided area include: a fixed constant method or a maximum line segment number method; The fixed constant method includes: taking the line length of the largest subdivided area of ​​the effective area image of the image to be processed as a reference, a preset fixed constant N as the number of equal parts, the line length of each equal part is the minimum unit for measuring the length of the subdivided area, and the minimum unit for measuring the line length is used as the unit line length standard of the subdivided area, wherein the fixed constant N is greater than 3; the calculation formula of the fixed constant method is as follows: L1=m / N; L1 represents the unit line length standard of the subdivided area of ​​the fixed constant method, m represents the pixel length of the effective connected domain of the largest subdivided area in the effective area image to be processed, and N represents a preset fixed constant; The maximum line segment number method includes: taking the maximum line length of the subdivided area of ​​the valid area image to be processed as a reference, taking the maximum number of line segments of the subdivided area of ​​the valid area image to be processed as the number of equal parts, the line length of each equal part is the minimum unit for measuring the length of the subdivided area, and the minimum unit for measuring the line length is used as the unit line length standard of the subdivided area. The calculation formula is as follows: L2=m / n1; L2 represents the unit line length standard of the subdivided area of ​​the maximum line segment number method, m represents the pixel length of the effective connected domain of the largest subdivided area in the effective area image to be processed, and n1 represents the maximum number of line segments in the subdivided area of ​​the effective area image to be processed; The step C32 of obtaining the line length value of each subdivided area according to the unit line length standard of the subdivided area includes: Determine the method currently used to confirm the unit line length standard of the subdivided area. If the method for confirming the unit line length standard of the subdivided area is the fixed constant method, the formula for obtaining the line length value of each subdivided area is as follows: H1=S / L1; Wherein, H1 represents the line length value of the subdivided area using the fixed constant method, S represents the pixel length of the effective connected domain of the current subdivided area, and L1 represents the unit line length standard of the subdivided area using the fixed constant method; If the method for confirming the unit line length standard of the subdivided area is the maximum line segment method, the formula for obtaining the line length value of each subdivided area is as follows: H2=S / L2; H2 represents the line length value of the subdivided area using the maximum line segment method, S represents the pixel length of the effective connected domain of the current subdivided area, and L2 represents the unit line length standard of the subdivided area using the maximum line segment number method.

4. The method for extracting image features and obtaining descriptors according to claim 1, characterized in that: In the step of "combining the subdivided areas of the effective area image of the picture to be processed to obtain a combined partial area of ​​the effective area image of the picture to be processed", at least two subdivided areas in a positionally adjacent or connected relationship are obtained in the effective area image of the picture to be processed, and combined according to a combination rule to form a local area, wherein the local area is a combined partial area of ​​the effective area image of the picture to be processed; The combination of subdivided areas of the valid area image must meet the following rules: Subdivided areas of the same combined part area should be connected or adjacent to each other; The number of subdivided area combinations of each combined partial area should be equal to each other or the deviation is less than a preset deviation value, and the preset deviation value is greater than or equal to 1 and less than 10; The number of subdivision area combinations of each combined partial area should be greater than or equal to 2; In the step of "counting the line segment length data of each of the combined partial regions", the line segment length data of each of the combined partial regions specifically include: the average number of line segments in the combined partial region, the main number of line segments in the combined partial region, the average line length value of the combined partial region, and the main line length value of the combined partial region; The average number of line segments of the combined partial area is the sum of the number of line segments of each subdivided area of ​​the current combined partial area divided by the number of subdivided areas of the current combined partial area; The method for obtaining the number of main line segments in the combined partial area is as follows: Statistically obtain the line segment with the most subdivided areas within the combined partial area and the ratio of the number of subdivided areas being greater than a threshold, wherein the number of subdivided areas represents the ratio of the number of subdivided areas owned by the line segment to the total number of subdivided areas, and the threshold is greater than 30% and less than or equal to 100%; The average line length of the combined partial area is the sum of the line length values ​​of the subdivided areas of the current combined partial area divided by the number of subdivided areas of the current combined partial area; The main line length value of the combined partial area means: when a certain line length value within the combined partial area has the largest number of subdivided areas and the ratio of the number of subdivided areas to the total number of subdivided areas of the combined partial area is greater than the preset value of the line length value ratio, then the certain line length value is the main line length value of the combined partial area; wherein the preset value of the line length value ratio is taken in the range of greater than 30% and less than or equal to 100%; In the step of "counting the characteristic data of the length of the line segments in the entire range of the effective area image of the picture to be processed", the characteristic data of the length of the line segments in the entire range of the effective area image of the picture to be processed are counted; wherein the characteristic data of the length of the line segments is the following data for the entire range of the effective area image of the picture to be processed: the total number of line segments in each subdivided area, the total number of line length values ​​in each subdivided area, and the number of color block connected domains in the effective area image; Obtaining the number of color block connected domains of the effective area image of the image to be processed according to the image feature data of the subdivided area of ​​the effective area image of the image to be processed; Obtain the sum of the number of line segments in each subdivided area in the valid area image of the image to be processed, and the sum is the total number of line segments in each subdivided area; Obtain the sum of the line length values ​​of each subdivided area in the valid area image of the image to be processed, and the sum is the total number of line length values ​​of each subdivided area; In the step of "combining the line segment length data of each of the combined partial areas with the feature data of the line segment length of the entire range to generate a rough image feature descriptor", the rough image feature descriptor includes: a combined descriptor of the average number of line segments of the combined partial areas of the image, a combined descriptor of the main number of line segments of the combined partial areas of the image, a combined descriptor of the average line length value of the combined partial areas of the image, a combined descriptor of the main line length value of the combined partial areas of the image, and a descriptor of the number of connected domains of color blocks in the effective area image, and the rough image feature descriptor can be represented by numbers or other characters; The method for expressing the combined descriptor of the average number of line segments in the combined partial area of ​​the image is composed of the following combinations: (1) using numbers or other characters to represent the total number of line segments in all subdivided areas of the effective area image; (2) the average number of line segments in each combined partial area; The method for expressing the combined descriptor of the number of main line segments in the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line segments in all subdivided areas of the effective area image; (2) the number of main line segments in each combined partial area; The method for expressing the combined descriptor of the average line length value of the combined partial area of ​​the image is composed of the following combinations: (1) a number or other characters representing the total number of line length values ​​of all subdivided areas of the effective area image; (2) the average line length value of each combined partial area; The method for expressing the combined descriptor of the main line length values ​​of the combined partial area of ​​the image is composed of the following combinations: (1) the total number of line length values ​​of all subdivided areas of the valid area image represented by numbers or other characters; (2) the main line length values ​​of each combined partial area.

5. The method for extracting image features and obtaining descriptors according to claim 1, characterized in that: The line segment number set of each subdivided area refers to a set of numbers or character strings that record the line segment numbers of each subdivided area in the order of the subdivided areas. The method of expressing the line segment number set of each subdivided area includes: The number of groups of numbers or other characters is equal to the number of subdivided areas of the valid area image of the image to be processed; Each group of numbers should represent the number of the subdivision area and the number of line segments in the subdivision area; The line length value set of each subdivided area refers to a set of numbers or character strings that record the line length values ​​of each subdivided area in the order of the subdivided area numbers. The method of expressing the set of line length values ​​of each subdivided area includes: The number of groups of numbers or other characters is equal to the number of subdivided areas of the valid area image of the image to be processed; Each group of numbers should represent the number of the subdivision area and the line length value of the subdivision area.

6. An image feature extraction and descriptor acquisition device, characterized in that: include: An image data acquisition module, a subdivision region processing module, a subdivision region data acquisition module, and an image feature descriptor acquisition module; The image data acquisition module is used to extract the effective area image and pixel color value data of the image to be processed and perform color block segmentation to obtain the effective area image and image data of the image to be processed; The subdivided region processing module is used to use the segmentation lines in the same direction to perform multiple equal segments on the effective region image, and obtain the subdivided regions and the subdivided region data set; wherein the direction of the segmentation line at least includes one or more directions of a specific angle; the subdivided region acquisition includes: the directions of the multiple segmentation lines used to segment the effective region image must be in the same direction, so as to obtain the subdivided regions segmented in one direction; the subdivided region data set includes: combining the subdivided regions in each cutting direction, so as to obtain the subdivided region data sets segmented in one or more directions; The subdivided area data acquisition module is used to confirm the connected domain, identify the line segments and measure the line length of the subdivided area to obtain the image feature data of the subdivided area; the image feature data of the subdivided area includes: the number of connected domains in the subdivided area, the number of line segments in the subdivided area and the line length value of the subdivided area; The image feature descriptor acquisition module is used to perform statistics and combination processing on the image feature data of the subdivided area to obtain image feature descriptors, including at least one or more of the following: a coarse image feature descriptor and a fine image feature descriptor; The steps of statistically analyzing and combining the image feature data of the subdivided areas include: combining the subdivided areas of the effective area image of the image to be processed to obtain the combined partial areas of the effective area image of the image to be processed; statistically analyzing the line segment length data of each of the combined partial areas; statistically analyzing the feature data of the line segment length of the entire range in the effective area image of the image to be processed; combining the line segment length data of each of the combined partial areas with the feature data of the line segment length of the entire range to generate a rough image feature descriptor; using the line segment number set of each subdivided area in the effective area image of the image to be processed and the line length value set of each subdivided area as a fine image feature descriptor; The rough image feature descriptor includes: an average line segment number combined descriptor of the combined partial area of ​​the image, a main line segment number combined descriptor of the combined partial area of ​​the image, an average line length value combined descriptor of the combined partial area of ​​the image, a main line length value combined descriptor of the combined partial area of ​​the image, and a color block connected domain number descriptor of the effective area image. The rough image feature descriptor is represented by numbers or other characters.

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

8. An image data storage device, characterized in that: include: A coarse image feature descriptor storage unit, used to store the coarse image feature descriptor generated by the method according to any one of claims 1 to 5 when the computer program is executed by the processor; A fine image feature descriptor storage unit is used to store the fine image feature description generated by implementing any one of claims 1-5 when the computer program is executed by the processor.