Sewing operation regulation and control parameter acquisition method and device, electronic equipment and medium
By segmenting the outer contours of the upper and lower fabrics of the sewing machine, the synchronized segment lengths and parameters are obtained, solving the problem of parameter control deviation caused by inconsistent fabric lengths and improving sewing accuracy and efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- JACK SEWING MASCH CO LTD
- Filing Date
- 2025-12-31
- Publication Date
- 2026-04-17
AI Technical Summary
When existing sewing machines encounter inconsistent fabric lengths, they need to adopt a segmented sewing mode, which leads to deviations in parameter control and affects sewing accuracy and efficiency.
The camera identifies the outer contours of the upper and lower fabrics, performs first and second segmentation processing, obtains the synchronized segment lengths, and adjusts the stitch count and upper and lower pressure parameters.
It improves sewing precision and work efficiency, reduces the workload of manual adjustments and the skill threshold for operation, and lowers the deviation of parameter control.
Smart Images

Figure CN121875017A_ABST
Abstract
Description
Technical Field
[0001] This disclosure pertains to the field of sewing control, specifically relating to methods and devices for acquiring sewing operation control parameters, electronic equipment, and media. Background Technology
[0002] When sewing with a stitching machine, the seams of two overlapping pieces of fabric need to be aligned and stitched. Conventional equipment typically has upper and lower fabric control devices on the needle plate that operate vertically along the fabric feed direction. These devices, combined with edge sensors, detect the upper and lower fabric edges to achieve alignment control. Currently, most similar equipment on the market uses this type of edge control scheme. However, for sewing scenarios where the upper and lower fabric pieces are of different lengths, a segmented sewing mode is required. The sewing parameters for each segment differ, necessitating manual adjustment of the programmed parameters based on the actual sewing results. This not only increases the workload and skill level required of operators but also easily leads to parameter control deviations, affecting sewing accuracy and work efficiency. Therefore, current methods for obtaining control parameters are prone to deviations, impacting sewing accuracy and work efficiency. Summary of the Invention
[0003] This disclosure provides a method, apparatus, electronic device, and medium for acquiring sewing operation control parameters, which addresses the problem in existing technologies where control parameter deviations are prone to occur, affecting sewing accuracy and work efficiency.
[0004] In a first aspect, this disclosure provides a method for obtaining sewing operation control parameters, comprising: acquiring the outer contours of an upper fabric piece and a lower fabric piece as recognized by a camera; performing a first segmentation process on the outer contours of the upper fabric piece and the lower fabric piece to obtain each straight line segment of the outer contours of the upper fabric piece and the lower fabric piece; performing a second segmentation process on the outer contours of the upper fabric piece and the lower fabric piece based on the difference between the straight line segments in the upper fabric piece and the straight line segments in the lower fabric piece to obtain the segment lengths of the upper fabric piece and the lower fabric piece after synchronization; and obtaining the number of stitches and upper and lower pressure parameters of the synchronized segment based on the synchronized segment lengths, the upper stitch length, and the lower stitch length.
[0005] By performing first and second segmentation processes based on the outer contours of the upper and lower fabric pieces, the segment lengths of the upper and lower fabric pieces after synchronization are obtained. Finally, the stitch count and upper and lower pressure parameters of each segment after synchronization are obtained, which can adjust the deviation of the control parameters, thereby improving sewing accuracy and work efficiency.
[0006] In one embodiment of this disclosure, the method for performing a first segmentation process on the outer contours of the upper fabric and the lower fabric to obtain each straight line segment of the outer contours of the upper fabric and the lower fabric includes: Step S1, obtaining a plurality of points of the contour to be processed, wherein the contour to be processed is initially the outer contour of the upper fabric and the outer contour of the lower fabric; Step S2, if the distance corresponding to the longest vertical distance point among the points of the contour to be processed is greater than a preset vertical distance, then the boundary point of the contour to be processed is obtained based on the longest vertical distance point; otherwise, the boundary point of the contour to be processed is obtained. Step S3: When the contour to be processed has the dividing point, obtain the updated contour to be processed based on the dividing point and the contour to be processed and return to step S1. The contour to be processed in step S1 is the updated contour to be processed. The updated contour to be processed includes the contour determined by the first point of the contour to be processed and the dividing point and the contour determined by the dividing point and the tail point of the contour to be processed.
[0007] In one embodiment of this disclosure, when there is only one point between the dividing point and the first point of the contour to be processed, an abnormal message is issued, the abnormal message being that the fabric sampling failed or the fabric contour is complex.
[0008] In one embodiment of this disclosure, a method for obtaining the synchronized segment lengths of the upper and lower fabrics by performing a second segmentation process on the outer contours of the upper and lower fabrics based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric includes: Step S4, obtaining two straight line segments to be processed, the length value of the upper fabric, and the length value of the lower fabric, wherein the straight line segments to be processed are initially the first straight line segment of the outer contour of the upper fabric and the first straight line segment of the outer contour of the lower fabric; Step S5, if the difference between the length value of the upper fabric and the length value of the lower fabric does not exceed a preset length tolerance value, then the synchronized segment length corresponding to the straight line segment to be processed is the longer length among the straight line segments to be processed, and the length values of the upper fabric and the lower fabric are... The length value of the lower fabric piece is cleared to zero, and the length values of the line segment to be processed, the upper fabric piece, and the lower fabric piece are updated to obtain the updated line segment to be processed and the updated fabric length value. Otherwise, the synchronized segment length corresponding to the line segment to be processed is the shorter length among the line segments to be processed, and the shorter length is subtracted from both the upper fabric piece length value and the lower fabric piece length value. The fabric length values corresponding to the line segment to be processed and the shorter length are updated to obtain the updated line segment to be processed and the updated fabric length value. Step S6: Return to step S1, where the line segment to be processed in step S1 is the updated line segment to be processed, and the length values of the upper fabric piece and the lower fabric piece are the updated fabric length values.
[0009] In one embodiment of this disclosure, when the straight line segment to be processed is a redundant segment, the length of the redundant segment is the sum of the actual length of the redundant segment and the difference between the total length of the straight line segments in the upper fabric and the total length of the straight line segments in the lower fabric.
[0010] In one embodiment of this disclosure, the method further includes: the straight line segment includes a redundant segment, and the differential stitch pitch on the redundant segment is expressed as: the differential stitch pitch = ,in, It is expressed as the difference in length between the straight segments of the upper fabric and the total length of the straight segments of the lower fabric.
[0011] In one embodiment of this disclosure, the number of pins for the synchronized segment length is expressed as:
[0012] The number of needles in the synchronized segment length = .
[0013] Secondly, embodiments of this disclosure provide a sewing operation control parameter acquisition device, comprising: a contour acquisition module for acquiring the outer contours of an upper fabric piece and a lower fabric piece as recognized by a camera; a first segmentation module for performing a first segmentation process on the outer contours of the upper fabric piece and the lower fabric piece to acquire each straight line segment of the outer contours of the upper fabric piece and the lower fabric piece; a second segmentation module for performing a second segmentation process on the outer contours of the upper fabric piece and the lower fabric piece based on the difference between the straight line segments in the upper fabric piece and the straight line segments in the lower fabric piece to acquire the segment lengths of the upper fabric piece and the lower fabric piece after synchronization; and a stitch count acquisition module for acquiring the stitch count and upper and lower pressure parameters of the synchronized segment based on the synchronized segment lengths, upper stitch distance, and lower stitch distance.
[0014] Thirdly, embodiments of this disclosure also provide a computer-readable storage medium having a computer program stored thereon. When executed by a processor, the computer program implements the control parameter acquisition method described in any of the first aspects.
[0015] Fourthly, embodiments of this disclosure also provide an electronic device. The electronic device includes: a memory storing a computer program; and a processor communicatively connected to the memory, which, when the computer program is invoked, executes the control parameter acquisition method described in any of the first aspects.
[0016] The sewing operation control parameter acquisition method, device, electronic equipment, and medium described above have the following beneficial effects:
[0017] By performing first and second segmentation processes based on the outer contours of the upper and lower fabric pieces, the segment lengths of the upper and lower fabric pieces after synchronization are obtained. Finally, the stitch count and upper and lower pressure parameters of the synchronized segments are obtained, which can adjust the deviation of the control parameters, thereby improving sewing accuracy and work efficiency. Attached Figure Description
[0018] Figure 1 The diagram shown is a structural schematic of the stitching machine according to an embodiment of this disclosure.
[0019] Figure 2 The flowchart shown is a method for obtaining sewing operation control parameters according to an embodiment of this disclosure.
[0020] Figure 3 The diagram shows a straight line segment of the upper and lower fabric pieces in an embodiment of this disclosure.
[0021] Figure 4 The flowchart shown is a method for performing a first segmentation process on the outer contours of the upper and lower fabric pieces, as described in this embodiment of the present disclosure, to obtain each straight line segment of the outer contours of the upper and lower fabric pieces.
[0022] Figure 5 The flowchart shows a method for implementing a second segmentation process on the outer contours of the upper and lower fabrics based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, in accordance with an embodiment of this disclosure, to obtain the segment lengths of the upper and lower fabrics after synchronization.
[0023] Figure 6 The diagram shown is a structural schematic of the sewing operation control parameter acquisition device according to an embodiment of this disclosure.
[0024] Figure 7 The diagram shown is a structural schematic of an electronic device according to an embodiment of this disclosure. Detailed Implementation
[0025] The following specific examples illustrate the implementation of this disclosure. Those skilled in the art can easily understand other advantages and effects of this disclosure from the content disclosed in this specification. This disclosure can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of this disclosure. It should be noted that, unless otherwise specified, the following embodiments and features in the embodiments can be combined with each other.
[0026] It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of this disclosure. Therefore, the illustrations only show the components related to this disclosure and are not drawn according to the number, shape and size of the components in actual implementation. In actual implementation, the form, quantity and proportion of each component can be arbitrarily changed, and the layout of the components may also be more complex.
[0027] The technical solutions of the present disclosure will be described in detail below with reference to the accompanying drawings.
[0028] The sewing operation control parameter acquisition method provided in this embodiment can be run in a sewing machine. Figure 1 This is a structural schematic diagram of the stitching machine. Figure 1 In this diagram, 1 is the upper differential feed head, 2 is the upper and lower edge control device, 3 is the auxiliary platform, 4 is the camera, 5 is the electronic control panel, and 6 is the camera bracket. The upper differential feed head 1 feeds the upper layer of fabric synchronously and at the same speed, or at a different speed, corresponding to the upper differential stitch distance. The electronic control panel 5 and the camera bracket 6 are mounted on the auxiliary platform 3, and the camera is mounted on the camera bracket 6.
[0029] The following will elaborate on the principles and implementation methods of the sewing operation control parameter acquisition method and device, electronic device and storage medium of this disclosure, so that those skilled in the art can understand the sewing operation control parameter acquisition method and device, electronic device and storage medium of this disclosure without creative labor.
[0030] Figure 2 This is a flowchart illustrating a method for obtaining sewing operation control parameters according to an embodiment of the present disclosure. Figure 2 As shown, the sewing operation control parameter acquisition method provided in this embodiment can be executed by a processor, and the method includes the following steps S11 to S14.
[0031] Step S11: Obtain the outer contours of the upper and lower fabric pieces as recognized by the camera. Step S12: Perform a first segmentation process on the outer contours of the upper and lower fabric pieces to obtain each straight line segment of the outer contours of the upper and lower fabric pieces.
[0032] Optionally, the outer contours of the upper and lower fabric pieces have corresponding points arranged in a clockwise order, such as P1, P2, P3...Pn, etc., and the number of points can be determined according to the specific accuracy of the camera. The straight line segment can refer to a straight line segment formed by connecting the points. The various straight line segments of the upper fabric piece and the various straight line segments of the lower fabric piece can be arranged sequentially in a clockwise order.
[0033] Optionally, the straight segment includes a redundant segment, and the differential needle pitch on the redundant segment is expressed as:
[0034] The differential needle spacing =
[0035] in, It is expressed as the difference between the total length of the straight line segments in the upper fabric and the total length of the straight line segments in the lower fabric, that is, the total length of the straight line segments in the upper fabric minus the total length of the straight line segments in the lower fabric.
[0036] Optionally, the differential stitch length can be the upper stitch length.
[0037] Step S13: Based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, perform a second segmentation process on the outer contours of the upper fabric and the lower fabric to obtain the segment lengths after the upper fabric and the lower fabric are synchronized.
[0038] Optionally, the synchronized segmentation may refer to the fact that the length and number of straight segments of the upper fabric and the lower fabric are the same, and the straight segments are the synchronized segments. Figure 3 The diagram shows straight line segments of the upper and lower fabric pieces according to an embodiment of this disclosure. The straight line segments in the upper and lower fabric pieces can be as follows: Figure 3 As shown, this embodiment will not elaborate further.
[0039] Step S14: Based on the synchronized segment length, upper stitch distance, and lower stitch distance, obtain the number of stitches and upper and lower pressure parameters of the synchronized segment.
[0040] Optionally, the number of pins for the synchronized segment length is expressed as:
[0041] The number of needles in the synchronized segment length =
[0042] Optionally, the stitch length can refer to the upper stitch length, which is generally equal to the lower stitch length. The upper and lower pressure parameters can refer to the relevant pressure parameters of the upper and lower edge control devices, which are generally determined by factory parameters. The number of stitches in the synchronized segments and the upper and lower pressure parameters can be used to solve problems such as misalignment of upper and lower fabric layers, uneven ends, and uneven edges. The upper and lower pressure parameters can refer to the pressure parameters applied to the fabric by the upper and lower gears on the sewing machine's robotic arm.
[0043] As described above, the sewing operation control parameter acquisition method includes: acquiring the outer contours of the upper and lower fabric pieces recognized by the camera; performing a first segmentation process on the outer contours of the upper and lower fabric pieces to obtain each straight line segment of the outer contours of the upper and lower fabric pieces; performing a second segmentation process on the outer contours of the upper and lower fabric pieces based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric to obtain the segment lengths of the upper and lower fabric pieces after synchronization; and obtaining the number of stitches and upper and lower pressure parameters of the synchronized segments based on the synchronized segment lengths, upper stitch length, and lower stitch length.
[0044] By performing first and second segmentation processes based on the outer contours of the upper and lower fabric pieces, the segment lengths of the upper and lower fabric pieces after synchronization are obtained. Finally, the stitch count and upper and lower pressure parameters of the synchronized segments are obtained, which can adjust the deviation of the control parameters, thereby improving sewing accuracy and work efficiency.
[0045] Figure 4 This is a flowchart illustrating a method for performing a first segmentation process on the outer contours of the upper and lower fabric pieces according to an embodiment of this disclosure to obtain individual straight line segments of the outer contours of the upper and lower fabric pieces. Figure 4 As shown, the method for performing a first segmentation process on the outer contours of the upper fabric and the lower fabric to obtain each straight line segment of the outer contours of the upper fabric and the lower fabric, provided in this embodiment of the present disclosure, includes the following steps S1 to S3.
[0046] Step S1: Obtain the points of several contours to be processed. The contours to be processed are initially the outer contours of the upper fabric and the lower fabric.
[0047] Step S2: If the distance corresponding to the longest vertical distance point among the points in the contour to be processed is greater than the preset vertical distance, then the boundary point of the contour to be processed is obtained based on the longest vertical distance point; otherwise, the straight line segment determined by the first and last points in the contour to be processed is obtained. The longest vertical distance point is the point with the longest distance from the points in the contour to be processed to the straight line segment determined by the first and last points.
[0048] Optionally, the distance corresponding to the longest vertical distance point is the distance of the straight line segment determined from the longest vertical distance point to the beginning and end points. The preset vertical distance can be flexibly set according to actual conditions, and this embodiment does not explicitly limit it.
[0049] Optionally, each straight line segment of the outer contour of the upper and lower fabric pieces can be composed of straight line segments determined by the beginning and end points of the contour to be processed.
[0050] Step S3: When the boundary point is present in the contour to be processed, obtain the updated contour to be processed based on the boundary point and the contour to be processed, and return to step S1. The contour to be processed in step S1 is the updated contour to be processed. The updated contour to be processed includes the contour determined by the first point of the contour to be processed and the boundary point, and the contour determined by the boundary point and the last point of the contour to be processed.
[0051] Optionally, the updated outline to be processed includes two outlines divided by the dividing point. The outline determined by the first point of the outline to be processed and the dividing point can be regarded as an outline cut off from the outer outline of the upper or lower fabric piece, and the first point of the cut outline is the first point of the outline to be processed, and the last point of the cut outline is the last point of the outline to be processed.
[0052] Optionally, when there is only one point between the dividing point and the first point of the contour to be processed, an abnormal message is issued. The abnormal message indicates that the fabric sampling has failed or the fabric contour is complex. The abnormal message can be used to remind workers to reoperate or improve the accuracy of fabric segmentation.
[0053] Figure 5 This is a flowchart illustrating a method for performing a second segmentation process on the outer contours of the upper and lower fabrics based on the difference between straight line segments in the upper fabric and straight line segments in the lower fabric, according to an embodiment of this disclosure, to obtain the segment lengths after synchronization of the upper and lower fabrics. Figure 5As shown, the method provided in this embodiment of the present disclosure for performing a second segmentation process on the outer contours of the upper fabric and the lower fabric based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, so as to obtain the segment lengths after the upper fabric and the lower fabric are synchronized, includes the following steps S4 to S6.
[0054] Step S4: Obtain two straight line segments to be processed, the length value of the upper fabric piece, and the length value of the lower fabric piece. The straight line segments to be processed are initially the first straight line segment of the outer contour of the upper fabric piece and the first straight line segment of the outer contour of the lower fabric piece.
[0055] Optionally, one of the two line segments to be processed corresponds to the line segment of the upper piece of fabric, and the other corresponds to the line segment of the lower piece of fabric. The length value of the upper piece of fabric can be represented by sum1, and the length value of the lower piece of fabric can be represented by sum2.
[0056] Step S5: If the difference between the length values of the upper and lower fabric pieces does not exceed a preset length tolerance value, then the synchronized segment length corresponding to the line segment to be processed is the longer length among the line segments to be processed. The length values of the upper and lower fabric pieces are then cleared to zero, and the length values of the line segment to be processed, the upper fabric piece length, and the lower fabric piece length are updated to obtain an updated line segment to be processed and an updated fabric length value. Otherwise, the synchronized segment length corresponding to the line segment to be processed is the shorter length among the line segments to be processed. The shorter length is subtracted from both the upper and lower fabric piece length values, and the fabric length values corresponding to the line segment to be processed and the shorter length are updated to obtain an updated line segment to be processed and an updated fabric length value.
[0057] Optionally, when the difference between the length value of the upper fabric piece and the length value of the lower fabric piece does not exceed a preset length tolerance value, the updated straight line segment to be processed includes the next straight line segment of the straight line segment to be processed, that is, the next straight line segment corresponding to the straight line segment of the upper fabric piece and the next straight line segment corresponding to the straight line segment of the lower fabric piece. The updated fabric length value includes the updated upper fabric length value and the updated lower fabric length value. The updated upper fabric length value can be the length value of the straight line segment of the upper fabric piece in the updated straight line segment to be processed, and the updated lower fabric length value can be the length value of the straight line segment of the lower fabric piece in the updated straight line segment to be processed.
[0058] Optionally, when the difference between the length of the upper fabric piece and the length of the lower fabric piece exceeds a preset length tolerance value, the updated straight line segment to be processed includes the longer straight line segment and the next straight line segment of the shorter straight line segment. The fabric length value corresponding to the shorter length can refer to the fabric length value of the upper fabric piece when the shorter length is the shorter length, and the fabric length value of the lower fabric piece when the shorter length is the shorter length. The updated fabric length value is obtained by adding the length value of the next straight line segment of the shorter straight line segment to the corresponding fabric length value after both the length values of the upper and lower fabric pieces have been reduced by the shorter length. The fabric length value corresponding to the longer straight line segment remains unchanged. The corresponding fabric length value can be the length value of the upper fabric piece or the length value of the lower fabric piece, depending on the situation. This embodiment will not elaborate further on this.
[0059] Optionally, the length of the straight line segment to be processed can refer to the calculated length of the straight line segment to be processed. When the straight line segment to be processed is a non-redundant segment, the calculated length is equal to the actual length of the straight line segment to be processed. When the straight line segment to be processed is a redundant segment, the calculated length of the redundant segment is the sum of the actual length of the redundant segment and the total difference between the straight line segments in the upper fabric and the lower fabric. That is, the length of the redundant segment = the actual length of the redundant segment + the total difference between the straight line segments in the upper fabric and the lower fabric. The actual length of the straight line segment is the true length of the straight line segment.
[0060] Optionally, the preset length tolerance value can be flexibly set according to the actual situation. This embodiment does not explicitly limit this. The difference between the length value of the upper fabric and the length value of the lower fabric can be the absolute value of the difference.
[0061] Step S6, return to step S1, the line segment to be processed in step S1 is the updated line segment to be processed, and the length values of the upper fabric and the lower fabric are the updated fabric length values.
[0062] In one embodiment of this disclosure, the method for obtaining the control parameters includes:
[0063] 1. Initial Sampling and Auto-Programming: After selecting the fabric recognition auto-programming mode on the control panel 5, place the upper fabric sewing segment in the corresponding area of the auxiliary platform 3. After the camera 4 recognizes the fabric edge outline, select the start point, end point, and redundancy point on the control panel 5 (the redundancy point is usually on the upper piece). Take out the upper fabric sewing segment and place it on the lower fabric, which will then be recognized again by the camera 4. Relevant parameters will be automatically output subsequently.
[0064] 2. Automatic compensation of programming parameters: After the initial sampling and programming, some problems may still occur. At this time, the corresponding problem can be selected on the control panel 5 to automatically compensate the parameters.
[0065] Automatic programming principle:
[0066] 1. Fabric recognition and automatic segmentation and straightening: After the camera recognizes the fabric, its outer contour is converted into corresponding orderly clockwise points P1, P2, P3...Pn (the number of points depends on the camera's accuracy). The nearest needle end is identified as P1, and the electrical point Pn is located; connecting these two points forms a straight line. Simultaneously, from... arrive Find the point with the longest perpendicular distance to the line. Its vertical distance is If the fabric segmentation accuracy is specified as A, then the following judgment can be made:
[0067] (1) When When A is true, it means that there is at least one point between the two points. The deviation from a straight line is too great, making it impossible to convert the outline of this section into a straight line. Key points should be preserved. Divide it into two segments, namely P1 to P2. and arrive The process of connecting the points into a straight line, finding the farthest point, and making a judgment is repeated recursively.
[0068] (2) When When the value is less than or equal to A, it means that all points between the two points are within the specified precision, i.e., the outline of this segment is approximately a straight line and can be converted into a straight line. Record the start and end points of this straight line segment. , , ...... and arranged in an orderly manner
[0069] (3) When When >A, but the points selected by the line are only one point apart, that is, the line becomes arrive Only in the middle This indicates that the fabric sampling failed or the fabric outline is complex. You can remind the worker to repeat the operation or improve the fabric segmentation accuracy A.
[0070] At this point, the endpoints of each line segment are obtained. , , ...... At this point, all the straight line segments are connected and closed. (Regarding...) arrive ,and There is a certain probability that the two straight lines are actually a single straight line, so we choose... arrive This is done by forming a straight line (this segment is counter-clockwise), and repeating the steps of finding the farthest point and making judgments. Finally, the endpoints of each straight line segment are found. , , ...... .
[0071] 2. Select the sewing start point, end point, and redundant end point: After the fabric is divided into segments as described above, select the endpoints of each straight line segment. , , ...... The images and endpoint positions are displayed on the electronic control panel 5 and saved. The operator selects the sewing start point, end point, and redundant endpoint.
[0072] 3. Synchronization of Upper and Lower Fabric Segments: After both upper and lower fabric pieces have been segmented and straightened, they are synchronized under certain circumstances. However, differences may occur in the segment lengths and number of segments between the upper and lower pieces, such as... Figure 3 As shown in the curved fabric pattern, the upper fabric has multiple straight lines, while the lower fabric has only one. Furthermore, the sum of the straight lines on the upper and lower fabric pieces is often not the same length, and the difference can be significant. This is because there are redundant sections during the fabric sewing process. In these sections, the stitch lengths of the sewing head and the feed head differ, requiring the corresponding length to be filled in. Therefore, multiple steps are needed to synchronize the upper and lower fabric pieces:
[0073] (1) Total length compensation of upper and lower pieces: Calculate the total length of the straight segments of the upper and lower pieces of fabric. and And calculate the difference. Assuming the redundant section contains an upper piece of fabric, the differential stitch length on that section should be:
[0074]
[0075] Furthermore, when multiple discontinuous redundant segments are involved, they are typically allocated proportionally according to their length.
[0076] (2) Secondary segmentation of upper and lower pieces: The specified length value is (The length of the upper piece of fabric mentioned above) and (The length value of the lower piece of fabric mentioned above), length tolerance value B (the preset length tolerance value mentioned above). Both the upper and lower pieces start from the starting point, and each segment is added sequentially. In, and calculate And determine:
[0077] ①If the difference If the length is less than or equal to B, then the two segments can be approximated as having the same length, and the length of the longer segment can be taken as the actual length L. Meanwhile... and Clear to zero and add the next paragraph. and .
[0078] ②If the difference If the length is greater than B, then the two segments are considered to have a larger difference in length, and the shorter segment's length is taken as the actual length L. Meanwhile... and Subtract the length of the shorter clip, and add the corresponding segment to the next segment of the shorter clip. middle.
[0079] Furthermore, the computational length of the redundant segment should be equal to... +Length of the redundant segment (the actual length mentioned above).
[0080] 4. Automatic programming output parameters: The corresponding parameters obtained after segmented synchronization. Output the number of stitches for each corresponding segment. And the upper stitch length (usually equal to the lower stitch length), and the upper and lower pressure parameters (determined by factory specifications).
[0081] The straight sections of the upper and lower fabric pieces can be divided into redundant sections or non-redundant sections. The upper and lower pressure parameters of the non-redundant sections can be determined by the factory parameters. The upper and lower pressure parameters of the redundant sections can generally be larger than those of the non-redundant sections. The amount by which the upper and lower pressure parameters of the redundant sections are larger than those of the non-redundant sections can be expressed as:
[0082]
[0083] in The coefficients derived from experience will not be elaborated upon in this embodiment.
[0084] Automatic compensation principle:
[0085] 1. After automatic programming, trial sewing can be performed. Due to factors such as fabric material, insufficient segmentation precision, and discrepancies in actual stitch length, issues such as misalignment of upper and lower fabric pieces, uneven ends, and uneven edges may occur. In this case, the electronic control system re-enters the first step of segmented straightening processing, selects the start and end points, and performs secondary parameter adjustments.
[0086] (1) If a single segment misalignment occurs, it may be that the segmentation accuracy of that segment is insufficient, and a more precise segmentation operation is required for the segment that has misalignment.
[0087] (2) If similar misalignment occurs in multiple segments, it indicates that there is a certain difference in the stitch spacing between the upper and lower segments. Then, depending on the upper and lower segments to which the misalignment belongs, the corresponding stitch spacing should be increased or decreased.
[0088] (3) If the ends are not uniform and there are no misaligned layers except for the redundant segments, it means that the stitch spacing parameters of the redundant segments are incorrect and need to be readjusted.
[0089] (4) If the edges are not aligned, it indicates that the pressure of the upper and lower edge control devices is insufficient. Adjust the relevant pressure parameters.
[0090] After the operator provides feedback on the actual sewing situation, the machine automatically makes corresponding compensations to achieve the best results.
[0091] Figure 6 This is a schematic diagram illustrating the structure of the sewing operation control parameter acquisition device 600 according to an embodiment of the present disclosure. Figure 6 As shown, the sewing operation control parameter acquisition device 600 includes:
[0092] The contour acquisition module 610 is used to acquire the outer contours of the upper and lower fabric pieces as recognized by the camera.
[0093] The first segmentation module 620 is used to perform a first segmentation process on the outer contours of the upper fabric and the lower fabric to obtain each straight line segment of the outer contours of the upper fabric and the lower fabric.
[0094] The second segmentation module 630 is used to perform a second segmentation process on the outer contours of the upper and lower fabrics based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, so as to obtain the segment lengths after the upper and lower fabrics are synchronized.
[0095] The needle count acquisition module 640 is used to acquire the needle count and upper and lower pressure parameters of the synchronized segment based on the synchronized segment length, upper needle distance, and lower needle distance.
[0096] In the sewing operation control parameter acquisition device 600, the contour acquisition module 610 and Figure 2 In the method for obtaining control parameters, step S11 corresponds one-to-one, the first segmentation module 620 corresponds one-to-one with step S12, the second segmentation module 630 corresponds one-to-one with step S13, and the needle count acquisition module 640 corresponds one-to-one with step S14.
[0097] Figure 7 The diagram shown is a structural schematic of an electronic device according to an embodiment of this disclosure. Figure 7 As shown, the electronic device provided in this embodiment includes a processor and a memory. The memory is configured to store an executable program. The processor is configured to execute the program to cause the electronic device to perform the control parameter acquisition method according to any of the preceding claims.
[0098] Preferably, the processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The memory can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0099] This embodiment also includes one or more of the following: a multimedia component, an input / output (I / O) interface, and a communication component.
[0100] The multimedia component may include a screen and an audio component. The screen may be, for example, a touchscreen, and the audio component is configured to output and / or input audio signals. For example, the audio component may include a microphone configured to receive external audio signals. The received audio signals may be further stored in memory or transmitted via a communication component. The audio component also includes at least one speaker configured to output audio signals. The I / O interface provides an interface between the processor and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual or physical buttons. The communication component is configured to enable wired or wireless communication between the timer and other devices. Wireless communication may include Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G, or 4G, or a combination thereof; therefore, the corresponding communication component may include a Wi-Fi module, a Bluetooth module, or an NFC module.
[0101] In the several embodiments provided in this disclosure, it should be understood that the disclosed systems, apparatuses, or methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules / units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or units may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection of apparatuses or modules or units may be electrical, mechanical, or other forms.
[0102] The modules / units described as separate components may or may not be physically separate. The components shown as modules / units may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules / units can be selected to achieve the objectives of the embodiments of this disclosure, depending on actual needs. For example, the functional modules / units in the various embodiments of this disclosure may be integrated into one processing module, or each module / unit may exist physically separately, or two or more modules / units may be integrated into one module / unit.
[0103] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this disclosure.
[0104] This disclosure also provides a computer-readable storage medium storing a computer program thereon. When executed by a processor, the computer program implements the image processing method and apparatus, electronic device, and storage medium provided in this disclosure. Those skilled in the art will understand that all or part of the steps in the methods of the above embodiments can be implemented by a program instructing a processor. The program can be stored in a computer-readable storage medium, which is a non-transitory medium, such as random access memory, read-only memory, flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disk, and any combination thereof. The storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital video disc (DVD)), or a semiconductor medium (e.g., solid-state disk (SSD)).
[0105] The above embodiments are merely illustrative of the principles and effects of this disclosure and are not intended to limit this disclosure. Any person skilled in the art can modify or alter the above embodiments without departing from the spirit and scope of this disclosure. Therefore, all equivalent modifications or alterations made by those skilled in the art without departing from the spirit and technical concept disclosed in this disclosure should still be covered by the claims of this disclosure.
Claims
1. A method for obtaining control parameters for sewing operations, characterized in that, include: Obtain the outer contours of the upper and lower pieces of fabric as recognized by the camera; The outer contours of the upper and lower fabric pieces are first segmented to obtain each straight line segment of the outer contours of the upper and lower fabric pieces; Based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, the outer contours of the upper fabric and the lower fabric are subjected to a second segmentation process to obtain the segment lengths after the upper fabric and the lower fabric are synchronized. Based on the synchronized segment length, upper stitch distance, and lower stitch distance, the number of stitches and upper and lower pressure parameters of the synchronized segment are obtained.
2. The method for obtaining control parameters according to claim 1, characterized in that, The method for performing a first segmentation process on the outer contours of the upper and lower fabric pieces to obtain each straight line segment of the outer contours of the upper and lower fabric pieces includes: Step S1: Obtain the points of several contours to be processed. The contours to be processed are initially the outer contours of the upper fabric and the lower fabric. Step S2: If the distance corresponding to the longest vertical distance point among the points in the contour to be processed is greater than the preset vertical distance, then the boundary point of the contour to be processed is obtained based on the longest vertical distance point; otherwise, the straight line segment determined by the first and last points in the contour to be processed is obtained. The longest vertical distance point is the point with the longest distance from the points in the contour to be processed to the straight line segment determined by the first and last points. Step S3: When the boundary point is present in the contour to be processed, obtain the updated contour to be processed based on the boundary point and the contour to be processed, and return to step S1. The contour to be processed in step S1 is the updated contour to be processed. The updated contour to be processed includes the contour determined by the first point of the contour to be processed and the boundary point, and the contour determined by the boundary point and the last point of the contour to be processed.
3. The method for obtaining control parameters according to claim 2, characterized in that, When there is only one point between the dividing point and the first point of the contour to be processed, an abnormal message is issued, which indicates that the fabric sampling has failed or the fabric contour is complex.
4. The method for obtaining control parameters according to claim 1, characterized in that, Based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, a second segmentation process is performed on the outer contours of the upper and lower fabrics to obtain the segment lengths after synchronization of the upper and lower fabrics. The method for achieving this includes: Step S4: Obtain two straight line segments to be processed, the length value of the upper fabric piece, and the length value of the lower fabric piece. The straight line segments to be processed are initially the first straight line segment of the outer contour of the upper fabric piece and the first straight line segment of the outer contour of the lower fabric piece. Step S5: If the difference between the length value of the upper fabric piece and the length value of the lower fabric piece does not exceed a preset length tolerance value, then the synchronized segment length corresponding to the straight line segment to be processed is the longer length among the straight line segments to be processed. The length values of the upper fabric piece and the lower fabric piece are then cleared to zero, and the length values of the straight line segment to be processed, the upper fabric piece, and the lower fabric piece are updated to obtain an updated straight line segment to be processed and an updated fabric length value. Otherwise, the synchronized segment length corresponding to the straight line to be processed is the shorter length among the straight line segments to be processed. The shorter length is subtracted from both the length values of the upper fabric piece and the lower fabric piece, and the fabric length values corresponding to the straight line segment to be processed and the shorter length are updated to obtain an updated straight line segment to be processed and an updated fabric length value. Step S6, return to step S1, the line segment to be processed in step S1 is the updated line segment to be processed, and the length values of the upper fabric and the lower fabric are the updated fabric length values.
5. The method for obtaining control parameters according to claim 3, characterized in that, When the straight line segment to be processed is a redundant segment, the length of the redundant segment is the sum of the actual length of the redundant segment and the difference between the total length of the straight line segments in the upper fabric and the lower fabric.
6. The method for obtaining control parameters according to claim 1, characterized in that, Also includes: The straight segment includes a redundant segment, and the differential needle pitch on the redundant segment is expressed as follows: The differential needle spacing = in, It is expressed as the difference in length between the straight segments of the upper fabric and the total length of the straight segments of the lower fabric.
7. The method for obtaining control parameters according to claim 1, characterized in that, The number of pins for the synchronized segment length is expressed as: The number of needles in the synchronized segment length = .
8. A device for acquiring control parameters for sewing operations, characterized in that, include: The contour acquisition module is used to acquire the outer contours of the upper and lower pieces of fabric as recognized by the camera. The first segmentation module is used to perform a first segmentation process on the outer contours of the upper fabric and the lower fabric to obtain each straight line segment of the outer contours of the upper fabric and the lower fabric. The second segmentation module is used to perform a second segmentation process on the outer contours of the upper and lower fabrics based on the difference between the straight line segments in the upper fabric and the straight line segments in the lower fabric, so as to obtain the segment lengths after the upper and lower fabrics are synchronized. The needle count acquisition module is used to acquire the needle count and upper and lower pressure parameters of the synchronized segment based on the synchronized segment length, upper needle distance, and lower needle distance.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the method for obtaining control parameters according to any one of claims 1 to 7.
10. An electronic device, characterized in that, include: The memory is configured to store a computer program; The processor is electrically coupled to the memory and configured to perform the control parameter acquisition method according to any one of claims 1 to 7.