Quantitative modeling method for flat wire forming parameters and forming angle based on cascaded machine learning
By constructing a quantitative model of flat wire forming parameters and forming angle using a cascaded machine learning method, the problem of difficult control of the forming angle of flat wire motors was solved, achieving efficient process optimization and improved motor forming accuracy.
Patent Information
- Application Number
- CN202511502893.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-21
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2045-10-21
AI Technical Summary
In existing technologies, the forming angle of flat wire motors is difficult to predict and control precisely, resulting in long process debugging cycles, high costs, and the inability to achieve mass production consistency and efficiency of high-end motors.
A quantitative modeling method for flat wire forming parameters and forming angles is constructed using a cascaded machine learning approach. Through data acquisition, feature engineering, and multi-model construction, the complex mapping relationship between geometric parameters and forming angles is revealed, thereby improving forming accuracy and stability.
It enables accurate prediction of the forming angle of flat wire motors, improves process development efficiency and forming quality, and ensures the consistency and efficiency of mass production of motors.
Smart Images

Figure CN120974950B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to a new energy vehicle flat wire motor hairpin winding bending forming parameter prediction method, mainly studies the forming angle prediction of flat wire enameled wire and the mapping relationship between the forming geometric parameters (wire width, thickness, width-thickness ratio) and the forming angle, specifically relates to a quantitative modeling method for flat wire forming parameters and forming angle based on cascading machine learning, and belongs to the technical field of new energy motor manufacturing. BACKGROUND
[0002] With the rapid development of new energy vehicle industry, higher requirements are put forward for the power density, efficiency and reliability of the driving motor. Flat wire motor has become the mainstream choice of the next generation of electric drive system due to its high slot fill rate and significant efficiency advantage. However, in the process of 2D CNC multi-step bending forming of enameled flat wire winding, due to the coupling of material rebound and geometric effect, the final forming angle is difficult to predict and control. At present, the internal influence law and quantitative relationship between flat wire geometric parameters and multi-step forming angle are still blank, which leads to the technical bottleneck of coordinated prediction and control of three forming angles, and seriously restricts the consistency and efficiency of high-end motor mass production.
[0003] At present, the bending forming mechanism of polyimide enameled flat copper wire still stays in the stage of experience cognition, and there is a lack of systematic explanation and quantitative model for how key parameters such as wire width, thickness, width-thickness ratio and cross-sectional moment of inertia affect the forming angle at each stage. This leads to the fact that the process development generally relies on the "trial and error - correction" mode, which not only has a long debugging cycle and high cost, but also the experience formed cannot be transferred across specifications, and it is impossible to build a reusable process knowledge system.
[0004] Therefore, there is an urgent need for a quantitative modeling method for enameled flat copper wire flat wire forming parameters and forming angles that can reveal the complex mapping relationship between geometric parameters and forming angles in the multi-step bending process, in order to fill the gap in mechanism cognition and systematic design methods in this field, and provide a theoretical cornerstone for intelligent design and accurate prediction of the process. SUMMARY
[0005] The present application aims to solve the technical problem that the three forming angles of wire with different geometric parameters are difficult to accurately control in the bending process. By establishing the quantitative mapping relationship between the forming geometric parameters and the three forming angles, the internal influence law is studied, the best process scheme for flat wire bending is provided, and the double improvement of forming precision and stability is realized.
[0006] The technical problem of the present application is solved by adopting the following technical scheme:
[0007] The quantitative modeling method for flat wire forming parameters and forming angles based on cascading machine learning includes the following steps:
[0008] S1: Data acquisition:
[0009] The data is derived from the process data of the bending of enameled flat wire in the 2D forming production process of new energy vehicle flat wire motor hairpin winding;
[0010] S2: Feature engineering:
[0011] On the basis of 10-dimensional original geometric parameters, 3-dimensional physical derived features such as width-thickness ratio, cross-sectional second moment, and arm ratio are constructed to form a 13-15 dimensional cascaded input feature set, which systematically represents the geometric properties and mechanical properties of the multi-step forming process, laying the foundation for the cascaded prediction model;
[0012] S3 Multi-model construction and parameter optimization
[0013] Based on RF, XGBoost and LightGBM algorithms, a cascaded chain regression model is constructed. Through independent test set verification, the model is optimized in stages, and the optimal algorithm is selected independently for each stage. In the first stage, the first forming angle θ1_pred is predicted based on 13-dimensional geometric features, in the second stage, the first forming angle θ1_pred is introduced to construct a 14-dimensional input to predict the second forming angle θ2_pred, and in the third stage, the third forming angle θ3_pred is predicted by fusing the previous prediction results to form a 15-dimensional input. This structure effectively captures the physical correlation and feature dependency in the multi-step forming process by gradually passing on the previous prediction information, ensuring the overall prediction accuracy;
[0014] S4: Model evaluation and optimization:
[0015] Through the Hold-out test method, the entire data set is randomly divided in the ratio of 8:2. Among them, 80% of the data is used as the training set to build and train the model; the other 20% of the data is strictly sealed as the test set during the entire model development period, and is only used for one-time, unbiased evaluation of the performance of the final model;
[0016] S5: Cascaded forming mechanism and feature evolution rule revelation:
[0017] This method uses the SHAP method to analyze the explainability of the cascaded chain regression model, and systematically reveals the influence mechanism of each process parameter in the three-stage forming process. Combined with the Gini feature importance and SHAP analysis results, a deep understanding of the physical mechanism of multi-step bending forming is formed;
[0018] S6: Feature optimization and engineering application:
[0019] By setting the target span or forming angle allowable error, the optimization algorithm is used to solve the optimal bending process parameters in reverse, thereby realizing the transformation from traditional "trial and error" machine adjustment to "prediction", and greatly improving the process development efficiency and forming quality.
[0020] Compared with the prior art, the present application has the following advantages:
[0021] (1) The SHAP explainability analysis is adopted to quantify the dynamic evolution rule from "geometric parameter dominance" to "deformation history dominance" in multi-step forming, such as the influence intensity (SHAP value 0.0637) of the second forming angle θ2_pred on the final result, which is 16.3 times that of the second, providing clear theoretical guidance for process optimization;
[0022] (2) The cascaded chain random forest model is innovatively constructed, and the structure strictly matches the physical time sequence, the importance of the previous forming angle in the subsequent stage is in the front row (such as the Gini importance of the first forming angle θ1_pred in the second stage is 0.3019), which ensures the physical rationality and high precision of the prediction result;
[0023] (3) Strong engineering practicability: based on actual production data modeling, the model has good generalization ability and engineering applicability;
[0024] (4) The cumulative contribution of the top five features in the SHAP importance of the three-stage forming angle prediction model is more than 85%, and the explanation degree of the second forming angle θ2_pred on the final result is 94.94%. BRIEF DESCRIPTION OF DRAWINGS
[0025] Figure 1 is a flowchart of the cascaded flat wire forming geometric parameter and forming angle rule analysis based on machine learning;
[0026] Figure 2 is a comparison diagram of the model prediction results and the true values of the three forming angles;
[0027] Figure 3 is a comparison diagram of the Gini feature importance of the random forest model for three-stage forming angle prediction;
[0028] Figure 4 is a random forest model SHAP feature importance ranking diagram for three-stage forming angle prediction;
[0029] Figure 5 is a random forest model SHAP feature influence analysis for three-stage forming angle prediction;
[0030] Figure 6 is a random forest model SHAP dependence diagram for three-stage forming angle prediction; DETAILED DESCRIPTION
[0031] The present application will be further described in detail below in combination with the drawings and examples.
[0032] The embodiment of the application adopts historical process data of a new energy automobile driving motor production line. The data is for polyimide enameled copper flat wire and covers wire parameters and bending process parameters of various specifications (wire width from 3.0 mm to 10.0 mm, wire thickness from 1.8 mm to 5.0 mm), a total of 745 groups of effective data. All data are collected through high-precision online measurement equipment, ensuring the authenticity and reliability of the data.
[0033] The above 745 groups of data are randomly divided into a training set (596 groups) and a test set (149 groups) in a ratio of 8:2. After data standardization processing of the input features (w, h), the LightGBM, XGBoost and RF regression algorithms are used for model training, and the steps are as follows:
[0034] S1 data collection:
[0035] The data is derived from the process data of enameled flat wire bending in the 2D forming production process of new energy automobile flat wire motor hairpin winding;
[0036] S2 feature engineering:
[0037] 2.1 original 10-dimensional geometric parameters:
[0038] Basic geometric parameters: wire width w (mm), wire thickness h (mm), crown segment height h1 (mm);
[0039] Bending angles: first bending angle θ1 (°), second bending angle θ2 (°), third bending angle θ3 (°);
[0040] Straight line segment lengths: first straight line segment b1 (mm), second straight line segment b2 (mm), third straight line segment b3 (mm), fourth straight line segment b4 (mm);
[0041] 2.2 3-dimensional physical mechanism derivation:
[0042] Basic geometric features: width-to-thickness ratio R, cross-sectional second moment I, arm ratio ;
[0043] Width-to-thickness ratio: R = w / h, cross-sectional second moment: , arm ratio: ;
[0044] 2.3 three forming angles Input parameter selection, :
[0045] First forming angle Input selection: 13 dimensions, wire width w, wire thickness h, crown segment height h1, first bending angle θ1, second bending angle θ2, third bending angle θ3, first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4, width-thickness ratio R, cross-sectional second moment I, force arm ratio ;
[0046] Second forming angle Input selection: 14 dimensions, wire width w, wire thickness h, crown segment height h1, first bending angle θ1, second bending angle θ2, third bending angle θ3, first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4, width-thickness ratio R, cross-sectional second moment I, force arm ratio , first forming angle ;
[0047] Third forming angle Input selection: 15 dimensions, wire width w, wire thickness h, crown segment height h1, first bending angle θ1, second bending angle θ2, third bending angle θ3, first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4, width-thickness ratio R, cross-sectional second moment I, force arm ratio , first forming angle , second forming angle ;
[0048] 2.4 Three forming angles As output features, :
[0049] First forming angle , second forming angle , third forming angle ;
[0050] S3 Multi-model construction and parameter optimization:
[0051] S3.1 Multi-model construction:
[0052] 3.1.1 Random Forest (RF):
[0053] 1) Single tree splitting criterion
[0054] The single tree splitting criterion is divided into classification task and regression task;
[0055] Classification task: single tree adopts the classification tree in the classification and regression tree (CART) algorithm, and the splitting criterion is usually Gini impurity (Gini), to maximize the decrease of impurity;
[0056] Regression task: single tree is CART regression tree, split criterion is usually mean square error to minimize the variance after split;
[0057] This method uses CART regression tree, the formula is as follows: the split target is to find the feature and split point that can minimize the sum of mean square error of the child nodes after split, that is, maximize the following gain (Gain):
[0058]
[0059] : the sample set on the parent node (Parent) before split; : the sample set on the left (Left) and right (Right) child nodes after split;
[0060] 2) Forest prediction
[0061] This method uses regression task (simple average), the formula is as follows:
[0062]
[0063] M: the number of decision trees; : the prediction output of the mth decision tree for input sample x; : the final prediction value of the random forest;
[0064] This model (RF) is one of the candidate base learners, which participates in the model optimization of each stage in the cascade chain regression. Its excellent anti-overfitting characteristics make it often become the preferred model when the input feature dimension is low (such as the first forming angle θ1_pred) or the data volume is small;
[0065] 3.1.2 eXtreme Gradient Boosting (XGBoost for short):
[0066] 1) Objective function
[0067]
[0068] The total cost of the model at the tth round of training; The loss function of the model for the ith sample at the tth round of training; The cumulative prediction result of the first t-1 trees; The prediction value of the tth tree being constructed for sample x i ; The regularization term;
[0069] 2) Second-order Taylor expansion
[0070]
[0071] is a first-order gradient, is a second-order gradient;
[0072] 3) Leaf weight analytical solution
[0073]
[0074] is the optimal weight of the jth leaf node; I j represents the set of all samples assigned to the jth leaf node;
[0075] 4) Split gain
[0076]
[0077] : the sample set on the parent node before splitting; : the sample set on the left (Left) and right (Right) child nodes after splitting; λ: L2 regularization coefficient; γ: minimum split gain threshold; λ and γ are adjustable regularization hyperparameters that together constitute the core embodiment of this method for controlling model complexity and improving generalization ability;
[0078] As one of the candidate base learners, this model (XGBoost) participates in the model selection of each stage in the cascade chain regression. The split gain criterion with regularization is one of the core bases of this method, and it often exhibits excellent performance when dealing with complex high-dimensional feature interactions (such as subsequent angle formation cascade prediction);
[0079] 3.1.3 Light Gradient Boosting Machine (LightGBM for short):
[0080] 1) Histogram algorithm
[0081] LightGBM uses the histogram algorithm to discretize continuous features, reducing the computational complexity of finding split points from depending on the number of unique values of the feature to only depending on the number of preset buckets, greatly improving training efficiency;
[0082]
[0083] x: a certain original value of feature j; min(j): the minimum value of feature j in all samples; min(x): the maximum value of feature j in all samples; max_bins: the preset maximum number of buckets; Floor function, which ensures the result is an integer; bin: the calculated bin number, which ranges from [0, max_bins-1];
[0084] 2) Leaf-wise Growth Strategy
[0085] LightGBM adopts the same advanced split-gain criterion (as shown in the following formula) as XGBoost to ensure the prediction accuracy when splitting nodes. However, the key efficiency improvement of this method lies in the application of this criterion by LightGBM through its unique Leaf-wise growth strategy. Unlike the traditional layer-wise growth strategy, Leaf-wise only splits the leaf node with the largest gain at each layer. This approach makes the loss function decrease faster and the convergence accuracy higher under the same model complexity, thereby providing a significant efficiency advantage for the cascaded optimization structure of this method.
[0086]
[0087] As one of the candidate base learners, this model (LightGBM) participates in the model optimization of each stage in the cascaded chain regression. Its histogram algorithm and Leaf-wise growth strategy are the key efficiency improvement points of this method, and this model is extremely competitive when dealing with large-scale data or having extremely high requirements for training speed.
[0088] 3.1.4 Cascaded Chain Regression Model (Cascaded Chain Regression):
[0089] 1) Chain Prediction Process
[0090] This method not only captures the physical dependency between angles through the cascaded chain regression structure, inputting the prediction results of the previous model as incremental features into the subsequent model, but also ensures that each link is driven by the algorithm most suitable for the data characteristics of that stage through the phased model optimization mechanism. This "adaptive chain structure" overcomes the defect that a single model may not perform well in some links, thereby achieving more accurate and robust prediction of the forming angle as a whole. The process is as follows:
[0091] Stage One (First Forming Angle θ1_pred):
[0092] Among them, model M1 is selected from the candidate pool [RF, XGBoost, LightGBM] according to the optimization strategy below;
[0093] Stage Two (Second Forming Angle θ2_pred):
[0094] wherein the model M2 is independent of M1 and is selected from the same pool of candidates according to the same strategy;
[0095] Stage three (third forming angle θ3_pred):
[0096] wherein the model M3 is also determined by independent optimization;
[0097] X: original input feature vector; : predicted value of the i-th forming angle predicted by the i-th stage model; M k : regression model finally determined by the systematic optimization process in the k-th stage;
[0098] 2) Staged model optimization strategy
[0099] The core of the optimization strategy is to independently select the model with the smallest validation error for each stage k. The mean absolute error (MAE) of each candidate model is directly calculated on the validation set, and the model with the smallest MAE is selected as the optimal model for that stage.
[0100] The model selection formula for stage k is:
[0101]
[0102] M k : optimal model selected for the k-th stage; : mean absolute error of model M on the k-th stage validation set A;
[0103] S4 model evaluation and optimization:
[0104] 4.1 Model evaluation index:
[0105] This method uses the mean absolute error MAE and the root mean square error RMSE as the precision evaluation index. The formulas are as follows:
[0106] (mean absolute value)
[0107] (root mean square error)
[0108] : true value of the i-th sample; : predicted value of the i-th sample; n: number of samples;
[0109] 4.2 Comparison and optimization of cascaded models:
[0110] The present embodiment adopts 745 group sample data of the bending of the enameled flat wire extracted in the 2D forming production process of the flat motor of the new energy vehicle, and the whole data set is randomly divided according to the proportion of 8:2 through the Hold-out test method. Among them, 80% of the data is used as the training set to build and train the model; the other 20% of the data is strictly sealed during the whole model development cycle and is only used for one-time and unbiased evaluation of the performance of the final model. The evaluation index is calculated according to S4.1. The results are shown in Table 1 and Figure 2
[0111] The scatter plots of the predicted values and the true values of the three forming angles are shown in Figs. 1-3, Figure 2 Figs. 1-3 are scatter plots of the predicted values and the true values of the LightGBM model; Figure 2 Figs. 1-3 are scatter plots of the predicted values and the true values of the XGBoost model; Figure 2 Figs. 1-3 are scatter plots of the predicted values and the true values of the RF model. As shown in Figs. 1-3, Figure 2 all data points are closely distributed on both sides of the ideal diagonal line y=x, forming a clear linear distribution band. This result strongly proves from the qualitative angle that the model of the present method successfully learns the complex law of the forming angle rebound, and the predicted value and the true value have high consistency and low systematic deviation; Figure 2 Table 1 Performance indicators of three candidate models on the independent test set
[0112]
[0113] In the present method, the mean absolute error (MAE) is given the highest weight as the core indicator directly measuring the prediction deviation, and is verified by the root mean square error (RMSE). From Table 1, it can be seen that for the first forming angle θ1_pred: the random forest (RF) leads in both MAE=0.109° and RMS=0.145° indicators, significantly better than other candidate models, and is the best choice; for the second forming angle θ2_pred: the performances of the three models are very close, and the RF performs best in MAE=0.140°, and its RMSE 0.192° is also flat with the optimal value, so the RF is the optimal choice at this stage; for the third forming angle θ3_pred: the RF and XGBoost have the best RMSE=0.122°, and the MAE=0.089° of the RF is slightly better than the LightGBM=0.091°, which is the best among all models. Therefore, the RF also shows the best comprehensive performance at this stage;
[0114]
[0115] Based on the above comprehensive analysis with MAE as the core, the final preferred cascade model combination of this method is determined as: M1=RF, M2=RF, M3=RF. The results show that the prediction average absolute error (MAE) of all three forming angles is less than 0.15°, as shown in Table 1; under the specific data set and feature engineering of this embodiment, the RF model provides the most consistent and accurate solution for the prediction task of the three forming angles;
[0116] The S5 cascade forming mechanism and feature evolution law is revealed:
[0117] 5.1 SHAP importance quantification:
[0118] This method uses the SHAP (Shapley Additive Explanations) method to analyze the explainability of the cascade chain regression model, and systematically reveals the influence mechanism of each process parameter in the three-stage forming process. Combined with the Gini feature importance and SHAP analysis results, a deep understanding of the physical mechanism of multi-step bending forming is formed;
[0119] Referring to Figure 3 and Table 2, the cascade chain regression model proposed by this method is verified by strict isolation verification, which confirms its significant effect and physical rationality in multi-step bending forming angle prediction;
[0120] Table 2 Gini feature importance (top five features) of random forest model for three-stage forming angle prediction
[0121]
[0122] As shown in Table 2, the test data of Gini feature importance (top five features) of the random forest model for three-stage forming angle prediction shows that for the first forming angle θ1_pred, the crown segment height h1 is the most important factor with an importance of 33.75%, the wire thickness h (19.95%), the cross-sectional second moment I (19.24%), and the width-thickness ratio R (17.07%) together form the core feature set, and the cumulative contribution of these four geometric parameters is as high as 90.01%, fully verifying the basic dominant role of the geometric parameters in the initial forming stage;
[0123] When entering the second forming angle θ2_pred, the model successfully captures the cumulative effect of the previous deformation, and the first forming angle θ1_pred ranks first with an importance of 30.19%, while the original geometric parameters such as the crown segment height h1 (19.09%) and the cross-sectional second moment I (17.29%) still have significant influence, forming a hybrid mode of "previous deformation effect and original geometric parameter co-driving", which accurately reflects the physical nature of the transition stage in multi-step forming;
[0124] Most importantly, in the third forming angle θ3_pred, the model reveals a strong physical law: the second forming angle θ2_pred determines the final forming result with an absolute dominance of 94.94%. This finding confirms that there is a nearly deterministic physical relationship between the third forming angle and the second forming angle in the process system of this method, and the later forming state is completely dominated by the previous deformation path. This discovery not only verifies the theoretical basis of the cascade chain structure, but also provides a clear direction for process optimization - by precisely controlling the previous forming stage, the final forming accuracy can be effectively guaranteed;
[0125] The Gini importance built-in random forest is essentially a measure of the intrinsic splitting utility of a feature in the model construction process, that is, by calculating the cumulative amount of impurity reduction when the node is split to evaluate its feature discrimination ability. However, this index has inherent limitations in theory: first, it is susceptible to feature dimension and numerical scale interference; second, it is sensitive to multicollinearity; third and most importantly, it cannot fairly distribute the interaction effects between features, often attributing the gain brought by interaction to the feature performing the split. Given these limitations, Gini importance cannot truly reflect the independent contribution of each feature to the prediction result, so its analysis results can only serve as auxiliary verification to understand the internal mechanism of the model. To achieve a perspective shift from "how the model is built" to "how the prediction is produced", and then accurately quantify the real physical impact of each feature on the final forming angle, this method introduces the Shapley Additive Explanation (SHAP) attribution framework based on coalition game theory;
[0126] Based on the Shapley Additive Explanation (SHAP) method, the three-stage forming angle prediction model is analyzed, and the influence mechanism and evolution law of each process parameter in different forming stages are systematically revealed. The analysis results (see Table 3 and Figure 4 、 Figure 5 and Figure 6 ) show that the SHAP feature importance and its influence direction exhibit significant systematic changes in different stages;
[0127] Table 3 SHAP feature importance ranking of three-stage forming angle prediction random forest model (top five features)
[0128]
[0129] Table 4 Summary table of key feature influence law of three-stage forming angle
[0130]
[0131] In the first forming angle θ1_pred stage, the model identifies the basic dominant role of geometric parameters. As shown in Table 3, the wire thickness h ranks first with a SHAP importance of 0.0306. Combined with the Figure 5 (A),Figure 6 (A) and Table 4, SHAP analysis shows that the wire thickness h is stably negatively correlated with the first forming angle θ1_pred, indicating that the first forming angle θ1_pred decreases by 0.0372° for every 1 mm increase in the wire thickness h; the larger the cross-sectional second moment I (importance 0.0213), the smaller the first forming angle θ1_pred; the width-thickness ratio R (importance 0.0176) also shows a positive correlation, and the larger the width-thickness ratio R, the larger the first forming angle θ1_pred; the crown segment height h1 (importance 0.0170), for every 1 mm increase in the crown segment height h1, the first forming angle θ1_pred increases by 0.0064°; the contribution of these four geometric parameters is absolutely dominant, accurately reflecting the decisive influence of the material geometric properties on the deformation behavior in the initial forming stage;
[0132] In the second forming angle θ2_pred stage, the model captures the cascading effect of the process, realizing the key transition from "geometric driving" to "deformation history driving". The first forming angle θ1_pred ranks first with a SHAP importance of 0.0374 (see Table 3), becoming the most critical influencing factor. According to Figure 5 (B) shows that the first forming angle θ1_pred is positively correlated with the second forming angle θ2_pred, combined with Figure 6 (B) and Table 4, for every 1° increase in the first forming angle θ1_pred, the second forming angle θ2_pred increases by 0.2803°, reflecting the amplification effect of the previous deformation on the subsequent process. At the same time, the influence of the original geometric parameters still exists but is weakening, such as the importance of the wire thickness h decreasing from 0.0306 to 0.0205, with a 33% attenuation in influence strength;
[0133] In the final third forming angle θ3_pred stage, the model reveals an almost deterministic physical law: the late forming state is completely dominated by the previous deformation path. Table 3 shows that the second forming angle θ2_pred takes the first place with a SHAP importance of 0.0637, which is 16.3 times the value of the second first forming angle θ1_pred (0.0039). From Figure 5 (C), Figure 6 (C) and Table 4 show that the second forming angle θ2_pred is strongly positively correlated with the third forming angle θ3_pred, and for every 1° increase in the second forming angle θ2_pred, the third forming angle θ3_pred increases by 0.8568°, showing a strong deformation accumulation and amplification effect; in sharp contrast, the importance of all original geometric parameters (such as the wire thickness h and the cross-sectional second moment I) has decreased to a very low level (<0.0032);
[0134] The SHAP analysis not only verifies the theoretical basis of the cascade chain regression model, but also quantitatively describes the evolution of the internal physical mechanism in the multi-step forming process, providing reliable data support and theoretical guidance for the precise control and optimization of process parameters.
[0135] The method analyzes the feature influence mechanism in the three-stage hairpin wire forming process by constructing a cascade chain random forest model and combining SHAP and Gini from two angles. Specifically, in the initial stage of the first forming angle θ1_pred, the geometric parameters such as wire thickness h and cross-sectional second moment I are decisive factors (both Gini and SHAP importance point to the crown segment height h1 and wire thickness h); as the forming progresses, the influence of the first forming angle θ1_pred becomes prominent (SHAP importance ranks first at the second forming angle θ2_pred stage); at the third forming angle θ3_pred, the second forming angle θ2_pred becomes dominant with a great advantage (SHAP importance is as high as 0.0637, 16.3 times that of the second place), while the influence of the original geometric parameters is negligible. SHAP analysis further quantifies the influence direction and strength of the features, confirming the existence of significant deformation accumulation and amplification in the cascade effect. This conclusion not only verifies the physical reasonableness of the cascade chain model from the data level, but also provides clear guidance for the forming control of multi-step forming process: in the early stage, focus on the geometric precision of raw materials and initial bending, and in the later stage, focus on the accurate monitoring and regulation of the deformation state of the previous sequence;
[0136] S6 Feature Optimization and Engineering Application:
[0137] Based on the above feature importance analysis results, the engineering application strategy proposed by this method is as follows: First, implement a differentiated data collection scheme, that is, in actual application, prioritize the measurement accuracy of high importance features (such as wire thickness, crown segment height, and previous forming angle), and use standard values or estimated values for low importance features, thereby significantly reducing data collection cost and complexity while maintaining high accuracy of the model; further, use the trained high-precision cascade model as a digital proxy model for rapid optimization of process parameters for new specifications of wire, by setting target span or forming angle allowable error, driving the optimization algorithm to solve the optimal bending process parameters, thereby realizing the transition from traditional "trial and error" machine adjustment to "predictive" control, greatly improving process development efficiency and forming quality.
[0138] In summary, the method establishes a quantitative prediction model for the multi-step bending process of enameled flat wire, and upgrades the traditional process relying on experience to a new stage of calculation and prediction. The method realizes accurate prediction of the three forming angles, providing theoretical support for the precision manufacturing and stable mass production of flat wire motor winding.
Claims
1. A method for quantitative modeling of flat wire forming parameters and forming angle based on cascaded machine learning, characterized in that Comprising the following steps: S1 data collection: The data comes from the process data of the bending of enameled flat wire in the 2D forming process of the flat wire motor of new energy vehicles; S2 feature engineering: On the basis of 10-dimensional original geometric parameters, 3-dimensional physical derived features such as width-thickness ratio, cross-sectional second moment, and force arm ratio are constructed to form a 13-15 dimensional cascaded input feature set; S3 multi-model construction and parameter optimization Based on RF, XGBoost and LightGBM three algorithms, a cascaded chain regression model is constructed, and the model is optimized through independent test set verification, and the optimal algorithm is selected independently in each stage; The first stage is based on 13-dimensional geometric features to predict the first forming angle θ1_pred, the second stage introduces the first forming angle θ1_pred to construct a 14-dimensional input to predict the second forming angle θ2_pred, and the third stage fuses the previous prediction results to form a 15-dimensional input to predict the third forming angle θ3_pred; S4 model evaluation and optimization: Through the Hold-out test method, the whole data set is randomly divided according to the ratio of 8:2, among which 80% of the data is used as the training set to construct and train the model; The other 20% of the data is used as the test set; S5 cascaded forming mechanism and feature evolution law revelation: The SHAP method is used for explainability analysis of the cascaded chain regression model, and the influence mechanism of each process parameter in the three-stage forming process is revealed; Combined with the Gini feature importance and SHAP analysis results, a deep understanding of the multi-step bending forming physical mechanism is formed; S6 feature optimization and engineering application: By setting the target span or forming angle allowable error, the optimization algorithm is used to inversely solve the optimal bending process parameters, so as to realize the transformation from traditional "trial and error" machine adjustment to "prediction", and improve the process development efficiency and forming quality.
2. The method for quantitatively modeling the flat wire forming parameters and forming angle based on cascaded machine learning according to claim 1, characterized in that S2 feature engineering is as follows: 2.1 original 10-dimensional geometric parameters: Basic geometric parameters: wire width w, wire thickness h, crown segment height h1; Bending angle: first bending angle θ1, second bending angle θ2, third bending angle θ3; Straight line segment length: first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4; 2.2 3-dimensional physical mechanism derived: Base geometry characteristics: width-thickness ratio R, section second moment I, lever ratio ; Width-to-thickness ratio: R = w / h, second moment of area: , lever ratio: ; 2.3 Three forming angles Input parameter selection, : First molding angle Input selection: 13 dimensions, wire width w, wire thickness h, crown segment height h1, first bending angle θ1, second bending angle θ2, third bending angle θ3, first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4, width-thickness ratio R, cross-sectional second moment I, force arm ratio ; Second molding angle Input selection: 14 dimensions, wire width w, wire thickness h, crown segment height h1, first bending angle θ1, second bending angle θ2, third bending angle θ3, first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4, width-thickness ratio R, cross-sectional second moment I, force arm ratio First molding angle ; Third forming angle Input selection: 15 dimensions, wire width w, wire thickness h, crown segment height h1, first bending angle θ1, second bending angle θ2, third bending angle θ3, first straight line segment b1, second straight line segment b2, third straight line segment b3, fourth straight line segment b4, width-thickness ratio R, cross-sectional second moment I, force arm ratio , first forming angle , second forming angle ; 2.4 Three forming angles As output features, : first molding angle second molding angle third molding angle .
3. The method for quantitatively modeling the flat wire forming parameters and forming angle based on cascaded machine learning according to claim 1, characterized in that S3 multi-model construction and parameter optimization is as follows: S3.1 multi-model construction: 3.1.1 random forest: 1) Single tree splitting criterion CART regression tree is used, and the formula is as follows: The splitting target is to find the feature and segmentation point that can minimize the sum of mean square errors of the child nodes after splitting, that is, to maximize the following gain (Gain): ; : Set of samples on the parent node before splitting; : Set of samples on the left and right child nodes after splitting; 2) Forest prediction The regression task is used, and the formula is as follows: ; M: number of decision trees; : prediction output of the mth decision tree for input sample x; : final prediction value of the random forest; 3.1.2 extreme gradient boosting machine: 1) Objective function ; The total cost of the model at the t-th training round; Let be the loss function of the model for the i-th sample during the t-th round of training; This represents the cumulative prediction results for the first t-1 trees; For the t-th tree being constructed, for sample x i The predicted value; For regularization terms; 2) Second-order Taylor expansion ; is a first order gradient, is a second order gradient; 3) Leaf weight analytical solution ; optimal weight for the jth leaf node; I j denotes the set of all samples assigned to the jth leaf node; 4) Splitting gain ; : sample set on the pre-split parent node; : sample set on the post-split left and right child nodes; λ: L2 regularization coefficient; γ: minimum split gain threshold; λ and γ are adjustable regularization hyperparameters; 3.1.3 light gradient boosting machine: 1) Histogram algorithm LightGBM uses a histogram algorithm to discretize continuous features, reducing the computational complexity of finding a split point from depending on the number of unique values of the feature to only depending on the number of preset bins, improving training efficiency; ; x: a certain original numerical value of feature j; min(j): the minimum value of feature j among all samples; min(x): the maximum value of feature j among all samples; max_bins: the preset maximum number of bins; : floor function, ensuring that the result is an integer; bin: The calculated bin number, ranging from [0, max_bins-1]; 2) Leaf priority growth strategy LightGBM adopts the same advanced split gain criterion as XGBoost to ensure prediction accuracy when splitting nodes; ; 4 Cascade chain regression model: 1) Chain prediction process Stage one (first forming angle θ1_pred): ; Among them, model M1 is selected from the candidate pool [RF, XGBoost, LightGBM] according to the preferred strategy below; Stage two (second forming angle θ2_pred): ; Among them, model M2 is independent of M1, and is selected from the same candidate pool according to the same strategy; Stage three (third forming angle θ3_pred): ; Among them, model M3 is also determined by independent optimization; X: original input feature vector; : predicted value of the i-th forming angle predicted by the i-th stage model; M k : regression model finalized by the k-th stage through systematical preferred process; 2) Staged model optimization strategy The core of the optimization strategy is to independently select the model with the smallest validation error for each stage k. The mean absolute error (MAE) of each candidate model is calculated directly on the validation set, and the model with the smallest MAE is selected as the optimal model for that stage. The model selection formula for stage k is: ; M k : optimal model selected for the kth stage; : mean absolute error of model M on the kth stage validation set A.
4. The method of claim 1, wherein the method is based on a cascade machine learning. S4 model evaluation and optimization: 4.1 Model evaluation index: This method uses the mean absolute error MAE and the root mean square error RMSE as the accuracy evaluation index formula as follows: (mean absolute value) (root mean square error) : true value of the i-th sample; : predicted value of the i-th sample; n: number of samples; 4.2 Cascade model comparison and optimization: Through the Hold-out test method, the entire data set is randomly divided according to an 8:2 ratio; Among them, 80% of the data is used as the training set to build and train the model; The other 20% of the data is used as the test set, and the evaluation index is calculated according to S4.1; Random Forest leads in MAE=0.109° and RMS=0.145° two indicators; For the second forming angle θ2_pred: RF performs best in MAE=0.140°, and its RMSE 0.192° is also flat with the optimal value, so RF is the optimal choice for this stage; For the third forming angle θ3_pred: RF and XGBoost's RMSE=0.122° are the best, while RF's MAE=0.089° is better than LightGBM's=0.091°, so RF also shows the best overall performance in this stage; Based on the above comprehensive analysis with MAE as the core, the final cascade model combination of this method is determined as: M1=RF, M2=RF, M3=RF.
5. The method for quantitatively modeling the flat wire forming parameters and forming angle based on cascaded machine learning according to claim 1, characterized in that S5 Cascade forming mechanism and characteristic evolution law is revealed as follows: 5.1 SHAP importance quantification: This method uses the SHAP method to analyze the explainability of the cascade chain regression model, and reveals the influence mechanism of each process parameter in the three-stage forming process; Combined with Gini feature importance and SHAP analysis results; Test data shows that in the first forming angle θ1_pred, the crown segment height h1 is the most critical influencing factor with an importance of 33.75%, the wire thickness h is 19.95%, the cross-sectional second moment I is 19.24%, and the width-thickness ratio R is 17.07%. Together they form the core feature set, with a cumulative contribution of 90.01%, verifying the basic dominant role of geometric parameters in the initial forming stage. When entering the second forming angle θ2_pred, the model successfully captures the cumulative effect of the pre-deformation, and the first forming angle θ1_pred ranks first with an importance of 30.19%, while the original geometric parameters such as the height of the crown segment h1 19.09% and the second moment of area I 17.29% still maintain their influence; Most importantly, in the third forming angle θ3_pred, the model reveals a physical law: the second forming angle θ2_pred determines the final forming result with an absolute dominance of 94.94%; In the first forming angle θ1_pred stage, the model identifies the basic dominant role of geometric parameters; the wire thickness h ranks first with a SHAP importance of 0.0306; the wire thickness h is negatively correlated with the first forming angle θ1_pred, indicating that for every 1 mm increase in wire thickness h, the first forming angle θ1_pred decreases by 0.0372°; the larger the second moment of area I, the smaller the first forming angle θ1_pred; the width-to-thickness ratio R also shows a positive correlation, the larger the width-to-thickness ratio R, the larger the first forming angle θ1_pred; the height of the crown segment h1, for every 1 mm increase in the height of the crown segment h1, the first forming angle θ1_pred increases by 0.0064°; In the second forming angle θ2_pred stage, the model captures the cascade effect of the process; the first forming angle θ1_pred ranks first with a SHAP importance of 0.0374, becoming the most critical influencing factor; the first forming angle θ1_pred is positively correlated with the second forming angle θ2_pred, and for every 1° increase in the first forming angle θ1_pred, the second forming angle θ2_pred increases by 0.2803°; In the final third forming angle θ3_pred stage, the second forming angle θ2_pred takes the first share with a SHAP importance of 0.0637, which is 16.3 times that of the second place first forming angle θ1_pred; the second forming angle θ2_pred is positively correlated with the third forming angle θ3_pred, and for every 1° increase in the second forming angle θ2_pred, the third forming angle θ3_pred increases by 0.8568°.
6. The method for quantitatively modeling the flat wire forming parameters and forming angle based on cascaded machine learning according to claim 1, characterized in that S6 Feature Optimization and Engineering Application: Implement a differentiated data collection scheme, that is, in actual application, ensure the measurement accuracy of high importance features, while using standard values or estimated values for low importance features, thereby maintaining high precision of the model while reducing data collection cost and complexity; then use the trained high-precision cascade model as a digital proxy model for rapid optimization of process parameters for new specifications of wire, by setting target span or forming angle allowable error, driving the optimization algorithm to solve the optimal bending process parameters reversely, realizing the transition from traditional "trial and error" machine adjustment to "predictive", improving process development efficiency and forming quality.
Citation Information
Patent Citations
Reconstruction method for continuous missing monitoring data of longitudinal displacement of suspension bridge beam end
CN115859813A
Predictive maintenance method for intelligent factory Internet of Things equipment
CN118070246A