Method and device for generating model chart through mannequin chart

By detecting and repairing the skeleton diagram of the human table map, the model picture generation problem caused by incomplete human table maps is solved, and high-quality and stable model picture is generated.

CN120070627APending Publication Date: 2025-05-30ZIXUN TECHNOLOGY (FUJIAN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510108331.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-23
Publication Date
2025-05-30

AI Technical Summary

Technical Problem

In the prior art, when generating model pictures of human-stage models, the incomplete human-stage images uploaded by users cannot be effectively processed, resulting in abnormal postures or incomplete limbs of the generated model pictures.

Method used

By detecting the skeleton diagram of the human table diagram, we can determine whether there is an abnormality. If it exists, repair it. Then, use the repaired skeleton diagram and human table diagram to input the Stable Diffusion algorithm to generate a model diagram.

Benefits of technology

The quality and stability of the generated model pictures are improved, ensuring that the generated model pictures are normal and the body is complete, and meeting the user's usage needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120070627A_ABST
    Figure CN120070627A_ABST
Patent Text Reader

Abstract

The invention provides a method and device for generating a model chart through a mannequin chart, and the method comprises the steps: detecting and obtaining a skeleton chart of an uploaded mannequin chart, and enabling the skeleton chart to comprise human skeleton key point information; judging whether the mannequin chart is abnormal or not according to the key point information of the human skeleton, and if not, directly generating the mannequin chart; if abnormity exists, repairing the skeleton diagram, and inputting the mannequin diagram and the skeleton diagram into a Stable Diffusion algorithm to generate a model diagram; the quality of the generated mannequin model chart is improved, and the use of subsequent users is met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and particularly to a method and device for generating model pictures through mannequin pictures. Background Art

[0002] The current mannequin model picture generation scheme mainly relies on the generation ability of the text-image large model to convert the mannequin picture uploaded by the user into a model picture. In this process, the key step is to extract the skeleton key point information of the mannequin. The skeleton key point information is crucial for controlling the posture and body integrity of the generated model. Therefore, it is necessary to perform posture inspection and repair on the extracted skeleton key point information to ensure that the generated model picture is both natural and complete.

[0003] However, this method has obvious defects: if the mannequin picture uploaded by the user is incomplete, such as a mannequin picture missing a head or an arm, then the extracted skeleton key point information will also be incomplete accordingly. In this case, it is impossible to generate a model picture with a normal posture and complete limbs. Summary of the Invention

[0004] The technical problem to be solved by the present invention is to provide a method and device for generating model pictures through mannequin pictures, which improves the quality of generating mannequin model pictures and meets the subsequent use of users.

[0005] In the first aspect, the present invention provides a method for generating a model picture through a mannequin picture, including the following steps:

[0006] Step 1, detecting and obtaining the skeleton picture of the uploaded mannequin picture, where the skeleton picture includes human skeleton key point information;

[0007] Step 2, judging whether there is an abnormality in the mannequin picture according to the human skeleton key point information. If there is no abnormality, go to Step 4; if there is an abnormality, go to Step 3;

[0008] Step 3, if there is an abnormality, repair the skeleton picture and enter Step 4;

[0009] Step 4, inputting the mannequin picture and the skeleton picture into the Stable Diffusion algorithm to generate a model picture.

[0010] In the second aspect, the present invention provides a device for generating a model picture through a mannequin picture, including:

[0011] An acquisition module, which detects and obtains the skeleton picture of the uploaded mannequin picture, where the skeleton picture includes human skeleton key point information;

[0012] Anomaly judgment module, which judges whether there is an anomaly in the mannequin image according to the human skeleton key point information. If there is no anomaly, it enters the model image generation module; if there is an anomaly, it enters the anomaly repair module;

[0013] Anomaly repair module, if there is an anomaly, it repairs the skeleton image and enters the model image generation module;

[0014] Model image generation module, which inputs the mannequin image and the skeleton image into the Stable Diffusion algorithm to generate the model image.

[0015] One or more technical solutions provided by the present invention have at least the following technical effects or advantages:

[0016] By using abnormal posture skeleton judgment and repair, the present invention judges and repairs the incomplete skeleton images extracted from the incomplete mannequin images uploaded by users (such as missing head, abnormal head, missing arm, abnormal arm, etc.); then uses the repaired skeleton images to guide the text-image large model to generate complete model images, greatly improving the stability of the mannequin model image function. Users can use the generated complete model images for subsequent use.

[0017] The above description is only an overview of the technical solution of the present invention. In order to understand the technical means of the present invention more clearly, it can be implemented according to the content of the description. And in order to make the above and other purposes, features and advantages of the present invention more obvious and understandable, the specific embodiments of the present invention are given below. Brief Description of the Drawings

[0018] The present invention will be further described below with reference to the accompanying drawings in conjunction with embodiments.

[0019] Figure 1 It is the flowchart of the method in Embodiment 1 of the present invention;

[0020] Figure 2 It is the structural schematic diagram of the device in Embodiment 2 of the present invention. Detailed Embodiments

[0021] The embodiments of the present application provide a method and device for generating model images from mannequin images. By using abnormal posture skeleton judgment and repair, the incomplete skeleton images extracted from the incomplete mannequin images uploaded by users (such as missing head, abnormal head, missing arm, abnormal arm, etc.) are judged and repaired; then the repaired skeleton images are used to guide the text-image large model to generate complete model images, greatly improving the stability of the mannequin model image function.

[0022] Embodiment 1

[0023] As Figure 1As shown in the figure, this embodiment provides a method for generating a model image from a mannequin image, including the following steps:

[0024] Step 1: Detect and obtain the skeleton image of the uploaded mannequin image, where the skeleton image includes human skeleton key point information; use the open-source 2D pose estimation algorithm DWpose to obtain the skeleton image of the mannequin image;

[0025] Step 2: Determine whether there is an abnormality in the mannequin image based on the human skeleton key point information. If there is no abnormality, go to Step 4; if there is an abnormality, go to Step 3;

[0026] Step 3: If there is an abnormality, repair the skeleton image and go to Step 4;

[0027] Step 4: Input the mannequin image and the skeleton image into the Stable Diffusion algorithm to generate a model image; specific prompt words can also be input into the Stable Diffusion algorithm to generate a set model image for the convenience of users' later use.

[0028] In this embodiment, preferably, the human skeleton key point information includes: nose key point, neck key point, right shoulder key point, right elbow key point, right wrist key point, left shoulder key point, left elbow key point, left wrist key point, right hip key point, left hip key point, right eye key point, left eye key point, right ear key point, and left ear key point.

[0029] In this embodiment, preferably, Step 1 is specifically: set the head skeleton point template, including the nose key point, right eye key point, left eye key point, right ear key point, and left ear key point; set the shoulder width as the distance from the left shoulder key point to the neck key point;

[0030] Set the position of the nose key point; the nose key point is directly above the neck key point, and the distance from the neck key point is 1.2 times the shoulder width;

[0031] Set the position of the left eye key point: the left eye key point is on the left side of the nose key point, the horizontal distance between the left eye key point and the nose key point is at 1 / 4 of the shoulder width, and the vertical distance between the left eye key point and the nose key point is at 1 / 6 of the shoulder width;

[0032] Set the position of the right eye key point: the right eye key point is on the right side of the nose key point, the horizontal distance between the right eye key point and the nose key point is at 1 / 4 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is at 1 / 6 of the shoulder width;

[0033] Set the position of the left ear key point: the left ear key point is on the same horizontal line as the nose key point, and the distance between the left ear key point and the nose key point is 1 / 2 of the shoulder width;

[0034] Set the position of the right ear key point: The right ear key point and the nose key point are on the same horizontal line, and the distance between the right ear key point and the nose key point is 1 / 2 of the shoulder width;

[0035] Set the left arm skeleton point template, and obtain at least one set of normal and complete left arm data. Each set of the left arm information includes the shoulder key point coordinates, the elbow key point coordinates, and the wrist key point coordinates;

[0036] Set the right arm skeleton point template, and obtain at least one set of normal and complete right arm data. Each set of the right arm information includes the shoulder key point coordinates, the elbow key point coordinates, and the wrist key point coordinates.

[0037] In this embodiment, preferably, the specific steps of step 3 are as follows:

[0038] For the abnormal judgment of the head: If there is no nose key point, supplement the head skeleton point template to the skeleton diagram; if there is a nose key point, delete all the head key points in the skeleton diagram, and then supplement the head skeleton point template to the skeleton diagram;

[0039] For the abnormal judgment of the neck length: If the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, move all the key points of the head downward so that the distance between the nose key point and the neck key point is greater than or equal to the shoulder width and less than or equal to 1.5 times the shoulder width; if the distance between the nose key point and the neck key point is less than the shoulder width, move all the key points of the head upward so that the distance between the nose key point and the neck key point is greater than or equal to the shoulder width and less than or equal to 1.5 times the shoulder width;

[0040] For the abnormal judgment of the arm: If the left elbow key point does not exist, it means that the left arm does not exist; if the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, the left arm is abnormal, and delete the left elbow key point and the left wrist key point in the skeleton diagram; select a set of left arm data, according to the left arm length equal to 2 times the shoulder width, map the left arm data to the skeleton diagram, align it with the left shoulder key point in the skeleton diagram, and repair the skeleton diagram;

[0041] If the right elbow key point does not exist, it means that the right arm does not exist; if the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, the right arm is abnormal, and delete the right elbow key point and the right wrist key point in the skeleton diagram; select a set of right arm data, according to the right arm length equal to 2 times the shoulder width, map the right arm data to the skeleton diagram, align it with the right shoulder key point in the skeleton diagram, and repair the skeleton diagram.

[0042] In this embodiment, preferably, the specific steps of step 2 are as follows: Judge whether the mannequin diagram is abnormal according to the human skeleton key point information,

[0043] If there is no nose key point, it is abnormal;

[0044] If there is a nose key point, and the horizontal distance between the left eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, or the vertical distance between the left eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, it is abnormal;

[0045] If there is a nose key point, and the horizontal distance between the right eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, it is abnormal;

[0046] If there is a nose key point, and the distance between the left ear key point and the nose key point is less than 1 / 4 of the shoulder width or greater than 3 / 4 of the shoulder width, it is abnormal;

[0047] If there is a nose key point, and the distance between the right ear key point and the nose key point is less than 1 / 4 of the shoulder width or greater than 3 / 4 of the shoulder width, it is abnormal;

[0048] If the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, or the distance between the nose key point and the neck key point is less than the shoulder width, it is abnormal;

[0049] If the left elbow key point does not exist, or the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, it is abnormal;

[0050] If the right elbow key point does not exist, or the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, it is abnormal;

[0051] If there is no abnormality, go to step 4; if there is an abnormality, go to step 3.

[0052] Based on the same inventive concept, the present application also provides an apparatus corresponding to the method in Embodiment 1. For details, see Embodiment 2.

[0053] Embodiment 2

[0054] As Figure 2 shown, in this embodiment, an apparatus for generating a model diagram from a mannequin diagram is provided, including:

[0055] An acquisition module that detects and acquires the skeleton diagram of the uploaded mannequin diagram, and the skeleton diagram includes human skeleton key point information; uses the open-source 2D pose estimation algorithm DWpose to acquire the skeleton diagram of the mannequin diagram;

[0056] Anomaly judgment module, which judges whether there is an anomaly in the mannequin image according to the human skeleton key point information. If there is no anomaly, it enters the model image generation module; if there is an anomaly, it enters the anomaly repair module;

[0057] Anomaly repair module, if there is an anomaly, it repairs the skeleton image and enters the model image generation module;

[0058] Model image generation module, which inputs the mannequin image and the skeleton image into the Stable Diffusion algorithm to generate a model image; specific prompt words can also be input into the Stable Diffusion algorithm to generate a set model image, which is convenient for the user's later use.

[0059] In this embodiment, preferably, the human skeleton key point information includes: nose key point, neck key point, right shoulder key point, right elbow key point, right wrist key point, left shoulder key point, left elbow key point, left wrist key point, right hip key point, left hip key point, right eye key point, left eye key point, right ear key point and left ear key point.

[0060] In this embodiment, preferably, the acquisition module is specifically: setting a head skeleton point template, including a nose key point, a right eye key point, a left eye key point, a right ear key point and a left ear key point; setting the shoulder width as the distance from the left shoulder key point to the neck key point;

[0061] Setting the position of the nose key point; the nose key point is directly above the neck key point, and the distance from the neck key point is 1.2 times the shoulder width;

[0062] Setting the position of the left eye key point: the left eye key point is on the left side of the nose key point, the horizontal distance between the left eye key point and the nose key point is at 1 / 4 of the shoulder width, and the vertical distance between the left eye key point and the nose key point is at 1 / 6 of the shoulder width;

[0063] Setting the position of the right eye key point: the right eye key point is on the right side of the nose key point, the horizontal distance between the right eye key point and the nose key point is at 1 / 4 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is at 1 / 6 of the shoulder width;

[0064] Setting the position of the left ear key point: the left ear key point and the nose key point are on the same horizontal line, and the distance between the left ear key point and the nose key point is 1 / 2 of the shoulder width;

[0065] Setting the position of the right ear key point: the right ear key point and the nose key point are on the same horizontal line, and the distance between the right ear key point and the nose key point is 1 / 2 of the shoulder width;

[0066] Set the left - arm skeleton point template, and obtain at least one set of normal and complete left - arm data. Each set of the left - arm information includes the shoulder key - point coordinates, the elbow key - point coordinates, and the wrist key - point coordinates;

[0067] Set the right - arm skeleton point template, and obtain at least one set of normal and complete right - arm data. Each set of the right - arm information includes the shoulder key - point coordinates, the elbow key - point coordinates, and the wrist key - point coordinates.

[0068] In this embodiment, preferably, the abnormal repair module is specifically:

[0069] For head abnormality judgment: If there is no nose key - point, supplement the head skeleton point template to the skeleton map; if there is a nose key - point, delete all the head key - points in the skeleton map, and then supplement the head skeleton point template to the skeleton map;

[0070] For neck - length abnormality judgment: If the distance between the nose key - point and the neck key - point is greater than 1.5 times the shoulder width, move all the key - points of the head downward so that the distance between the nose key - point and the neck key - point is greater than or equal to the shoulder width and less than or equal to 1.5 times the shoulder width; if the distance between the nose key - point and the neck key - point is less than the shoulder width, move all the key - points of the head upward so that the distance between the nose key - point and the neck key - point is greater than or equal to the shoulder width and less than or equal to 1.5 times the shoulder width;

[0071] For arm abnormality judgment: If the left - elbow key - point does not exist, it means the left arm does not exist; if the distance between the left - shoulder key - point and the left - elbow key - point is less than 1.2 times the shoulder width, the left arm is abnormal. Delete the left - elbow key - point and the left - wrist key - point in the skeleton map; select a set of left - arm data, map the left - arm data to the skeleton map according to the left - arm length equal to 2 times the shoulder width, align it with the left - shoulder key - point in the skeleton map, and repair the skeleton map;

[0072] If the right - elbow key - point does not exist, it means the right arm does not exist; if the distance between the right - shoulder key - point and the right - elbow key - point is less than 1.2 times the shoulder width, the right arm is abnormal. Delete the right - elbow key - point and the right - wrist key - point in the skeleton map; select a set of right - arm data, map the right - arm data to the skeleton map according to the right - arm length equal to 2 times the shoulder width, align it with the right - shoulder key - point in the skeleton map, and repair the skeleton map.

[0073] In this embodiment, preferably, the abnormal judgment module is specifically: Judge whether the mannequin map is abnormal according to the human - skeleton key - point information,

[0074] If there is no nose key - point, it is abnormal;

[0075] If there is a nose key point, and the horizontal distance between the left eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, or the vertical distance between the left eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, it is abnormal;

[0076] If there is a nose key point, and the horizontal distance between the right eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, it is abnormal;

[0077] If there is a nose key point, and the distance between the left ear key point and the nose key point is less than 1 / 4 of the shoulder width or greater than 3 / 4 of the shoulder width, it is abnormal;

[0078] If there is a nose key point, and the distance between the right ear key point and the nose key point is less than 1 / 4 of the shoulder width or greater than 3 / 4 of the shoulder width, it is abnormal;

[0079] If the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, or the distance between the nose key point and the neck key point is less than the shoulder width, it is abnormal;

[0080] If the left elbow key point does not exist, or the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, it is abnormal;

[0081] If the right elbow key point does not exist, or the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, it is abnormal;

[0082] If there is no abnormality, it enters the model image generation module; if there is an abnormality, it enters the abnormality repair module.

[0083] Since the device introduced in the second embodiment of the present invention is the device adopted for implementing the method of the first embodiment of the present invention, based on the method introduced in the first embodiment of the present invention, those skilled in the art can understand the specific structure and variations of the device, so it will not be elaborated here. Any device adopted for the method of the first embodiment of the present invention belongs to the scope protected by the present invention.

[0084] Although the specific implementation manners of the present invention have been described above, those skilled in the art should understand that the specific embodiments we described are illustrative rather than used to limit the scope of the present invention. Equivalent modifications and variations made by those skilled in the art in accordance with the spirit of the present invention should be covered within the scope protected by the claims of the present invention.

Claims

1. A method for generating a model image through a mannequin image, characterized in that: The steps include: Step 1: Detect and obtain the skeleton diagram of the uploaded mannequin diagram, wherein the skeleton diagram includes key point information of the human skeleton; Step 2: Determine whether there is any abnormality in the human figure according to the key point information of the human skeleton. If there is no abnormality, proceed to step 4; If there is an abnormality, go to step 3; Step 3: If there is an abnormality, the skeleton image is repaired and the process goes to step 4; Step 4: Input the mannequin image and skeleton image into the Stable Diffusion algorithm to generate a model image.

2. The method for generating a model image through a mannequin image according to claim 1, characterized in that: The human skeleton key point information includes: nose key point, neck key point, right shoulder key point, right elbow key point, right wrist key point, left shoulder key point, left elbow key point, left wrist key point, right hip key point, left hip key point, right eye key point, left eye key point, right ear key point and left ear key point.

3. The method for generating a model image through a mannequin image according to claim 2, characterized in that: The step 1 specifically includes: setting a head skeleton point template, including a nose key point, a right eye key point, a left eye key point, a right ear key point and a left ear key point; setting the shoulder width to be the distance from the left shoulder key point to the neck key point; Set the key point position of the nose; The nose key point is located directly above the neck key point, and the distance from the neck key point is 1.2 times the shoulder width; Set the position of the left eye key point: the left eye key point is located on the left side of the nose key point, the horizontal distance between the left eye key point and the nose key point is 1 / 4 of the shoulder width, and the vertical distance between the left eye key point and the nose key point is 1 / 6 of the shoulder width; Set the right eye key point position: the right eye key point is located on the right side of the nose key point, the horizontal distance between the right eye key point and the nose key point is 1 / 4 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is 1 / 6 of the shoulder width; Set the position of the left ear key point: the left ear key point and the nose key point are located on the same horizontal line, and the distance between the left ear key point and the nose key point is 1 / 2 shoulder width; Set the position of the right ear key point: the right ear key point and the nose key point are located on the same horizontal line, and the distance between the right ear key point and the nose key point is 1 / 2 shoulder width; Set a left arm skeleton point template to obtain at least one set of normal and complete left arm data, each set of left arm information including shoulder key point coordinates, elbow key point coordinates and wrist key point coordinates; A right arm skeleton point template is set to obtain at least one set of normal and complete right arm data, each set of right arm information including shoulder key point coordinates, elbow key point coordinates and wrist key point coordinates.

4. The method for generating a model image through a mannequin image according to claim 3, characterized in that: The step 3 is specifically as follows: For head abnormality judgment: if there is no nose key point, the head skeleton point template is added to the skeleton image; if there is a nose key point, all the head key points in the skeleton image are deleted, and then the head skeleton point template is added to the skeleton image; For abnormal neck length judgment: if the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, move all the key points of the head downward so that the distance between the nose key point and the neck key point is greater than or equal to the shoulder width, and less than or equal to 1.5 times the shoulder width; If the distance between the nose key point and the neck key point is less than the shoulder width, move all the key points of the head upwards so that the distance between the nose key point and the neck key point is greater than or equal to the shoulder width and less than or equal to 1.5 times the shoulder width; For arm abnormality judgment: if the left elbow key point does not exist, it means that the left arm does not exist; if the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, the left arm is abnormal, and the left elbow key point and the left wrist key point in the skeleton image are deleted; select a left arm data, according to the left arm length equal to 2 times the shoulder width, map the left arm data to the skeleton image, align it with the left shoulder key point in the skeleton image, and repair the skeleton image; If the right elbow key point does not exist, it means that the right arm does not exist; if the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, the right arm is abnormal, and the right elbow key point and the right wrist key point in the skeleton image are deleted; select a right arm data, and map the right arm data to the skeleton image according to the right arm length being equal to 2 times the shoulder width, align it with the right shoulder key point in the skeleton image, and repair the skeleton image.

5. The method for generating a model image through a mannequin image according to claim 3, characterized in that: The step 2 specifically includes: judging whether there is any abnormality in the figure according to the key point information of the human skeleton, If the nose key point does not exist, it is an exception; If there is a nose key point, the horizontal distance between the left eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, or the vertical distance between the left eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, then it is abnormal; If there is a nose key point, if the horizontal distance between the right eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, it is abnormal; If there is a nose key point, it is abnormal if the distance between the left ear key point and the nose key point is less than 1 / 4 shoulder width or greater than 3 / 4 shoulder width; If there is a nose key point, it is abnormal if the distance between the right ear key point and the nose key point is less than 1 / 4 shoulder width or greater than 3 / 4 shoulder width; If the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, or the distance between the nose key point and the neck key point is less than the shoulder width, it is abnormal; If the left elbow key point does not exist, or the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, it is abnormal; If the right elbow key point does not exist, or the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, it is abnormal; If there is no abnormality, go to step 4; If there is an abnormality, go to step 3.

6. A device for generating a model image from a mannequin image, characterized in that: include: An acquisition module detects and acquires a skeleton diagram of the uploaded human figure, wherein the skeleton diagram includes key point information of a human skeleton; The abnormality judgment module judges whether there is any abnormality in the mannequin image according to the key point information of the human skeleton. If there is no abnormality, the module enters the model image generation module; If there is an abnormality, enter the abnormality repair module; The abnormality repair module repairs the skeleton image if an abnormality exists and enters the model image generation module; The model image generation module inputs the mannequin image and the skeleton image into the Stable Diffusion algorithm to generate a model image.

7. The device for generating a model image from a mannequin image according to claim 6, characterized in that: The human skeleton key point information includes: nose key point, neck key point, right shoulder key point, right elbow key point, right wrist key point, left shoulder key point, left elbow key point, left wrist key point, right hip key point, left hip key point, right eye key point, left eye key point, right ear key point and left ear key point.

8. The device for generating a model image from a mannequin image according to claim 7, characterized in that: The acquisition module specifically includes: setting a head skeleton point template, including a nose key point, a right eye key point, a left eye key point, a right ear key point and a left ear key point; setting the shoulder width to be the distance from the left shoulder key point to the neck key point; Set the key point position of the nose; The nose key point is located directly above the neck key point, and the distance from the neck key point is 1.2 times the shoulder width; Set the position of the left eye key point: the left eye key point is located on the left side of the nose key point, the horizontal distance between the left eye key point and the nose key point is 1 / 4 of the shoulder width, and the vertical distance between the left eye key point and the nose key point is 1 / 6 of the shoulder width; Set the right eye key point position: the right eye key point is located on the right side of the nose key point, the horizontal distance between the right eye key point and the nose key point is 1 / 4 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is 1 / 6 of the shoulder width; Set the position of the left ear key point: the left ear key point and the nose key point are located on the same horizontal line, and the distance between the left ear key point and the nose key point is 1 / 2 shoulder width; Set the position of the right ear key point: the right ear key point and the nose key point are located on the same horizontal line, and the distance between the right ear key point and the nose key point is 1 / 2 shoulder width; Set a left arm skeleton point template to obtain at least one set of normal and complete left arm data, each set of left arm information including shoulder key point coordinates, elbow key point coordinates and wrist key point coordinates; A right arm skeleton point template is set to obtain at least one set of normal and complete right arm data, each set of right arm information including shoulder key point coordinates, elbow key point coordinates and wrist key point coordinates.

9. The device for generating a model image from a mannequin image according to claim 8, characterized in that: The abnormality repair module is specifically: For head abnormality judgment: if there is no nose key point, the head skeleton point template is added to the skeleton image; if there is a nose key point, all the head key points in the skeleton image are deleted, and then the head skeleton point template is added to the skeleton image; For abnormal neck length judgment: if the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, move all the key points of the head downward so that the distance between the nose key point and the neck key point is greater than or equal to the shoulder width, and less than or equal to 1.5 times the shoulder width; If the distance between the nose key point and the neck key point is less than the shoulder width, move all the key points of the head upwards so that the distance between the nose key point and the neck key point is greater than or equal to the shoulder width and less than or equal to 1.5 times the shoulder width; For arm abnormality judgment: if the left elbow key point does not exist, it means that the left arm does not exist; if the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, the left arm is abnormal, and the left elbow key point and the left wrist key point in the skeleton image are deleted; select a left arm data, according to the left arm length equal to 2 times the shoulder width, map the left arm data to the skeleton image, align it with the left shoulder key point in the skeleton image, and repair the skeleton image; If the right elbow key point does not exist, it means that the right arm does not exist; if the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, the right arm is abnormal, and the right elbow key point and the right wrist key point in the skeleton image are deleted; select a right arm data, and map the right arm data to the skeleton image according to the right arm length being equal to 2 times the shoulder width, align it with the right shoulder key point in the skeleton image, and repair the skeleton image.

10. The device for generating a model image from a mannequin image according to claim 8, characterized in that: The abnormality judgment module specifically judges whether there is an abnormality in the human figure according to the key point information of the human skeleton. If the nose key point does not exist, it is an exception; If there is a nose key point, the horizontal distance between the left eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, or the vertical distance between the left eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, then it is abnormal; If there is a nose key point, if the horizontal distance between the right eye key point and the nose key point is less than 1 / 8 of the shoulder width or greater than 3 / 8 of the shoulder width, and the vertical distance between the right eye key point and the nose key point is less than 1 / 12 of the shoulder width or greater than 1 / 4 of the shoulder width, it is abnormal; If there is a nose key point, it is abnormal if the distance between the left ear key point and the nose key point is less than 1 / 4 shoulder width or greater than 3 / 4 shoulder width; If there is a nose key point, it is abnormal if the distance between the right ear key point and the nose key point is less than 1 / 4 shoulder width or greater than 3 / 4 shoulder width; If the distance between the nose key point and the neck key point is greater than 1.5 times the shoulder width, or the distance between the nose key point and the neck key point is less than the shoulder width, it is abnormal; If the left elbow key point does not exist, or the distance between the left shoulder key point and the left elbow key point is less than 1.2 times the shoulder width, it is abnormal; If the right elbow key point does not exist, or the distance between the right shoulder key point and the right elbow key point is less than 1.2 times the shoulder width, it is abnormal; If there is no abnormality, enter the model image generation module; If there is an abnormality, enter the abnormality repair module.

Citation Information

Patent Citations

  • Method and equipment for generating virtual model based on mannequin model

    CN117234342A

  • Depth camera-based three-dimensional human skeleton recognition method and device

    CN118212659A