Clothing matching method and electronic device
By acquiring clothing images from display devices and using matching models to recommend clothing, the problem of limited display device functionality is solved, enabling intelligent clothing matching and improving the user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- QINGDAO HISENSE SMART LIFE TECH CO LTD
- Filing Date
- 2022-07-29
- Publication Date
- 2026-05-29
AI Technical Summary
Existing display devices have limited functionality and cannot effectively provide clothing matching recommendations.
A method and electronic device for clothing matching are provided. By acquiring images of clothing to be matched and target clothing types, the images are processed using a matching model to generate clothing image recommendations with a matching degree higher than a threshold.
This enables electronic devices to provide outfit recommendations, improving the user experience and reducing the workload for users when choosing clothing combinations.
Smart Images

Figure CN115269898B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of home technology, and in particular to a method for matching clothing and an electronic device. Background Technology
[0002] The display device has a camera and a display screen. The device can capture images of clothing using the camera and display those images on the screen.
[0003] However, display devices can currently only display images, and their functions are relatively limited. Summary of the Invention
[0004] This application provides a method for matching clothing and an electronic device, which can solve the problem of the limited functionality of display devices in related technologies. The technical solution is as follows:
[0005] On the one hand, a method for matching clothing is provided, which is applied to electronic devices; the method includes:
[0006] In response to an outfit matching instruction, obtain a first image of at least one outfit to be matched, and at least one target outfit type;
[0007] For each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group. The image group includes at least one second image. The type of clothing in each second image is the target clothing type, and the matching degree between the clothing in each second image and the at least one clothing to be matched is greater than the matching degree threshold.
[0008] The second image in each of the aforementioned image groups is recommended.
[0009] On the other hand, an electronic device is provided, the electronic device comprising: a processor; the processor being used for:
[0010] In response to an outfit matching instruction, obtain a first image of at least one outfit to be matched, and at least one target outfit type;
[0011] For each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group. The image group includes at least one second image. The type of clothing in each second image is the target clothing type, and the matching degree between the clothing in each second image and the at least one clothing to be matched is greater than the matching degree threshold.
[0012] The second image in each of the aforementioned image groups is recommended.
[0013] In another aspect, an electronic device is provided, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the clothing matching method as described above.
[0014] In another aspect, a computer-readable storage medium is provided, wherein a computer program is stored therein, the computer program being loaded and executed by a processor to implement the clothing matching method as described above.
[0015] In another aspect, a computer program product containing instructions is provided, which, when run on the computer, causes the computer to perform the clothing matching method described above.
[0016] The beneficial effects of the technical solution provided in this application include at least the following:
[0017] This application provides a clothing matching method and an electronic device. The electronic device, after acquiring a first image of at least one garment to be matched and at least one target garment type, processes the at least one first image and each target garment type using a matching model to obtain at least one second image of a garment whose matching degree with the at least one garment to be matched is greater than a matching degree threshold and whose garment type is the target garment type. Therefore, the electronic device provided in this application can determine images of garments that match the garment to be matched based on the image of the garment to be matched; that is, the electronic device provided in this application can provide outfit recommendations, thus offering rich functionality. Furthermore, since the electronic device can provide outfit recommendations, users do not need to select garments from multiple options for matching, thereby effectively improving the user experience. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 This is a flowchart of a clothing matching method provided in an embodiment of this application;
[0020] Figure 2 This is a schematic diagram of the implementation environment involved in a clothing matching method provided in an embodiment of this application;
[0021] Figure 3 This is a flowchart of another clothing matching method provided in the embodiments of this application;
[0022] Figure 4 This application provides an embodiment of a display device for acquiring a first image of at least one garment to be matched, and an interface diagram of at least one target garment type;
[0023] Figure 5 This is a flowchart illustrating how an electronic device, according to an embodiment of this application, processes multiple first images of clothing to be matched and the target clothing type using a matching model to obtain an image group.
[0024] Figure 6 This is a flowchart illustrating how an electronic device, according to an embodiment of this application, determines the target distance between the feature vector of a third image and the feature vector of at least one image of a target garment using a matching model.
[0025] Figure 7 This is a schematic diagram of at least one second image provided in an embodiment of this application;
[0026] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application;
[0027] Figure 9 This is a software structure block diagram of an electronic device provided in an embodiment of this application. Detailed Implementation
[0028] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.
[0029] This application provides a method for matching clothing, which is applied to an electronic device. Optionally, the electronic device can be a display device or a server. The server can be a single server, a server cluster consisting of several servers, or a cloud computing service center. The display device can be a mirror display, a mobile terminal, or a smart TV, etc. The mobile terminal can be a mobile phone, tablet computer, or laptop computer, etc. See also Figure 1 The method includes:
[0030] Step 101: In response to the clothing matching instruction, obtain a first image of at least one garment to be matched, and at least one target clothing type.
[0031] Each of the at least one target clothing type is paired with at least one clothing type to be matched. The at least one target clothing type can be at least one of the following clothing types: tops, bottoms, jumpsuits, coats, shoes, bags, hats, scarves, sunglasses, jewelry, and accessories. The top does not include coats; for example, the top can be a sweatshirt, sweater, short-sleeved shirt, or blouse.
[0032] In this embodiment, if the electronic device is a display device and a fashion app is installed on it, the fashion matching instruction can be triggered by a touch operation on the application identifier of the fashion app. Furthermore, after receiving the fashion matching instruction, the electronic device can display multiple candidate images and multiple candidate clothing types. Then, in response to a selection operation of a first image of at least one garment to be matched from the multiple candidate images, the display device can acquire at least one first image, and in response to a selection operation of at least one target clothing type from the multiple candidate clothing types, it can acquire at least one target clothing type.
[0033] If the electronic device is a server, then see [link to relevant documentation]. Figure 2 The electronic device 110 can be connected to the display device 120. The clothing matching instruction can be sent from the display device to the electronic device. The clothing matching instruction carries a first image of at least one garment to be matched, and at least one target garment type. The process by which the display device acquires the first image of at least one garment to be matched and at least one target garment type can refer to the relevant implementation process of acquiring the first image and target garment type when the electronic device is a display device, which will not be described in detail in this embodiment.
[0034] Understandably, if the electronic device acquires multiple first images of at least one garment to be paired with clothing, and multiple target clothing types, then the electronic device can make multi-element outfit recommendations based on multiple first images and multiple target clothing types. This increases the flexibility of the electronic device in making outfit recommendations and improves the user experience.
[0035] Step 102: For each target clothing type, use a matching model to process at least one first image and the target clothing type to obtain an image group.
[0036] The image set includes at least one second image, where the type of clothing in each second image is the target clothing type, and the matching degree between the clothing in each second image and at least one clothing to be matched is greater than a matching degree threshold. This matching model can be pre-trained by an electronic device.
[0037] Step 103: Recommend the second image in each image group.
[0038] In the embodiments of this application, for the implementation of the electronic device as a display device, the electronic device can directly display the second image included in each image group in at least one image group, so as to achieve the effect of recommending the second image in each image group.
[0039] In the implementation where the electronic device acts as the server, the electronic device can send the second image from each image group to the display device connected to it for display, thereby achieving the effect of recommending the second image from each image group.
[0040] In summary, this application provides a clothing matching method. An electronic device, after acquiring at least one first image of a garment to be matched and at least one target garment type, processes the at least one first image and each target garment type using a matching model to obtain at least one second image of a garment whose matching degree with the at least one garment to be matched is greater than a matching degree threshold and whose garment type is the target garment type. Therefore, the electronic device provided in this application can determine images of garments that match the garment to be matched based on the image of the garment to be matched; that is, the electronic device provided in this application can provide outfit recommendations, thus offering rich functionality. Furthermore, since the electronic device can provide outfit recommendations, users do not need to select garments from multiple options for matching, thereby effectively improving the user experience.
[0041] This application uses an electronic device as a display device as an example to illustrate the process of the clothing matching method provided in this application. See also: Figure 3 The method includes:
[0042] Step 201: In response to the clothing matching instruction, display multiple alternative images and multiple alternative clothing types.
[0043] The clothing types in the multiple candidate images include at least one type of clothing to be paired. The multiple candidate clothing types can include at least two of the following: tops, bottoms, jumpsuits, coats, shoes, bags, hats, scarves, sunglasses, jewelry, and accessories. For example, the multiple candidate clothing types include: tops, bottoms, jumpsuits, coats, shoes, bags, hats, scarves, sunglasses, jewelry, and accessories.
[0044] It is understood that each of the multiple clothing options mentioned above is a major category (also known as a parent category). Each clothing category can also include multiple subcategories (also known as child categories). For example, tops can include: sweatshirts, short-sleeved shirts, and blouses, etc. Bottoms can include: trousers and skirts, etc. Dresses can include: dresses and jumpsuits, etc. Outerwear can include: down jackets, trench coats, and wool coats, etc. Shoes can include: sandals, canvas shoes, and boots, etc. Bags can include: handbags, crossbody bags, and backpacks, etc. Hats can include: sun hats and rain hats, etc. Scarves can include: wool scarves and silk scarves, etc. Sunglasses can include: sunglasses and light-colored sunglasses, etc. Jewelry can include: bracelets, necklaces, and earrings, etc. Accessories can include: belts and shawls, etc.
[0045] In one alternative implementation, the display device, in response to a clothing matching instruction, can directly display multiple alternative images. In this implementation, the clothing type in the multiple alternative images is one or more of a plurality of alternative clothing types.
[0046] In another alternative implementation, the display device can categorize and display images of clothing of different types. Based on this, in response to a clothing matching instruction, the display device can first display multiple alternative clothing types. Then, in response to a selection operation for at least one reference clothing type among the multiple alternative clothing types, the display device can display multiple alternative images of each of those reference clothing types. In this implementation, the clothing type of the garments in the multiple alternative images constitutes a single reference clothing type. Each reference clothing type can be the clothing type of one of at least one garment to be matched.
[0047] Because the display device can categorize and store images of different clothing types, when selecting the first image of a reference clothing type, the user can directly choose that reference clothing type from multiple alternative clothing types, and then select the first image from multiple alternative images of that reference clothing type. This eliminates the need to first determine the type of clothing among multiple alternative images of different clothing types before selecting the first image of the reference clothing type. This improves the efficiency of obtaining the first image and enhances the user experience.
[0048] Understandably, if there are multiple reference clothing types, the display device can respond sequentially to a selection operation for each of the multiple reference clothing types, displaying multiple alternative images for each reference clothing type.
[0049] It's also understandable that, for a display device to be able to categorize and display images of clothing of different types, the display device can categorize and store images of clothing of different types. For example, the display device can categorize and store images of clothing of different styles according to clothing style. For each clothing style, the display device can categorize and store images of clothing of different types according to clothing type.
[0050] Optionally, the multiple candidate images may be pre-stored in the display device (e.g., a mirror display). For example, the display device may capture images of all clothing owned by the user of the display device via a camera, and for each image, the display device may perform image recognition to determine the type of clothing to which the clothing in the image belongs, and then add the image to the image set corresponding to that type of clothing.
[0051] Step 202: In response to the selection operation of at least one first image of clothing to be matched from a plurality of candidate images, acquire at least one first image.
[0052] After the display device displays multiple alternative images, the user can select at least one first image of clothing to be matched from the multiple alternative images. Accordingly, the display device can acquire at least one first image in response to the selection operation of the first image of the at least one outfit to be matched.
[0053] For example, if the display device is a mirror monitor, see [link to relevant documentation]. Figure 4 The mirror display has a clothing matching app installed. The mirror display can receive clothing matching commands triggered by touch operations targeting the app's identifier, and can respond to these commands by displaying a matching interface. This interface includes selection controls for multiple clothing types such as tops, bottoms, outerwear, and jumpsuits, as well as a matching control 01.
[0054] like Figure 4 As shown, the user touched the selection control 02 corresponding to the download. Accordingly, the display device can display multiple alternative images for the download. For example... Figure 4 As shown, the display device can display one of the multiple alternative images on the current interface, and can display other alternative images that are different from the current alternative image in response to a swipe operation on the screen of the display device (such as a left swipe or a right swipe).
[0055] Then, the display device can respond to a touch operation on the matching control 01 and display the currently displayed alternative image (i.e., Figure 4 The image of the skirt in the image is identified as the first image of an outfit to be paired with.
[0056] Step 203: In response to the selection operation for at least one target clothing type among multiple alternative clothing types, obtain at least one target clothing type.
[0057] Each of the at least one target clothing type is paired with at least one clothing type to be paired.
[0058] For examples, please continue to see Figure 4 Upon receiving a touch operation on the matching control 01, the display device can show selection controls for multiple alternative clothing types. Then, in response to a touch operation on the top selection control 03, the display device can select the top as the target clothing type. For example... Figure 4 As shown, the selection control for each available clothing type displays an image of that clothing type.
[0059] Step 204: For each target clothing type, use a matching model to process at least one first image and the target clothing type to obtain an image group.
[0060] The image group includes at least one second image, in which the type of clothing is the target clothing type, and the degree of matching between the clothing in each second image and at least one clothing to be matched is greater than the degree of matching threshold.
[0061] In the embodiments of this application, for each target clothing type, the display device uses a matching model to process at least one first image and the target clothing type to obtain an image group. There are multiple ways to achieve this. The embodiments of this application use the following two optional implementation methods as examples to illustrate the process of the display device using a matching model to process at least one first image and the target clothing type.
[0062] In one alternative implementation, see [link to implementation details]. Figure 5 For each target clothing type, the process by which the display device uses a matching model to process multiple first images of clothing to be matched and the target clothing type to obtain an image group may include:
[0063] Step 2041: For each target clothing type, obtain multiple third images.
[0064] In each of the third images, the clothing type is the target clothing type.
[0065] For example, if the display device is a user's private device, the plurality of third images may include images of clothing of all the target clothing types owned by that user. Furthermore, the plurality of third images may also include images of clothing of the target clothing types that the user does not own.
[0066] Step 2042: For each of the multiple third images, determine the target distance between the feature vector of the third image and the feature vector of at least one first image.
[0067] The feature vector of each image in the first and third images may include the image feature vector of that image. The image feature vector of each image may be obtained by processing the image through a convolutional neural network using a matching model.
[0068] Optionally, the feature vector of each image may also include a semantic feature vector of text describing the clothing in the image. Since the feature vector also includes a semantic feature vector, the accuracy of the determined target distance can be ensured, which in turn ensures the accuracy of the determined second image.
[0069] Understandably, in addition to the implementation of semantic feature vectors, the display device can also store text describing the clothing in each of the multiple candidate images. This text can describe features such as the style and color of the clothing. This text can be acquired by the display device in response to user input.
[0070] Step 2043: The third image whose target distance is less than the distance threshold is identified as the second image in an image group.
[0071] In this embodiment, after the matching model in the display device obtains multiple target distances, for each target distance, the matching model can compare the target distance with a distance threshold. If the matching model determines that the target distance between a certain third image and at least one first image is less than the distance threshold, then the third image can be identified as the second image in an image group.
[0072] The distance threshold can be a fixed value pre-stored by the display device, or it can be flexibly determined by the display device based on the number of second images in the image group. For example, after the display device determines the target distance between each of the multiple third images and at least one first image through a matching model, it can sort the multiple distances in ascending order. Then, if the display device determines that the number of second images in each image group is N, where N is an integer greater than or equal to 1, the display device can determine the (N+1)th target distance among the sorted multiple target distances as the distance threshold.
[0073] As described in steps 2041 to 2043 above, if the distance between the feature vector of one garment image and the feature vector of another garment image is less than a distance threshold, then the description indicates that the matching degree between the one garment and the other garment is greater than the matching degree threshold.
[0074] In this embodiment of the application, if the number of at least one garment to be matched is multiple, that is, the number of first images is multiple, then see Figure 6 The process by which a display device determines the target distance between the feature vector of a third image and the feature vector of at least one image of a target garment through a matching model may include:
[0075] Step S1: For each first image, determine the initial distance between the feature vector of the third image and the feature vector of the first image.
[0076] The distance between the feature vector of each first image and the feature vector of the third image can be the Euclidean distance.
[0077] In this embodiment, the matching model may include multiple sub-models, each sub-model corresponding to a type combination. In this implementation, each type combination includes two clothing types. The display device can determine a target sub-model from the multiple sub-models and use this target sub-model to process the feature vectors of the third image and the first image to obtain an initial distance between the feature vectors of the third image and the first image.
[0078] The target type combination corresponding to the target sub-model includes: the clothing type of the clothing to be matched in the first image, and the target clothing type. Since the display device can use the target sub-model corresponding to the target type combination from multiple sub-models to process the first image and the target clothing type, it can ensure that the image group corresponding to the target clothing type is determined relatively accurately.
[0079] It is understandable that the display device stores the correspondence between type combinations and sub-models, and the display device can determine the target sub-model from the correspondence based on the target type combination.
[0080] Step S2: The weighted average of multiple initial distances is determined as the target distance between the feature vector of the third image and the feature vector of at least one first image.
[0081] In this embodiment of the application, after obtaining the initial distance between the third image and each of the multiple first images, the matching model can perform a weighted summation of the multiple initial distances to determine the weighted average of the multiple initial distances as the target distance between the feature vector of the third image and the feature vectors of the multiple first images.
[0082] The weight of each initial distance among the multiple initial distances can be pre-stored by the display device and determined during the training of the model.
[0083] In another alternative implementation, in a scenario where there are multiple first images, the process by which the display device processes at least one first image and the target clothing type using a matching model to obtain an image group for each target clothing type may include: for each target clothing type, the display device processes a reference matching image and the target clothing type using a matching model to obtain an image group.
[0084] The reference image is obtained based on multiple first images. That is, the display device can treat the multiple first images as a whole and process this whole through a matching model to obtain an image group.
[0085] Understandably, in this implementation, the type combination corresponding to each of the multiple sub-models included in the matching model can include at least two clothing types. For example, the type combination corresponding to some sub-models can include three clothing types.
[0086] In the embodiments of this application, if there are multiple target clothing types, in an optional example, for each target clothing type, the display device can directly process at least one first image and the target clothing type using a matching model to obtain an image group.
[0087] In another alternative example, the multiple target clothing types include: a first target clothing type and a second target clothing type, and the matching priority of the first target clothing type is higher than that of the second target clothing type. Then, for each target clothing type, the process of the display device using a matching model to process at least one first image and one target clothing type to obtain an image group may include:
[0088] For a first target clothing type, the display device uses a matching model to process at least one first image and the first target clothing type to obtain a first image group. The type of clothing in each second image included in the first image group is the first target clothing type. Then, for a second target clothing type, the display device uses a matching model to process at least one first image, the second target clothing type, and at least one second image from the first image group to obtain a second image group.
[0089] In this second image group, the type of clothing in each second image is the second target clothing type. The matching priority of each clothing type among the multiple clothing types can be pre-stored by the display device.
[0090] Therefore, it can be seen that the matching degree between the clothing in each second image of the first image group and at least one piece of clothing to be matched is greater than the matching degree threshold. Similarly, the matching degree between the clothing in each second image of the second image group and at least one piece of clothing to be matched, as well as the clothing in one second image of the first image group, is greater than the matching degree threshold. This ensures that the clothing in any second image of the first image group, and the clothing in the corresponding second image of the second image group, have a good matching effect. Here, the corresponding second image can refer to a second image obtained based on the at least one first image and the corresponding second image.
[0091] In this embodiment, compared to clothing items such as shoes, bags, hats, scarves, sunglasses, jewelry, and accessories, clothing items such as tops, bottoms, jumpsuits, and coats have a greater impact on the overall effect of clothing coordination. Therefore, the priority for coordinating tops, bottoms, jumpsuits, and coats can be higher than that for shoes, bags, hats, scarves, sunglasses, jewelry, and accessories. That is, when coordinating outfits, tops, bottoms, jumpsuits, and coats are considered first, followed by shoes, bags, hats, scarves, sunglasses, jewelry, and accessories. This ensures that the clothing items in the second images of each image group, as well as at least one garment to be coordinated, achieve a better coordination effect.
[0092] Among them, the priority of matching tops, bottoms, jumpsuits and coats can be the same or different, and the priority of matching shoes, bags, hats, scarves, sunglasses, jewelry and accessories can also be the same or different.
[0093] For example, if the clothing to be matched is a top, and multiple target clothing types include: bottoms, outerwear, shoes, bags, hats, scarves, sunglasses, jewelry, and accessories, the matching model can first determine the target bottoms to match the top, and then determine the target outerwear to match both the top and the target bottoms. Then, the matching model can determine the shoes, bags, hats, scarves, sunglasses, jewelry, and accessories to match the top, the target bottoms, and the target outerwear. For instance, the matching model can first determine the target shoes to match the top, the target bottoms, and the target outerwear, and then determine the bag to match the top, the target bottoms, the target outerwear, and the target shoes. This process continues until all target clothing types are obtained. The compatibility of the target clothing with other clothing is greater than a compatibility threshold.
[0094] Similarly, if the clothing to be styled is bottoms, and multiple target clothing types include: tops, coats, shoes, bags, hats, scarves, sunglasses, jewelry, and accessories, then the styling model can first determine the target tops to pair with the bottoms, and then determine the target coats to pair with both the bottoms and the target tops. Then, the styling model can determine the shoes, bags, hats, scarves, sunglasses, jewelry, and accessories to pair with the bottoms, the target tops, and the target coats.
[0095] If the clothing to be matched is a jumpsuit, and there are multiple target clothing types including: coat, shoes, bag, hat, scarf, sunglasses, jewelry and accessories, then the matching model can first determine the target coat to match the jumpsuit, and then determine the shoes, bag, hat, scarf, sunglasses, jewelry and accessories to match the jumpsuit and the target coat.
[0096] Understandably, the display device can train a matching model before processing at least one first image and at least one target clothing type using the matching model. For example, the display device can train multiple sub-models and weights for the output of each sub-model to obtain the matching model. This ensures that the trained matching model has high reliability.
[0097] The embodiments of this application include multiple clothing types, such as tops, bottoms, jumpsuits, coats, shoes, bags, hats, scarves, sunglasses, jewelry, and accessories. Each sub-model corresponds to a type combination that includes two clothing types. Taking the feature vector of each image as an example, which includes an image feature vector and a semantic feature vector, the process of training a matching model using a display device provided in the embodiments of this application is illustrated by way of example.
[0098] The display device can acquire multiple sample data sets. Each sample data set includes: a first sample image, a second sample image, a third sample image, a first sample text describing the clothing in the first sample image, a second sample text describing the clothing in the second sample image, a third sample text describing the clothing in the third sample image, the matching degree between the clothing in the first sample image and the clothing in the second sample image, and the matching degree between the clothing in the first sample image and the clothing in the third sample image. The display device can then train the model using these multiple sample data sets to obtain a sub-model.
[0099] In this combination, the clothing type in the first sample image is one of the clothing types in a type combination, and the clothing types in the second and third sample images are the other clothing type in the same combination. Furthermore, the matching degree between the clothing in the first and second sample images is higher than a matching degree threshold, while the matching degree between the clothing in the first and third sample images is lower than a matching degree threshold. This type combination includes any two clothing types from a set of multiple clothing types.
[0100] It is understandable that each type combination includes two clothing types that can be the same or different. This ensures that after obtaining the first images of multiple clothing items of the same type to be matched, the display device can still output the image set through the matching model, thereby ensuring the normal operation of the matching model and ensuring the normal progress of the process of determining the matching clothing for the multiple clothing items to be matched.
[0101] It is also understandable that if the type combination includes two clothing types that can be the same or different, then 66 type combinations can be obtained based on the aforementioned multiple clothing types. Correspondingly, the matching model trained by the display device can include 66 sub-models.
[0102] In this embodiment, the process by which the display device trains multiple sample data to obtain a sub-model corresponding to a certain type of combination may include: for each sample image among the first, second, and third sample images, the display device processes the sample image using a convolutional neural network to obtain the image feature vector of the sample image, and extracts at least one keyword from the sample text describing the clothing in the sample image. Then, the display device obtains the semantic feature vector of the sample image based on the at least one keyword, and trains a sub-model corresponding to the type of combination based on the image feature vector and semantic feature vector of each sample image from the first to the third sample images, as well as a loss function. The image feature vector and semantic feature vector of each sample image have the same dimension.
[0103] Optionally, the loss function can be a triplet loss function. This triplet loss function L satisfies the following formula:
[0104] S = L c +L v Formula (1)
[0105] Among them, L c It can satisfy the following formula (2), L v It can satisfy the following formula (3).
[0106] L c =L(T1+T2+T3) Formula (2)
[0107] L v =L vi +L vj +L vk Formula (3)
[0108] In formula (2), T1 is the mapping vector obtained by mapping the image feature vector of the first sample image to the feature space corresponding to the type combination. T2 is the mapping vector obtained by mapping the image feature vector of the second sample image to the same feature space. T3 is the mapping vector obtained by mapping the image feature vector of the third sample image to the same feature space. In formula (3), L... vi It can satisfy the following formula (4), L vj It can satisfy the following formula (5), L vk It satisfies the following formula (6).
[0109] L vi =L(T1+Y1+Y2)+L(T1+T1+T3) Formula (4)
[0110] L vj =L(T2+Y1+Y2)+L(T2+T2+T3) Formula (5)
[0111] L vk =L(T3+Y3+Y2)+L(T3+T2+T3) Formula (6)
[0112] In formulas (4) to (6), Y1 is the mapping vector obtained by mapping the semantic feature vector of the first sample image to the feature space. Y2 is the mapping vector obtained by mapping the semantic feature vector of the second sample image to the feature space. Y3 is the mapping vector obtained by mapping the semantic feature vector of the second sample image to the feature space.
[0113] In this embodiment of the application, L(A+B+C) can satisfy:
[0114] L(A+B+C)=max{0,d AB -d AC +μ} + Formula (7)
[0115] In formula (7), A, B, and C are all vectors with the same dimension. AB Let d be the distance between vector A and vector B. AC Let μ be the distance between vectors A and C. μ is a constant.
[0116] Based on the above formula (7), it can be determined that L(T1+T2+T3) in formula (2) satisfies:
[0117]
[0118] Similarly, we can obtain L(T1+Y1+Y2) to L(T3+T2+T3) in formulas (4) to (6).
[0119] According to formulas (2), (4), and (6) above, the display device maps the feature vector of each sample image to the feature space corresponding to that type of combination, rather than mapping it to the global feature space. This avoids mistransmission of matching information (for example, if the distance between the feature vector of a shoe and the feature vector of a bottom in the global feature space is less than a distance threshold, and the distance between the feature vector of the bottom and the feature vector of a top in the global feature space is also less than a distance threshold, then the distance between the feature vector of the shoe and the feature vector of the top in the global feature space will also be less than a distance threshold. However, the shoe and the top may not actually match), thus ensuring a higher reliability and novelty of the obtained matching model.
[0120] Optionally, the display device may employ a deep residual network (ResNet) to perform feature extraction processing on each sample image to obtain an image feature vector for that sample image. This deep residual network may be an 18-layer deep residual network. The dimension of the image feature vector may be 64-dimensional or 512-dimensional.
[0121] After obtaining at least one keyword from the sample text, the display device can, for each keyword, obtain a one-hot encoded word vector corresponding to that keyword based on its ranking among multiple candidate keywords. Then, for each word vector, the display device can use a word-to-vector (Word2Vec) model to map it into an n-dimensional word vector. Here, the one-hot encoded word vector has a dimension of 1, and n is an integer greater than 1. The multiple keywords are pre-stored in the display device.
[0122] Subsequently, the display device can perform dimensionality reduction processing on the n-dimensional word vector of each keyword in at least one keyword to obtain the dimensionality-reduced word vector, and then determine the semantic feature vector of the sample image based on the weighted average of the at least one dimensionality-reduced word vector.
[0123] Optionally, the display device can use principal component analysis (PCA) algorithm to reduce the dimensionality of the n-dimensional word vector for each keyword.
[0124] It is understood that the process of training a sub-model corresponding to a type combination consisting of at least three clothing types for a display device can refer to the process of training a sub-model corresponding to a reference clothing type for a display device, and will not be repeated here in the embodiments of this application.
[0125] In this embodiment, after training each sub-model, for the third clothing type, the display device can train the proportion of the auxiliary distance output by each sub-model in the reference distance based on the third sample image (i.e., a sample of clothing of the third clothing type), at least one fourth sample image (i.e., a sample image of clothing of the fourth clothing type), and the reference matching degree between the clothing of the third clothing type and the clothing of the at least one fourth clothing type. That is, the weight of the output result of each sub-model in the process of determining the clothing of the third clothing type that matches the clothing of the at least one fourth clothing type.
[0126] The third clothing type differs from the fourth clothing type; the third clothing type can be any of the multiple clothing types. The reference distance is negatively correlated with the reference matching degree. That is, the higher the reference matching degree, the smaller the reference distance. Each sub-model in at least one sub-model corresponds to a type combination including: one fourth clothing type and the third clothing type. When there are multiple fourth images, there are also multiple fourth clothing types, and these multiple fourth clothing types are different.
[0127] Understandably, during the training of the outfit matching model, the display device can update the third and fourth clothing types, as well as the number of fourth clothing types, to train the weights of the output results of each sub-model in various outfit matching scenarios. In these different outfit matching scenarios, the clothing types of the outfits to be matched, and / or the number of outfits to be matched, and / or the target clothing type are different.
[0128] Taking a scenario where there are at least three fourth sample images, this paper provides an example of how a display device determines the weights of the output results of three sub-models in a scenario where it determines the matching of clothing of a third clothing type with clothing of three fourth clothing types.
[0129] For any fourth sample image of clothing of a fourth clothing type, the display device can map the fourth sample image to the feature space corresponding to the two reference type combinations, respectively, to obtain two mapping vectors, and then obtain the average vector of the six mapping vectors. Each reference type combination includes: the given fourth clothing type and one of the remaining two fourth clothing types.
[0130] Then, for each fourth sample image, the display device can use a corresponding sub-model to process the fourth sample image and the third sample image to obtain the auxiliary distance between the feature vector of the fourth sample image and the feature vector of the third sample image. The type combination corresponding to the sub-model includes the fourth clothing type and the third clothing type in the fourth sample image.
[0131] Subsequently, the display device can learn three weights that correspond one-to-one with the three auxiliary distances (i.e., the output results of the three sub-models in the scenario of matching the third clothing type with the clothing of the three fourth clothing types) based on the three auxiliary distances and the distance between the average vector and the feature vector of the third sample image.
[0132] Step 205: Recommend the second image in each image group.
[0133] In the embodiments of this application, the display device can directly display each second image included in each image group in at least one image group, so as to achieve the effect of recommending the second image in each image group.
[0134] It is understandable that after acquiring the first image and the target clothing type, the display device can also acquire the target clothing style and recommend a second image of clothing with that target clothing style in each image group. The target clothing style can be acquired by the display device in response to user input.
[0135] For example, assuming the display device obtains a skirt as the clothing to be matched, and obtains multiple target clothing types including short-sleeved shirts and shoes, then see 7. The display device displays the target short-sleeved shirts and target shoes on the matching interface that have a matching degree greater than the matching degree threshold with the skirt, as determined by the matching model.
[0136] from Figure 7 As can be seen, the matching interface can also display selection controls for multiple clothing types besides tops and shoes. Therefore, if the user needs to obtain other clothing types to match the current short-sleeved shirt, the target short-sleeved shirt, and the target shoes, they can then touch the selection control for those other clothing types. Correspondingly, the display device can respond to the touch operation on the selection control for those other clothing types, obtaining and displaying the other clothing types that match the current short-sleeved shirt, the target short-sleeved shirt, and the target shoes.
[0137] It should be noted that the order of steps in the clothing matching method provided in this application embodiment can be appropriately adjusted, and steps can also be added or removed as appropriate. Any variations that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the protection scope of this application, and therefore will not be elaborated further.
[0138] In summary, this application provides a clothing matching method. An electronic device, after acquiring at least one first image of a garment to be matched and at least one target garment type, processes the at least one first image and each target garment type using a matching model to obtain at least one second image of a garment whose matching degree with the at least one garment to be matched is greater than a matching degree threshold and whose garment type is the target garment type. Therefore, the electronic device provided in this application can determine images of garments that match the garment to be matched based on the image of the garment to be matched; that is, the electronic device provided in this application can provide outfit recommendations, thus offering rich functionality. Furthermore, since the electronic device can provide outfit recommendations, users do not need to select garments from multiple options for matching, thereby effectively improving the user experience.
[0139] This application provides an electronic device that can execute the clothing matching method provided in the above-described method embodiments. See also... Figure 8The electronic device 110 includes a processor 1101. The processor 1101 is used for:
[0140] In response to an outfit matching instruction, obtain a first image of at least one outfit to be matched, and at least one target outfit type;
[0141] For each target clothing type, a matching model is used to process at least one first image and the target clothing type to obtain an image group. The image group includes at least one second image. The type of clothing in each second image is the target clothing type, and the matching degree between the clothing in each second image and at least one clothing to be matched is greater than the matching degree threshold.
[0142] The second image in each image group is recommended.
[0143] Optionally, the processor 1101 can be used for:
[0144] For each target clothing type, multiple third images are obtained, and the type of clothing in each third image is the target clothing type.
[0145] For each of the multiple third images, determine the target distance between the feature vector of the third image and the feature vector of at least one first image;
[0146] The third image whose target distance is less than the distance threshold is identified as the second image in an image group.
[0147] Optionally, the number of at least one garment to be matched can be multiple. The processor 1101 can be used for:
[0148] For each first image, determine the initial distance between the feature vector of the third image and the feature vector of the first image;
[0149] The weighted average of multiple initial distances is used to determine the target distance between the feature vector of the third image and the feature vector of at least one first image.
[0150] Optionally, the model includes multiple sub-models, each sub-model corresponding to a type combination, and each type combination includes two clothing types. The processor 1101 can be used for:
[0151] For each first image, the target sub-model from multiple sub-models is used to determine the initial distance between the feature vector of the third image and the feature vector of the first image;
[0152] The target type combination corresponding to the target sub-model includes the clothing type of the clothing to be matched in the first image, and the target clothing type.
[0153] Optionally, the number of at least one garment to be matched can be multiple. The processor 1101 can be used for:
[0154] For each target clothing type, a matching model is used to process the reference matching image and the target clothing type to obtain an image set;
[0155] The reference matching image is obtained based on multiple first images.
[0156] Optionally, there may be multiple target clothing types, including a first target clothing type and a second target clothing type, wherein the matching priority of the first target clothing type is higher than that of the second target clothing type. The processor 1101 can be used for:
[0157] For the first target clothing type, a matching model is used to process at least one first image and the first target clothing type to obtain a first image group. The type of clothing in each second image included in the first image group is the first target clothing type.
[0158] For the second target clothing type, a matching model is used to process at least one first image, the second target clothing type, and at least one second image in the first image group to obtain a second image group. The type of clothing in each second image in the second image group is the second target clothing type.
[0159] Optionally, the electronic device is a display device, and the electronic device further includes a display screen 131. The processor 1101 can be used for:
[0160] In response to an outfit matching command, the control display screen 131 displays multiple alternative images and multiple alternative clothing types, wherein the clothing type of the clothing in the multiple alternative images includes: at least one clothing type of the outfit to be matched.
[0161] In response to a selection operation for at least one first image among a plurality of candidate images, at least one first image is acquired;
[0162] In response to a selection operation for at least one target clothing type among multiple alternative clothing types, obtain at least one target clothing type.
[0163] Optionally, the electronic device is a server, which is connected to the display device. The processor 1101 can be used to: send the second image from each image group to the display device for display;
[0164] Optionally, the electronic device is a display device, and the electronic device further includes a display screen 131. The processor 1101 can be used for:
[0165] The control display shows the second image in each image group.
[0166] In summary, this application provides an electronic device that, after acquiring at least one first image of an outfit to be styled and at least one target outfit type, processes the first image and each target outfit type using a styling model to obtain at least one second image of an outfit whose styling degree with the at least one outfit to be styled is greater than a styling degree threshold and whose outfit type is the target outfit type. Therefore, the electronic device provided in this application can determine, based on the image of the outfit to be styled, the image of the outfit to be styled, which means it can provide outfit recommendations. Thus, the electronic device has a rich set of functions. Furthermore, because the electronic device can provide outfit recommendations, users do not need to select outfits from multiple options, thereby effectively improving the user experience.
[0167] See Figure 8 The electronic device 110 provided in this application embodiment may also include: a display unit 130, a radio frequency (RF) circuit 150, an audio circuit 160, a wireless fidelity (Wi-Fi) module 170, a Bluetooth module 180, a power supply 190, and a camera 121, etc.
[0168] The camera 121 can be used to capture still images or videos. An object is projected onto a photosensitive element by generating an optical image through the lens. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then transmitted to the processor 1101 to be converted into a digital image signal.
[0169] The processor 1101 is the control center of the electronic device 110. It connects various parts of the terminal via various interfaces and lines, and performs various functions and processes data by running or executing software programs stored in the memory 140 and calling data stored in the memory 140. In some embodiments, the processor 1101 may include one or more processing units; the processor 1101 may also integrate an application processor and a baseband processor, wherein the application processor mainly handles the operating system, user interface, and applications, and the baseband processor mainly handles wireless communication. It is understood that the baseband processor may not be integrated into the processor 1101. In this application, the processor 1101 can run an operating system and applications, control the user interface display, and implement the clothing matching method provided in the embodiments of this application. Furthermore, the processor 1101 is coupled to the input unit and the display unit 130.
[0170] The display unit 130 can be used to receive input digital or character information and generate signal inputs related to user settings and function control of the electronic device 110. Optionally, the display unit 130 can also be used to display information input by the user or information provided to the user, as well as various menus of the electronic device 110, forming a graphical user interface (GUI). The display unit 130 may include a display screen 131 disposed on the front of the electronic device 110. The display screen 131 may be configured as a liquid crystal display, a light-emitting diode, or the like. The display unit 130 can be used to display the various graphical user interfaces described in this application.
[0171] The display unit 130 includes a display screen 131 and a touch screen 132 disposed on the front of the electronic device 110. The display screen 131 can be used to display preview images. The touch screen 132 can collect touch operations from the user on or near it, such as clicking buttons, dragging scroll boxes, etc. The touch screen 132 can cover the display screen 131, or the touch screen 132 can be integrated with the display screen 131 to realize the input and output functions of the electronic device 110. After integration, it can be referred to as a touch display screen.
[0172] The memory 140 can be used to store software programs and data. The processor 1101 executes various functions of the electronic device 110 and performs data processing by running the software programs or data stored in the memory 140. The memory 140 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device. The memory 140 stores an operating system that enables the electronic device 110 to run. In this application, the memory 140 may store the operating system and various application programs, and may also store code that executes the clothing matching method provided in the embodiments of this application.
[0173] The RF circuit 150 can be used to receive and transmit signals during information transmission or calls. It can receive downlink data from the base station and hand it over to the processor 1101 for processing; it can also send uplink data to the base station. Typically, the RF circuit includes, but is not limited to, devices such as antennas, at least one amplifier, transceivers, couplers, low-noise amplifiers, and duplexers.
[0174] Audio circuit 160, speaker 161, and microphone 162 provide an audio interface between the user and electronic device 110. Audio circuit 160 converts received audio data into electrical signals and transmits them to speaker 161, where speaker 161 converts them into sound signals for output. Electronic device 110 may also be equipped with volume buttons for adjusting the volume of the sound signal. On the other hand, microphone 162 converts collected sound signals into electrical signals, which are then received by audio circuit 160, converted into audio data, and output to RF circuit 150 for transmission to, for example, another terminal, or to memory 140 for further processing. In this application, microphone 162 can acquire the user's voice.
[0175] Wi-Fi is a short-range wireless transmission technology. Electronic device 110 can use Wi-Fi module 170 to help users send and receive emails, browse web pages, and access streaming media, providing users with wireless broadband internet access.
[0176] Bluetooth module 180 is used to interact with other Bluetooth devices that also have Bluetooth modules via the Bluetooth protocol. For example, electronic device 110 can establish a Bluetooth connection with wearable electronic devices (such as smartwatches) that also have Bluetooth modules through Bluetooth module 180, thereby exchanging data.
[0177] The electronic device 110 also includes a power supply 190 (such as a battery) that supplies power to various components. The power supply can be logically connected to the processor 1101 through a power management system, thereby enabling the management of charging, discharging, and power consumption. The electronic device 110 may also be equipped with a power button for powering on and off the terminal, as well as screen locking.
[0178] Electronic device 110 may include at least one sensor 1110, such as motion sensor 11101, distance sensor 11102, and temperature sensor 11103. Electronic device 110 may also be configured with other sensors such as gyroscope, barometer, hygrometer, thermometer, and infrared sensor.
[0179] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the mobile terminal and various devices described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0180] Figure 9 is a software structure block diagram of a mobile terminal provided in an embodiment of this application. The layered architecture divides the software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the Android runtime environment (ART) and system libraries, and the kernel layer.
[0181] The application layer can include a series of application packages. For example... Figure 9 As shown, the application package can include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and SMS. The application framework layer provides application programming interfaces (APIs) and programming frameworks for the applications in the application layer. The application framework layer includes some predefined functions.
[0182] like Figure 9 As shown, the application framework layer may include a window manager, content provider, view system, phone manager, resource manager, notification manager, etc.
[0183] The window manager is used to manage windowed applications. It can retrieve screen size, determine the presence of a status bar, lock the screen, and capture screenshots, among other things.
[0184] Content providers store and retrieve data, making that data accessible to applications. This data may include videos, images, audio, made and received phone calls, browsing history and bookmarks, phone books, etc.
[0185] A view system includes visual controls, such as controls for displaying text and controls for displaying images. View systems can be used to build applications. A display interface can consist of one or more views. For example, a display interface including a text notification icon could include views for displaying text and views for displaying images.
[0186] The phone manager is used to provide communication functions for electronic devices 110. For example, it manages call status (including connection and disconnection).
[0187] The file explorer provides applications with various resources, such as localized strings, icons, images, layout files, video files, and more.
[0188] The notification manager allows applications to display notifications in the status bar. These notifications can be used to convey informational messages and can disappear automatically after a short pause, requiring no user interaction. For example, the notification manager can be used to notify users of download completion or message alerts. The notification manager can also display notifications as icons or scrolling text in the top status bar, such as notifications from background applications, or as dialog boxes on the screen. Examples include displaying text messages in the status bar, emitting alert sounds, vibrating communication terminals, and flashing indicator lights.
[0189] The Android runtime consists of the core libraries and the virtual machine. The Android runtime is responsible for the scheduling and management of the Android system.
[0190] The core library consists of two parts: one part is the functionalities that need to be called by the Java language, and the other part is the Android core library.
[0191] The application layer and application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.
[0192] System libraries can include multiple functional modules. For example: surface manager, media libraries, 3D graphics processing libraries (e.g., OpenGL ES), 2D graphics engines (e.g., SGL), etc.
[0193] The Surface Manager is used to manage the display subsystem and provides the blending of 2D and 3D layers for multiple applications.
[0194] The media library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG.
[0195] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
[0196] A 2D graphics engine is a graphics engine for 2D drawing.
[0197] The kernel layer is the layer between hardware and software. The kernel layer contains at least the display driver, camera driver, audio driver, and sensor driver.
[0198] This application provides an electronic device that may include a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the clothing matching method provided in the above embodiments, for example... Figure 1 or Figure 3 The method shown.
[0199] This application provides a computer-readable storage medium storing a computer program, which is loaded and executed by a processor using the clothing matching method provided in the above embodiments, for example... Figure 1 or Figure 3 The method shown.
[0200] This application also provides a computer program product containing instructions. When the computer program product is run on a computer, it causes the computer to execute the clothing matching method provided in the above-described method embodiments, for example... Figure 1 or Figure 3 The method shown.
[0201] Those skilled in the art will understand that all or part of the steps of the above embodiments can be implemented by hardware or by a program instructing related hardware. The program can be stored in a computer-readable storage medium, such as a read-only memory, a disk, or an optical disk.
[0202] It should be understood that the term "and / or" as used herein indicates that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. The character " / " generally indicates that the preceding and following objects are in an "or" relationship. Furthermore, the term "at least one" in this application means one or more, and the term "multiple" in this application means two or more.
[0203] In this application, the terms "first," "second," etc., are used to distinguish identical or similar items that have essentially the same function. It should be understood that there is no logical or temporal dependency between "first," "second," and "nth," nor is there any limitation on quantity or execution order. For example, without departing from the scope of the various examples described, a first image can be referred to as a second image, and similarly, a second image can be referred to as a first image.
[0204] The above description is merely an exemplary embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.
Claims
1. A method for matching clothing, characterized in that, Applied to electronic devices; the method includes: In response to an outfit matching instruction, obtain a first image of at least one outfit to be matched, and at least one target outfit type; For each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group. The image group includes at least one second image. The type of clothing in each second image is the target clothing type, and the matching degree between the clothing in each second image and the at least one clothing to be matched is greater than the matching degree threshold. The second image in each of the aforementioned image groups is recommended; Wherein, if the at least one target clothing type includes a first target clothing type and a second target clothing type, and the matching priority of the first target clothing type is higher than that of the second target clothing type, then for each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group, including: For the first target clothing type, the matching model is used to process the at least one first image and the first target clothing type to obtain a first image group, wherein the type of clothing in each second image included in the first image group is the first target clothing type. For the second target clothing type, the matching model is used to process the at least one first image, the second target clothing type, and at least one second image in the first image group to obtain a second image group, wherein the type of clothing in each second image in the second image group is the second target clothing type.
2. The method according to claim 1, characterized in that, For each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group, including: For each target clothing type, multiple third images are obtained, and the type of clothing in each third image is the target clothing type; For each of the plurality of third images, determine the target distance between the feature vector of the third image and the feature vector of at least one first image; The third image whose target distance is less than the distance threshold is identified as the second image in an image group.
3. The method according to claim 2, characterized in that, The number of at least one garment to be matched is multiple; determining the target distance between the feature vector of the third image and the feature vector of the image of the at least one target garment includes: For each of the first images, determine the initial distance between the feature vector of the third image and the feature vector of the first image; The weighted average of the multiple initial distances is determined as the target distance between the feature vector of the third image and the feature vector of at least one first image.
4. The method according to claim 3, characterized in that, The matching model includes multiple sub-models, each sub-model corresponding to a type combination, and each type combination including two clothing types; for each first image, determining the initial distance between the feature vector of the third image and the feature vector of the first image includes: For each of the first images, the target sub-model among the plurality of sub-models is used to determine the initial distance between the feature vector of the third image and the feature vector of the first image; The target type combination corresponding to the target sub-model includes the clothing type of the clothing to be matched in the first image, and the target clothing type.
5. The method according to claim 1, characterized in that, The number of at least one garment to be matched is multiple; for each target garment type, a matching model is used to process the at least one first image and the target garment type to obtain an image group, including: For each target clothing type, a matching model is used to process the reference matching image and the target clothing type to obtain an image group; The reference matching image is obtained based on multiple first images.
6. The method according to any one of claims 1 to 5, characterized in that, The electronic device is a display device; The process of responding to a clothing matching instruction by acquiring a first image of at least one garment to be matched, and at least one target clothing type, includes: In response to an outfit matching instruction, multiple alternative images and multiple alternative clothing types are displayed, wherein the clothing type of the clothing in the multiple alternative images includes: the clothing type of the at least one outfit to be matched; In response to a selection operation for at least one first image among a plurality of candidate images, the at least one first image is acquired; In response to a selection operation for at least one target clothing type among the plurality of alternative clothing types, the at least one target clothing type is obtained.
7. The method according to any one of claims 1 to 5, characterized in that, The electronic device is a server, and the server is connected to the display device; the recommendation of the second image in each of the image groups includes: The second image from each of the image groups is sent to the display device for display.
8. The method according to any one of claims 1 to 5, characterized in that, The electronic device is a display device; the recommendation of the second image in each of the image groups includes: Display the second image in each of the image groups.
9. An electronic device, characterized in that, The electronic device includes: a processor; the processor is used for: In response to an outfit matching instruction, obtain a first image of at least one outfit to be matched, and at least one target outfit type; For each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group. The image group includes at least one second image. The type of clothing in each second image is the target clothing type, and the matching degree between the clothing in each second image and the at least one clothing to be matched is greater than the matching degree threshold. The second image in each of the aforementioned image groups is recommended; Wherein, if the at least one target clothing type includes a first target clothing type and a second target clothing type, and the matching priority of the first target clothing type is higher than that of the second target clothing type, then for each target clothing type, a matching model is used to process the at least one first image and the target clothing type to obtain an image group, including: For the first target clothing type, the matching model is used to process the at least one first image and the first target clothing type to obtain a first image group, wherein the type of clothing in each second image included in the first image group is the first target clothing type. For the second target clothing type, the matching model is used to process the at least one first image, the second target clothing type, and at least one second image in the first image group to obtain a second image group, wherein the type of clothing in each second image in the second image group is the second target clothing type.