Clothing attribute recognition method, device and electronic equipment

Through the clothing attribute recognition method based on neural network, the pre-trained model is used to automatically identify clothing attributes, which solves the problems of low efficiency and error-prone manual identification in the existing technology, and achieves efficient and accurate clothing attribute recognition.

CN111079757BActive Publication Date: 2024-09-20BEIJING QIHOOD TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201811223714.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2018-10-19
Publication Date
2024-09-20
Estimated Expiration
2038-10-19

AI Technical Summary

Technical Problem

The existing technology that manually obtains the clothing attribute information of a target person or target group has problems such as inefficiency, error-prone, and high labor costs.

Method used

The clothing attribute recognition method based on neural network is used to identify the clothing attributes of the image to be recognized through the pre-trained neural network model, including body shape area segmentation, clothing feature extraction and similarity calculation, to achieve automatic identification of clothing attributes.

Benefits of technology

It improves the efficiency and accuracy of clothing attribute recognition, reduces the cost of manual recognition, and avoids manual recognition errors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111079757B
    Figure CN111079757B
Patent Text Reader

Abstract

The embodiments of the present application provide a clothing attribute recognition method, device and electronic device, which are applied to the field of image recognition technology, wherein the method comprises: identifying and determining that an image to be recognized includes at least one target person through a preset recognition method, and then performing clothing attribute recognition on the image to be recognized including the at least one target person through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person, that is, the embodiments of the present application realize automatic recognition of the clothing attributes of the target person included in the image to be recognized through the pre-trained neural network recognition model, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors in manual recognition, and reducing labor costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image recognition technology, and more specifically, to a clothing attribute recognition method, device and electronic device. Background Art

[0002] Clothes rank first among the “food, clothing, housing and transportation” commonly mentioned in our country. Clothes have become an indispensable thing for people. It is of great value to obtain clothing attribute information of target persons or target groups. For example, merchants can provide customers with targeted clothing products based on the clothing attribute information obtained. Public security organs can quickly find lost children or quickly identify criminal suspects through the clothing attribute information obtained from the target persons. How to obtain clothing attribute information of target persons or target groups has become a key issue.

[0003] At present, in order to identify and determine the clothing attribute information of a target person or a target group, the existing technology adopts a manual classification and statistics method to obtain the clothing attribute information of the target person or the target object. For example, a merchant's researcher collects images of people passing by at an intersection, and then manually counts the clothing attribute information (such as the color and style of clothes and accessories) of the target person contained in the collected images, thereby determining the popular clothing. However, obtaining the clothing attribute information of the target person or the target group according to the existing manual statistics method, especially when it is necessary to obtain the clothing information of a large number of people, has the problems of low efficiency, easy errors and high labor costs. Summary of the invention

[0004] The present application provides a clothing attribute recognition method, device and electronic device for improving the efficiency and accuracy of clothing attribute recognition. The technical solution adopted in the present application is as follows:

[0005] In a first aspect, a method for identifying clothing attributes based on a neural network is provided, the method comprising:

[0006] Using a preset recognition method, identifying and determining that the image to be recognized includes at least one target person;

[0007] The clothing attribute recognition of an image to be recognized including at least one target person is performed through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person.

[0008] Specifically, the clothing attribute recognition of the image to be recognized including at least one target person is performed through the pre-trained neural network recognition model to obtain the clothing attribute recognition result of the at least one target person, including:

[0009] The pre-trained neural network recognition model is used to segment the body area of ​​any target person in the image to be identified, and the clothing attributes of each body area are identified to obtain the clothing attribute recognition result of the target person in the image to be identified.

[0010] Specifically, the clothing attribute recognition of the image to be recognized including at least one target person is performed through the pre-trained neural network recognition model to obtain the clothing attribute recognition result of the at least one target person, including:

[0011] Segmenting the image to be identified to obtain at least one segmented image including a single target person;

[0012] The clothing attribute recognition is performed on any segmented image including a single target person through a pre-trained neural network recognition model to obtain the clothing attribute recognition result of the person included in any segmented image.

[0013] The clothing attribute recognition result of the person includes at least one of the following:

[0014] Clothing type; Clothing color; Clothing quantity;

[0015] The clothing includes at least one of the following:

[0016] Clothes, hats, shoes, accessories.

[0017] Specifically, by using a preset recognition method, it is determined that the image to be recognized includes at least one target person, including:

[0018] Extracting at least one image frame from the video captured by the image capture device according to a preset extraction frequency, wherein the preset extraction frequency is determined based on a statistically obtained average duration of pedestrians passing through an area controlled by the image capture device;

[0019] At least one image frame is detected and recognized by using a pre-trained portrait detection and recognition model to identify and determine at least one image to be recognized that includes at least one target person.

[0020] Further, the image to be identified is segmented to obtain at least one segmented image including a single target person, including at least one of the following:

[0021] Segmenting the image to be identified based on a region segmentation method to obtain at least one segmented image including a single target person;

[0022] The image to be identified is segmented based on an edge segmentation method to obtain at least one segmented image including a single target person.

[0023] Furthermore, the clothing attribute recognition is performed on any segmented image including a single target person through the pre-trained neural network recognition model to obtain the clothing attribute recognition result of the person included in any segmented image, including:

[0024] Extract clothing features from any segmented image including a single target person, and obtain clothing feature information for any target person;

[0025] The clothing feature information of any target person is input into the pre-trained neural network recognition model to obtain the clothing attribute recognition result of any person.

[0026] Furthermore, the method also includes,

[0027] For the current image to be identified, a first predetermined number of image frames preceding the current image to be identified and a second predetermined number of image frames following the current image to be identified on the video time axis are segmented to obtain a plurality of segmented images including a single target person;

[0028] Extracting character features from multiple segmented images including a single target character to obtain characteristic information for each character;

[0029] The similarity is calculated for the feature information of each person, and multiple segmented images including a single target person are deduplicated according to the similarity calculation result to obtain deduplicated segmented images;

[0030] The clothing attribute recognition is performed on any segmented image including a single target person through the pre-trained neural network recognition model to obtain the clothing attribute recognition results of the person included in any segmented image, including:

[0031] The clothing attributes of the deduplicated segmented images are recognized through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of a person included in any deduplicated segmented image.

[0032] Furthermore, the method further comprises:

[0033] storing clothing attribute recognition results, images to be recognized, and corresponding relationships between clothing attribute recognition results and images to be recognized;

[0034] The method further comprises:

[0035] When a person query request including clothing attribute information is received, the image information of the person corresponding to the query request is queried and determined based on the correspondence between the clothing attribute recognition result and the image to be recognized.

[0036] In a second aspect, a neural network-based clothing attribute recognition device is provided, the device comprising a recognition determination module and a recognition module;

[0037] An identification and determination module, used to identify and determine that the image to be identified includes at least one target person through a preset identification method;

[0038] The recognition module performs clothing attribute recognition on the image to be recognized including at least one target person determined by the recognition and determination module through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person.

[0039] Furthermore, the recognition module is used to perform body area segmentation on any target person in the image to be identified through a pre-trained neural network recognition model, and to perform clothing attribute recognition on each body area to obtain a clothing attribute recognition result of the target person in the image to be identified.

[0040] Further, the recognition module includes a first segmentation unit and a recognition unit;

[0041] The first segmentation unit is used to segment the image to be identified to obtain at least one segmented image including a single target person;

[0042] The recognition unit is used to recognize clothing attributes of any segmented image including a single target person obtained by the segmentation processing of the first segmentation unit through a pre-trained neural network recognition model, and obtain a clothing attribute recognition result of the person included in any segmented image.

[0043] The clothing attribute recognition result of the person includes at least one of the following:

[0044] Clothing type; Clothing color; Clothing quantity;

[0045] The clothing includes at least one of the following:

[0046] Clothes, hats, shoes, accessories.

[0047] Further, the identification and determination module includes an extraction unit and an identification and determination unit;

[0048] An extraction unit, configured to extract at least one image frame from the video captured by the image capture device according to a preset extraction frequency, wherein the preset extraction frequency is determined based on a statistically obtained average duration of a pedestrian passing through an area controlled by the image capture device;

[0049] The recognition and determination unit is used to detect and identify at least one image frame extracted by the extraction unit through a pre-trained portrait detection and recognition model, and identify and determine at least one image to be recognized that includes at least one target person.

[0050] Furthermore, the first segmentation unit is used to perform segmentation processing on the image to be identified based on a region segmentation method to obtain at least one segmented image including a single target person;

[0051] And / or used to segment the image to be identified based on an edge segmentation method to obtain at least one segmented image including a single target person.

[0052] Further, the recognition unit includes a feature extraction subunit and an input subunit;

[0053] A feature extraction subunit is used to extract clothing features from any segmented image including a single target person, so as to obtain clothing feature information for any target person;

[0054] The input subunit is used to input the clothing feature information for any target person extracted by the feature extraction subunit into the pre-trained neural network recognition model to obtain the clothing attribute recognition result of any person.

[0055] Furthermore, the recognition module also includes a second segmentation unit, a feature extraction unit and a deduplication unit;

[0056] A second segmentation unit is used to segment a first predetermined number of image frames preceding the current image to be identified and a second predetermined number of image frames following the current image to be identified on a video time axis to obtain a plurality of segmented images including a single target person;

[0057] A feature extraction unit, configured to extract character features from a plurality of segmented images including a single target character obtained by the segmentation process of the second segmentation unit, to obtain feature information for each character;

[0058] a deduplication unit, configured to perform similarity calculation on the feature information for each person extracted by the feature extraction unit, and to perform deduplication on a plurality of segmented images including a single target person according to the similarity calculation result, to obtain deduplicated segmented images;

[0059] The recognition unit is used to perform clothing attribute recognition on the deduplicated segmented images obtained after deduplication processing by the deduplication unit through a pre-trained neural network recognition model, and obtain the clothing attribute recognition result of the person included in any deduplicated segmented image.

[0060] Furthermore, the device also includes a storage module;

[0061] The storage module is used to store clothing attribute recognition results, segmented images, and the corresponding relationship between the clothing attribute recognition results and the segmented images;

[0062] The device also includes a query determination module;

[0063] The query determination module is used to query and determine the image information of the person corresponding to the query request based on the corresponding relationship between the clothing attribute recognition result and the segmented image through the storage module when receiving a person query request including clothing attribute information.

[0064] In a third aspect, an electronic device is provided, the electronic device comprising:

[0065] one or more processors;

[0066] Memory;

[0067] One or more applications, wherein the one or more applications are stored in a memory and configured to be executed by one or more processors, and the one or more programs are configured to: execute the neural network-based clothing attribute recognition method shown in the first aspect.

[0068] In a fourth aspect, a computer-readable storage medium is provided, which is used to store computer instructions. When the computer-readable storage medium is run on a computer, the computer can execute the neural network-based clothing attribute recognition method shown in the first aspect.

[0069] The embodiments of the present application provide a clothing attribute recognition method, device and electronic device. Compared with the prior art that manually recognizes the clothing attributes of a target person or a target group, the present application uses a preset recognition method to identify and determine that an image to be recognized includes at least one target person, and then uses a pre-trained neural network recognition model to perform clothing attribute recognition on the image to be recognized including the at least one target person to obtain a clothing attribute recognition result of the at least one target person. That is, the embodiments of the present application use a pre-trained neural network recognition model to realize automatic recognition of the clothing attributes of the target person included in the image to be recognized, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors and low efficiency of manual recognition, and reducing labor costs.

[0070] Additional aspects and advantages of the present application will be partially given in the following description, which will become apparent from the following description, or will be understood through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0071] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0072] Figure 1 A flowchart of a method for identifying clothing attributes based on a neural network according to an embodiment of the present application;

[0073] Figure 2 A schematic diagram of the structure of a clothing attribute recognition device based on a neural network according to an embodiment of the present application;

[0074] Figure 3 It is a structural schematic diagram of another neural network-based clothing attribute recognition device according to an embodiment of the present application;

[0075] Figure 4 A schematic diagram of the structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0076] The embodiments of the present application are described in detail below, and examples of the embodiments 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 application, and cannot be interpreted as limiting the present application.

[0077] Those skilled in the art will appreciate that, unless otherwise stated, the singular forms "a", "an" and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of the present application refers to the presence of features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof. In order to make the purpose, technical solutions and advantages of the present application clearer, the embodiments of the present application will be further described in detail below in conjunction with the accompanying drawings.

[0078] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0079] The embodiment of the present application provides a method for identifying clothing attributes based on a neural network. As shown in 1, the method may include the following steps:

[0080] Step S101, identifying and determining that the image to be identified includes at least one target person through a preset identification method;

[0081] For the embodiment of the present application, a corresponding recognition method is preset to determine that the image to be recognized includes at least one target person, and remove images that do not include the target person.

[0082] Step S102: performing clothing attribute recognition on an image to be recognized including at least one target person using a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person.

[0083] For the embodiment of the present application, the clothing attributes of the image to be identified are identified by a pre-trained neural network recognition model, and the clothing attribute recognition result of the target person in the image to be identified including at least one target person is obtained. Among them, the pre-trained neural network recognition model can be a neural network recognition model based on Faster-RCNN (Faster-Regions with Convolutional Neural Network, a convolutional neural network with regions), and its architecture can adopt VGG16, ResNet, GoogLeNet, which is not limited here, and can also be a neural network model based on RCNN (Region based CNN) or SSD (Single Shot multibox Detector) or YOLO.

[0084] Exemplarily, the training samples of the neural network recognition model based on Faster-RCNN may include multiple images including at least one target person and annotated clothing attributes obtained from videos or images captured by a camera device. Using the annotated image samples to train the neural network is conducive to improving the accuracy of the neural network in recognizing image data. During the training process, by comparing the training results with the manually annotated information, when the comparison results meet the predetermined accuracy requirements, the training can be considered completed. When the comparison results do not meet the accuracy requirements, the training can be continued by adjusting the corresponding parameters (such as the parameters in each convolutional neural network layer, etc.) until the training results meet the predetermined accuracy requirements. In addition, the neural network recognition model based on Faster-RCNN can also be obtained by fine-tuning an existing model.

[0085] The embodiment of the present application provides a clothing attribute recognition method based on a neural network. Compared with the prior art of manually identifying the clothing attributes of a target person or a target group, the embodiment of the present application uses a preset recognition method to identify and determine that an image to be recognized includes at least one target person, and then uses a pre-trained neural network recognition model to perform clothing attribute recognition on the image to be recognized including the at least one target person to obtain a clothing attribute recognition result of the at least one target person. That is, the embodiment of the present application uses a pre-trained neural network recognition model to realize automatic recognition of the clothing attributes of the target person included in the image to be recognized, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors and low efficiency of manual recognition, and reducing labor costs.

[0086] This embodiment of the application provides a possible implementation method, step S102 includes:

[0087] Step 1021 (not shown in the figure) is to segment the body area of ​​any target person in the image to be identified through a pre-trained neural network recognition model, and to identify clothing attributes for each body area to obtain a clothing attribute recognition result of the target person in the image to be identified.

[0088] In the embodiment of the present application, the body area of ​​the person to be identified in the image is divided into upper body and lower body through the pre-trained neural network recognition model, and the clothing attributes of each divided body area are identified, such as identifying that the target person wears red clothes on the upper body and black pants on the lower body, thereby obtaining the clothing attribute recognition result of the person in the segmented image. The division of the body area can be achieved by extracting Gabor features of M directions and N scales of each body area feature to obtain a body area feature vector, and then according to the obtained feature vector, the clothing attribute recognition result of the person included in the segmented image is identified.

[0089] Exemplarily, when clothing attributes of an image to be identified that includes at least one target person are recognized, multiple detection frames are generated for the image to be processed using methods such as RPN (Region Proposal Network) in Faster-RCNN, and the Fast-RCNN detector network layer in Faster-RCNN can extract the appearance feature information of each detection frame generated by the RPN layer. The Fast-RCNN detector network layer in Faster-RCNN performs judgment processing on the appearance feature information of each detection frame in the image to be processed to determine the probability that each detection frame belongs to each class. That is, after the Fast-RCNN detector network layer extracts the appearance feature information of each detection frame generated by the RPN layer, the Fast-RCNN detector network layer can also make predictions for the appearance feature information of each detection frame extracted, thereby forming an N-dimensional vector for each detection frame and outputting it, and an N-dimensional vector is the probability that a detection frame predicted by it belongs to N classes, where N is the total number of classes.

[0090] For the embodiment of the present application, the body regions of the person in the image to be identified are divided through a pre-trained neural network model, and the clothing attributes of each body region are identified and determined, thereby solving the problem of identifying the clothing attributes of different body regions of the person (such as the color of the clothing worn on the upper and lower body).

[0091] This embodiment of the application provides a possible implementation method, step S102 includes:

[0092] Step 1022 (not shown in the figure), segmenting the image to be identified to obtain at least one segmented image including a single target person;

[0093] For the embodiment of the present application, the image to be identified is segmented to obtain one or more segmented images containing only a single target person. In addition, image portions that are useless for identifying the attributes of the target clothing, such as the image of the blank background portion, can be removed to reduce the amount of data to be processed. The image can also be normalized and segmented.

[0094] Step 1023 (not shown in the figure) is to perform clothing attribute recognition on any segmented image including a single target person through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the person included in any segmented image.

[0095] For the embodiment of the present application, any segmented image including a single target person is used as input and input into a pre-trained neural network recognition model, and the pre-trained neural network recognition model outputs a clothing attribute recognition result for the target person in the input segmented image. The pre-trained neural network recognition model is pre-trained by training samples, and the training samples include multiple images including the target person and clothing attributes annotated by the target person in the above images, such as the color of the clothing.

[0096] In the embodiment of the present application, the image to be identified is segmented to obtain at least one segmented image including a single target, and then the clothing attribute recognition result of the target person in the image to be identified is obtained through the pre-trained neural network recognition model, thereby realizing automatic recognition of the clothing attributes of the target person included in the image to be identified, thereby improving the efficiency of clothing attribute recognition.

[0097] The clothing attribute recognition result of the person includes at least one of the following:

[0098] Clothing type; Clothing color; Clothing quantity;

[0099] The clothing includes at least one of the following:

[0100] Clothes, hats, shoes, accessories.

[0101] For the embodiment of the present application, the clothing attribute recognition result includes but is not limited to the style of clothing, the color of clothing and the number of clothing, where clothing includes but is not limited to clothes, hats, shoes and accessories.

[0102] For the embodiments of the present application, corresponding clothing attribute information of the target person can be obtained based on different purposes or application scenarios.

[0103] This embodiment of the application provides a possible implementation method, wherein step 101 includes:

[0104] Step S1011 (not shown in the figure), extracting at least one image frame from the video captured by the image capture device according to a preset extraction frequency, wherein the preset extraction frequency is determined based on the statistically obtained average duration of pedestrians passing through the area controlled by the image capture device;

[0105] For the embodiments of the present application, any image acquisition device has an effective monitoring area. The extraction frequency can be set according to the statistically average time it takes for pedestrians to enter and leave the effective monitoring area, and image frames can be extracted from the video acquired by the acquisition device based on the extraction frequency. For example, the statistically average time it takes for pedestrians to enter and leave the acquisition control range is 3 seconds, and the acquired video is 24 frames per second. One image frame can be extracted every no more than 72 frames.

[0106] Step S1012 (not shown in the figure) detects and identifies at least one image frame using a pre-trained portrait detection and recognition model to identify and determine at least one image to be identified that includes at least one target person.

[0107] For the embodiments of the present application, a portrait detection and recognition model can be trained in advance by including a plurality of positive and negative training samples including the target person and not including the target person, and then the pre-trained portrait detection and recognition model is used to perform portrait detection and recognition on at least one image frame to obtain at least one image to be recognized including at least one target person, wherein the portrait detection and recognition model can also be a portrait detection and recognition model based on a background modeling algorithm. Commonly used background modeling algorithms include: Gaussian mixture model (Mixture of Gaussian model), frame difference algorithm (BackgroundSubtraction), gradient orientation histogram (HoG), etc.

[0108] For the embodiment of the present application, at least one image frame is extracted from the captured video according to a preset extraction frequency, and then at least one image to be identified including a target person is determined from the at least one image frame through a pre-trained portrait detection and recognition model, thereby solving the problem of acquiring images to be identified including at least one target person and providing a basis for subsequent recognition of the clothing attributes of the target person.

[0109] The present application embodiment provides a possible implementation method, wherein step S1022 may include but is not limited to at least one of step S10221 (not shown in the figure) and step S10222 (not shown in the figure).

[0110] Step S10221, segmenting the image to be identified based on a region segmentation method to obtain at least one segmented image including a single target person;

[0111] Step S10222: segment the image to be identified based on an edge segmentation method to obtain at least one segmented image including a single target person.

[0112] For the embodiments of the present application, the image to be identified can be segmented by a region segmentation method and / or an edge segmentation method to obtain at least one segmented image including a single target person. Among them, edge detection, that is, detecting the place where the gray level or structure has a sudden change, indicates the end of one region and the beginning of another region. This discontinuity is called an edge. Different images have different gray levels, and there are generally obvious edges at the boundaries. This feature can be used to segment the image. Among them, the region segmentation method includes two types: region production and region splitting and merging. The basic idea of ​​region growing is to group pixels with similar properties to form a region; region splitting and merging is almost the inverse process of region growing. Starting from the entire image, it is continuously split to obtain each sub-region, and then the foreground area is merged to achieve target extraction.

[0113] For the embodiments of the present application, the problem of segmenting the image to be identified is solved by a region segmentation method and / or an edge segmentation method, and the image to be identified containing multiple target persons is segmented into a segmented image containing only a single target person.

[0114] This embodiment of the application provides a possible implementation method, wherein step S1023 includes:

[0115] Step S10231 (not shown in the figure), extracting clothing features from any segmented image including a single target person, and obtaining clothing feature information for any target person;

[0116] Step S10232 (not shown in the figure) inputs the clothing feature information of any target person into the pre-trained neural network recognition model to obtain the clothing attribute recognition result of any person.

[0117] For the embodiments of the present application, the clothing features of the target person in any segmented image can be extracted through a feature extraction model, and then the clothing features for any target person are input into a pre-trained neural network recognition model to identify and determine the clothing attribute recognition results of any target person.

[0118] In the embodiment of the present application, the clothing features of the target person in the extracted segmented image are input into the pre-trained neural network recognition model for clothing attribute recognition, thereby solving the problem of clothing attribute recognition of the target person. In addition, the data processing amount of the pre-trained neural network recognition model is reduced.

[0119] The embodiment of the present application also provides another possible implementation method, step S102 further includes:

[0120] Step S1024 (not shown in the figure), for the current image to be identified, a first predetermined number of image frames before and a second predetermined number of image frames after the current image to be identified on the video time axis are segmented to obtain a plurality of segmented images including a single target person;

[0121] For the embodiment of the present application, the numerical values ​​of the first predetermined number and the second predetermined number are preset, wherein the numerical values ​​of the first predetermined number and the second predetermined number can be determined based on the predetermined monitoring time length, and segmentation is performed on the first predetermined number of image frames in front of the current image to be identified and the second predetermined number of image frames in the back, wherein the above-mentioned segmentation can be implemented based on image segmentation methods such as region segmentation method and edge segmentation method, so as to obtain multiple segmented images including a single target person.

[0122] Step S1025 (not shown in the figure), extracting character features from a plurality of segmented images including a single target character to obtain feature information for each character;

[0123] For the embodiment of the present application, the character features of the target person in multiple segmented images including a single target person are extracted through a feature extraction model to obtain feature information of each person, wherein the feature information can be represented by a feature vector.

[0124] Step S1026 (not shown in the figure), performing similarity calculation on the feature information of each person, and deduplicating multiple segmented images including a single target person according to the similarity calculation result to obtain deduplicated segmented images;

[0125] For example, the similarity between the feature information of each character is determined by calculating the Euclidean distance or cosine similarity between the feature information of each character, and based on the similarity calculation result, it is determined that the characters whose similarity reaches a certain threshold are the same person, and the segmented images corresponding to the characters determined to be the same person are deduplicated accordingly to obtain the deduplicated segmented images.

[0126] Wherein, step S1023 specifically includes:

[0127] Step 10233 (not shown in the figure) performs clothing attribute recognition on the deduplicated segmented images through a pre-trained neural network recognition model to obtain clothing attribute recognition results of the characters included in any deduplicated segmented image.

[0128] For the embodiment of the present application, the deduplicated segmented images are input into a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the person included in any deduplicated segmented image.

[0129] In the embodiment of the present application, multiple segmented images including a single target person are deduplicated, and the clothing attributes of the target person are identified on the deduplicated segmented images, thereby avoiding repeated identification and improving the accuracy of subsequent statistical clothing attribute information. In addition, the data processing amount of the pre-trained neural network recognition model is reduced.

[0130] The embodiment of the present application also provides another possible implementation method, the method further includes:

[0131] Step S103 (not shown in the figure), storing the clothing attribute recognition result, the image to be recognized, and the corresponding relationship between the clothing attribute recognition result and the image to be recognized;

[0132] For the embodiment of the present application, the clothing attribute recognition results, the direction to be recognized and the corresponding relationship between the two are stored by a corresponding storage device.

[0133] The method further comprises:

[0134] Step S104 (not shown in the figure), when a person query request including clothing attribute information is received, based on the correspondence between the clothing attribute recognition result and the image to be recognized, the image information of the person corresponding to the query request is queried and determined.

[0135] For the embodiment of the present application, when a character query request including clothing attribute information is received from a user, the image information of the character corresponding to the query request is queried and determined through the corresponding storage device based on the index relationship between the clothing attribute recognition result and the image to be identified.

[0136] For the embodiment of the present application, through the correspondence between the clothing attribute recognition result and the image to be recognized, when a query request including clothing attribute information is received, the character image information corresponding to the clothing attribute information is queried and determined.

[0137] Figure 2 A neural network-based clothing attribute recognition device provided in an embodiment of the present application includes: a recognition and determination module 201 and a recognition module 202;

[0138] The identification and determination module 201 is used to identify and determine that the image to be identified includes at least one target person through a preset identification method;

[0139] The recognition module 202 performs clothing attribute recognition on the image to be recognized including at least one target person determined by the recognition and determination module 201 through a pre-trained neural network recognition model, and obtains a clothing attribute recognition result of the at least one target person.

[0140] The embodiment of the present application provides a clothing attribute recognition device based on a neural network. Compared with the prior art that manually recognizes the clothing attributes of a target person or a target group, the embodiment of the present application uses a preset recognition method to identify and determine that an image to be recognized includes at least one target person, and then uses a pre-trained neural network recognition model to perform clothing attribute recognition on the image to be recognized including the at least one target person to obtain a clothing attribute recognition result of the at least one target person. That is, the embodiment of the present application uses a pre-trained neural network recognition model to realize automatic recognition of the clothing attributes of the target person included in the image to be recognized, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors in manual recognition, and reducing labor costs.

[0141] The clothing attribute recognition device based on neural network of this embodiment can execute a clothing attribute recognition method based on neural network provided in the above embodiment of this application, and its implementation principle is similar and will not be repeated here.

[0142] The present application embodiment provides another clothing attribute recognition device based on neural network, such as Figure 3 As shown, the device 30 of this embodiment may include an identification and determination module 301 and an identification module 302, wherein:

[0143] The identification and determination module 301 is used to identify and determine that the image to be identified includes at least one target person through a preset identification method;

[0144] in, Figure 3 The identification and determination module 301 in Figure 2 The functions of the identification and determination module 201 in are the same or similar.

[0145] The recognition module 302 performs clothing attribute recognition on the image to be recognized including at least one target person determined by the recognition and determination module 301 through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person.

[0146] in, Figure 3 The identification module 302 in Figure 2 The function of the identification module 202 in is the same or similar.

[0147] Specifically, the recognition module 302 is used to segment the body area of ​​any target person in the image to be recognized through a pre-trained neural network recognition model, and recognize clothing attributes for each body area to obtain a clothing attribute recognition result of the target person in the image to be recognized.

[0148] For the embodiment of the present application, the body regions of the person in the image to be identified are divided through a pre-trained neural network model, and the clothing attributes of each body region are identified and determined, thereby solving the problem of identifying the clothing attributes of different body regions of the person (such as the color of the clothing worn on the upper and lower body).

[0149] Specifically, the identification module 302 includes a first segmentation unit 3021 and an identification unit 3022;

[0150] The first segmentation unit 3021 is used to segment the image to be identified to obtain at least one segmented image including a single target person;

[0151] The recognition unit 3022 is used to perform clothing attribute recognition on any segmented image including a single target person obtained by the segmentation process of the first segmentation unit 3021 through a pre-trained neural network recognition model, and obtain a clothing attribute recognition result of the person included in any segmented image.

[0152] In the embodiment of the present application, the image to be identified is segmented to obtain at least one segmented image including a single target, and then the clothing attribute recognition result of the target person in the image to be identified is obtained through the pre-trained neural network recognition model, thereby realizing automatic recognition of the clothing attributes of the target person included in the image to be identified, thereby improving the efficiency of clothing attribute recognition.

[0153] The clothing attribute recognition result of the person includes at least one of the following:

[0154] Clothing type; Clothing color; Clothing quantity;

[0155] The clothing includes at least one of the following:

[0156] Clothes, hats, shoes, accessories.

[0157] For the embodiments of the present application, corresponding clothing attribute information of the target person can be obtained based on different purposes or application scenarios.

[0158] Specifically, the identification and determination module 301 includes an extraction unit 3011 and an identification and determination unit 3012;

[0159] An extraction unit 3011 is used to extract at least one image frame from the video captured by the image capture device according to a preset extraction frequency, wherein the preset extraction frequency is determined based on the statistically obtained average duration of pedestrians passing through the area controlled by the image capture device;

[0160] The identification and determination unit 3012 is used to detect and identify at least one image frame extracted by the extraction unit 3012 through a pre-trained portrait detection and recognition model, and identify and determine at least one image to be identified that includes at least one target person.

[0161] For the embodiment of the present application, at least one image frame is extracted from the captured video according to a preset extraction frequency, and then at least one image to be identified including a target person is determined from the at least one image frame through a pre-trained portrait detection and recognition model, thereby solving the problem of acquiring images to be identified including at least one target person and providing a basis for subsequent recognition of the clothing attributes of the target person.

[0162] Specifically, the first segmentation unit 3021 is used to segment the image to be identified based on a region segmentation method to obtain at least one segmented image including a single target person;

[0163] And / or used to segment the image to be identified based on an edge segmentation method to obtain at least one segmented image including a single target person.

[0164] For the embodiments of the present application, the problem of segmenting the image to be identified is solved by a region segmentation method and / or an edge segmentation method, and the image to be identified containing multiple target persons is segmented into a segmented image containing only a single target person.

[0165] Further, the recognition unit 3022 includes a feature extraction subunit (not shown in the figure) and an input subunit (not shown in the figure);

[0166] A feature extraction subunit is used to extract clothing features from any segmented image including a single target person, so as to obtain clothing feature information for any target person;

[0167] The input subunit is used to input the clothing feature information for any target person extracted by the feature extraction subunit into the pre-trained neural network recognition model to obtain the clothing attribute recognition result of any person.

[0168] In the embodiment of the present application, the clothing features of the target person in the extracted segmented image are input into the pre-trained neural network recognition model for clothing attribute recognition, thereby solving the problem of clothing attribute recognition of the target person. In addition, the data processing amount of the pre-trained neural network recognition model is reduced.

[0169] Furthermore, the recognition module 302 also includes a second segmentation unit 3023, a feature extraction unit 3024 and a deduplication unit 3025;

[0170] The second segmentation unit 3023 is used to segment the first predetermined number of image frames before and the second predetermined number of image frames after the current image to be identified on the video time axis to obtain a plurality of segmented images including a single target person;

[0171] A feature extraction unit 3024 is used to extract character features from the multiple segmented images including a single target person obtained by the segmentation process of the second segmentation unit 3023 to obtain feature information for each person;

[0172] The deduplication unit 3025 is used to perform similarity calculation on the feature information for each person extracted by the feature extraction unit 3024, and to perform deduplication on multiple segmented images including a single target person according to the similarity calculation result to obtain deduplicated segmented images;

[0173] The recognition unit 3022 is used to perform clothing attribute recognition on the deduplicated segmented image obtained after the deduplication processing by the deduplication unit 3025 through a pre-trained neural network recognition model, and obtain the clothing attribute recognition result of the person included in any deduplicated segmented image.

[0174] In the embodiment of the present application, multiple segmented images including a single target person are deduplicated, and the clothing attributes of the target person are identified on the deduplicated segmented images, thereby avoiding repeated identification and improving the accuracy of subsequent statistical clothing attribute information. In addition, the data processing amount of the pre-trained neural network recognition model is reduced.

[0175] Specifically, the device also includes a storage module 303 and a query module 304;

[0176] The storage module 303 is used to store clothing attribute recognition results, images to be recognized, and the corresponding relationship between clothing attribute recognition results and images to be recognized;

[0177] The query determination module 304 is used to query and determine the image information of the person corresponding to the query request based on the correspondence between the clothing attribute recognition result and the segmented image through the storage module when receiving a person query request including clothing attribute information.

[0178] For the embodiment of the present application, through the correspondence between the clothing attribute recognition result and the image to be recognized, when a query request including clothing attribute information is received, the character image information corresponding to the clothing attribute information is queried and determined.

[0179] The embodiment of the present application provides a clothing attribute recognition device based on a neural network. Compared with the prior art that manually recognizes the clothing attributes of a target person or a target group, the embodiment of the present application uses a preset recognition method to identify and determine that an image to be recognized includes at least one target person, and then uses a pre-trained neural network recognition model to perform clothing attribute recognition on the image to be recognized including the at least one target person to obtain a clothing attribute recognition result of the at least one target person. That is, the embodiment of the present application uses a pre-trained neural network recognition model to realize automatic recognition of the clothing attributes of the target person included in the image to be recognized, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors in manual recognition, and reducing labor costs.

[0180] The embodiment of the present application provides a clothing attribute recognition device based on a neural network, which is applicable to the method shown in the above embodiment and will not be described in detail here.

[0181] The present application embodiment provides an electronic device, such as Figure 4 As shown, Figure 4 The electronic device 40 shown includes: a processor 4001 and a memory 4003. The processor 4001 and the memory 4003 are connected, such as through a bus 4002. Further, the electronic device 40 may also include a transceiver 4004. It should be noted that in actual applications, the transceiver 4004 is not limited to one, and the structure of the electronic device 400 does not constitute a limitation on the embodiments of the present application.

[0182] The processor 4001 is used in the embodiment of the present application to implement Figure 2 or Figure 3 The identification module, the function of the identification module, and the method for implementing Figure 3 The functions of the storage module 303 and the query determination module 304 are shown. The transceiver 4004 includes a receiver and a transmitter.

[0183] Processor 4001 may be a CPU, a general-purpose processor, a DSP, an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component or any combination thereof. It may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. Processor 4001 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.

[0184] The bus 4002 may include a path to transmit information between the above components. The bus 4002 may be a PCI bus or an EISA bus, etc. The bus 4002 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 4Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0185] Memory 4003 can be ROM or other types of static storage devices that can store static information and instructions, RAM or other types of dynamic storage devices that can store information and instructions, or it can be EEPROM, CD-ROM or other optical disk storage, optical disk storage (including compressed optical disk, laser disk, optical disk, digital versatile disk, Blu-ray disk, etc.), magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited to this.

[0186] The memory 4003 is used to store the application code for executing the solution of the present application, and the execution is controlled by the processor 4001. The processor 4001 is used to execute the application code stored in the memory 4003 to implement Figure 2 or Figure 3 The illustrated embodiment provides the operation of the neural network-based clothing attribute recognition device.

[0187] The present application embodiment provides an electronic device applicable to the above method embodiment, which will not be described in detail here.

[0188] The embodiment of the present application provides an electronic device. Compared with the prior art that manually identifies the clothing attributes of a target person or a target group, the embodiment of the present application uses a preset recognition method to identify and determine that an image to be identified includes at least one target person, and then uses a pre-trained neural network recognition model to perform clothing attribute recognition on the image to be identified including the at least one target person to obtain a clothing attribute recognition result of the at least one target person. That is, the embodiment of the present application uses a pre-trained neural network recognition model to realize automatic recognition of the clothing attributes of the target person included in the image to be identified, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors in manual recognition, and reducing labor costs.

[0189] An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the program is executed by a processor, the method shown in the above embodiment is implemented.

[0190] The embodiment of the present application provides a computer-readable storage medium. Compared with the prior art of manually identifying the clothing attributes of a target person or a target group, the embodiment of the present application uses a preset recognition method to identify and determine that an image to be identified includes at least one target person, and then uses a pre-trained neural network recognition model to perform clothing attribute recognition on the image to be identified including the at least one target person to obtain a clothing attribute recognition result of the at least one target person. That is, the embodiment of the present application uses a pre-trained neural network recognition model to realize automatic recognition of the clothing attributes of the target person included in the image to be identified, thereby improving the efficiency of clothing attribute recognition, avoiding the problem of easy errors in manual recognition, and reducing labor costs.

[0191] The present application embodiment provides a computer-readable storage medium applicable to the above method embodiment, which will not be described in detail here.

[0192] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.

[0193] The above are only some implementation methods of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A clothing attribute recognition method based on neural network, characterized in that: include, Using a preset recognition method, identifying and determining that the image to be recognized includes at least one target person; Performing clothing attribute recognition on an image to be recognized including at least one target person through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person; The method of performing clothing attribute recognition on an image to be recognized including at least one target person through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of at least one target person includes: segmenting the image to be recognized to obtain at least one segmented image including a single target person; performing clothing attribute recognition on any segmented image including a single target person through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the person included in any segmented image; The method further includes: for the current image to be identified, segmenting a first predetermined number of image frames in front and a second predetermined number of image frames in the back relative to the current image to be identified on the video time axis to obtain a plurality of segmented images including a single target person; extracting person features from the plurality of segmented images including the single target person to obtain feature information for each person; performing similarity calculation on the feature information for each person, and deduplicating the plurality of segmented images including the single target person according to the similarity calculation result to obtain deduplicated segmented images; The method of performing clothing attribute recognition on any segmented image including a single target person through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the person included in any segmented image includes: performing clothing attribute recognition on the deduplicated segmented image through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the person included in any segmented image after deduplication.

2. The method according to claim 1, characterized in that: The pre-trained neural network recognition model is used to perform clothing attribute recognition on an image to be recognized including at least one target person, and obtains a clothing attribute recognition result of at least one target person, including: The body area of ​​any target person in the image to be identified is segmented by a pre-trained neural network recognition model, and clothing attributes are recognized for each body area to obtain a clothing attribute recognition result of the target person in the image to be identified.

3. The method according to claim 1, characterized in that The clothing attribute recognition result of the character includes at least one of the following: Clothing type; Clothing color; Clothing quantity; The clothing includes at least one of the following: Clothes, hats, shoes, accessories.

4. The method according to claim 1, characterized in that: The method of identifying and determining that the image to be identified includes at least one target person by a preset identification method includes: Extracting at least one image frame from the video captured by the image capture device according to a preset extraction frequency, wherein the preset extraction frequency is determined based on a statistically obtained average duration of pedestrians passing through an area controlled by the image capture device; The at least one image frame is detected and recognized by using a pre-trained portrait detection and recognition model to identify and determine at least one image to be recognized that includes at least one target person.

5. The method according to claim 1, characterized in that The segmenting process of the image to be identified to obtain at least one segmented image including a single target person includes at least one of the following: Segmenting the image to be identified based on a region segmentation method to obtain at least one segmented image including a single target person; The image to be identified is segmented based on an edge segmentation method to obtain at least one segmented image including a single target person.

6. The method according to claim 1, characterized in that The clothing attribute recognition is performed on any segmented image including a single target person through the pre-trained neural network recognition model to obtain the clothing attribute recognition result of the person included in any segmented image, including: Extract clothing features from any segmented image including a single target person, and obtain clothing feature information for any target person; The clothing feature information of any target person is input into the pre-trained neural network recognition model to obtain the clothing attribute recognition result of any person.

7. The method according to claim 1, characterized in that The method further comprises: The clothing attribute recognition results, the image to be recognized, and the corresponding relationship between the clothing attribute recognition results and the image to be recognized are stored.

8. The method according to claim 7, characterized in that The method further comprises: When a person query request including clothing attribute information is received, the image information of the person corresponding to the query request is queried and determined based on the correspondence between the clothing attribute recognition result and the image to be recognized.

9. A clothing attribute recognition device based on neural network, characterized in that: The device comprises an identification and determination module and an identification module; The identification and determination module is used to identify and determine that the image to be identified includes at least one target person through a preset identification method; The recognition module performs clothing attribute recognition on the image to be recognized including at least one target person identified and determined by the recognition and determination module through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the at least one target person; The recognition module includes a first segmentation unit and a recognition unit; The first segmentation unit is used to segment the image to be identified to obtain at least one segmented image including a single target person; the identification unit is used to identify clothing attributes of any segmented image including a single target person obtained by the segmentation process of the first segmentation unit through a pre-trained neural network recognition model to obtain a clothing attribute recognition result of the person included in any segmented image; The identification module also includes a second segmentation unit, a feature extraction unit and a deduplication unit; The second segmentation unit is used to segment a first predetermined number of image frames in front of the current image to be identified and a second predetermined number of image frames in the back on the video time axis relative to the current image to be identified, so as to obtain a plurality of segmented images including a single target person; the feature extraction unit is used to extract person features from the plurality of segmented images including the single target person obtained by the segmentation process of the second segmentation unit, so as to obtain feature information for each person; the deduplication unit is used to perform similarity calculation on the feature information for each person extracted by the feature extraction unit, and deduplication the plurality of segmented images including the single target person according to the similarity calculation result, so as to obtain deduplicated segmented images; The recognition unit is used to perform clothing attribute recognition on the deduplicated segmented images obtained after deduplication processing by the deduplication unit through a pre-trained neural network recognition model, and obtain clothing attribute recognition results of the characters included in any deduplicated segmented image.

10. The device according to claim 9, characterized in that The recognition module is used to segment the body area of ​​any target person in the image to be recognized through a pre-trained neural network recognition model, and recognize clothing attributes for each body area to obtain a clothing attribute recognition result of the target person in the image to be recognized.

11. The device according to claim 9, characterized in that The clothing attribute recognition result of the character includes at least one of the following: Clothing type; Clothing color; Clothing quantity; The clothing includes at least one of the following: Clothes, hats, shoes, accessories.

12. The device according to claim 9, characterized in that The identification and determination module includes an extraction unit and an identification and determination unit; The extraction unit is used to extract at least one image frame from the video captured by the image acquisition device according to a preset extraction frequency, wherein the preset extraction frequency is determined based on the statistically obtained average duration of pedestrians passing through the area controlled by the image acquisition device; The recognition and determination unit is used to detect and identify at least one image frame extracted by the extraction unit through a pre-trained portrait detection and recognition model, and identify and determine at least one image to be recognized that includes at least one target person.

13. The device according to claim 9, characterized in that The first segmentation unit is used to segment the image to be identified based on a region segmentation method to obtain at least one segmented image including a single target person; And / or used to segment the image to be identified based on an edge segmentation method to obtain at least one segmented image including a single target person.

14. The device according to claim 9, characterized in that The recognition unit includes a feature extraction subunit and an input subunit; The feature extraction subunit is used to extract clothing features from any segmented image including a single target person, to obtain clothing feature information for any target person; The input subunit is used to input the clothing feature information for any target person extracted by the feature extraction subunit into a pre-trained neural network recognition model to obtain a clothing attribute recognition result of any person.

15. The device according to claim 9, characterized in that Also included is a storage module; The storage module is used to store clothing attribute recognition results, segmented images, and the corresponding relationship between the clothing attribute recognition results and the segmented images.

16. The device according to claim 15, characterized in that Also included is a query determination module; The query determination module is used to query and determine the image information of the person corresponding to the query request based on the corresponding relationship between the clothing attribute recognition result and the segmented image through the storage module when receiving a person query request including clothing attribute information.

17. An electronic device, characterized in that: include: one or more processors; Memory; One or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to: execute the neural network-based clothing attribute recognition method according to any one of claims 1 to 8.

18. A computer-readable storage medium, characterized in that: The computer storage medium is used to store computer instructions, and when it is run on a computer, the computer can execute the neural network-based clothing attribute recognition method described in any one of claims 1 to 8.