Three-dimensional garment design drawing generation method, device and electronic equipment
By acquiring structured text information and utilizing a trained 3D clothing design drawing generation model, the problems of complex user interaction and poor natural language interaction effects were solved, achieving efficient and accurate 3D clothing design drawing generation, and improving user experience and the realism and professionalism of the design drawings.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHADOW EYE TECH SHANGHAI CO LTD
- Filing Date
- 2025-06-25
- Publication Date
- 2026-05-05
AI Technical Summary
Existing technologies for automatically generating 3D clothing design drawings suffer from complex user interactions and inconvenient operation, as well as poor interaction between natural language and design models, resulting in a poor user experience and limited applicability.
By acquiring structured text information as input, a 3D clothing design drawing generation model is used for predictive processing to generate 3D clothing design drawings that conform to the user's design intent. The model achieves efficient and accurate mapping between natural language and 3D clothing design drawings through training with a large number of 3D design drawing samples and corresponding text information.
It significantly improves the convenience and flexibility for users to express their design intentions, narrows the information gap between design intentions and generated results, and enhances the realism and professionalism of 3D clothing design drawings.
Smart Images

Figure CN120726232B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of clothing design technology, and in particular to a method, apparatus and electronic device for generating three-dimensional clothing design drawings. Background Technology
[0002] With the rapid development of digital design technology, the automatic generation of 3D clothing design drawings has become an important direction for the intelligentization of the apparel industry. Through computer-aided design, designers can realize their creative expression more efficiently, shorten the design cycle, and meet personalized needs.
[0003] In related technologies, image prediction techniques based on Convolutional Neural Networks (CNNs) are commonly used, combined with Principal Component Analysis (PCA) to simplify garment panel data, or differentiable simulation optimization techniques are employed to recover the material properties and pattern details of the garment. These methods improve the automation and refinement of the design to some extent, but they often rely on complex parameter settings and image processing workflows, lacking intuitive and diverse user interaction methods. This makes it difficult to meet the user's needs for convenience and flexibility in expressing design intent, resulting in a poor user experience and limited applicability. Furthermore, existing technologies have not yet achieved direct and efficient interaction with natural language, leading to an information gap between design intent and the generated results.
[0004] Therefore, in the automatic generation technology of 3D clothing design drawings, the complexity of user interaction, the inconvenience of operation, and the poor interaction effect between natural language and design model have become problems that urgently need to be solved. Summary of the Invention
[0005] This application provides a method, apparatus, and electronic device for generating three-dimensional clothing design drawings, in order to solve the problems of complex user interaction and inconvenient operation in existing automatic generation technologies for three-dimensional clothing design drawings, as well as poor interaction between natural language and design models.
[0006] In a first aspect, this application provides a method for generating three-dimensional clothing design drawings, the method comprising:
[0007] Obtain first text information, which describes the color information, style information, material information, and detail information of the desired first three-dimensional clothing design drawing; wherein, the detail information is used to indicate at least one of the patterns, collar type, sleeve type, skirt hem, and trouser hem related to the first three-dimensional clothing design drawing;
[0008] The first text information is predicted and processed based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing; wherein, the 3D clothing design drawing generation model is obtained by training a 3D clothing design drawing sample and the corresponding second text information, and the second text information is used to describe the color information, style information, material information and detail information of the 3D clothing design drawing sample.
[0009] In one possible design, the step of performing predictive processing on the first text information based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing includes:
[0010] The first text information is processed to obtain the first text guidance vector;
[0011] Based on the 3D clothing design drawing generation model, cross-attention processing is performed on the starting word and the first text guidance vector to obtain the target word sequence;
[0012] Based on the target word sequence, the first three-dimensional clothing design drawing is obtained and output.
[0013] In one possible design, the step of performing cross-attention processing on the starting lexical unit and the first text guidance vector to obtain the target lexical unit sequence includes:
[0014] The first word is obtained by performing cross-attention processing on the starting word and the first text guidance vector;
[0015] The starting word and the first word are concatenated to obtain the first word sequence;
[0016] Set the first word sequence as the starting word and repeat the above cross-attention processing steps until the ending word is obtained;
[0017] The target word sequence is obtained by concatenating the terminating word and the corresponding starting word.
[0018] In one possible design, the step of performing cross-attention processing on the starting lexical unit and the first text guidance vector to obtain the first lexical unit includes:
[0019] The starting word is processed by a position encoder, a parameter encoder, and a value encoder respectively to obtain the position latent vector, parameter latent vector, and value latent vector corresponding to the starting word; wherein, the position encoder, the parameter encoder, and the value encoder are trained using the three-dimensional clothing design sample; the position latent vector corresponding to the starting word is used to indicate the position of the starting word on the first three-dimensional clothing design; the parameter latent vector corresponding to the starting word is used to indicate the parameter type of the starting word; and the value latent vector corresponding to the starting word is used to indicate the numerical information corresponding to the starting word.
[0020] The starting word, along with the positional latent vector, parameter latent vector, and value latent vector corresponding to the starting word, are concatenated to obtain the second word sequence.
[0021] The second word sequence and the first text guidance vector are subjected to cross-attention processing to obtain the first word.
[0022] In one possible design, prior to acquiring the first text information, the method further includes:
[0023] Obtain a training sample set, which includes multiple training samples, wherein the training samples are the 3D clothing design drawing sample and the second text information corresponding to the 3D clothing design drawing sample;
[0024] Based on the multiple training samples, the initial 3D clothing design drawing generation model is trained to obtain the 3D clothing design drawing generation model.
[0025] In one possible design, training the initial 3D clothing design drawing generation model based on the multiple training samples to obtain the 3D clothing design drawing generation model includes:
[0026] For any training sample among the plurality of training samples, a second text guidance vector is obtained based on the second text information corresponding to the three-dimensional clothing design drawing sample;
[0027] Cross-attention processing is performed on the starting word and the second text guidance vector to obtain the third word sequence corresponding to the 3D clothing design sample;
[0028] The fourth word sequence corresponding to the three-dimensional clothing design sample is determined using preset rules;
[0029] A loss function is constructed based on the difference between the third word sequence and the fourth word sequence, and the initial 3D clothing design drawing generation model is updated based on the loss function to obtain the 3D clothing design drawing generation model.
[0030] In one possible design, determining the fourth word sequence corresponding to the 3D clothing design sample using preset rules includes:
[0031] The rotation quaternions and translation vectors corresponding to multiple polygonal panels corresponding to the 3D clothing design sample are determined, as well as the edge information and stitching information corresponding to multiple edges of each polygonal panel. The rotation quaternions indicate the rotation angle of the polygonal panel relative to the global coordinate system; the translation vectors indicate the position offset of the polygonal panel relative to the global coordinate system; the edge information indicates the start point, end point, and Bézier curve control point of the edge; and the stitching information indicates whether the edge is to be stitched and the position of the target edge to be stitched with.
[0032] The rotation quaternions and translation vectors corresponding to the multiple polygonal panels, as well as the edge information and stitching information corresponding to the multiple edges of each polygonal panel, are spliced together to obtain the fourth word sequence.
[0033] Secondly, this application provides a three-dimensional clothing design drawing generation device, comprising:
[0034] The acquisition module is used to acquire first text information, which describes the color information, style information, material information, and detail information of the desired first three-dimensional clothing design drawing; wherein, the detail information is used to indicate at least one of the patterns, collar type, sleeve type, skirt hem, and trouser hem related to the first three-dimensional clothing design drawing;
[0035] The output module is used to perform prediction processing on the first text information based on the three-dimensional clothing design drawing generation model to obtain and output the first three-dimensional clothing design drawing; wherein, the three-dimensional clothing design drawing generation model is obtained by training a three-dimensional clothing design drawing sample and the second text information corresponding to the three-dimensional clothing design drawing sample, and the second text information is used to describe the color information, style information, material information and detail information of the three-dimensional clothing design drawing sample.
[0036] Thirdly, this application provides an electronic device, including: a memory and at least one processor;
[0037] The memory stores computer-executed instructions;
[0038] The at least one processor executes computer execution instructions stored in the memory, causing the at least one processor to perform the method described in the first aspect or various possible designs of the first aspect.
[0039] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed, implement the method described in the first aspect or various possible designs of the first aspect.
[0040] Fifthly, this application provides a computer program product, which includes computer program code that, when run on a computer, causes the computer to implement the method described in the first aspect or various possible designs of the first aspect.
[0041] In a sixth aspect, this application provides a chip, comprising: an interface circuit and a logic circuit, wherein the interface circuit is configured to receive signals from other chips outside the chip and transmit them to the logic circuit, or to send signals from the logic circuit to other chips outside the chip, and the logic circuit is configured to implement the method described in the first aspect or various possible designs of the first aspect.
[0042] This application provides a method, apparatus, and electronic device for generating three-dimensional clothing design drawings. In this method, first text information is used as input to a three-dimensional clothing design drawing generation model. The first text information, written in natural language, describes the color, style, material, and detail information of the first three-dimensional clothing design drawing that the user expects. The three-dimensional clothing design drawing generation model then performs predictive processing on the first text information to obtain the corresponding first three-dimensional clothing design drawing, achieving efficient conversion from natural language to three-dimensional clothing design drawings. The three-dimensional clothing design drawing generation model uses text information expressed in natural language as input, significantly improving the convenience and flexibility for users to express their design intentions. Simultaneously, by accurately expressing the clothing color, style, material, and details using the first text information, the information gap between the design intention and the generated result is effectively narrowed, enhancing the realism and professionalism of the three-dimensional clothing design drawing. Attached Figure Description
[0043] Figure 1 A flowchart illustrating a method for generating three-dimensional clothing design drawings provided in this application embodiment;
[0044] Figure 2 A flowchart illustrating another method for generating three-dimensional clothing design drawings provided in this application embodiment;
[0045] Figure 3 A flowchart illustrating another method for generating three-dimensional clothing design drawings provided in this application embodiment;
[0046] Figure 4 A flowchart illustrating another method for generating three-dimensional clothing design drawings provided in this application embodiment;
[0047] Figure 5 This is a schematic diagram of the structure of a three-dimensional clothing design drawing generation device provided in an embodiment of this application;
[0048] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0049] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0050] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein in the specification of the application is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims and drawings of this application are intended to cover non-exclusive inclusion.
[0051] The term "embodiment" as used herein means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of the phrase "embodiment" in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0052] In this article, the term "and / or" simply describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can mean: A exists, A and B can exist simultaneously, and B exists. Additionally, the character " / " in this article generally indicates that the preceding and following related objects have an "or" relationship.
[0053] Furthermore, the terms "first," "second," etc., in the specification and claims of this application or in the aforementioned drawings are used to distinguish different objects rather than to describe a specific order, and may explicitly or implicitly include one or more of the features.
[0054] In the description of this application, unless otherwise stated, "multiple" and "at least two" mean two or more (including two), and similarly, "multiple groups" and "at least two groups" mean two or more (including two groups).
[0055] In the description of this application, it should be noted that, unless otherwise explicitly specified and limited, the terms "connected" and "linked" should be interpreted broadly. For example, "connected" or "linked" can refer not only to a physical connection, but also to an electrical connection or a signal connection. For instance, it can be a direct connection, i.e., a physical connection, or an indirect connection through at least one intermediate component, as long as the circuit is connected. It can also refer to the internal connection between two components. A signal connection can refer not only to a signal connection through a circuit, but also to a signal connection through a medium, such as radio waves. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.
[0056] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. It should be noted that, unless otherwise specified, different technical features in this application can be combined with each other.
[0057] First, the terms and concepts used in one or more embodiments of this specification will be explained.
[0058] A token is the smallest unit or basic element used to represent processed text in natural language processing. A token can be a single character or a sequence of multiple characters.
[0059] The following section introduces the implementation background of the technical solutions provided in the embodiments of this application.
[0060] With the rapid development of digital design technology, the automatic generation of 3D clothing design drawings has become an important direction for the intelligentization of the apparel industry. Through computer-aided design, designers can realize their creative expression more efficiently, shorten the design cycle, and meet personalized needs.
[0061] In related technologies, image prediction techniques based on Convolutional Neural Networks (CNNs) are commonly used, combined with Principal Component Analysis (PCA) to simplify garment panel data, or differentiable simulation optimization techniques are employed to recover the material properties and pattern details of the garment. These methods improve the automation and refinement of the design to some extent, but they often rely on complex parameter settings and image processing workflows, lacking intuitive and diverse user interaction methods. This makes it difficult to meet users' needs for convenience and flexibility in expressing design intent, resulting in a poor user experience and limited applicability. Furthermore, existing technologies have not yet achieved direct and efficient interaction with natural language, leading to an information gap between design intent and the generated results.
[0062] Therefore, in the automatic generation technology of 3D clothing design drawings, the complexity of user interaction, the inconvenience of operation, and the poor interaction effect between natural language and design model have become problems that urgently need to be solved.
[0063] Based on the problems existing in related technologies, this application provides a method for generating three-dimensional clothing design drawings. By obtaining structured text information describing the color, style, material and details of clothing as input conditions for a three-dimensional clothing design drawing generation model, the three-dimensional clothing design drawing generation model is used to predict and process the text information to generate a three-dimensional clothing design drawing that conforms to the user's design intent.
[0064] The structured text information in this application includes details related to 3D clothing design drawings, such as patterns, collar types, sleeve types, skirt hems, and trouser hems. This enhances the convenience and flexibility for users to express their design needs, effectively overcoming the shortcomings of traditional technologies that rely on complex parameter inputs and single interaction methods. Furthermore, the 3D clothing design drawing generation model is trained based on a large-scale sample of 3D design drawings and corresponding text information, enabling efficient and accurate mapping between natural language and 3D clothing design drawings, effectively narrowing the information gap between design intent and the generated result.
[0065] In summary, the 3D clothing design drawing generation method provided in this application improves the user-friendliness, interaction efficiency, and accuracy of design expression in the 3D clothing design drawing generation process through a text-driven generation mechanism and structured detail control. This effectively solves the technical problems that urgently need to be addressed in the background technology, such as the complexity of user interaction, inconvenience of operation, and low efficiency of natural language interaction.
[0066] Next, through some specific embodiments and accompanying drawings, we will describe in detail how this application solves the problems of complex user interaction and inconvenient operation in existing automatic generation technology of 3D clothing design drawings, as well as the poor interaction effect between natural language and design model.
[0067] Figure 1 This is a flowchart illustrating a method for generating three-dimensional clothing design drawings, provided as an embodiment of this application. Figure 1 As shown, the method for generating three-dimensional clothing design drawings provided in this application embodiment specifically includes S101 and S102, which will be described in detail below.
[0068] It should be noted that the execution subject of the three-dimensional clothing design drawing generation method provided in this application embodiment can be a controller in a terminal device, such as a mobile phone or a computer.
[0069] S101, Obtain the first text information.
[0070] The first text information is used to describe the color information, style information, material information, and detail information of the desired first three-dimensional clothing design drawing.
[0071] It should be noted that the first text information uses natural language to describe the key attributes of the first 3D clothing design drawing that the user expects to generate, including color information, style information, material information, and detail information.
[0072] Among them, color information is used to describe the main color tone, auxiliary colors and their distribution characteristics in the first three-dimensional clothing design drawing.
[0073] Specifically, color information supports hierarchical description, including different levels such as primary color, secondary color, and accent color, which facilitates the detailed breakdown of color distribution in different parts of the first 3D garment design drawing. The primary color is applied to the main body of the first 3D garment design drawing, the secondary color is used for decorative patterns in the first 3D garment design drawing, and the accent color is used for details such as buttons and zippers.
[0074] The style information is used to describe the overall style and structural features of the first three-dimensional clothing design drawing.
[0075] Specifically, style information includes at least one of the following: clothing category, clothing silhouette, and design style.
[0076] Clothing category is used to indicate the basic type of the first 3D clothing design drawing, such as dress, shirt, suit, jacket, trousers, etc., to ensure that the 3D clothing design drawing generation model can be generated with corresponding structural features and design styles for different clothing categories.
[0077] The garment silhouette is used to indicate the overall shape of the first three-dimensional garment design drawing, such as fitted, loose, straight, or voluminous.
[0078] The design style is used to indicate the style attributes of the first 3D clothing design drawing, such as casual, formal, sporty, retro, modern, etc., to provide style guidance for the generation model of the 3D clothing design drawing, and to assist in generating a first 3D clothing design drawing that conforms to a specific design style.
[0079] The material information describes the type of fabric and its physical properties used in the first three-dimensional clothing design drawing.
[0080] Specifically, material information includes at least one of the following: fabric category, physical properties, and texture characteristics.
[0081] Fabric category is used to indicate the fabric used in the first 3D clothing design drawing, such as cotton, silk, wool, denim, leather, lace, etc., to ensure that the 3D clothing design drawing generation model can generate the first 3D clothing design drawing with corresponding surface texture and shape representation according to different material characteristics.
[0082] Physical properties are used to indicate the physical characteristics of a fabric, such as softness, elasticity, thickness, breathability, and luster.
[0083] Texture features are used to indicate the texture details of the fabric surface, such as fine, rough, fuzzy, striped, and checkered patterns, so that the first 3D garment design drawing output by the 3D garment design drawing generation model can show a realistic visual effect.
[0084] The detailed information is used to indicate at least one of the patterns, collar type, sleeve type, skirt hem, and trouser hem related to the first three-dimensional garment design drawing.
[0085] It should be noted that the detailed information is used to refine and enrich the key design elements in the first three-dimensional clothing design drawing.
[0086] Patterns are used to indicate decorative graphics contained on the surface of the first three-dimensional garment design drawing, such as prints, embroidery, geometric patterns, stripes, polka dots, and flowers. The type, color, size, and arrangement of patterns can all be described through detailed information.
[0087] Collar type is used to indicate the shape and style of the neckline in the first three-dimensional garment design drawing, such as stand collar, turn-down collar, round neck, V-neck, boat neck, etc.
[0088] Sleeve type is used to indicate the shape and length of the sleeves in the first three-dimensional garment design drawing, such as sleeveless, short sleeve, three-quarter sleeve, long sleeve, lantern sleeve, puff sleeve, etc.
[0089] When the first 3D clothing design drawing is a skirt, the skirt hem is used to indicate the shape of the hem in the first 3D clothing design drawing, such as a straight skirt, umbrella skirt, fishtail skirt, A-line skirt, etc.
[0090] When the first three-dimensional clothing design drawing is of trousers, the trouser hem is used to indicate the design shape of the bottom of the trouser leg in the first three-dimensional clothing design drawing, such as skinny jeans, flared jeans, straight-leg jeans, tapered jeans, etc.
[0091] In this embodiment, the first text information input by the user describes in natural language the color, style, material, and detailed attributes of the first 3D clothing design drawing that the user expects. This facilitates the accurate capture of the user's design intent by the 3D clothing design drawing generation model, laying a solid foundation for the accurate generation of the subsequent first 3D clothing design drawing. The 3D clothing design drawing generation method of this application supports multi-dimensional and multi-level design requirement input, greatly improving the convenience and flexibility of user interaction and overcoming the limitations of traditional complex parameter input methods.
[0092] S102. Based on the three-dimensional clothing design drawing generation model, the first text information is predicted and processed to obtain and output the first three-dimensional clothing design drawing.
[0093] The 3D clothing design drawing generation model is obtained by training 3D clothing design drawing samples and the corresponding second text information.
[0094] It should be noted that the 3D clothing design drawing generation model is obtained by supervised learning of the initial 3D clothing design drawing generation model using a large number of 3D clothing design drawing samples and the corresponding second text information.
[0095] During the training process of the initial 3D clothing design drawing generation model, the initial 3D clothing design drawing generation model continuously learns the complex relationship between the second text information and the corresponding 3D clothing design drawing samples, and continuously optimizes the loss function to obtain the 3D clothing design drawing generation model.
[0096] The second text information is used to describe the color, style, material, and detail information of the 3D clothing design sample.
[0097] It should be noted that the method of using the second text information to describe the three-dimensional clothing design sample is similar to the method of using the first text information to describe the first three-dimensional clothing design, and will not be described again in this embodiment.
[0098] In this embodiment, the first text information is used as input to the 3D clothing design drawing generation model. The 3D clothing design drawing generation model performs efficient predictive processing on the first text information to obtain the first 3D clothing design drawing, achieving a precise mapping from text description to 3D clothing design drawing. This not only enhances the interaction efficiency between natural language and the 3D clothing design drawing generation model and narrows the information gap between design intent and generated results, but also meticulously reproduces the color, style, material, and details of the clothing, significantly improving the realism and professionalism of the first 3D clothing design drawing generated by the 3D clothing design drawing generation model, thereby meeting users' needs for high-quality, personalized 3D clothing design drawings.
[0099] It should be noted that the prediction process includes encoding the first text information, cross-attention processing of the starting token and the encoded first text information (first text guiding vector), and decoding of the target token sequence obtained by the cross-attention processing.
[0100] This application provides a method for generating 3D clothing design drawings. The method uses first text information as input to a 3D clothing design drawing generation model. This first text information, written in natural language, describes the color, style, material, and detail information of the first 3D clothing design drawing that the user expects. The 3D clothing design drawing generation model then performs predictive processing on the first text information to obtain the corresponding first 3D clothing design drawing, achieving efficient conversion from natural language to 3D clothing design drawings. The 3D clothing design drawing generation model uses text information expressed in natural language as input, significantly improving the convenience and flexibility for users to express their design intentions. Simultaneously, by accurately expressing the clothing's color, style, material, and details using the first text information, the information gap between the design intention and the generated result is effectively narrowed, enhancing the realism and professionalism of the 3D clothing design drawing.
[0101] In the above embodiments, the terminal device needs to perform predictive processing on the first text information based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing. Next, the specific process by which the terminal device performs predictive processing on the first text information based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing will be described in detail.
[0102] Figure 2 This is a flowchart illustrating another method for generating three-dimensional clothing design drawings provided in an embodiment of this application. Figure 2 As shown, in one possible embodiment, S102 can be implemented by S1021 to S1023, which will be described in detail below.
[0103] S1021. Process the first text information to obtain the first text guiding vector.
[0104] Among them, the first text guidance vector is the semantic representation of the first text information. The first text guidance vector can accurately reflect the semantic features of the color information, style information, material information and detail information of the first three-dimensional clothing design drawing that the user expects to obtain.
[0105] It should be noted that the terminal device can use a Contrastive Language-Image Pre-training (CLIP) model to encode the first text information to obtain the first text guidance vector.
[0106] Specifically, the method of encoding the first text information using the CLIP model to obtain the first text guiding vector is an existing method, and will not be described in detail in this embodiment.
[0107] In another embodiment, the terminal device can preprocess and encode the first text information input by the user through a natural language processing module to obtain a first text guidance vector.
[0108] Specifically, firstly, a tokenizer is used to split the first text information into multiple tokens; secondly, a pre-trained language model (such as BERT, GPT, etc.) is used to map each token to a shared high-dimensional embedding space; finally, a text encoder (Transformer encoding layer, recurrent neural network, etc.) is used to perform contextual modeling on the embedding vectors, fuse semantic information, and output the first text guidance vector.
[0109] In this embodiment, by preprocessing and encoding the first text information, a high-quality first text guidance vector is generated. This first text guidance vector accurately captures the multi-dimensional semantic information in the user's design intent, providing a precise semantic foundation for the subsequent generation of the first 3D clothing design drawing. Simultaneously, it effectively enhances the expressive power and semantic consistency of the text information, strengthens the correlation between natural language and the 3D clothing design drawing generation model, and significantly improves the 3D clothing design drawing generation model's understanding depth and response accuracy to design requirements, thereby ensuring the accuracy and personalization of the generated first 3D clothing design drawing.
[0110] S1022. Based on the 3D clothing design drawing generation model, cross-attention processing is performed on the starting token and the first text guidance vector to obtain the target token sequence.
[0111] The starting token is a fixed starting symbol.
[0112] It should be noted that the terminal device inputs the starting token and the first text guidance vector into the cross-attention layer in the Transformer architecture. The cross-attention layer calculates the attention weight between the starting token and the first text guidance vector, focuses on the key semantic features in the first text guidance vector, and gradually generates a target token sequence that conforms to the semantics of the first text guidance vector.
[0113] The target token sequence refers to a set of encoded sequences generated step-by-step through a cross-attention mechanism, combining the initial token and the first text guidance vector. The target token sequence is used to construct the first 3D clothing design.
[0114] It should be noted that the target token sequence, in units of tokens, encodes the construction instructions or feature representations in the process of generating the first 3D clothing design drawing. By generating the target token sequence, it is possible to achieve an effective mapping from natural language descriptions to 3D clothing design drawings, promote the deep integration of textual semantic information and 3D model features, and lay the foundation for achieving accurate and high-quality generation of the first 3D clothing design drawing.
[0115] In this embodiment, cross-attention processing is used to effectively guide and constrain the generation process of the first 3D clothing design drawing by the first text guidance vector. This ensures that the generated first 3D clothing design drawing accurately matches the user's needs in terms of color, style, material, and details, improves the collaborative efficiency between the first text information and the 3D clothing design drawing generation model, and significantly reduces the gap between the design intent and the generated result. This, in turn, improves the generation quality and expressiveness of the first 3D clothing design drawing generated by the 3D clothing design drawing generation model.
[0116] S1023. Based on the target token sequence, obtain and output the first three-dimensional clothing design drawing.
[0117] After obtaining the target token sequence, the terminal device inputs the target token sequence into the decoding module, which then converts the target token sequence into a specific representation of the first three-dimensional clothing design drawing.
[0118] Specifically, the decoding module can use convolutional networks, graph neural networks, or voxel-based and point cloud-based 3D reconstruction algorithms to gradually restore the spatial structure, color distribution, material texture, and detailed form of the first 3D clothing design drawing, and finally generate a first 3D clothing design drawing that is highly consistent with the description of the first text information.
[0119] This embodiment achieves accurate conversion from semantic sequence to first three-dimensional clothing design drawing. The generated first three-dimensional clothing design drawing not only meets the various design requirements described by the first text information, but also has good visual performance and practicality, significantly improving the efficiency and quality of three-dimensional clothing design drawing generation.
[0120] In this embodiment, the first text information is efficiently encoded to obtain a first text guidance vector. A cross-attention mechanism is then used to achieve deep fusion between the first text guidance vector and the 3D clothing design drawing generation model, thereby generating a target token sequence for constructing the first 3D clothing design drawing. Finally, the 3D clothing design drawing is accurately reconstructed based on the target token sequence. This significantly improves the ability of natural language to guide the 3D clothing design drawing generation process and effectively solves the problems of poor interaction between natural language and design model, as well as mismatch between design intent and generation result in the prior art.
[0121] In the above embodiments, the terminal device needs to perform cross-attention processing on the starting token and the first text guidance vector to obtain the target token sequence. Next, the specific process by which the terminal device performs cross-attention processing on the starting token and the first text guidance vector to obtain the target token sequence will be described in detail.
[0122] In one possible embodiment, S1022 can be implemented by Sa1 to Sa4, which are described in detail below.
[0123] Sa1. Perform cross-attention processing on the starting token and the first text guidance vector to obtain the first token.
[0124] The terminal device inputs the preset start token and the first text guidance vector into the cross-attention layer. The cross-attention layer uses the start token as the query and the first text guidance vector as the key and value, calculates the attention weight, and thus focuses on the key information in the first text guidance vector to generate a first token that is semantically related to the first text guidance vector.
[0125] The first token is the initial generation result of the target token sequence, reflecting the first step response to the first text guiding vector.
[0126] This embodiment effectively initiates the guiding role of the first text guiding vector in the generation of the target token sequence through this step, enabling the 3D clothing design drawing generation model to accurately guide the generation of subsequent tokens based on the semantic features of the first text guiding vector, ensuring the semantic coherence and accuracy of the generated target token sequence.
[0127] Sa2. Concatenate the starting token and the first token to obtain the first token sequence.
[0128] The preset starting token and the first token are concatenated along the sequence dimension to form a first token sequence of length 2. This first token sequence serves as the initial context for generating the target token sequence, providing input for the next step of cross-attention processing.
[0129] Sa3. Set the first token sequence as the starting token and repeat the above cross-attention processing steps until the ending token is obtained.
[0130] In this process, after the terminal device sets the first token sequence as the starting token, it repeats the method steps shown in Sa1 above until a termination token appears.
[0131] It should be noted that the terminal device uses the first token sequence as the new starting token, and inputs the new starting token and the first text guidance vector into the cross-attention layer. The cross-attention layer performs cross-attention processing on the new starting token and the first text guidance vector to obtain the new first token.
[0132] The cross-attention layer performs cross-attention processing on the new starting token and the first text guidance vector to obtain the new first token. The specific process is similar to the specific process of obtaining the first token in Sa1 above, and will not be described again in this embodiment.
[0133] The termination token is a fixed termination symbol. It is used to mark the end of the generation of the target token sequence.
[0134] In this embodiment, the 3D clothing design drawing generation model can dynamically capture the relationship between the semantics of the first text guidance vector and the generated content through recursive cross-attention processing, thereby achieving gradual refinement and expression of complex design information and ensuring that the final generated token sequence is complete and semantically rich.
[0135] Sa4. Concatenate the termination token and the corresponding starting token to obtain the target token sequence.
[0136] After generating the termination token, the system concatenates the termination token with the corresponding starting token along the sequence dimension to form a complete target token sequence. The target token sequence contains all tokens generated from the starting token to the termination token.
[0137] For example, the first text input by the user is: "Design a red dress with lace trim and puff sleeves." The starting token is " <start>The termination token is " <end>".
[0138] First, the cross-attention layer uses " <start>"As a query, combining the first text guidance vector obtained by encoding the first text information, an attention weight is calculated, focusing on the key information in the first text guidance vector that has the semantics of "red", "dress", "lace trim", and "puff sleeves", generating the first token, which is "dress", and then..." <start>The first token sequence is formed by concatenating " and "dress". <start>dress.
[0139] Secondly, the first token sequence " <start>"dress" is used as the new starting token. Combined with the first text guiding vector, cross-attention processing is performed to generate the next token, "red". These tokens are then concatenated to form the next token sequence, which is "". <start>"dress red"; then, the next token sequence " <start>Using "dress red" as the new starting token, repeat the above steps multiple times until the generated token is "dress red". <end>"; where, in the token sequence" <start>If "dress red lace puff sleeves" is used as the new starting token, the generated token will be " <end>".
[0140] Finally, the token sequence " <start>"dress red lace puff sleeves" and "terminal token" <end>"By concatenating these sequences, we can obtain the target token sequence, which is..." <start>dress red lace puffsleeves <end>".
[0141] In this embodiment, by recursively inputting the starting token and the first text guidance vector into a cross-attention layer, a complete target token sequence is gradually generated, achieving efficient conversion from natural language to instructions for generating 3D clothing design drawings. This helps ensure the semantic coherence and accuracy of the generated target token sequence, enhances the guiding ability of text information in the 3D clothing design drawing generation process, effectively solves the problem of mismatch between design intent and generated results in existing technologies, and significantly improves the generation quality and user satisfaction of 3D clothing design drawings.
[0142] In the above embodiments, the terminal device needs to perform cross-attention processing on the starting token and the first text guidance vector to obtain the first token. Next, the specific process by which the terminal device performs cross-attention processing on the starting token and the first text guidance vector to obtain the first token will be described in detail.
[0143] In one possible embodiment, Sa1 can be implemented by Sa11 to Sa13, which are described in detail below.
[0144] Sa11 processes the starting token using the position encoder, parameter encoder, and value encoder respectively, to obtain the position latent vector, parameter latent vector, and value latent vector corresponding to the starting token.
[0145] It should be noted that by processing the starting token with a position encoder, the position latent vector corresponding to the starting token can be obtained; by processing the starting token with a parameter encoder, the parameter latent vector corresponding to the starting token can be obtained; and by processing the starting token with a value encoder, the value latent vector corresponding to the starting token can be obtained.
[0146] Among them, the position encoder, parameter encoder, and value encoder are obtained by training through 3D clothing design drawings.
[0147] It's important to note that the training of the position encoder involves understanding and representing the positions of different parts of a 3D garment design sample. This includes the positional relationships and relative positions of different parts of the 3D garment design (such as the neckline, cuffs, and hem) in 3D space. The position encoder learns from the 3D garment design sample how to transform the features of different spatial positions into a latent position vector. This latent position vector is used to accurately indicate the spatial position of each part of the 3D garment design during the subsequent generation of the 3D garment design.
[0148] The training of the parametric encoder involves understanding and representing parameters related to 3D clothing design samples, such as attributes like color, material, and style. Using design information from the 3D clothing design samples, the parametric encoder learns how to transform the color, material, and style attributes of the 3D clothing design samples into parametric latent vectors. These latent vectors are used to accurately indicate the parametric information of each part of the 3D clothing design sample during subsequent generation.
[0149] The training of a value encoder involves understanding and representing numerical values associated with 3D clothing design samples, such as dimensions, proportions, and angles. Using specific numerical data from the 3D clothing design samples, the value encoder can generate corresponding latent value vectors. For example, the value encoder learns how to convert numerical information such as "shoulder width: 40cm" and "waist circumference: 70cm" into a format that a computer can understand.
[0150] The latent vector corresponding to the starting token is used to indicate the position of the starting token on the first 3D clothing design drawing.
[0151] It should be noted that the position latent vector is a high-dimensional vector. The position latent vector of the starting token represents the spatial position information of the starting token in the 3D clothing design drawing. Each starting token generates a corresponding position latent vector based on its positional characteristics in the 3D clothing design drawing.
[0152] The positional characteristics of the starting token in a 3D clothing design drawing include spatial coordinates and relative positional relationships. By determining the latent position vector corresponding to the starting token, the 3D clothing design drawing generation model can accurately place the various parts of the first 3D clothing design drawing during the generation process, ensuring that the spatial layout of each design element is consistent with the user's requirements.
[0153] The implicit parameter vector corresponding to the starting token is used to indicate the parameter type of the starting token.
[0154] It should be noted that the parameter latent vector is also a high-dimensional vector. The parameter latent vector of the starting token represents the design information of the starting token, including its color, style, material, and details. By determining the parameter latent vector corresponding to the starting token, the 3D clothing design drawing generation model can accurately understand the design requirements and attributes of each part in the first 3D clothing design drawing during the generation process, ensuring that the subsequently generated first 3D clothing design drawing can correctly express the user's design intent.
[0155] The implicit vector corresponding to the starting token is used to indicate the numerical information corresponding to the starting token.
[0156] It should be noted that the value latent vector of the starting token represents the numerical information associated with the starting token. Unlike the parameter latent vector, the value latent vector directly corresponds to the specific numerical values in the 3D clothing design drawing. The value latent vector can include at least one of the numerically related information such as size information, proportion information, and angle information.
[0157] For example, implicit value vectors can include size information, such as "shoulder width: 40cm" and "trouser length: 100cm". Implicit value vectors can also include proportion information, such as "chest to waist ratio". Implicit value vectors can also include angle information, such as whether the sleeves of certain designs are at a specific angle (45-degree cuff).
[0158] By determining the latent vector corresponding to the starting token, the 3D clothing design drawing generation model can generate 3D clothing design drawings that meet actual wearing requirements based on specific size, proportion, or angle requirements.
[0159] Sa12. Concatenate the starting token, along with its corresponding position latent vector, parameter latent vector, and value latent vector, to obtain the second token sequence.
[0160] The terminal device concatenates the starting token and its corresponding latent position vector, parameter latent vector, and value latent vector to form a second token sequence. The second token sequence integrates the position information, parameter information, and value information of the starting token, enabling the 3D clothing design drawing generation model to simultaneously refer to the position information, parameter information, and value information of the starting token when generating the first token, ensuring that the subsequently generated first 3D clothing design drawing better matches the user's design intent.
[0161] Sa13. Perform cross-attention processing on the second token sequence and the first text guidance vector to obtain the first token.
[0162] It should be noted that the method of performing cross-attention processing on the second token sequence and the first text guiding vector to obtain the first token is similar to the method of performing cross-attention processing on the starting token and the first text guiding vector to obtain the first token in the steps of the method shown in Sa1 above. This embodiment will not repeat the details.
[0163] In this embodiment, by performing cross-attention processing on the starting token and the first text guidance vector, and combining the positional encoder, parameter encoder, and value encoder to generate the positional latent vector, parameter latent vector, and value latent vector based on the starting token, the spatial position, attribute information, and numerical information of each starting token are accurately encoded and fused. This effectively enhances the ability of the 3D clothing design drawing generation model to control the position, attributes, and details of each part in the 3D clothing design drawing, ensuring that the generated target token sequence can accurately reflect the user's design intent.
[0164] In the above embodiments, the terminal device needs to perform predictive processing on the first text information based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing. Next, the specific process of obtaining the 3D clothing design drawing generation model will be described in detail.
[0165] Figure 3 This is a flowchart illustrating another method for generating three-dimensional clothing design drawings provided in an embodiment of this application. Figure 3 As shown, in one possible embodiment, before the method step shown in S101, the three-dimensional clothing design drawing generation method further includes S301 and S302, which are described in detail below.
[0166] S301. Obtain the training sample set.
[0167] The training sample set includes multiple training samples, which are 3D clothing design drawings and the corresponding second text information.
[0168] It should be noted that the second text information corresponding to each 3D clothing design sample is a descriptive text for that sample. This second text information describes the color, style, material, and detail information of the corresponding 3D clothing design sample.
[0169] The second text information can be manually entered by the designer in advance, or it can be extracted through image recognition technology. This embodiment does not make specific limitations on this.
[0170] S302. Based on multiple training samples, train the initial 3D clothing design drawing generation model to obtain the 3D clothing design drawing generation model.
[0171] The initial 3D clothing design generation model is a pre-defined model structure, possibly based on neural networks, generative adversarial networks, or other deep learning models. This initial model needs to be gradually optimized through training to enable it to generate 3D clothing designs that meet the requirements of the input text information.
[0172] During the training process of the initial 3D clothing design drawing generation model, the initial 3D clothing design drawing generation model receives multiple training samples and adjusts the parameters through algorithms (such as backpropagation, gradient descent, etc.) so that the output of the initial 3D clothing design drawing generation model gradually approaches the 3D clothing design drawing indicated by the training samples, thereby obtaining the 3D clothing design drawing generation model.
[0173] In this embodiment, a rich and diverse training sample set is constructed by acquiring a large number of high-quality 3D clothing design drawings and the corresponding second text information for each 3D clothing design drawing sample. This provides sufficient data support for training the initial 3D clothing design drawing generation model, thereby obtaining the 3D clothing design drawing generation model. When the 3D clothing design drawing generation model receives new natural language descriptive text information, it can quickly and accurately generate high-quality 3D clothing design drawings.
[0174] In the above embodiments, the terminal device needs to train the initial 3D clothing design drawing generation model based on multiple training samples to obtain the 3D clothing design drawing generation model. Next, the specific process of the terminal device training the initial 3D clothing design drawing generation model based on multiple training samples to obtain the 3D clothing design drawing generation model will be described in detail.
[0175] Figure 4 This is a flowchart illustrating another method for generating three-dimensional clothing design drawings provided in this application embodiment. Figure 4 As shown, in one possible embodiment, the method steps shown in S302 can be implemented by S3021 to S3024, which are described in detail below.
[0176] S3021. For any training sample among multiple training samples, obtain the second text guidance vector based on the second text information corresponding to the 3D clothing design drawing sample.
[0177] The method for obtaining the second text guidance vector based on the second text information corresponding to the three-dimensional clothing design drawing sample for any training sample is similar to the method for processing the first text information to obtain the first text guidance vector in S1021 above, and will not be described again in this embodiment.
[0178] S3022. Perform cross-attention processing on the initial token and the second text guidance vector to obtain the third token sequence corresponding to the 3D clothing design sample.
[0179] In this embodiment, the terminal device performs cross-attention processing on the starting token and the second text guidance vector to obtain the third token sequence corresponding to the 3D clothing design sample. This is similar to the method in S1022 above, which performs cross-attention processing on the starting token and the first text guidance vector to obtain the target token sequence. This embodiment will not repeat the details.
[0180] S3023. Use preset rules to determine the fourth token sequence corresponding to the 3D clothing design sample.
[0181] The preset rules can be standard templates for clothing design, standardized expressions of design drawings, etc., and this embodiment does not make specific limitations on them.
[0182] It should be noted that by determining the fourth token sequence corresponding to the 3D clothing design sample through preset rules, a standardized and unified reference label can be provided for each 3D clothing design sample. This simplifies the sample labeling process in the initial 3D clothing design generation model training process, ensures the consistency between the samples learned by the initial 3D clothing design generation model and the actual application, and makes the subsequently obtained 3D clothing design generation model more reliable.
[0183] S3024. Construct a loss function based on the difference between the third token sequence and the fourth token sequence, and update the initial 3D clothing design drawing generation model based on the loss function to obtain the 3D clothing design drawing generation model.
[0184] For the same 3D clothing design sample, the third token sequence corresponding to the 3D clothing design sample is obtained by the initial 3D clothing design sample generation model through a cross-attention mechanism. The third token sequence is related to the second text guidance vector corresponding to the 3D clothing design sample. The fourth token sequence corresponding to the 3D clothing design sample is a token sequence obtained by processing the 3D clothing design sample through preset rules. The fourth token sequence represents the standard output of the 3D clothing design sample.
[0185] The loss function is used to quantify the difference between the third and fourth token sequences. By minimizing the loss function, the initial 3D clothing design generation model can be continuously optimized, making the 3D clothing design output by the initial 3D clothing design generation model closer to the 3D clothing design sample.
[0186] In this embodiment, the difference between the third and fourth token sequences is calculated, and a loss function is constructed based on this difference to continuously optimize the parameters of the initial 3D clothing design drawing generation model, thereby obtaining the 3D clothing design drawing generation model. This 3D clothing design drawing generation model can accurately extract design elements from text information described in natural language and generate high-quality 3D clothing design drawings that conform to the user's design intent, effectively solving the problem of mismatch between generated results and design intent in existing technologies.
[0187] In the above embodiments, the terminal device needs to determine the fourth token sequence corresponding to the 3D clothing design sample using preset rules. The specific process of the terminal device determining the fourth token sequence corresponding to the 3D clothing design sample using preset rules will be described in detail below.
[0188] In one possible embodiment, the method steps shown in S3023 can be implemented by Sc1 and Sc2, which are described in detail below.
[0189] Sc1. Determine the rotation quaternions and translation vectors corresponding to the multiple polygon panels of the 3D clothing design sample, as well as the edge information and stitching information corresponding to the multiple edges of each polygon panel.
[0190] It should be noted that, in order to facilitate the processing of 3D clothing design samples in a computer, 3D clothing design samples are usually divided into multiple two-dimensional polygonal panels (such as hexagons, quadrilaterals, triangles, etc.). Each polygonal panel represents a component of the 3D clothing design sample, and multiple polygonal panels can be connected to form a complete 3D clothing design sample.
[0191] For example, a 3D clothing design sample might be a dress, which can be divided into multiple parts, such as the skirt body, hem, and waistband. Each part can be represented by at least one polygon panel. Each polygon panel can be an unfolded view of a certain part of the dress, depicting the flat pattern of the dress fabric, its dimensions, shape, etc.
[0192] The rotation quaternion is used to indicate the rotation angle of the polygon panel relative to the global coordinate system.
[0193] It should be noted that a global coordinate system is a coordinate system used to describe the position of an object or point in space. The global coordinate system provides a fixed and uniform spatial positioning standard for all objects, and regardless of how an object rotates or translates, its spatial position can be accurately determined using the global coordinate system.
[0194] The translation vector is used to indicate the position offset of the polygon panel relative to the global coordinate system.
[0195] Among them, edge information is used to indicate the start and end points of the edges and the control points of the Bézier curve.
[0196] It should be noted that Bézier curve control points are used to describe the curve shape of the edge.
[0197] Based on the start and end points of each edge, as well as the control points of the Bézier curve for each edge, the position of each edge in space can be precisely determined.
[0198] The stitching information indicates whether the edges are to be stitched, and the location of the target edge to be stitched with.
[0199] It should be noted that each polygonal panel has its own corresponding identification information to facilitate accurate identification and positioning. This identification information includes, but is not limited to, the panel's type, size, and design attributes. This identification information allows for the differentiation of different types of polygonal panels.
[0200] In addition, each edge of each polygon panel also has its corresponding identification information. The identification information for each edge includes the coordinates of the start and end points of the edge, as well as the coordinates of the Bézier curve control points of the edge. The identification information of each edge can accurately express the edge information and stitching information of each edge.
[0201] Sc2. The rotation quaternions and translation vectors corresponding to multiple polygon panels, as well as the edge information and stitching information corresponding to multiple edges of each polygon panel, are concatenated to obtain the fourth token sequence.
[0202] It should be noted that the fourth token sequence links together the geometry, structure, and stitching information of all polygonal panels to form a comprehensive representation containing all necessary design features.
[0203] In this embodiment, a fourth token sequence is obtained by splicing the rotation quaternions, translation vectors, edge information and stitching information corresponding to all polygonal panels. The fourth token sequence centrally represents the geometric information, structural information and stitching information of all polygonal panels, providing a comprehensive description of the three-dimensional clothing design sample.
[0204] Figure 5 This is a schematic diagram of a three-dimensional clothing design drawing generation device provided in an embodiment of this application. Figure 5 As shown, the three-dimensional clothing design drawing generation device provided in this embodiment includes an acquisition module 501 and an output module 502.
[0205] The acquisition module 501 is used to acquire first text information, which describes the color information, style information, material information and detail information of the desired first three-dimensional clothing design drawing; wherein the detail information is used to indicate at least one of the patterns, collar type, sleeve type, skirt hem and trouser hem related to the first three-dimensional clothing design drawing.
[0206] The output module 502 is used to perform prediction processing on the first text information based on the three-dimensional clothing design drawing generation model to obtain and output the first three-dimensional clothing design drawing; wherein, the three-dimensional clothing design drawing generation model is obtained by training a three-dimensional clothing design drawing sample and the second text information corresponding to the three-dimensional clothing design drawing sample, and the second text information is used to describe the color information, style information, material information and detail information of the three-dimensional clothing design drawing sample.
[0207] It should be understood that the corresponding processes performed by each module have been described in detail in the above method embodiments, and will not be repeated here for the sake of brevity.
[0208] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 6 As shown, the electronic device 600 provided in this embodiment includes a memory 601 and a processor 602.
[0209] The memory 601 can be a separate physical unit, connected to the processor 602 via a bus 603. Alternatively, the memory 601 and processor 602 can be integrated and implemented in hardware. The memory 601 stores program instructions, which the processor 602 calls to execute the operations performed by the terminal device in any of the above method embodiments.
[0210] Optionally, when some or all of the methods in the above embodiments are implemented by software, the electronic device 600 may also include only the processor 602. A memory 601 for storing programs is located outside the electronic device 600, and the processor 602 is connected to the memory via circuitry / wires to read and execute the programs stored in the memory. The processor 602 may be a central processing unit (CPU), a network processor (NP), or a combination of a CPU and an NP. The processor 602 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof. The PLD may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL), or any combination thereof.
[0211] The memory 601 may include volatile memory, such as random-access memory (RAM); the memory may also include non-volatile memory, such as flash memory, hard disk drive (HDD), or solid-state drive (SSD); the memory may also include combinations of the above types of memory.
[0212] For example, this application provides a chip including: an interface circuit and a logic circuit. The interface circuit is used to receive signals from other chips outside the chip and transmit them to the logic circuit, or to send signals from the logic circuit to other chips outside the chip. The logic circuit is used to perform the operations performed by the terminal device in the above method embodiments.
[0213] For example, this application provides a computer-readable storage medium storing computer program instructions thereon, which are executed by the processor of an electronic device to cause the electronic device to perform the operations performed by the terminal device in the above method embodiments.
[0214] For example, this application provides a computer program product that, when run on an electronic device, causes the electronic device to perform the operations performed by the terminal device in the above method embodiments.
[0215] The above description is merely a specific embodiment of this application, enabling those skilled in the art to understand or implement this application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of this application. Therefore, this application is not to be limited to the embodiments described herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.< / end> < / start> < / end> < / start> < / end> < / start> < / end> < / start> < / start> < / start> < / start> < / start> < / start> < / end> < / start>
Claims
1. A method for generating three-dimensional clothing design drawings, characterized in that, The method includes: Obtain a training sample set, which includes multiple training samples, wherein the training samples are the 3D clothing design drawing sample and the second text information corresponding to the 3D clothing design drawing sample; Based on the multiple training samples, the initial 3D clothing design drawing generation model is trained to obtain the 3D clothing design drawing generation model. Obtain first text information, which describes the color information, style information, material information, and detail information of the desired first three-dimensional clothing design drawing; wherein, the detail information is used to indicate at least one of the patterns, collar type, sleeve type, skirt hem, and trouser hem related to the first three-dimensional clothing design drawing; The first text information is predicted and processed based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing; wherein, the second text information is used to describe the color information, style information, material information and detail information of the 3D clothing design drawing sample; The process of training the initial 3D clothing design drawing generation model based on the multiple training samples to obtain the 3D clothing design drawing generation model includes: For any training sample among the plurality of training samples, a second text guidance vector is obtained based on the second text information corresponding to the three-dimensional clothing design drawing sample; Cross-attention processing is performed on the starting word and the second text guidance vector to obtain the third word sequence corresponding to the 3D clothing design sample; The fourth word sequence corresponding to the three-dimensional clothing design sample is determined using preset rules; A loss function is constructed based on the difference between the third word sequence and the fourth word sequence, and the initial 3D clothing design drawing generation model is updated based on the loss function to obtain the 3D clothing design drawing generation model. The step of determining the fourth word sequence corresponding to the 3D clothing design sample using preset rules includes: The rotation quaternions and translation vectors corresponding to multiple polygonal panels corresponding to the 3D clothing design sample are determined, as well as the edge information and stitching information corresponding to multiple edges of each polygonal panel. The rotation quaternions indicate the rotation angle of the polygonal panel relative to the global coordinate system; the translation vectors indicate the position offset of the polygonal panel relative to the global coordinate system; the edge information indicates the start point, end point, and Bézier curve control point of the edge; and the stitching information indicates whether the edge is to be stitched and the position of the target edge to be stitched with. The rotation quaternions and translation vectors corresponding to the multiple polygonal panels, as well as the edge information and stitching information corresponding to the multiple edges of each polygonal panel, are spliced together to obtain the fourth word sequence.
2. The method according to claim 1, characterized in that, The method of predicting and processing the first text information based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing includes: The first text information is processed to obtain the first text guidance vector; Based on the 3D clothing design drawing generation model, cross-attention processing is performed on the starting word and the first text guidance vector to obtain the target word sequence; Based on the target word sequence, the first three-dimensional clothing design drawing is obtained and output.
3. The method according to claim 2, characterized in that, The step of performing cross-attention processing on the starting lexical unit and the first text guidance vector to obtain the target lexical unit sequence includes: The first word is obtained by performing cross-attention processing on the starting word and the first text guidance vector; The starting word and the first word are concatenated to obtain the first word sequence; Set the first word sequence as the starting word and repeat the above cross-attention processing steps until the ending word is obtained; The target word sequence is obtained by concatenating the terminating word and the corresponding starting word.
4. The method according to claim 3, characterized in that, The step of performing cross-attention processing on the starting lexical unit and the first text guidance vector to obtain the first lexical unit includes: The starting word is processed by a position encoder, a parameter encoder, and a value encoder respectively to obtain the position latent vector, parameter latent vector, and value latent vector corresponding to the starting word; wherein, the position encoder, the parameter encoder, and the value encoder are trained using the three-dimensional clothing design sample; the position latent vector corresponding to the starting word is used to indicate the position of the starting word on the first three-dimensional clothing design; the parameter latent vector corresponding to the starting word is used to indicate the parameter type of the starting word; and the value latent vector corresponding to the starting word is used to indicate the numerical information corresponding to the starting word. The starting word, along with the positional latent vector, parameter latent vector, and value latent vector corresponding to the starting word, are concatenated to obtain the second word sequence. The second word sequence and the first text guidance vector are subjected to cross-attention processing to obtain the first word.
5. A three-dimensional clothing design drawing generation device, characterized in that, The device includes: The acquisition module is used to acquire a training sample set, which includes multiple training samples, and the training samples are the three-dimensional clothing design drawing sample and the second text information corresponding to the three-dimensional clothing design drawing sample; The training module is used to train the initial 3D clothing design drawing generation model based on the multiple training samples to obtain the 3D clothing design drawing generation model. The acquisition module is further configured to acquire first text information, which describes the color information, style information, material information, and detail information of the desired first three-dimensional clothing design drawing; wherein the detail information indicates at least one of the patterns, collar type, sleeve type, skirt hem, and trouser hem related to the first three-dimensional clothing design drawing. The output module is used to perform prediction processing on the first text information based on the 3D clothing design drawing generation model to obtain and output the first 3D clothing design drawing; wherein, the 3D clothing design drawing generation model is obtained by training a 3D clothing design drawing sample and the second text information corresponding to the 3D clothing design drawing sample, and the second text information is used to describe the color information, style information, material information and detail information of the 3D clothing design drawing sample; The training module is specifically used to: for any training sample among the plurality of training samples, obtain a second text guidance vector based on the second text information corresponding to the three-dimensional clothing design sample; Cross-attention processing is performed on the starting word and the second text guidance vector to obtain the third word sequence corresponding to the 3D clothing design sample; The fourth word sequence corresponding to the three-dimensional clothing design sample is determined using preset rules; A loss function is constructed based on the difference between the third word sequence and the fourth word sequence, and the initial 3D clothing design drawing generation model is updated based on the loss function to obtain the 3D clothing design drawing generation model. The step of determining the fourth word sequence corresponding to the 3D clothing design sample using preset rules includes: The rotation quaternions and translation vectors corresponding to multiple polygonal panels corresponding to the 3D clothing design sample are determined, as well as the edge information and stitching information corresponding to multiple edges of each polygonal panel. The rotation quaternions indicate the rotation angle of the polygonal panel relative to the global coordinate system; the translation vectors indicate the position offset of the polygonal panel relative to the global coordinate system; the edge information indicates the start point, end point, and Bézier curve control point of the edge; and the stitching information indicates whether the edge is to be stitched and the position of the target edge to be stitched with. The rotation quaternions and translation vectors corresponding to the multiple polygonal panels, as well as the edge information and stitching information corresponding to the multiple edges of each polygonal panel, are spliced together to obtain the fourth word sequence.
6. An electronic device, characterized in that, include: Memory and at least one processor; The memory stores computer-executed instructions; The at least one processor executes computer execution instructions stored in the memory, causing the at least one processor to perform the method as described in any one of claims 1 to 4.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions that, when executed, implement the method as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Image processing method based on cross attention and related equipment thereof
CN118918222A
Text-driven garment template intelligent generation method
CN120197247A