A Structure Line-Driven Segmentation and Grading Method and System

Through the structural line-driven slicing and coding method, the geometric similarity principle and computer graphics automatically calculate the coding position, the problem of too much artificial input in the existing clothing CAD software is solved, and efficient coding and cost reduction is achieved.

CN114444144BActive Publication Date: 2025-07-22SUN YAT SEN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111622236.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-28
Publication Date
2025-07-22
Estimated Expiration
2041-12-28

AI Technical Summary

Technical Problem

The existing clothing CAD software still requires a lot of manual input during the process of coding, resulting in inefficient and high labor costs. In particular, the point-to-coding method requires more coding points and relies on human experience.

Method used

The slicing and coding method driven by structural line is used to divide the clothing sample into multiple areas through geometric similarity principles and computer graphics. The sizing position and size of the coding are automatically calculated by using the changes in the structural line to reduce human input.

Benefits of technology

It improves the efficiency of coding, reduces labor costs, and achieves satisfactory coding effect while reducing the amount of user input through structural algorithms.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114444144B_ABST
    Figure CN114444144B_ABST
Patent Text Reader

Abstract

The present invention discloses a segmentation grading method and system driven by structural lines. A user inputs a set of horizontal and vertical structural lines for a sample piece, generates structural points and structural edges according to the structural lines, and sets regions; according to the part grading table and the part correlation degree parameter table, calculates the longitudinal grading amount of the horizontal structural line and the transverse grading amount of the vertical structural line, the offset amount of the horizontal structural line and the offset amount of the vertical structural line, and the coordinate offset amount of the structural points; updates the position coordinates of the contour points according to the coordinate offset amount, thereby obtaining the structural information of the new sample piece after grading and obtaining the sample piece drawing after grading. The segmentation grading method of the present invention does not require manual operation by personnel with clothing manufacturing knowledge, improves the grading efficiency and reduces the labor cost; compared with the existing point grading method, the segmentation grading method of the present invention uses a structure-preserving algorithm to automatically calculate the offset amount of the contour points of the entire region, and can achieve a satisfactory grading effect while reducing the user input amount.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of clothing CAD, and in particular to a structure line driven segmentation and grading method and system. Background Art

[0002] As people's living standards improve, they increasingly consider the fit of clothing when choosing clothes. Therefore, when enterprises produce clothing, they generally provide multiple sizes for a piece of clothing. A unique pattern is required to make each size of clothing. The method of designing a pattern for each size of clothing is inefficient. Therefore, in the industry, experienced fashion designers usually draw a pattern of an intermediate size first. This process is called pattern making. Then, while keeping the pattern structure unchanged, the pattern is enlarged or reduced by a certain method to obtain other sizes of patterns. This process is called grading. The existing manual grading methods include point grading, line grading, general drawing push method, similar type push method, etc. Manual grading still requires a large number of pattern makers with clothing knowledge to operate. With the development of information technology, clothing CAD software has become more and more powerful and mature. The method of grading by computer has gradually been promoted, which solves the problems of low efficiency and high labor cost in the past manual grading of clothing.

[0003] One of the current existing technologies is point grading. Now many clothing CADs have implemented the point grading method driven by input, which is the main method currently used to achieve grading through computers. Its main process is: 1. Input sample point information and point connection information 2. Set grading points 3. Input grading formula 4. Input grade difference information 5. Calculate grading point offset 6. Calculate non-grading point offset according to the algorithm 7. Interpolation 8. Complete grading. The disadvantage of this type of technology is that when grading by the point grading method, more manual input is still required. The main reason is that there are many grading points in a sample, and the grading formula for each grading point needs to be designed through human experience, which is inefficient. Summary of the invention

[0004] The purpose of the present invention is to overcome the shortcomings of the existing methods and propose a structure line driven segmentation and grading method and system. The main problem solved by the present invention is how to use the principle of geometric similarity and computer graphics related knowledge to segment the sample into multiple areas according to the rules. Each area can automatically calculate its position and size after grading according to the algorithm by changing a small number of control lines, thereby reducing manual input.

[0005] In order to solve the above problems, the present invention proposes a structure line driven segmentation and grading method, the method comprising:

[0006] Read out the contour point information and contour edge information representing all pattern piece structures from the DXF format file that stores the pattern piece structure information, and obtain the part grading table K corresponding to the garment, where K t represents the grading difference of the t-th part;

[0007] For any one of the said pattern pieces, the user inputs a set of horizontal and vertical structure lines. The information of each structure line includes the position information represented by the straight line equation and the part relevance degree parameter table α belonging to the part where the structure line is located. The length of the part relevance degree parameter table is the same as the length of the part grading table K. The t-th item α t represents the relevance degree of the t-th part in the part grading table K when calculating the grading amount of the structure line;

[0008] Generate structure points at the intersections of the horizontal structure lines and vertical structure lines, and at the intersections of the structure lines and the contour edges. The connection line between adjacent structure points on the same structure line is set as a structure edge. The part jointly formed by the contour edges and the structure edges is set as an area. Then, re-establish a coordinate system and translate the whole pattern piece to ensure that the whole pattern piece is in the first quadrant for convenient grading;

[0009] According to the part grading table K and the part relevance degree parameter table α, calculate the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line;

[0010] Calculate the offset dy of the horizontal structure line according to the longitudinal grading amount Δhor of the horizontal structure line, and calculate the offset dx of the vertical structure line according to the transverse grading amount Δver of the vertical structure line;

[0011] Calculate the coordinate offset S of the structure points according to the offset dy of the horizontal structure line and the offset dx of the vertical structure line Offset ;

[0012] According to the coordinate offset S Offset Update the position coordinates of the contour points, so as to obtain the structure information of the new pattern piece after grading. Then, through the contour edge information of the new pattern piece after grading, use the spline interpolation algorithm to draw the edge structure of the new pattern piece after grading, and obtain the graded pattern piece drawing.

[0013] Preferably, the calculation of the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line according to the part grading table K and the part relevance degree parameter table α is specifically as follows:

[0014] Calculate the longitudinal grading amount Δhor of the horizontal structure line:

[0015]

[0016] Among them, Δhor i represents the longitudinal grading amount of the i-th horizontal structure line, and α i represents the part correlation degree parameter table of the i-th horizontal structure line, and α i t represents the correlation degree of the t-th part in the part grading table K when calculating the grading amount of the i-th horizontal structure line, and n represents the length of K;

[0017] Calculate the transverse grading amount Δver of the vertical structure line:

[0018]

[0019] Among them, Δver i represents the transverse grading amount of the i-th vertical structure line, and α i represents the part correlation degree parameter table of the i-th vertical structure line, and α i t represents the correlation degree of the t-th part in the part grading table K when calculating the grading amount of the i-th vertical structure line, and n represents the length of K.

[0020] Preferably, calculate the offset dy of the horizontal structure line according to the longitudinal grading amount Δhor of the horizontal structure line, and calculate the offset dx of the vertical structure line according to the transverse grading amount Δver of the vertical structure line. Specifically:

[0021] Calculate the offset dy of the horizontal structure line:

[0022]

[0023] Among them, dy i represents the offset of the i-th horizontal structure line in the y-axis direction;

[0024] Calculate the offset dx of the vertical structure line:

[0025]

[0026] Among them, dx i represents the offset of the i-th vertical structure line in the x-axis direction.

[0027] Preferably, calculate the coordinate offset S Offset of the structure point according to the offset dy of the horizontal structure line and the offset dx of the vertical structure line. Specifically:

[0028]

[0029] Among them, S i represents the i-th structure point, and S i Offset represents S iCoordinate offset

[0030] Preferably, according to the coordinate offset S Offset Update the position coordinates of the contour points, specifically:

[0031] Traverse all contour points, and for each contour point P, perform the following steps:

[0032] Query the region to which the contour point P belongs, denoted as A;

[0033] Calculate the updated abscissa p x ′;

[0034] Calculate the updated ordinate p y ′.

[0035] Preferably, the calculation of the updated abscissa p x ′ of the contour point P is specifically:

[0036] Query the number of horizontal structure edges in the region A;

[0037] If there is only one horizontal structure edge L in the region A, and S1 and S2 are two structure points on the structure edge L, use the following formula of the triangle structure-preserving algorithm to obtain the relative coordinates (x 12 , y 12 ) of the contour point P:

[0038] Where

[0039] Where v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively;

[0040] Denote v1′ and v2′ as the coordinates of the structure points v1 and v2 after offset, and S1 Offset , S2 Offset are the structure point offsets of S1 and S2 respectively, and obtain v1′ and v2′:

[0041] v1′ = v1 + S1 Offset

[0042] v2′ = v2 + S2 Offset

[0043] Denote p′ as the point that keeps the structure of △S1S2P unchanged. According to the definition of the relative coordinates of the triangle, the relative coordinates (x 12 , y 12 ) of the contour point P remain unchanged at this time. Use the following formula of the triangle structure-preserving algorithm to obtain the reference coordinate p′ corresponding to the structure edge L:

[0044] Among them

[0045] Therefore, the abscissa of the updated contour point P

[0046] If there are two horizontal structural edges L1 and L2 in region A, according to the above steps for calculating the reference coordinates, the reference coordinates p1' and p2' corresponding to the structural edges L1 and L2 are obtained, and the midpoint of p1' and p2' is taken as p ′ : Then the abscissa of the updated contour point P

[0047] Preferably, the ordinate p of the updated contour point P is calculated y ′, specifically as follows:

[0048] Query the number of vertical structural edges in the region A;

[0049] If there is only one vertical structural edge L in region A, and S1 and S2 are two structural points on the structural edge L, the relative coordinates (x 12 , y 12 ) of the contour point P are obtained using the following formula of the triangle structure-preserving algorithm:

[0050] Among them

[0051] Among them, v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively;

[0052] Let v1' and v2' be the coordinates after the offsets of the structural points v1 and v2 respectively, and S1 Offset , S2 Offset are the structural point offsets of S1 and S2 respectively, and v1' and v2' are obtained:

[0053] v1' = v1 + S1 Offset

[0054] v2' = v2 + S2 Offset

[0055] Let p' be the point that keeps the structure of △S1S2P unchanged. According to the definition of the relative coordinates of the triangle, the relative coordinates (x 12 , y 12 ) of the contour point P remain unchanged at this time, and the reference coordinate p' corresponding to the structural edge L is obtained using the following formula of the triangle structure-preserving algorithm:

[0056] Among them

[0057] Therefore, the updated ordinate of the profile point P

[0058] If there are two vertical structural edges L1 and L2 in region A, according to the above steps for calculating the reference coordinates, the reference coordinates p1' and p2' corresponding to the structural edges L1 and L2 are obtained, and the midpoint of p1' and p2' is taken as p ′ : Then the updated ordinate of the profile point P

[0059] Correspondingly, the present invention also provides a structure line-driven grading and pattern cutting system, including:

[0060] A garment pattern information reading unit, configured to read out the profile point information and profile edge information representing all pattern structures from a DXF format file storing the garment pattern structure information, and obtain the part grading table K corresponding to the garment, where K t represents the grading difference of the t-th part;

[0061] A structure line input unit, for a user to input a set of horizontal and vertical structure lines for any one of the above-mentioned all patterns. The information of each structure line includes the position information represented by a straight line equation and the part correlation degree parameter table α to which the structure line belongs; structure points are generated at the intersections of the horizontal structure line and the vertical structure line, and at the intersections of the structure line and the profile edge. The connection line between adjacent structure points on the same structure line is set as a structure edge, and the part jointly formed by the profile edge and the structure edge is set as a region. Then, a coordinate system is re-established, and the whole pattern is translated to ensure that the whole pattern is in the first quadrant;

[0062] A structure point coordinate offset calculation unit, configured to calculate the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line according to the part grading table K and the part correlation degree parameter table α; calculate the horizontal structure line offset dy according to the longitudinal grading amount Δhor of the horizontal structure line, and calculate the vertical structure line offset dx according to the transverse grading amount Δver of the vertical structure line; calculate the coordinate offset S of the structure point according to the horizontal structure line offset dy and the vertical structure line offset dx Offset ;

[0063] A profile edge position calculation and drawing unit, configured to update the position coordinates of the profile points according to the coordinate offset S Offset to obtain the structure information of the graded new pattern, and then, through the profile edge information of the graded new pattern, use the spline interpolation algorithm to draw the edge structure of the graded new pattern to obtain the graded pattern diagram.

[0064] Implementing the present invention has the following beneficial effects:

[0065] The slicing grading method of the present invention is designed based on the principles of manual grading and geometric similarity. It does not require manual operation by those with clothing-making knowledge, improving the grading efficiency and reducing labor costs. Compared with the existing point grading method, the slicing grading method of the present invention uses a structure-preserving algorithm to automatically calculate the offset of the contour points of the entire area, achieving a satisfactory grading effect while reducing the amount of user input. BRIEF DESCRIPTION OF THE DRAWINGS

[0066] Figure 1 is the overall flowchart of the structure-line-driven slicing grading method according to an embodiment of the present invention;

[0067] Figure 2 is a schematic diagram of the data structure Pattern according to an embodiment of the present invention;

[0068] Figure 3 is a schematic diagram of the structure line according to an embodiment of the present invention;

[0069] Figure 4 is a schematic diagram of the area divided by the structure line according to an embodiment of the present invention;

[0070] Figure 5 is a schematic diagram of the grading amount of the structure line according to an embodiment of the present invention;

[0071] Figure 6 is the structural diagram of the structure-line-driven slicing grading system according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0072] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without making creative efforts belong to the scope of protection of the present invention.

[0073] Figure 1 is the overall flowchart of the structure-line-driven slicing grading method according to an embodiment of the present invention, as Figure 1 shown, the method includes:

[0074] S1, read out the contour point information and contour edge information representing all pattern structures from the DXF format file storing the pattern structure information of the garment, and obtain the part grading table K corresponding to the garment, where Kt represents the grading difference of the t-th part;

[0075] S2. For any one of all the sample pieces, the user inputs a set of horizontal and vertical construction lines. The information of each construction line includes the position information represented by a straight-line equation and a part correlation degree parameter table α belonging to this construction line, where the length of the part correlation degree parameter table is the same as that of the part grading difference table K. The t-th item α t represents the correlation degree of the t-th part in the part grading difference table K when calculating the grading amount of this construction line;

[0076] S3. Generate construction points at the intersections of the horizontal construction lines and vertical construction lines, and at the intersections of the construction lines and the contour edges. The connection line between adjacent construction points on the same construction line is set as a construction edge, and the part jointly formed by the contour edge and the construction edge is set as an area. Then, re-establish a coordinate system and translate the whole sample piece to ensure that the whole sample piece is in the first quadrant for convenient grading;

[0077] S4. According to the part grading difference table K and the part correlation degree parameter table α, calculate the longitudinal grading amount Δhor of each horizontal construction line and the transverse grading amount Δver of each vertical construction line;

[0078] S5. Calculate the offset dy of the horizontal construction line according to the longitudinal grading amount Δhor of the horizontal construction line, and calculate the offset dx of the vertical construction line according to the transverse grading amount Δver of the vertical construction line;

[0079] S6. Calculate the coordinate offset S of the construction points according to the offset dy of the horizontal construction line and the offset dx of the vertical construction line Offset ;

[0080] S7. Update the position coordinates of the contour points according to the coordinate offset S Offset to obtain the structural information of the new sample piece after grading. Then, through the contour edge information of the new sample piece after grading, use the spline interpolation algorithm to draw the edge structure of the new sample piece after grading to obtain the graded sample piece drawing.

[0081] Step S1 is specifically as follows:

[0082] First, parse out the contour point information and contour edge information representing all the sample piece structures in the DXF format file (the DXF format is a tagged data representation of all the information contained in a graphic file. In this embodiment, this file stores the structural information of the clothing sample piece), and save them in our custom data structure Pattern (pattern). At the same time, input and save the part grading difference table K corresponding to this clothing, where K t represents the grading difference of the t-th part. The design of the data structure Pattern is as Figure 2 shown.

[0083] Step S2 is specifically as follows:

[0084] Select a block in the pattern and copy it, then perform grading operations.

[0085] As Figure 3 shown, the user inputs a set of horizontal and vertical construction lines. The information of each construction line includes the position information represented by a straight-line equation and the table of part correlation degree parameters α belonging to the part where the construction line is located. For example, a horizontal construction line can be expressed as y = k, and a vertical construction line can be expressed as x = k; the length of the table of part correlation degree parameters is the same as the length of the part grading difference table K. The t-th item α t in the table represents the correlation degree of the t-th part in the part grading difference table K when calculating the grading amount of the construction line.

[0086] Step S3 is as follows:

[0087] As Figure 4 shown, generate construction points at the intersections of the horizontal and vertical construction lines and at the intersections of the construction lines and the contour edges. The connection lines between adjacent construction points on the same construction line are set as construction edges, and the part jointly formed by the contour edge and the construction edge is set as an area. Then, re-establish a coordinate system and translate the whole block to ensure that the whole block is in the first quadrant, which is convenient for grading. When the whole block is in the first quadrant, if the coordinate axes are used as the reference lines, the block is always enlarged in the direction away from the reference line and reduced in the direction close to the reference line during grading.

[0088] Step S4 is as follows:

[0089] As Figure 5 shown, calculate the grading amount of the construction line:

[0090] S4-1, calculate the longitudinal grading amount Δhor of the horizontal construction line:

[0091]

[0092] where Δhor i represents the longitudinal grading amount of the i-th horizontal construction line, α i represents the table of part correlation degree parameters of the i-th horizontal construction line, and α i t represents the correlation degree of the t-th part in the part grading difference table K when calculating the grading amount of the i-th horizontal construction line. n represents the length of K;

[0093] S4-2, calculate the transverse grading amount Δver of the vertical construction line:

[0094]

[0095] where Δver iDenote the horizontal grading amount of the \(i\)-th vertical structure line as \(\alpha\). i Denote the part correlation degree parameter table of the \(i\)-th vertical structure line as \(\alpha\). i t Denote the correlation degree when calculating the grading amount of the \(i\)-th vertical structure line for the \(t\)-th part in the part step difference table \(K\), and \(n\) represents the length of \(K\).

[0096] Step S5 is as follows:

[0097] S5-1, calculate the horizontal structure line offset \(dy\):

[0098]

[0099] where \(dy\) i Denote the offset of the \(i\)-th horizontal structure line in the \(y\)-axis direction.

[0100] S5-2, calculate the vertical structure line offset \(dx\):

[0101]

[0102] where \(dx\) i Denote the offset of the \(i\)-th vertical structure line in the \(x\)-axis direction.

[0103] Step S6 is as follows:

[0104] Calculate the structure point coordinate offset:

[0105]

[0106] where \(S\) i Denote the \(i\)-th structure point, \(S\) i Offset Denote \(S\) i 's coordinate offset.

[0107] Step S7 is as follows:

[0108] Traverse all contour points. For each contour point \(P\), perform the following steps:

[0109] S7-1, query the area to which the contour point \(P\) belongs, denoted as \(A\).

[0110] S7-2, calculate the updated abscissa \(p\) of the contour point \(P\) x ':

[0111] Query the number of horizontal structure edges in the area \(A\).

[0112] (1) If there is only one horizontal structure edge \(L\) in the area \(A\), denote \(S1\) and \(S2\) as the two structure points on the structure edge \(L\), and obtain the relative coordinates \((x\) of the contour point \(P\) using the following formula of the triangle structure preservation algorithm.12 , y 12 ):

[0113] Among them

[0114] Among them, v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively;

[0115] Let v1′ and v2′ be the coordinates of the structure points v1 and v2 after offset, and S1 Offset , S2 Offset be the structure point offsets of S1 and S2 respectively, and obtain v1′ and v2′:

[0116] v1′ = v1 + S1 Offset

[0117] v2′ = v2 + S2 Offset

[0118] Let p′ be the point that keeps the structure of △S1S2P unchanged. According to the definition of the relative coordinates of the triangle, the relative coordinates (x 12 , y 12 ) of the contour point P remain unchanged at this time. Use the following formula of the triangle structure-preserving algorithm to obtain the reference coordinate p′ corresponding to the structure edge L:

[0119] Among them

[0120] Therefore, the updated abscissa of the contour point P

[0121] (2) If there are two horizontal structure edges L1 and L2 in region A, according to the above steps of calculating the reference coordinates, obtain the reference coordinates p1′ and p2′ corresponding to the structure edges L1 and L2, and take the midpoint of p1′ and p2′ as p ′ : Then the updated abscissa of the contour point P

[0122] S7-3, calculate the updated ordinate p y ′ of the contour point P:

[0123] Query the number of vertical structure edges in the region A

[0124] (1) If there is only one vertical structure edge L in region A, denote S1 and S2 as two structure points on the structure edge L, and use the following formula of the triangle structure-preserving algorithm to obtain the relative coordinates (x 12 , y 12 ) of the contour point P:

[0125] wherein

[0126] wherein, v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively;

[0127] Let v1′ and v2′ be the coordinates after the offsets of the structure points v1 and v2 respectively, and S1 Offset , S2 Offset be the structure point offsets of S1 and S2 respectively, and v1′ and v2′ are obtained as follows:

[0128] v1′ = v1 + S1 offset

[0129] v2′ = v2 + S2 Offset

[0130] Let p′ be the point that keeps the structure of △S1S2P unchanged. According to the definition of the relative coordinates of a triangle, the relative coordinates (x 12 , y 12 ) of the contour point P remain unchanged at this time. The reference coordinate p′ corresponding to the structure edge L is obtained using the following formula of the triangle structure-preserving algorithm:

[0131] wherein

[0132] Therefore, the updated ordinate of the contour point P

[0133] (2) If there are two perpendicular structure edges L1 and L2 in region A, according to the above steps of calculating the reference coordinates, the reference coordinates p1′ and p2′ corresponding to the structure edges L1 and L2 are obtained, and the midpoint of p1′ and p2′ is taken as p′: Then the updated ordinate of the contour point P

[0134] S7-4, using p′ = (p x ′, p y ′) to update the coordinates of the contour point P.

[0135] S7-5, after all the contour points have completed the coordinate update, the new pattern piece Block structure information after grading is obtained. Then, through the contour edge information of the new pattern piece after grading, the edge structure of the new pattern piece after grading is drawn using the spline interpolation algorithm to obtain the graded pattern piece drawing.

[0136] Correspondingly, the present invention also provides a structure line-driven slicing and grading system, as shown in Figure 6 and includes:

[0137] The garment pattern information reading unit 1 is used to read out the contour point information and contour edge information representing all the pattern structures from a DXF format file storing the garment pattern structure information, and obtain the part grading table K corresponding to the garment, where K t represents the grading of the t-th part;

[0138] The structure line input unit 2 is used for the user to input a set of horizontal and vertical structure lines for any one of the above-mentioned patterns. The information of each structure line includes the position information represented by a straight line equation and the part relevance parameter table α to which the structure line belongs; structure points are generated at the intersections of the horizontal structure lines and the vertical structure lines, and at the intersections of the structure lines and the contour edges. The connection line between adjacent structure points on the same structure line is set as a structure edge, and the part jointly composed of the contour edge and the structure edge is set as an area. Then, a new coordinate system is established, and the whole pattern is translated to ensure that the whole pattern is in the first quadrant;

[0139] The structure point coordinate offset calculation unit 3 is used to calculate the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line according to the part grading table K and the part relevance parameter table α; calculate the horizontal structure line offset dy according to the longitudinal grading amount Δhor of the horizontal structure line, and calculate the vertical structure line offset dx according to the transverse grading amount Δver of the vertical structure line; calculate the coordinate offset S of the structure point according to the horizontal structure line offset dy and the vertical structure line offset dx Offset ;

[0140] The contour edge position calculation and drawing unit 4 is used to update the position coordinates of the contour points according to the coordinate offset S Offset so as to obtain the structure information of the graded new pattern. Then, through the contour edge information of the graded new pattern, use the spline interpolation algorithm to draw the edge structure of the graded new pattern to obtain the graded pattern diagram.

[0141] Therefore, the grading method of the present invention is designed according to the manual grading principle and the geometric similarity principle, without the need for manual operation by those with clothing manufacturing knowledge, improving the grading efficiency and reducing the labor cost; compared with the existing point grading method, the grading method of the present invention uses a structure-preserving algorithm to automatically calculate the offsets of all the contour points in the whole area, and can achieve a satisfactory grading effect while reducing the user input amount.

[0142] The above has introduced in detail a segmentation and grading method and system driven by structural lines provided by the embodiments of the present invention. Specific examples are used in this article to elaborate on the principle and implementation manner of the present invention. The description of the above embodiments is only used to help understand the method and its core idea of the present invention; at the same time, for those of ordinary skill in the art, according to the idea of the present invention, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present invention.

Claims

1. A segmentation grading method driven by structure lines, characterized in that The method includes: Read out the contour point information and contour edge information representing all pattern structures from the DXF format file that stores the pattern structure information of the garment, and obtain the part grading table K corresponding to this garment, where K t represents the grading difference of the t-th part; For any one of all the sample pieces, the user inputs a set of horizontal and vertical construction lines. The information of each construction line includes the position information represented by a straight-line equation and a table of part correlation degree parameters α belonging to the part to which the construction line belongs. The length of the table of part correlation degree parameters is the same as the length of the part grading difference table K, and the t-th item α t represents the correlation degree of the t-th part in the part grading difference table K when calculating the grading amount of the construction line; Generating structure points at the intersections of the horizontal structure lines and the vertical structure lines, and at the intersections of the structure lines and the contour edges. The connection lines between adjacent structure points on the same structure line are set as structure edges. The part formed by the contour edges and the structure edges is set as a region. Then, a coordinate system is re-established, and the entire sample piece is translated to ensure that the entire sample piece is in the first quadrant for convenient grading. Calculating the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line according to the part grading difference table K and the part relevance degree parameter table α. Calculating the horizontal structure line offset dy according to the longitudinal grading amount Δhor of the horizontal structure line, and calculating the vertical structure line offset dx according to the transverse grading amount Δver of the vertical structure line. Calculate the coordinate offset S of the structure point according to the horizontal structure line offset dy and the vertical structure line offset dx Offset ; According to the coordinate offset S Offset Update the position coordinates of the contour points, so as to obtain the structural information of the new pattern piece after grading. Then, based on the contour edge information of the new pattern piece after grading, use the spline interpolation algorithm to draw the edge structure of the new pattern piece after grading, and obtain the graded pattern piece drawing; Specifically, calculating the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line according to the part grading difference table K and the part relevance degree parameter table α is specifically as follows: Calculating the longitudinal grading amount Δhor of the horizontal structure line: Among them, Δhor i represents the longitudinal grading amount of the i-th horizontal structure line, and α i represents the part correlation degree parameter table of the i-th horizontal structure line, and α i t represents the correlation degree when calculating the grading amount of the i-th horizontal structure line for the t-th part in the part grading difference table K, and n represents the length of K; Calculating the transverse grading amount Δver of the vertical structure line: Among them, Δver i represents the horizontal grading amount of the i-th vertical structure line, and α i represents the part correlation degree parameter table of the i-th vertical structure line, and α i t represents the correlation degree when calculating the grading amount of the i-th vertical structure line for the t-th part in the part grading difference table K, and n represents the length of K; Specifically, calculating the horizontal structure line offset dy according to the longitudinal grading amount Δhor of the horizontal structure line, and calculating the vertical structure line offset dx according to the transverse grading amount Δver of the vertical structure line is specifically as follows: Calculating the horizontal structure line offset dy: wherein, dy i represents the offset of the i-th horizontal structure line in the y-axis direction; Calculating the vertical structure line offset dx: wherein, dx i represents the offset of the i-th vertical structure line in the x-axis direction; Specifically, the coordinate offset S of the structure point is calculated based on the horizontal structure line offset dy and the vertical structure line offset dx Offset , specifically as follows: Among them, S i represents the i-th structural point, and S i Offset represents the coordinate offset of S i ; Specifically, according to the coordinate offset S Offset Update the position coordinates of the contour points, specifically: Traverse all contour points. For each contour point P, perform the following steps: Query the region A to which the contour point P belongs, denoted as A. Calculate the updated abscissa p of the contour point P x ′; Calculate the updated ordinate p of the contour point P y ′; Among them, the updated abscissa p x ′ of the calculated contour point P is specifically: Query the number of horizontal structure edges in the region A. If there is only one horizontal structural edge L in region A, and S1 and S2 are two structural points on the structural edge L, the relative coordinates (x 12 , y 12 ) of the contour point P are obtained by using the following formula of the triangle structure-preserving algorithm: wherein Where v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively. Let \(v1'\) and \(v2'\) be the coordinates of the structural points \(v1\) and \(v2\) after offset, and \(S1\) Offset and \(S2\) Offset be the structural point offsets of \(S1\) and \(S2\) respectively. Then \(v1'\) and \(v2'\) are obtained as follows: v1′ = v1 + S1 Offset v2′ = v2 + S2 Offset Let \(p'\) be the point that keeps the structure of \(\triangle S_1S_2P\) unchanged. According to the definition of the relative coordinates of a triangle, the relative coordinates \((x 12 ,y 12 )\) of the contour point \(P\) remain unchanged at this time. The reference coordinate \(p'\) corresponding to the structural edge \(L\) is obtained by using the following formula of the triangle structure preservation algorithm: wherein Therefore, the abscissa of the updated contour point P If there are two horizontal structural edges L1 and L2 in region A, according to the above steps for calculating the reference coordinates, the reference coordinates p1' and p2' corresponding to the structural edges L1 and L2 are obtained, and the midpoint of p1' and p2' is taken as p': Then the updated abscissa of the contour point P wherein, the updated ordinate p y ' of the calculated contour point P is specifically: Query the number of vertical structure edges in the region A. If there is only one vertical structural edge L in region A, and S1 and S2 are two structural points on the structural edge L, the relative coordinates (x 12 , y 12 ) of the contour point P are obtained by using the following formula of the triangle structure preservation algorithm: wherein Where v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively. Let \(v1'\) and \(v2'\) be the coordinates of the structure points \(v1\) and \(v2\) after offset, and \(S1\) Offset and \(S2\) Offset be the structure point offsets of \(S1\) and \(S2\) respectively. Then \(v1'\) and \(v2'\) are obtained as follows: v1′ = v1 + S1 Offset v2' = v2 + S2 Offset Let \(p'\) be the point that keeps the structure of \(\triangle S_1S_2P\) unchanged. According to the definition of the relative coordinates of a triangle, the relative coordinates \((x 12 , y 12 )\) of the contour point \(P\) remain unchanged at this time. The reference coordinates \(p'\) corresponding to the structural edge \(L\) are obtained by using the following formula of the triangle structure-preserving algorithm: Among them Therefore, the updated ordinate of the contour point P If there are two vertical structural edges L1 and L2 in region A, according to the above steps for calculating the reference coordinates, the reference coordinates p1' and p2' corresponding to the structural edges L1 and L2 are obtained, and the midpoint of p1' and p2' is taken as p': Then the updated ordinate of the contour point P 2. A structure line-driven segmentation and grading system, characterized in that, The system includes: A garment pattern information reading unit is used to read out the contour point information and contour edge information representing all pattern structures from a DXF format file storing the garment pattern structure information, and obtain the part grading table K corresponding to the garment, where K t represents the grading of the t-th part; A structure line input unit for the user to input a set of horizontal and vertical structure lines for any one of all the sample pieces. The information of each structure line includes the position information represented by the straight line equation and the part relevance degree parameter table α to which the structure line belongs. Generating structure points at the intersections of the horizontal structure lines and the vertical structure lines, and at the intersections of the structure lines and the contour edges. The connection lines between adjacent structure points on the same structure line are set as structure edges. The part formed by the contour edges and the structure edges is set as a region. Then, a coordinate system is re-established, and the entire sample piece is translated to ensure that the entire sample piece is in the first quadrant. A structural point coordinate offset calculation unit is configured to calculate the vertical grading amount Δhor of each horizontal structural line and the horizontal grading amount Δver of each vertical structural line according to the part grading table K and the part correlation degree parameter table α; calculate the horizontal structural line offset dy according to the vertical grading amount Δhor of the horizontal structural line, and calculate the vertical structural line offset dx according to the horizontal grading amount Δver of the vertical structural line; calculate the coordinate offset S of the structural point according to the horizontal structural line offset dy and the vertical structural line offset dx Offset ; The contour edge position calculation and drawing unit is used to update the position coordinates of the contour points according to the coordinate offset S Offset so as to obtain the structural information of the new pattern piece after grading. Then, based on the contour edge information of the new pattern piece after grading, the edge structure of the new pattern piece after grading is drawn using the spline interpolation algorithm to obtain the pattern piece diagram after grading; Specifically, in the structure point coordinate offset calculation unit, calculating the longitudinal grading amount Δhor of each horizontal structure line and the transverse grading amount Δver of each vertical structure line according to the part grading difference table K and the part relevance degree parameter table α is specifically as follows: Calculating the longitudinal grading amount Δhor of the horizontal structure line: Among them, Δhor i represents the vertical grading amount of the i-th horizontal structure line, and α i represents the part correlation degree parameter table of the i-th horizontal structure line. α i t represents the correlation degree when calculating the grading amount of the i-th horizontal structure line for the t-th part in the part step difference table K, and n represents the length of K; Calculating the transverse grading amount Δver of the vertical structure line: Among them, Δver i represents the horizontal grading amount of the i-th vertical structure line, and α i represents the table of part correlation degree parameters of the i-th vertical structure line. α i t represents the correlation degree when calculating the grading amount of the i-th vertical structure line for the t-th part in the part step difference table K, and n represents the length of K; Specifically, in the structural point coordinate offset calculation unit, the horizontal structural line offset dy is calculated based on the vertical grading amount Δhor of the horizontal structural line, and the vertical structural line offset dx is calculated based on the horizontal grading amount Δver of the vertical structural line. Specifically: Calculate the horizontal structural line offset dy: where dy i represents the offset of the i-th horizontal structure line in the y-axis direction; Calculate the vertical structural line offset dx: where, dx i represents the offset of the i-th vertical structure line in the x-axis direction; Specifically, in the structural point coordinate offset calculation unit, the coordinate offset S of the structural point is calculated based on the horizontal structural line offset dy and the vertical structural line offset dx Offset , specifically as follows: Among them, S i represents the i-th structural point, and S i Offset represents the coordinate offset of S i ; Specifically, in the contour edge position calculation and drawing unit, according to the coordinate offset S Offset Update the position coordinates of the contour points, specifically: Traverse all contour points. For each contour point P, perform the following steps: Query the region to which the contour point P belongs, denoted as A; Calculate the updated abscissa p of the contour point P x '; Calculate the updated ordinate p of the contour point P y ′; Among them, the abscissa p of the updated contour point P x ′ is specifically as follows: Query the number of horizontal structural edges in the region A; If there is only one horizontal structural edge L in region A, and S1 and S2 are two structural points on the structural edge L, the relative coordinates (x 12 , y 12 ) of the contour point P are obtained by using the following formula of the triangle structure-preserving algorithm: wherein Where v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively; Let \(v1'\) and \(v2'\) be the coordinates of the structural points \(v1\) and \(v2\) after offset, and \(S1\) Offset and \(S2\) Offset be the structural point offsets of \(S1\) and \(S2\) respectively. Then \(v1'\) and \(v2'\) are obtained as follows: v1′ = v1 + S1 Offset v2′ = v2 + S2 Offset Let \(p'\) be the point that keeps the structure of \(\triangle S_1S_2P\) unchanged. According to the definition of the relative coordinates of a triangle, the relative coordinates \((x 12 , y 12 )\) of the contour point \(P\) remain unchanged at this time. The reference coordinate \(p'\) corresponding to the structural edge \(L\) is obtained by using the following formula of the triangle structure-preserving algorithm: wherein Therefore, the abscissa of the updated contour point P If there are two horizontal structural edges L1 and L2 in region A, according to the above steps for calculating the reference coordinates, the reference coordinates p1' and p2' corresponding to the structural edges L1 and L2 are obtained, and the midpoint of p1' and p2' is taken as p': Then the updated abscissa of the contour point P Among them, the updated ordinate p y ′ of the calculated contour point P is specifically: Query the number of vertical structural edges in the region A; If there is only one vertical structural edge L in region A, and S1 and S2 are two structural points on the structural edge L, the relative coordinates (x 12 , y 12 ) of the contour point P are obtained by using the following formula of the triangle structure-preserving algorithm: wherein Where v1, v2, and p are the coordinates of the three points S1, S2, and P of △S1S2P respectively; Let \(v1'\) and \(v2'\) be the coordinates of the structure points \(v1\) and \(v2\) after offset, and \(S1\) Offset and \(S2\) Offset be the structure point offsets of \(S1\) and \(S2\) respectively. Then, \(v1'\) and \(v2'\) are obtained as follows: v1′ = v1 + S1 Offset v2′ = v2 + S2 Offset Let \(p'\) be the point that keeps the structure of \(\triangle S_1S_2P\) unchanged. According to the definition of the relative coordinates of a triangle, the relative coordinates \((x 12 ,y 12 )\) of the contour point \(P\) remain unchanged at this time. The reference coordinates \(p'\) corresponding to the structural edge \(L\) are obtained by using the following formula of the triangle structure-preserving algorithm: wherein Therefore, the updated ordinate of the contour point P If there are two vertical structural edges L1 and L2 in region A, according to the above steps for calculating the reference coordinates, the reference coordinates p1' and p2' corresponding to the structural edges L1 and L2 are obtained, and the midpoint of p1' and p2' is taken as p': Then the updated ordinate of the contour point P

Citation Information

Patent Citations

  • 3D (three-dimensional) apparel grading method based on human body characteristics

    CN102708231A

  • Automatic grading method and system and terminal equipment

    CN110652060A