Abstract
Laser powder bed fusion (L-PBF) additive manufacturing (AM) is one type of metal-based AM process that is capable of producing high-value complex components with a fine geometric resolution. As melt-pool characteristics such as melt-pool size and dimensions are highly correlated with porosity and defects in the fabricated parts, it is crucial to predict how process parameters would affect the melt-pool size and dimensions during the build process to ensure the build quality. This paper presents a two-level machine-learning (ML) model to predict the melt-pool size during the scanning of a multitrack build. To account for the effect of thermal history on melt-pool size, a so-called (prescan) initial temperature is predicted at the lower-level of the modeling architecture and then used as a physics-informed input feature at the upper-level for the prediction of melt-pool size. Simulated data sets generated from the autodesk'snetfabbsimulation are used for model training and validation. Through numerical simulations, the proposed two-level ML model has demonstrated a high prediction performance, and its prediction accuracy improves significantly compared to a naive one-level ML without using the initial temperature as an input feature.
1 Introduction
Laser powder bed fusion (L-PBF) additive manufacturing (AM) offers a way to build complex metallic components directly from a computer-aided design file through selectively melting alloy powder in a layer-by-layer manner [1,2]. During the L-PBF process, a thin layer of alloy powder is first placed on the build plate by a recoater, and then a laser is applied to selectively melt the powder layer in terms of the model of the part geometry. Once a layer of the part is completed, the build platform is lowered, and a new layer of powder is placed. The process is repeated to build the entire three-dimensional part layer-by-layer. Compared to other metallic AM technologies such as the laser engineering net shaping (LENS) directed energy deposition (DED), L-PBF enables fabrication of components in a much finer resolution (in the order of tens of microns) and with a faster laser scan speed (from a hundred to multithousand mm/s), which poses significant challenges to the computational cost in simulating L-PBF processes [3].
One challenge associated with fabrication of parts with L-PBF lies in that the end parts could be liable to thermal defects such as porosity and microcracks. Previous studies have shown that porosity-related thermal defects are highly correlated with melt-pool size, shape, or individual dimensions [4–6]. For example, when the applied energy density is too low, it could cause small melt-pool size resulting in lack-of-fusion porosity, and when the applied energy density is too high, it could result in overmelting or keyhole-induced porosity. In addition, certain scan patterns (build plans) could render the keyhole-induced porosity more likely to happen, e.g., they are more frequently seen at laser turnarounds during scanning a multihatch build with switching laser travel directions, where the returning end of the track gets heated repeatedly. Hence, melt-pool size (or melt-pool dimensions) could serve as a useful proxy to indicate porosity-related thermal defects, and it is important to develop modeling and simulation tools to predict melt-pool geometry (size, shape, or individual dimensions) under different process conditions.
Many studies on modeling of L-PBF processes and melt-pool dynamics focused on finite element analysis (FEA)-based modeling of solids or combined with fluid mechanics for the modeling of melt flow, as summarized in the review paper [7]. However, these modeling and simulation methods often require a high-performance computing infrastructure [8], and the simulation of a large part could be a highly resource-intensive and time-consuming task, which makes the resulting model prediction almost impossible to be used in real-time optimization to reduce or avoid porosity-related thermal defects.
Machine learning (ML), with the capability of handling a large amount of data and adapting to newly available data, could be a promising tool to develop alternative predictive models for highly complicated physical phenomena. Furthermore, once an ML model is trained, it can be used to provide rapid predictions for unobserved (untrained) samples, and thus ML models can be developed to substitute for models with a high computational cost. ML algorithms have been applied to various aspects of AM research including the design of AM, material design, and characterization of microstructure [9,10]. In addition, a large number of studies focused on leveraging ML's powerful capability in image recognition to classify build quality or to detect part defects. A support vector machine scheme was applied to layer images for in situ defect detection in L-PBF [11]. A convolutional neural network was applied to in situ and ex situ melt-pool data on track width and continuity to classify build quality [12]. A multiscale convolutional neural network was developed to detect and classify spreading anomalies in L-PBF [13]. To detect keyholing porosity or balling instability in L-PBF, supervised machine learning was used to classify observed melt pools by linking in situ and ex situ morphology [14]. A Bayesian classifier was developed and applied to in situ layer images to detect low quality fusion or defects in L-PBF [15].
However, there are limited studies on applying ML techniques to AM process modeling. For the LENS DED systems, a back propagation network with adaptive learning rate as well as a least-square support vector machine was trained to map the process parameters to the depositing height [16]. Recurrent neural networks were developed to predict the thermal history and temperature field for DED processes [17,18]. For selective laser sintering, neural networks and genetic algorithms were applied to search the optimal layer thickness, hatch spacing, laser power, speed, and work surrounding temperature that can yield the minimum shrinkage ratio [19]. Back propagation neural networks were developed for the spreading process of L-PBF, mapping from the spreader speeds to the spread layer parameters [20].
Several studies also developed ML models to predict melt-pool size, surface area, or an individual dimension (e.g., melt-pool width or depth) for L-PBF processes, but restricted to single-track samples [21–24]. A dynamic metamodeling method using kriging covariance matrices was applied to predict the melt-pool width, and then genetic algorithms were applied to optimize the process parameters [21]. In Ref. [22], Gaussian processes were used to construct a surrogate response surface model to predict the melt-pool depth as a function of process parameters consisting of the laser power and laser scanning speed. The Gaussian-process-based model was trained and validated on experimental data of single-track deposits of 316 L stainless steel. In addition, the study [22] also demonstrated that the Gaussian-process-based surrogate model can be trained using simulated data sets from the powder-scale simulation model [25], and the resulting model can then serve as an approximation of the high-fidelity simulation to identify process windows that can keep the melt pool away from the keyhole mode. A similar Gaussian-process-based model was developed in Ref. [24] to predict the remelted depth of single-tracks of stainless steel as a function of laser power and scan speed, using simulated and experimental data. A sequential-decision-analysis neural network model was developed in Ref. [23], where measurement data from pyrometer and high-speed video camera were used to train the proposed neural networks to predict the melt-pool mean width (and the associated standard deviation) as well as the continuity of single-tracks as a function of laser power and speed.
Note that these ML models for predicting the melt-pool dimensions or the surface area were restricted to single-tracks. As acknowledged in Ref. [22], the melt pools being measured or simulated were in steady-state. As a result, these models cannot be generalized to parts with more than a single-track, where the thermal history (resulted from the scan pattern) plays an important role in affecting the melt-pool size and geometry during the build process. In this paper, we propose a machine-learning model with a two-level architecture to predict the melt-pool size during the L-PBF scanning of a multitrack part. To account for the effect of thermal history and scan pattern on the melt-pool size, a so-called (prescan) initial temperature [26] is predicted at the lower-level of the modeling architecture and then used as an input feature at the upper-level of the modeling architecture to predict the melt-pool size. Including the initial temperature at the point of select-to-scan, which is a proxy for the thermal history, as one input feature of the upper-level ML model makes the proposed ML modeling methodology physics-informed and distinct from existing ML-based predictive models for single-tracks.
The authors acknowledge that it is possible to develop sophisticated deep-learning neural networks such as recurrent neural networks where time history information is embedded implicitly, to predict melt-pool geometry during the build process of multitrack parts. However, it is commonly known that deep-learning neural networks in general require a much larger amount of training data compared to the nondeep-learning models. In addition, although deep neural networks allow automatic feature extraction, it is often not clear how to interpret these features being automatically extracted with physical meaning. One contribution of this paper lies in that by utilizing a hierarchical modeling architecture and including a physics-informed input feature, the resulting nondeep-learning models can demonstrate sufficient prediction performance.
Simulated data sets, generated from a commercial FEA-based software, autodesk'snetfabbsimulation, are used in this paper for model training and validation. As pointed out in Refs. [22] and [27], training ML models using FEA-based high-fidelity simulations enables an approximation of the FEA models and thus enables fast predictions for unobserved (untrained) process conditions. Nevertheless, the authors acknowledge the inevitable modeling errors associated with FEA-based models including netfabbsimulation, and future work will include validating the proposed modeling methodologies using experimental data. Preliminary results of this paper were presented at the ASME Dynamic Systems and Control Conference [28]. This paper has added new results and an entirely new section on exploration of additional process parameters and input-feature space (Sec. 5).
The remainder of the paper is organized as follows. Sec. 2 presents the modeling methodology, Sec. 3 describes the simulated data for training and testing, results and discussions are given in Sec. 4, Sec. 5 further investigates additional process parameters and input-feature space, and conclusions are drawn in the end.
2 Modeling Methodology
This section presents the proposed two-level ML modeling methodology to predict the melt-pool volume in the L-PBF scanning of a multitrack part. A schematic plot of the multitrack part is given in Fig. 1, where laser switches its scanning direction after finishing each track. For simplicity of the illustration, the laser power is first considered as the only varying process parameter with other process parameters fixed. Exploration of additional process parameters and input-feature space will be discussed in Sec. 5. Melt-pool volume is chosen as the model output, as previous studies have shown that the melt-pool size is highly correlated with porosity-related thermal defects [4–6] (see more discussions in the introduction). Nevertheless, the proposed methodology is applicable to other geometric variables such as the melt-pool depth or width, as long as the corresponding data are available for training and validation.
2.1 A Two-Level Machine-Learning Architecture.
When more than one track (hatch) is scanned, the melt-pool size of the current track will be affected by the thermal history caused by scanning the past tracks. Hence, the melt-pool size will not stay constant from track to track even under the constant process parameters. Take the scan pattern in Fig. 1 as an example, where the laser switches its scanning direction from track to track. The beginning end of the second track and each subsequent track is expected to have a bigger melt pool since it gets heated repeatedly. As a result, we consider that it is essential to include the thermal history (a result of process parameters and scan pattern) as one input feature of the proposed ML model for a multitrack build. When the input features of a ML model are chosen to incorporate physical domain knowledge for an efficient learning and model prediction, the corresponding ML approach is often referred to be physics-informed.
In our prior analytical modeling work for LENS DED processes [29–31] and for L-PBF [26], a so-called initial temperature at the deposition point (or point of select-to-scan) was identified as a key variable in characterizing the thermal history. Such initial temperature was defined and computed as the summation of the temperature contributions from all past tracks (hatches) being built, excluding the effect of scanning the current track [26,29–31]. For LENS DED, the initial temperature computed from an analytical model was compared to that computed from the FEA simulation in Ref. [31], where the temperature at a distance of multiple laser-spot-size ahead of the laser was picked as the initial temperature at the deposition point. As detailed in Appendix A, the analytical computation of initial temperature (referred to as the physics-based analytical (PBA) model in this paper) accounts for the laser scan path and any interhatch dwell time.
Note that the aforementioned initial temperature, although deemed essential to the prediction of melt-pool size in scanning a multitrack part, is not explicitly available as one of the given process parameters. Hence, a two-level architecture is proposed here for the ML-based, moving-source model to predict the melt-pool size. As shown in Fig. 2, the lower-level ML model predicts the initial temperature Tinitial at the point of select-to-scan based on the process-parameter inputs (e.g., laser power and laser scan speed) and the laser position on a track under scanning. The upper-level ML model uses the initial temperature, along with the process parameters and laser position, to predict the melt-pool size.
2.2 Lower-Level: A Hybrid Model for Predicting Initial Temperature.
A hybrid ML model is proposed here to predict the initial temperature Tinitial at the lower-level of the modeling architecture. As shown in Fig. 3, a PBA model is used to compute an estimate of Tinitial (denoted by ), then a Gaussian process regression (GPR) model is trained to model , which is the difference between the reference value of Tinitial produced by FEA and .
2.2.1 Physics-Based Analytical Model.
For a multitrack build illustrated in Fig. 1, by the results from Ref. [26], the initial temperature at a point of select-to-scan with coordinate (x, y, z) equals the initial temperature of the substrate (ambient temperature unless the substrate is preheated) plus the summation of temperature contributions of all past tracks. Specifically, for each past track i, a pair of virtual heat sources i are assigned to replace the original laser heat source as soon as it finishes the scanning of track i to characterize the subsequent temperature cooling. The temperature contribution from each past track i is computed by the temperature induced from the virtual heat-source pair i. Detailed computation of such temperature contributions as well as the final initial temperature is given in Appendix A.
2.2.2 Gaussian Process Regression Model for Error Approximation.
Gaussian process regression models are often interpreted as defining a distribution over functions. The predictions from a GPR model take the form of a predictive distribution, which is completely specified by its mean function and covariance function. In the lower-level of the modeling architecture, GPR is used to learn and predict the error between the reference initial temperature generated by the FEA simulations of netfabb and that computed by the analytical model, i.e., to model and predict as illustrated in Fig. 3.
For each track in the multitrack part, we collect the following data for the Gaussian process training: (i) deposition distance of each sampling point si measured from the start of the track, where , with L denoting the track length; (ii) net power applied at this sampling point qi which is equal to the product of laser power Q and laser absorption efficiency η (assuming other process parameters fixed); and (iii) the resulting error ei in initial temperature between the PBA computation and the FEA reference value for the sampling point. The number of sampling points in each track here depends on the step size in the FEA simulation. Then, let denote the matrix of input vectors for training with , where n denotes the total number of samples used in the training set. The matrix is often referred to as the design matrix. Let denote the series of the observed error in initial temperature corresponding to each input vector in . Consequently, the training dataset for GPR can be denoted as . A test input matrix corresponding to the testing dataset can be defined accordingly.
where denotes the covariance matrix by applying Eq. (1) in an elementwise manner, i.e., with element for training and/or testing input samples and .
2.3 Upper-Level: Prediction of Melt-Pool Size.
In terms of the ML terminology, the melt-pool size here is referred to as the response. The input-feature vector consisting of the process parameters, laser deposition distance along the track, and the initial temperature is referred to as the input. The mapping from the input to the response is the regression function to be learned by the upper-level ML. In addition to GPR, seven other commonly used ML algorithms are also examined at the upper-level to predict melt-pool size. They are: (i) ML-based linear regression, (ii) Kernel ridge regression, (iii) regression tree, (iv) support vector machine, (v) boosted trees, (vi) random forests, and (vii) a shallow neural network. Fivefold cross-validation is implemented to determine the hyperparameters of the ML algorithms. The regression analysis is performed in matlab using the statisticsandmachinelearningtoolbox.
2.4 Nondimensionalization and Normalization of Input Features.
where Tm denotes the melting temperature of the material of the build part, and T0 denotes the ambient temperature. After nondimensionalization, we further normalize each input feature with respect to its maximum and minimum values to rescale it into the range of 0–1. The laser power does not go through nondimensionalization, and only normalization is applied to scale it into the range of 0–1.
3 Simulated Data for Training and Testing
In this study, autodesk'snetfabbsimulation is used to simulate the L-PBF process in generating training and testing data for the prediction of melt-pool size. netfabbsimulation is capable of computing the melt-pool volume during the build process.
A single-layer, multitrack part of Inconel 625, as illustrated in Fig. 1, is simulated with netfabb. Specifically, the part has six parallel tracks with each track's length and a hatch spacing of , built on top of a substrate of Inconel 625 with a dimension of . Under a constant laser scan speed of , five simulation experiments are conducted, each with a constant laser power chosen from the set (). The process parameters and the material property of Inconel 625 used in the netfabb simulations are listed in Tables 5 and 6, respectively, in Appendix B. Four elements per laser radius are used for mesh generation along the laser path, and the corresponding FEA mesh is shown in Fig. 4. The temporal resolution (average time-step) of the simulation is 4.6875 s.
Parameter | Value |
---|---|
Hatch spacing (mm) | 0.1 |
Laser beam diameter (mm) | 0.075 |
Laser scan speed (mm/s) | 800 |
Interhatch dwell time (s) | |
Laser absorption efficiency | 0.4 |
Parameter | Value |
---|---|
Hatch spacing (mm) | 0.1 |
Laser beam diameter (mm) | 0.075 |
Laser scan speed (mm/s) | 800 |
Interhatch dwell time (s) | |
Laser absorption efficiency | 0.4 |
T () | Thermal conductivity | Specific heat |
---|---|---|
25 | 10.0 × 10−3 | 405 |
200 | 12.5 × 10−3 | 460 |
300 | 14.0 × 10−3 | 480 |
400 | 15.0 × 10−3 | 500 |
500 | 16.0 × 10−3 | 525 |
600 | 18.0 × 10−3 | 550 |
800 | 22.0 × 10−3 | 600 |
900 | 24.0 × 10−3 | 630 |
1000 | 25.0 × 10−3 | 650 |
1200 | 25.5 × 10−3 | 680 |
1290 | 102 × 10−3 | |
Material density | ρ () | 8440 |
Melting temperature | Tm () | 1295 |
Latent heat of fusion | HSL (J/kg) | 287,000 |
Convection coefficient | αs () | 25 |
T () | Thermal conductivity | Specific heat |
---|---|---|
25 | 10.0 × 10−3 | 405 |
200 | 12.5 × 10−3 | 460 |
300 | 14.0 × 10−3 | 480 |
400 | 15.0 × 10−3 | 500 |
500 | 16.0 × 10−3 | 525 |
600 | 18.0 × 10−3 | 550 |
800 | 22.0 × 10−3 | 600 |
900 | 24.0 × 10−3 | 630 |
1000 | 25.0 × 10−3 | 650 |
1200 | 25.5 × 10−3 | 680 |
1290 | 102 × 10−3 | |
Material density | ρ () | 8440 |
Melting temperature | Tm () | 1295 |
Latent heat of fusion | HSL (J/kg) | 287,000 |
Convection coefficient | αs () | 25 |
Simulated data from the netfabb are plotted in Fig. 5. Figure 5(a) shows the initial temperature with respect to the deposition distance s (from 0 to 10 mm) for each track under each constant process condition, where each subplot from left to right corresponds to track 1–track 6. In netfabb simulation, the temperature at a distance of four times laser-spot-size ahead of the laser is picked as the initial temperature at the select-to-scan point. Figure 5(b) shows the resulting melt-pool volume, which is computed as the volume of the melted material (above the material melting temperature, 1295 for Inconel 625) at the time instant when the laser passes by. Figures 5(c) and 5(d) provide a visualization of the FEA simulated melt-pool volume and temperature profile under the laser power Q = 250 W, where two locations during the scanning of the second track are selected for demonstration. Figure 5(c) shows the melt-pool volume right after the start of the second track at distance = 0.375 mm (of a 10 mm track). Figure 5(d) shows the melt-pool volume right after the midpoint of the second track at distance = 5.625 mm, where the melt-pool volume is nearly back to steady-state. Point A/B in Figs. 5(c) and 5(d) illustrates schematically where the initial temperature is picked: ahead of the laser but the temperature is not affected by the laser heat source—it only reflects the thermal buildup due to scanning the past tracks.
Note that under the relatively low laser power, e.g., 100 W, the temperature along the track may stay lower than the melting temperature even in the presence of thermal history, which causes the resulting melt-pool volume to be nearly zero. However, we still include these data in training the two-level machine-learning model, for the sake of predicting melt-pool volumes under a varying laser-power trajectory within the range of 100–250 W, which will be presented in Sec. 4.2.
As shown in Fig. 5, under each constant process condition (combination of a constant laser-power value and v = 800 mm/s), the initial temperature for the first track stays constant as the ambient temperature, and the corresponding melt-pool volume stays constant as well after a quick transient. However, starting from the second track, the initial temperature at the beginning of each track rises up drastically, caused by the laser scan pattern where the laser repeatedly heats the track end. As a result, the melt-pool volume surges at the beginning of each track, and it then gradually reduces to a steady-state value with the increase of the distance s. The proposed ML model needs to capture and predict such change in the melt-pool volume caused by thermal history, despite of under constant process parameters.
Consequently, for this six-track build, only track 2–track 6 are of interest to model the melt-pool volume variation in the presence of thermal history. In this study, the simulated data on initial temperature and melt-pool volume from track 2 to track 5 will be used for training and cross-validation to choose hyperparameters of the ML algorithms. Then, the simulated data on initial temperature and melt-pool volume from track 6 will be used for testing. In addition, we will use the trained ML model to predict the melt-pool volumes under a varying laser-power trajectory and compare the model predictions with that from the netfabb simulation (Sec. 4.2).
4 Results and Discussions
Two testing cases are considered in this study to evaluate the performance of the proposed two-level ML architecture. First, the trained model is used to predict the melt-pool volume in building a new track (track 6) in the multitrack part under constant process parameters (Sec. 4.1). The main purpose of this testing case is to evaluate the ML-based model in capturing the melt-pool volume variation subject to thermal history, which is important in modeling any part consisting of more than a single-track. Hence, for the simplicity of illustration, constant process parameters used in the training are applied in this testing case. In the second testing case (Sec. 4.2), the trained ML model is used to predict the melt-pool volumes of track 2–track 5 but under a varying laser-power trajectory, which includes predictions for untrained process conditions. For the lower-level GPR model that is used to learn the modeling error of the PBA model, the hyperparameters obtained from the model training are and . For the upper-level GPR model that is used to predict the melt-pool volume, the hyperparameters obtained from the model training are and . The tuned hyperparameters of other ML algorithms are given in Appendix C.
4.1 Prediction for a New Track
4.1.1 Prediction of Initial Temperature.
At the lower-level of the two-level architecture, a hybrid model (PBA + GPR) is trained to predict the initial temperature. Figure 6 shows the hybrid-model predicted initial temperature along the scanning of track 6 versus that generated by FEA as the ground truth. Corresponding to the testing data for track 6, the averaged root-mean-square error (RMSE) between the PBA model predictions and the FEA simulated reference data is , whereas the hybrid model has a RMSE of , with a reduction of 65.5% in RMSE compared to the PBA model.
4.1.2 Prediction of Melt-Pool Volume.
At the upper-level of the two-level architecture, GPR and other seven commonly used ML algorithms are evaluated in predicting melt-pool volumes for track 6 using the initial temperature predicted by the hybrid model. The coefficient of determination R2 and the regression loss in RMSE are used to compare the performance of these ML algorithms with respect to the FEA simulated data as the ground truth. The corresponding statistics are given in Table 1, where and Ltrain are computed on training data for track 2–track 5, and and Ltest are computed on testing data for track 6. Table 1 shows that all ML algorithms have performed really well except the ML-based linear regression, suggesting that a nonlinear function is more suitable to characterize the mapping from the input features to the melt-pool size. The GPR model achieves the highest R2 value and the lowest RMSE among all the upper-level ML algorithms, but the difference between its R2 value and that of the other high-performing ML algorithms is small or negligible, further indicating that any of the upper-level ML algorithms being examined (except linear regression) has performed sufficiently well. Figure 7(a) shows the scatter plot of the GPR predicted melt-pool volumes for track 6 versus the FEA simulated response as the ground truth. Figure 8(a) shows the trajectory of GPR predicted melt-pool volume with respect to the distance s for track 6 versus the reference trajectory given by the FEA simulation. It is observed that the predictions have a good agreement with the reference values.
Upper-level ML algorithms | Ltrain (mm3) | Ltest (mm3) | ||
---|---|---|---|---|
Gaussian process | 0.9999 | 7.41 × 10−6 | 0.9993 | 2.81 × 10−5 |
Linear regression | 0.7632 | 4.54 × 10−4 | 0.7533 | 5.58 × 10−4 |
Kernel ridge | 0.9955 | 4.97 × 10−5 | 0.9927 | 8.11 × 10−5 |
Regression tree | 0.9983 | 3.94 × 10−5 | 0.9939 | 8.97 × 10−5 |
Support vector | 0.9569 | 1.92 × 10−4 | 0.9543 | 2.37 × 10−4 |
Boosted trees | 0.9994 | 2.11 × 10−5 | 0.9949 | 7.51 × 10−5 |
Random forests | 0.9998 | 1.24 × 10−5 | 0.9954 | 8.01 × 10−5 |
Shallow neural network | 0.9997 | 1.39 × 10−5 | 0.9991 | 2.96 × 10−5 |
Upper-level ML algorithms | Ltrain (mm3) | Ltest (mm3) | ||
---|---|---|---|---|
Gaussian process | 0.9999 | 7.41 × 10−6 | 0.9993 | 2.81 × 10−5 |
Linear regression | 0.7632 | 4.54 × 10−4 | 0.7533 | 5.58 × 10−4 |
Kernel ridge | 0.9955 | 4.97 × 10−5 | 0.9927 | 8.11 × 10−5 |
Regression tree | 0.9983 | 3.94 × 10−5 | 0.9939 | 8.97 × 10−5 |
Support vector | 0.9569 | 1.92 × 10−4 | 0.9543 | 2.37 × 10−4 |
Boosted trees | 0.9994 | 2.11 × 10−5 | 0.9949 | 7.51 × 10−5 |
Random forests | 0.9998 | 1.24 × 10−5 | 0.9954 | 8.01 × 10−5 |
Shallow neural network | 0.9997 | 1.39 × 10−5 | 0.9991 | 2.96 × 10−5 |
4.1.3 Comparison of Two-Level Machine-Learning Prediction Versus a Single-Level Machine-Learning Prediction.
where n denotes the number of samples, and l represents the number of independent input features. For the single-level GPR, the resulting , whereas for the upper-level GPR of the two-level ML, .
RMSE (mm3) | 100 W | 150 W | 200 W | 250 W | 300 W |
---|---|---|---|---|---|
One-level | 5.32 × 10−7 | 1.09 × 10−5 | 1.22 × 10−4 | 2.84 × 10−4 | 5.37 × 10−4 |
Two-level | 1.38 × 10−7 | 2.69 × 10−6 | 1.84 × 10−5 | 3.18 × 10−5 | 5.21 × 10−5 |
RMSE (mm3) | 100 W | 150 W | 200 W | 250 W | 300 W |
---|---|---|---|---|---|
One-level | 5.32 × 10−7 | 1.09 × 10−5 | 1.22 × 10−4 | 2.84 × 10−4 | 5.37 × 10−4 |
Two-level | 1.38 × 10−7 | 2.69 × 10−6 | 1.84 × 10−5 | 3.18 × 10−5 | 5.21 × 10−5 |
4.2 Prediction of Melt-Pool Volumes Under a Varying Laser-Power Trajectory.
The two-level ML, with GPR at the upper-level, is also used to predict the melt-pool volume under a varying laser-power trajectory for track 2–track 5, where the laser scan speed remains at v = 800 mm/s. The varying laser-power trajectory, shown in Fig. 9(a), corresponds to the laser-power trajectory of a nonlinear inverse-dynamics control [34], which was derived from an analytic model of melt-pool dynamics to regulate the melt-pool volume to a constant set point during the build process. Specifically, a constant laser power of was applied for track 1, where the melt-pool volume reached around mm3 after the initial transient, in terms of Fig. 5(b). Then, a varying laser-power trajectory was derived for track 2–track 5 to compensate for heat accumulation so that the resulting melt-pool volume can be regulated to the same steady-state value of the first track.
4.2.1 Computation Cost of Machine-Learning Prediction Versus Finite Element Analysis.
In computing the melt-pool volumes for the first five tracks under the varying laser-power trajectory, the prediction by the two-level ML model took 0.0248 s in matlab, whereas the FEA via autodesk'snetfabblocalsimulation took 1.985 h. Both ML predictions and FEA simulations were conducted on a Dell® computer with Intel® Xeon® CPU E5-2687W (3.4 GHz) (Round Rock, TX). Hence, the ML model, once trained, shows a great promise as an approximation to the FEA prediction for unobserved process conditions with a significantly lower computation cost.
5 Exploration of Additional Process Parameters and Input-Feature Space
5.1 Input-Feature Space.
For the ML models discussed in Secs. 2–4, we have focused on the three-tuple input features, which consist of the laser power, laser distance s from the start of the track, and the initial temperature. The ML models are learned as a function of laser power but with other process parameters fixed. It is not difficult to add additional process parameters such as laser scan speed to the proposed ML models, as the analytical computation of the initial temperature (see Appendix A) can accommodate any given scan speed, and it is straightforward to expand the input dimension of the GPR model to include additional process parameters.
In this section, we examine when the energy density is adopted as an input feature, if the model trained with the same amount of data as in Sec. 3 (collected from v = 800 mm/s and five levels of laser power) can be used to predict the melt-pool volume under a different laser scan speed. Volumetric power input is commonly used to define energy density = [35], where P is the laser power, v is the laser scan speed, h is the hatch spacing, and lt denotes the layer thickness. In this study, considering a fixed hatch spacing and a single layer, the input feature representing the energy density is then defined as the ratio of laser power P and laser scan speed v, i.e., .
This section will also evaluate if adding the track number of the multitrack part to the inputs of the upper-level GPR model would improve the prediction performance, and furthermore, if using both the track no. and distance s as input features will be sufficient to replace initial temperature for the GPR model (which then reduces into a single-level ML) without causing much performance degradation.
To answer these questions, this section conducts a more systematic search of the input-feature space of the upper-level GPR model by successively reducing information to the model inputs from an initial comprehensive set of input features to help understand the relative importance of each input feature in the modeling. As detailed in Table 3, the upper-level GPR model A-1 in group 1 contains the most comprehensive list of input features; from group 1 to group 2, track no. (TRN) is dropped from the list of input features; and then from group 2 to group 3, distance s (DIS) is dropped from the list of input features. Within each group, from model A to model C, the energy density is either dropped from the model inputs or used to replace the other two process parameters: laser power and scan speed. Model D-1 in group 1 is used to examine if including both track no. and distance s as input features of a GPR model can replace the information provided by the initial temperature. That is, model D-1 reduces into a new single-level ML. It should be noted that the training data remain the same as obtained in Sec. 3, with output responses of the training data remain to be the melt-pool volumes from track 2 to track 5, only with the input vector of the training data varying from A-1 to C-3 in Table 3. No additional training data are used here. As the number of input features varies, the adjusted coefficient of determination is used here to evaluate and compare the upper-level GPR models.
Group | Upper-level GPR models | Input features |
---|---|---|
1 | A-1 | DIS, TRN, POW, SPD, EDS, and ITM |
B-1 | DIS, TRN, POW, SPD, and ITM | |
C-1 | DIS, TRN, EDS, and ITM | |
D-1 | DIS, TRN, and EDS | |
2 | A-2 | DIS, POW, SPD, EDS, and ITM |
B-2 | DIS, POW, SPD, and ITM | |
C-2 | DIS, EDS, and ITM | |
3 | A-3 | POW, SPD, EDS, and ITM |
B-3 | POW, SPD, and ITM | |
C-3 | EDS and ITM |
Group | Upper-level GPR models | Input features |
---|---|---|
1 | A-1 | DIS, TRN, POW, SPD, EDS, and ITM |
B-1 | DIS, TRN, POW, SPD, and ITM | |
C-1 | DIS, TRN, EDS, and ITM | |
D-1 | DIS, TRN, and EDS | |
2 | A-2 | DIS, POW, SPD, EDS, and ITM |
B-2 | DIS, POW, SPD, and ITM | |
C-2 | DIS, EDS, and ITM | |
3 | A-3 | POW, SPD, EDS, and ITM |
B-3 | POW, SPD, and ITM | |
C-3 | EDS and ITM |
The GPR model A-1 includes the most comprehensive set of input features. From group 1 → group 2, track no. is dropped from the list of model inputs; and from group 2 → group 3, DIS is dropped from the model inputs. Within each group, from model A → C, EDS is either dropped from the model inputs or used to replace POW and SPD.
5.2 Testing on a New Track.
Figure 10 shows the scatter plots of the predictions by the upper-level GPR models A-1 to C-3 on melt-pool volumes of a new track (track 6) versus the ground truth (FEA predictions using netfabb), where the process conditions (laser power and scan speed) stay the same from the training to the testing. The value of for each model is provided in the caption of each subplot. Following observations are made:
Adding track no. to the input features would only degrade the model prediction performance, by comparing the scatter plots of group 1 (A-1, B-1, and C-1) and those of group 2 (A-2, B-2, and C-2). This is not unexpected since the new track no., where a prediction needs to be made, cannot be interpolated from the training set.
The laser distance (DIS) is an input feature that should be included. By comparing the scatter plots of group 2 (A-2, B-2, and C-2) and those of group 3 (A-3, B-3, and C-3), a visible performance degradation with reduced is observed when DIS is removed from the inputs of the upper-level GPR.
Replacing the initial temperature by the track no. and laser position on the track renders model D-1 fail to predict the melt-pool volume of a new track, indicated by R2 = 0 or negative value for (marked as n/a in Fig. 10).
In addition, it is reasonable to see that all three models A-2 to C-2 perform with no difference when the process conditions remain the same from training to testing, and the corresponding scatter plots for A-2 to C-2 resemble the scatter plot in Fig. 7(a).
5.3 Testing on a New Scan Speed.
As the main objective here is to examine how different choices of input features would affect the performance of the upper-level GPR model, the FEA simulated initial temperatures under the new scan speed are fed into the upper-level when the initial temperature (ITM) is one of the input features of the upper-level GPR model. That is, all upper-level GPR models A's to C's are compared based on the same lower-level outputs. Figure 11 shows the scatter plots of the predictions by the upper-level GPR models A-1 to C-3 on the melt-pool volumes under a new scan speed v = 1000 mm/s versus the ground truth (FEA simulated response using netfabb). It is noticed that when the laser scan speed is included as one of the input features (e.g., A-1, B-1; A-2, B-2; and A-3, B-3), the corresponding model trained at a single scan speed is not able to predict for a new scan speed with an acceptable performance. However, by comparing the scatter plot of model B-2 to that of model C-2, it is observed that when the energy density is adopted as an input feature to replace the inputs of laser power plus scan speed, it enables the model to predict, with an approximation, at a new scan speed. This can be explained as follows. The training is performed at v = 800 mm/s with the five laser-power levels within 100 W–300 W, which is equivalent to the energy density E ranging within 0.125–0.375 (). Then for the testing scan speed of v = 1000 mm/s combined with the five laser-power levels, the energy density E ranges from 0.1 to 0.3 (), mostly within the training range of E. Such results imply that using the energy density as an input feature (rather than two process inputs on laser power and scan speed) could potentially save the amount of required training data.
6 Conclusions
This paper developed a two-level machine-learning model to predict the melt-pool size as a function of process parameters during the scanning of a multitrack part in L-PBF. By utilizing a hierarchical modeling architecture, the proposed machine-learning model was able to include the prescan initial temperature as a physics-informed input feature at the upper-level and thus enabled the model to capture the effect of thermal history on the melt-pool size in scanning a multitrack part, without having to resort to deep neural networks that could require a more complicated training process and a large amount of training data. The proposed two-level machine-learning model predictions had 74–90% lower RMSE than the single-level machine-learning model without including the initial temperature as an input feature. In addition, simulation results indicated that as long as the initial temperature was included as an input feature, any of the upper-level machine-learning algorithms being examined (except linear regression) performed sufficiently well. The modeling methodology was demonstrated on the melt-pool volume in this paper, but it can be applied to any melt-pool geometric variables such as melt-pool width or depth. Currently, autodesk'snetfabb outputs melt-pool volume, but it is not difficult to add a postprocessing procedure to extract other melt-pool geometric variables [36].
Future work will include validation of the proposed machine-learning models using experimental data. It might be difficult to directly measure melt-pool volume experimentally. However, melt-pool geometric variables such as melt-pool cross-sectional area, width, and depth could be measured by cross-sectioning of a multitrack sample followed by etching and image processing [26]. Nevertheless, for samples with a short track length, the number of experimental data sets that could be obtained from cross-sectioning is often limited, as cross-sectioning and polishing result in a significant loss of material per cut. Alternatively, melt-pool length and width could be extracted from high-speed infrared imaging of melt pools [37]; nevertheless, the experimental study in Ref. [37] contained only measurements from single scan tracks.
Funding Data
PA Manufacturing Fellows Initiative (Subcontract No. 1060145-406189).
Penn State University (ICDS Seed Grant).
NSF (Grant No. 2015930; Funder ID: 10.13039/100000001).
An Analytical Model on Prescan Initial Temperature
This appendix summarizes the analytical computation of initial temperature derived in our prior work [26,31]. Consider the initial temperature at the deposition (or select-to-scan) point before laser hits it and assume that the temperature at a (small) distance ahead of the moving laser source has yet been heated up by the laser heat source. Such initial temperature at the select-to-scan point represents the thermal contribution due to the scanning of all past tracks, excluding the effect of scanning the current track.
As shown in Fig. 12, after the moving heat source finishes scanning a track i with a constant net power q (which is equal to the product of laser power Q and the laser absorption efficiency η) and speed v, a pair of virtual heat sources, consisting of a positive virtual heat source i (with net power q) and a negative virtual heat source i (with net power −q, also referred to as a virtual heat sink), are assigned to track i. The positive virtual heat source i represents the continuation of the physical heat source, whereas the virtual heat sink i starts when the physical heat source ceases to scan track i. The pair of virtual heat sources keep traveling with the same speed v and direction as the original physical heat source in scanning track i. Then, the prescan initial temperature at any select-to-scan point is equal to the ambient temperature plus the summation of the temperature contributions from all pairs of virtual heat sources representing all past tracks.
where denotes the distance from the point of interest to the center of the laser heat source, k denotes a constant thermal conductivity, and a denotes a constant thermal diffusivity with , where ρ is the material density and Cp is the constant specific heat.
with erf() denoting the error function.
where L denotes the track length; if j is odd or if j is even, with denoting the x-coordinate of the virtual heat-source pair i; and . The computation of the x-coordinate can easily accommodate the laser scan pattern and interhatch dwell time during which the virtual heat sources keep traveling.
Note that the computation of the initial temperature uses the Rosenthal's solution in Eq. (A3), and the Rosenthal's solution was derived based on the assumption that the thermal properties of the material are constants. Hence, in this study, an average thermal conductivity and specific heat with a subsequent constant thermal diffusivity (given in Table 4) are used in the computation of the initial temperature, in contrast to that temperature-dependent material properties are used in the netfabb FEA simulations. All other process parameters take the same values as used in the netfabb simulations as given in Table 5.
Process Parameters and Material Properties Used in netfabb Finite Element Analysis
Hyperparameters of Machine-Learning Algorithms
The tuned hyperparameters of the ML algorithms evaluated in Sec. 4 are presented as follows. The hyperparameter values of the GPR are given in Sec. 4 and thus omitted here.
Machine-learning-based linear regression: matlabfitlm is used. The objective is to tune the weights of , where y denotes the system output; x1, x2, and x3 denote the normalized input-feature deposition distance, laser power, and initial temperature, respectively. The tuned weights are β0 = −0.1358, β1 = 0.0175, β2 = 0.3610, and β3 = 0.3994.
Kernel ridge regression: The objective is to solve , where y denotes the vector of sample outputs, and X is a matrix formed by the feature vectors, satisfying , where denotes a feature mapping corresponding to a kernel matrix K. A squared exponential kernel is used here. The optimized solution w satisfies . The hyperparameters are set as λ = 0.001 and σl = 0.5.
Regression tree: matlabfitrtree is used. No hyperparameters are tuned.
Support vector regression: matlabfitrsvm is used. The objective is to solve , where b is the bias, denotes the ϵ-insensitive loss, and denotes a feature mapping corresponding to a squared exponential kernel . The hyperparameter σl = 1.
Boosted trees: matlabfitrensemble is used. Number of learning cycles (number of trees) = 100.
Random forests: Number of learning cycles (number of trees) = 200.
Shallow neural network: matlabfitnet is used. Number of neurons in the hidden layer = 30.
Footnotes
When the covariance matrix of the training data is not invertible, a small noise variance could be set to ensure the invertibility of the matrix .