Material tensile property prediction method based on nanoindentation and machine learning
Through nano-indentation and machine learning methods, a microstructure-stress-strain field database was constructed, and the U-Net deep learning framework was used to predict the tensile performance of materials, which solved the problem of single and time-consuming prediction of traditional methods, and achieved efficient and accurate prediction of the tensile performance of materials.
Patent Information
- Application Number
- CN202510047678.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-13
- Publication Date
- 2025-05-16
- Estimated Expiration
- 2045-01-13
AI Technical Summary
The traditional constitutive model has a single prediction result and cannot effectively reflect the internal stress and strain distribution of materials. It is time-consuming and expensive to obtain stress and strain curves and serialize cloud maps of existing metal materials.
Using nano-indentation and machine learning methods, microstructure photos, finite element simulations, and microstructure-stress and strain field databases are taken through metallographic microscope, and architecture adjustment and optimization are used to predict material tensile performance and provide stress and strain cloud diagrams and curves.
It realizes a highly automated prediction of the structure-effect relationship of materials, greatly reducing labor and time costs, and the prediction accuracy reaches more than 95%, which can effectively reflect the internal stress and strain distribution of materials and shorten the research and development cycle of new materials.
Smart Images

Figure CN120015189A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of material tensile properties prediction, and in particular to a material tensile properties prediction method based on nanoindentation and machine learning. Background Art
[0002] Traditional constitutive models fail to consider the distribution of stress-strain cloud maps corresponding to the curves while predicting the stress-strain curves. The prediction results are single and cannot effectively reflect the stress-strain distribution and change process inside the material. The existing metal materials have the problem of time-consuming and consumable materials for obtaining stress-strain curves and serialized cloud maps. Traditional material mechanical property tests, such as tensile tests, usually require the preparation of a large number of specimens, and only limited data points can be obtained for each test. This not only consumes a lot of time and resources, but is also particularly expensive for newly developed materials or material testing in special application scenarios. The macroscopic mechanical properties of materials are closely related to their microstructures (such as grain size, phase distribution, defects, etc.). However, it is difficult for traditional methods to directly link microstructural characteristics with macroscopic mechanical properties, resulting in an insufficient understanding of material behavior. Therefore, a material tensile property prediction method based on nanoindentation and machine learning is provided. Summary of the invention
[0003] The purpose of the present invention is to provide a material tensile properties prediction method based on nanoindentation and machine learning, so as to solve the problems proposed in the above background technology that the prediction results of the traditional constitutive model are single and the existing metal material stress-strain curves and serialized cloud maps are time-consuming and consumable.
[0004] To achieve the above object, the present invention aims to provide a method for predicting material tensile properties based on nanoindentation and machine learning, comprising the following steps: S1. Use a metallographic microscope to take metallographic photos of microstructures and pre-process the metallographic photos; S2, performing finite element simulation based on the structure on the pre-processed metallographic photograph to obtain stress-strain data; S3, constructing a microstructure-stress-strain field database based on metallographic photographs and stress-strain data; S4. Based on the microstructure-stress-strain field database, the U-Net deep learning framework is adjusted and optimized to predict the tensile properties of materials and provide stress-strain cloud maps and curves.
[0005] As a further improvement of the technical solution, in S2, the pre-processed metallographic photograph is subjected to a finite element simulation based on the structure to obtain stress-strain data, comprising the following steps: S2.1. Select multiple locations from the pre-processed metallographic photographs, apply a series of known loads using a nanoindenter, and record the corresponding displacement responses; S2.2, import the pre-processed metallographic photograph into the finite element software, and divide the image into fine grids according to the microstructural features in the metallographic photograph, where each grid unit corresponds to a pixel point in the metallographic photograph; S2.3, apply periodic boundary conditions to the finite element model; S2.4. Based on the results of nanoindentation, specify the material properties of different regions in the finite element model; S2.5, set simulation conditions, start the finite element analysis software to perform simulation calculations according to the set conditions, and output data according to equal strain intervals during the calculation process; S2.6. After the simulation calculation is completed, the stress and strain data corresponding to the microstructure image at each moment are extracted frame by frame, and the stress and strain values of each grid unit are extracted in turn in each frame; S2.7. Use the extracted stress-strain value data to draw a stress-strain cloud diagram, and calculate the average value of the stress-strain values of all grid units as the stress-strain curve data of the entire material.
[0006] As a further improvement of the technical solution, in S3, constructing a microstructure-stress-strain field database based on metallographic photographs and stress-strain data includes the following steps: S3.1, obtaining all pre-processed metallographic photographs and corresponding stress-strain data from step S1 and step S2 as samples; S3.2, according to the time and space position, each metallographic photo is matched with its corresponding stress and strain data through the time and space registration algorithm; S3.3, converting the metallographic photographs into a tensor format used for machine learning, and also converting the stress-strain data into a tensor format; S3.4, dividing the processed tensor data into a training set and a test set according to the required ratio; S3.5. Select a relational database management system, define the table structure, and enter the converted image tensor and stress-strain data tensor into the database to form a microstructure-stress-strain field database.
[0007] As a further improvement of the technical solution, in S3.2, each metallographic photograph is matched one-to-one with its corresponding stress-strain data by a spatiotemporal registration algorithm, including the following steps: S3.21. Verify that the timestamps of each metallographic photograph and the corresponding stress-strain data are accurately recorded and synchronized with each other; S3.22. Based on the experimental setup, preliminarily estimate the spatial position relationship between the metallographic photographs and the stress-strain cloud map; S3.23, use the feature detection algorithm SIFT to extract stable feature points from metallographic photos; S3.24, matching the two sets of feature points to find the best correspondence; S3.25, calculating a geometric transformation model according to the matched feature points; S3.26, applying the calculated transformation to the stress-strain contour data to align them spatially with the metallographic photograph; S3.27. Using mutual information as a metric, the transformation parameters are adjusted through an optimization algorithm until the best match is achieved.
[0008] As a further improvement of the technical solution, in S3.27, the mutual information is: ; in, Represents the pixel value distribution in the metallographic photograph; Represents the stress value distribution in the stress-strain cloud diagram; Indicates the probability of a certain pixel value appearing in the metallographic photograph; Indicates the probability of a certain stress value appearing in the stress-strain cloud diagram; It indicates the probability of co-occurrence of pixel values and stress values at the same position in the metallographic photograph and the stress-strain cloud map; Represents all possible pixel values in the metallographic photograph; Represents all possible stress values in the stress-strain cloud diagram; Represents a specific pixel value in a metallographic photograph; Represents a specific stress value in the stress-strain cloud diagram.
[0009] As a further improvement of the technical solution, in S4, based on the microstructure-stress-strain field database, the U-Net deep learning framework is adjusted and optimized to predict the tensile properties of the material, and a stress-strain cloud map and curve are provided, including the following steps: S4.1, load the training set and test set from the constructed microstructure-stress-strain field database; S4.2, select the U-Net architecture consisting of an encoder and a decoder as the starting point, and the encoder and decoder are connected at both ends through a skip connection; S4.3, adjusting the encoder and decoder; S4.4, define an error function to measure the difference between the predicted stress and strain values and the true values; S4.5. Determine the model hyperparameters, train the model based on the training set, monitor the changing trend of the training loss, and save the parameters after the training is completed; S4.6, performing model evaluation based on the test set in the database constructed in step S3; S4.7. Use the trained model to predict the new metallographic photograph, output the corresponding predicted stress-strain cloud map, and draw the stress-strain curve based on the predicted stress-strain value.
[0010] As a further improvement of the technical solution, in S4.3, adjusting the encoder and the decoder includes the following steps: S4.31, adjust the encoder to use a 3×3 convolution kernel in each convolution layer, with a step size of 1, and use the same padding method for padding. The weights of each layer are initialized to normal distribution random values with a mean of 0 and a standard deviation of 0.02; S4.32. ReLU is used as the activation function in the encoder, and the maximum pooling method is used to gradually reduce the spatial dimension of the input; S4.33, adjust the decoder to use a 2×2 convolution kernel with a stride of 2 in each deconvolution layer; S4.34. Concatenate the feature map in the encoder with the feature map of the corresponding level in the decoder. If the size after deconvolution does not match, use bilinear interpolation to adjust it to the appropriate size.
[0011] As a further improvement of the technical solution, in S4.32, a maximum pooling method is used to gradually reduce the spatial dimension of the input, including the following steps: S4.321, performing image segmentation on the pre-processed metallographic photograph; S4.322. Select pooling window size ; S4.323. Determine the distance the pooling window moves each time ; S4.324, for each channel Traverse the entire input image, for position The maximum value is calculated by the maximum pooling formula, and the maximum pooling formula is optimized according to the directional characteristics of the grain boundaries in the metallographic photos; S4.325, place the maximum value in the new output activation map At the corresponding position in , a downsampled image is formed; S4.326. After maximum pooling, a new feature map is obtained, and the spatial dimension of the new feature map is smaller than the original input.
[0012] As a further improvement of the technical solution, in S4.324, the maximum pooling formula is: ; in, Indicates that the output feature map of a pooling operation in a certain layer of the U-Net model is at position and Channel The value of Indicates the height of the pooling window; Indicates the width of the pooling window; Indicates the step size of the pooling window; Indicates the channel index; Represents the row offset within the pooling window; represents the column offset within the pooling window; According to the directional characteristics of grain boundaries in metallographic photos, the maximum pooling formula is optimized: ; ; in, Indicates that the output feature map after optimization is at position and Channel The value of represents the direction-sensitive weight of the grain boundary; represents the adjustment coefficient of the directional weight; Indicates the first The gradient direction of pixels; represents the main direction angle; Represents the weight adjustment coefficient of the gradient amplitude; Indicates the pixels in the metallographic photo Point The gradient value of the direction; Indicates the pixels in the metallographic photo Point The gradient value of the direction.
[0013] As a further improvement of the technical solution, in S4.4, the error function is: ; in, represents the average mean square error of all samples; represents the total number of samples; Indicates the number of frames per sample; Indicates The sample in The true stress-strain values of the frame; Indicates The sample in Predicted stress-strain values of the frame; Indicates the sample index; Indicates the frame index.
[0014] Compared with the prior art, the present invention has the following beneficial effects: 1. In this material tensile properties prediction method based on nanoindentation and machine learning, with the help of the trained U-Net deep learning model, a highly automated prediction result of the structure-activity relationship of the material can be made. Compared with the experimental and finite element simulation methods, the U-Net deep learning model can give the prediction curve and cloud map in a very short time, which greatly reduces the manpower and time costs. The trained model can achieve a prediction accuracy of more than 95%, and can maintain stable prediction for different test images.
[0015] 2. In this material tensile properties prediction method based on nanoindentation and machine learning, the frame data of the material stress-strain field is output through the U-Net deep learning model, so that the stress-strain cloud map can be drawn based on the output data, and the internal stress state of the material under stress can be analyzed according to the stress-strain cloud map at different stages. The stress and strain physical field is predicted through the material microstructure geometry, which bridges the gap between the material's microstructure and physical properties, and provides scalability by predicting complex material behavior (regardless of component shape, boundary conditions, and geometric hierarchy). BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Figure 1 is a flow chart of the overall method of the present invention; Figure 2 A schematic diagram of a network model provided by the present invention; Figure 3 A schematic diagram showing the comparison between the predicted stress field cloud map and the target cloud map of the present invention; Figure 4 This is a schematic diagram comparing the predicted strain field cloud map and the target cloud map of the present invention; Figure 5 It is a schematic diagram comparing the predicted stress-strain curve and the target curve of the present invention. DETAILED DESCRIPTION
[0017] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0018] Example: See Figure 1 As shown, this embodiment provides a method for predicting material tensile properties based on nanoindentation and machine learning, comprising the following steps: S1. Use a metallographic microscope to take metallographic photos of microstructures and pre-process the metallographic photos; In this embodiment, a sample is cut from the material, and the sample surface is firstly ground flat using sandpaper of different grain sizes, and then after polishing and etching, a plurality of metallographic photographs are taken using a metallographic microscope. The metallographic photographs are then preprocessed to have uniform size, color, and length and width.
[0019] S2, performing finite element simulation based on the structure on the pre-processed metallographic photograph to obtain stress-strain data; In this embodiment, the tissue-based finite element simulation can directly link the microstructure characteristics of the material (such as grain size, shape, orientation, phase distribution, etc.) with the macroscopic mechanical properties, so as to have a deeper understanding of the relationship between the two. This is helpful for the development of new high-performance materials and the optimization of existing materials. Finite element simulation is a numerical method that does not require physical destruction of the actual material. The same set of data can be used repeatedly for multiple simulation experiments, saving materials and costs. Compared with traditional experimental methods, finite element simulation can complete a large number of simulations under different conditions in a short period of time, reducing the time and resource investment required for physical experiments. By combining microstructure information, finite element simulation can span different scales from micro to macro, provide more comprehensive and accurate predictions of mechanical behavior, and support the needs of multi-scale modeling. The pre-processed metallographic photographs are subjected to a finite element simulation based on the structure to obtain stress-strain data, including the following steps: S2.1. Select multiple locations from the pre-processed metallographic photographs, apply a series of known loads using a nanoindenter, and record the corresponding displacement responses. Each test point should correspond to a pixel area in the metallographic photograph as much as possible to ensure that the measured parameters such as hardness and elastic modulus can reflect the true characteristics of different microstructures of the material (such as grains, phase boundaries, precipitates, etc.); S2.2, import the pre-processed metallographic photograph into the finite element software, and divide the image into fine grids according to the microstructural features in the metallographic photograph, where each grid unit corresponds to a pixel point in the metallographic photograph; S2.3. Apply periodic boundary conditions to the finite element model to simulate the behavior of infinite material bodies and reduce the influence of edge effects; S2.4. Based on the results of nanoindentation, specify the material properties of different regions in the finite element model. For example, different grains or phases can be assigned different elastic moduli and Poisson's ratios. S2.5. Set simulation conditions, including loading mode (determine the loading mode during simulation, such as uniaxial tension, biaxial tension, etc., to match the actual experimental conditions) and step size (determine the total strain amount during the simulation and the step size of each output data. Usually, data will be output at equal strain intervals to obtain a continuous stress-strain curve). Start the finite element analysis software to perform simulation calculations according to the set conditions. During the calculation process, the output data will be output at equal strain intervals, that is, the stress-strain data will be output once every fixed step size from the initial state under a fixed total strain; S2.6. After the simulation calculation is completed, the stress and strain data corresponding to the microstructure image at each moment are extracted frame by frame, and the stress and strain values of each grid unit are extracted in turn in each frame; S2.7. Use the extracted stress-strain value data to draw a stress-strain cloud diagram to show the internal stress distribution of the material, and calculate the average value of the stress-strain values of all grid units as the stress-strain curve data of the entire material.
[0020] S3, constructing a microstructure-stress-strain field database based on metallographic photographs and stress-strain data; In this example, by combining the microstructural characteristics of the material (such as grain size, morphology, distribution, etc.) with the corresponding stress-strain data, a deeper understanding of the relationship between the two can be achieved. This association helps to reveal how the internal structure of the material affects its macroscopic mechanical behavior; the constructed database can be reused in multiple research projects, reducing the need for repeated experiments and saving time and resources. At the same time, it provides valuable historical data support for subsequent research; The microstructure-stress-strain field database is constructed based on metallographic photos and stress-strain data, including the following steps: S3.1, obtaining all pre-processed metallographic photographs and corresponding stress-strain data from step S1 and step S2 as samples, ensuring that all images and data file formats are consistent, such as converting the metallographic photographs into a uniform resolution and color mode, and saving the stress-strain data into a standardized table or array format; S3.2. According to the time and space position, each metallographic photo is matched with its corresponding stress and strain data through the time-space registration algorithm. This means that each frame of stress-strain cloud map data must be able to accurately reflect the stress distribution inside the material at that moment and match the metallographic photo taken at the same time point; Among them, the spatiotemporal registration algorithm is a technology used to synchronize and align data from different sources or time points to ensure that they accurately correspond in time and space, and to ensure that each metallographic photograph accurately matches the corresponding stress-strain data in time and space, which is essential for establishing the relationship between microstructural characteristics and macroscopic mechanical properties. Accurate registration can improve the accuracy of model predictions; spatiotemporal registration helps reduce measurement errors caused by changes in the internal structure of the material or changes in external loading conditions. By adjusting the transformation parameters through the optimization algorithm to achieve the best match, the consistency and reliability of the data can be ensured, and the intrinsic connection between the material microstructure (such as grains, phase boundaries, etc.) and the mechanical response (such as stress and strain) can be more clearly revealed, which helps to deeply understand the behavior mechanism of the material and provide theoretical support for material design; Each metallographic photo is matched to its corresponding stress-strain data one by one through a spatiotemporal registration algorithm, including the following steps: S3.21. Verify that the timestamps of each metallographic photograph and the corresponding stress-strain data are accurately recorded and synchronized with each other; S3.22. Based on the experimental settings (such as sample fixing method, loading direction, etc.), preliminarily estimate the spatial position relationship between the metallographic photos and the stress-strain cloud map; S3.23, use the feature detection algorithm SIFT to extract stable feature points from metallographic photos; S3.24, matching the two sets of feature points to find the best correspondence; S3.25. Calculate the geometric transformation model based on the matched feature points: ,in, are the coordinates of the original point, are the transformed point coordinates, is the transformation matrix; S3.26, applying the calculated transformation to the stress-strain contour data to align them spatially with the metallographic photograph; S3.27, using mutual information as a metric, the transformation parameters are adjusted through an optimization algorithm until the best match is achieved; Furthermore, mutual information is a statistic that measures the degree of mutual dependence between two variables, indicating how much information one variable can obtain through another variable; mutual information can capture nonlinear relationships between variables, not just linear correlations. This is particularly important for dealing with complex data sets, especially when there are complex interactions between variables. Mutual information is invariant to monotonic transformations, which means that even if two variables undergo different monotonic transformations (such as logarithmic or exponential transformations), the mutual information value between them remains unchanged. This makes mutual information more stable when comparing data of different scales or distributions; mutual information can reflect all forms of correlation, not just first and second order statistical properties based on mean and variance. It takes into account the complete probability distribution of the data, and therefore can more comprehensively measure the dependency between two random variables; The mutual information is: ; in, Represents the pixel value distribution in the metallographic photograph; Represents the stress value distribution in the stress-strain cloud diagram; Indicates the probability of a certain pixel value appearing in the metallographic photograph; Indicates the probability of a certain stress value appearing in the stress-strain cloud diagram; It indicates the probability of co-occurrence of pixel values and stress values at the same position in the metallographic photograph and the stress-strain cloud map; Represents all possible pixel values in the metallographic photograph; Represents all possible stress values in the stress-strain cloud diagram; Represents a specific pixel value in a metallographic photograph; Represents a specific stress value in the stress-strain contour diagram; S3.3. Convert the metallographic photos into a tensor format used by machine learning. Each image can be represented as a three-dimensional tensor (width × height × number of channels), where the number of channels is usually 3 (RGB images) or 1 (grayscale images). Convert the stress-strain data into a tensor format, which involves rearranging the stress-strain values into a form compatible with the image tensor, such as creating a two-dimensional tensor of the same size as the image, where each element represents the stress-strain value of the corresponding pixel point. S3.4, divide the processed tensor data into training set and test set according to the required ratio (10:1); S3.5. Select a relational database management system and define the table structure to ensure that the image tensor and its corresponding stress-strain data tensor can be efficiently stored and retrieved, and enter the converted image tensor and stress-strain data tensor into the database to form a microstructure-stress-strain field database, ensuring that each record contains a unique identifier for easy tracking and association.
[0021] S4. Based on the microstructure-stress-strain field database, the U-Net deep learning framework is adjusted and optimized to predict the tensile properties of materials and provide stress-strain cloud maps and curves; In this embodiment, by using detailed microstructure information and stress-strain data as input, U-Net can learn the complex relationship between the internal structure and mechanical properties of the material, thereby achieving high-precision tensile performance prediction. The generated stress-strain cloud map can intuitively display the internal stress distribution of the material, helping researchers to better understand the behavior of the material under different loading conditions. In addition, the stress-strain curve provides a basis for quantitative analysis, which is convenient for evaluating key properties such as strength and ductility of the material; traditional material testing methods are time-consuming and costly. This method can complete a large number of simulation experiments in a short period of time, quickly screen out new materials with potential or optimize the design of existing materials, greatly shortening the research and development cycle of new materials; using deep learning models for virtual testing can significantly reduce the number of actual physical experiments, saving resources while also reducing development costs; Based on the microstructure-stress-strain field database, the U-Net deep learning framework is adjusted and optimized to predict the tensile properties of materials and provide stress-strain cloud maps and curves, including the following steps: S4.1. Load the training set and test set from the constructed microstructure-stress-strain field database to ensure that the image tensor and stress-strain data tensor are correctly paired; S4.2, select the U-Net architecture consisting of an encoder (contracting path) and a decoder (expanding path) as the starting point, and the encoder and decoder are connected by skip connections (such as Figure 2 As shown in Figure 1, the encoder gradually reduces the spatial dimension of the input tensor by convolution and increases the number of feature channels, while the decoder gradually restores the spatial dimension of the image by deconvolution and reduces the number of feature channels. S4.3, adjusting the encoder and decoder; The adjustment of the encoder and the decoder includes the following steps: S4.31. Adjust the encoder to use a 3×3 convolution kernel in each convolution layer with a step size of 1. Use the same padding method to keep the spatial size unchanged. The weights of each layer are initialized to normal distribution random values with a mean of 0 and a standard deviation of 0.02. S4.32, ReLU is used as the activation function in the encoder, and the maximum pooling method is used to gradually reduce the spatial dimension of the input. ReLU is used as the activation function in the encoder to introduce nonlinearity, so that the network can learn complex features, while the maximum pooling gradually reduces the spatial dimension of the input by selecting the maximum value of the local area, while retaining the most critical information; Among them, the advantage of using the maximum pooling method to gradually reduce the spatial dimension of the input is that it can retain the most significant feature information while reducing the amount of calculation and model parameters, which helps prevent overfitting and improve the generalization ability of the model. In addition, maximum pooling can also provide a certain degree of translation invariance, making the model less sensitive to small-scale movement of the input data; The maximum pooling method is used to gradually reduce the spatial dimension of the input, including the following steps: S4.321, performing image segmentation on the preprocessed metallographic photographs and converting them into a format suitable for input into a neural network; S4.322. Select pooling window size ; S4.323. Determine the distance the pooling window moves each time ; S4.324, for each channel Traverse the entire input image, for position The maximum value is calculated by the maximum pooling formula, and the maximum pooling formula is optimized according to the directional characteristics of the grain boundaries in the metallographic photos; Furthermore, the maximum pooling formula is: ; in, Indicates that the output feature map of a pooling operation in a certain layer of the U-Net model is at position and Channel The value of is the maximum value in the area covered by the pooling window, which retains the most significant feature information in the area; Represents the height of the pooling window, which means the number of pixels covered by the pooling window in the vertical direction (rows) in the metallographic photograph or stress-strain field tensor; Represents the width of the pooling window, which indicates the number of pixels covered by the pooling window in the horizontal direction (columns); Represents the step size of the pooling window, which defines the distance the pooling window slides each time. It controls the resolution of the feature map of the metallographic photo or stress-strain field tensor after the pooling operation; Represents a channel index, which indicates different types of feature channels in metallographic photographs or stress-strain fields (e.g., RGB image channels or stress and strain components); Represents the row offset within the pooling window; represents the column offset within the pooling window; The directionality of grain boundaries is one of the important factors affecting the tensile properties of materials, especially when predicting stress-strain distribution and material failure behavior. The optimized pooling method can more sensitively capture the directional characteristics of grain boundaries by introducing directional weights, thereby providing richer feature information for deep learning models. The traditional maximum pooling method only extracts the maximum value within the window, which easily ignores complex details such as the directionality of grain boundaries. By optimizing the pooling method, different pixels are given importance weights based on direction and gradient, which can effectively retain the grain boundary characteristics and reduce information loss. In the conversion process from metallographic photos to finite element simulation, microstructural characteristics directly affect mesh division and regional attribute allocation. After optimizing the pooling method, the extracted direction-sensitive features can more accurately guide finite element modeling, improve the resolution and accuracy of the simulation, and thus obtain more realistic stress-strain data. The optimized pooling method generates high-quality feature maps in the preprocessing of metallographic photos, making them more suitable for input into deep learning models. During the training process, these direction-sensitive features can help U-Net learn the local patterns of grains and boundary areas more effectively, thereby improving the prediction performance. According to the directional characteristics of grain boundaries in metallographic photos, the maximum pooling formula is optimized: ; ; in, Indicates that the output feature map after optimization is at position and Channel The value of represents the direction-sensitive weight of the grain boundary; represents the adjustment coefficient of the directional weight; Indicates the first The gradient direction of each pixel is calculated from the gradient information of the metallographic photograph and is used to describe the direction of the grain boundary; Indicates the main direction angle (radian), which is the statistical main direction of grain distribution in the material metallographic photograph; Represents the weight adjustment coefficient of the gradient amplitude; Indicates the pixels in the metallographic photo Point The gradient value of the direction; Indicates the pixels in the metallographic photo Point The gradient value of the direction; S4.325, place the maximum value in the new output activation map At the corresponding position in , a downsampled image is formed; S4.326, after the maximum pooling, a new feature map is obtained, the spatial dimension of the new feature map is smaller than the original input, this new feature map retains the most important information in the original input, while reducing the amount of calculation and the number of parameters; S4.33, adjust the decoder to use a 2×2 convolution kernel with a step size of 2 in each deconvolution layer to restore the spatial dimension; S4.34. Concatenate the feature map in the encoder with the feature map of the corresponding level in the decoder to retain more detailed information. If there is a size mismatch after deconvolution, use bilinear interpolation to adjust to the appropriate size (bilinear interpolation estimates the pixel value at the new position by calculating the weighted average of four adjacent pixels, thereby smoothly adjusting the image to the required size). Select hyperparameters such as model round, batch size, and buffer size; S4.4, define an error function to measure the difference between the predicted stress and strain values and the true values; Furthermore, the error function is: ; in, Represents the average mean square error of all samples as the final loss function; represents the total number of samples; Indicates the number of frames per sample; Indicates The sample in The true stress-strain values of the frame; Indicates The sample in Predicted stress-strain values of the frame; Indicates the sample index; Indicates the frame number index; S4.5. Perform model training based on the training set, monitor the changing trend of training loss, and promptly detect overfitting or underfitting. The training process is performed based on model parameters. After the training is completed, the model parameters are saved for subsequent deployment and use. S4.6. Perform model evaluation based on the test set in the database constructed in step S3 to ensure that the model can perform well on unseen data. If the accuracy meets the requirements, the model training is completed. If not, modify the model hyperparameters and perform new training, and continue to evaluate until the model prediction accuracy meets the requirements. S4.7. Use the trained model to predict the new metallographic photos and output the corresponding predicted stress-strain cloud map (such as Figure 3 , Figure 4 As shown in the figure, the internal stress distribution of the material is intuitively displayed, and the stress-strain curve is drawn according to the predicted stress-strain value (such as Figure 5), reflecting the mechanical response of the material at different strain levels; The stress-strain cloud map is a commonly used visualization tool in material mechanics analysis. It uses color changes to represent the distribution of stress or strain inside the material. Its functions are mainly reflected in the following aspects: intuitively displaying the stress-strain distribution inside the material, including stress concentration areas and low stress areas. Through color changes, the stress level can be quickly identified; the uniformity of stress distribution can be evaluated. By observing the distribution of colors in the stress-strain cloud map, the stress uniformity of the material can be understood. When the color distribution is relatively uniform, it means that the stress distribution of the material is relatively uniform. If the color is obviously non-uniform, it indicates stress concentration; assisting design optimization. The cloud map provides an intuitive way to observe and analyze the internal stress state of the material when it is stressed, which is of great significance for optimizing design, improving material utilization efficiency and structural reliability. At present, there are two main methods for obtaining material stress-strain curves, namely preparing tensile specimens for physical testing or establishing finite element models for numerical simulation; and drawing stress-strain cloud maps is mainly done through finite element model numerical simulation, and can also be done through digital image correlation (DIC) experiments.
[0022] The above shows and describes the basic principles, main features and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited by the above embodiments, and the above embodiments and descriptions are only preferred examples of the present invention, and are not intended to limit the present invention. Without departing from the spirit and scope of the present invention, the present invention may have various changes and improvements, and these changes and improvements all fall within the scope of the present invention to be protected.
Claims
1. A method for predicting material tensile properties based on nanoindentation and machine learning, characterized in that: The following steps are involved: S1. Use a metallographic microscope to take metallographic photos of microstructures and pre-process the metallographic photos; S2, performing finite element simulation based on the structure on the pre-processed metallographic photograph to obtain stress-strain data; S3, constructing a microstructure-stress-strain field database based on metallographic photographs and stress-strain data; S4. Based on the microstructure-stress-strain field database, the U-Net deep learning framework is adjusted and optimized to predict the tensile properties of materials and provide stress-strain cloud maps and curves.
2. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 1, characterized in that: In S2, the pre-processed metallographic photograph is subjected to a finite element simulation based on the structure to obtain stress-strain data, which includes the following steps: S2.
1. Select multiple locations from the pre-processed metallographic photographs, apply a series of known loads using a nanoindenter, and record the corresponding displacement responses; S2.2, import the pre-processed metallographic photograph into the finite element software, and divide the image into fine grids according to the microstructural features in the metallographic photograph, where each grid unit corresponds to a pixel point in the metallographic photograph; S2.3, apply periodic boundary conditions to the finite element model; S2.
4. Based on the results of nanoindentation, specify the material properties of different regions in the finite element model; S2.5, set simulation conditions, start the finite element analysis software to perform simulation calculations according to the set conditions, and output data according to equal strain intervals during the calculation process; S2.
6. After the simulation calculation is completed, the stress and strain data corresponding to the microstructure image at each moment are extracted frame by frame, and the stress and strain values of each grid unit are extracted in turn in each frame; S2.
7. Use the extracted stress-strain value data to draw a stress-strain cloud diagram, and calculate the average value of the stress-strain values of all grid units as the stress-strain curve data of the entire material.
3. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 2, characterized in that: In S3, a microstructure-stress-strain field database is constructed based on metallographic photographs and stress-strain data, including the following steps: S3.1, obtaining all pre-processed metallographic photographs and corresponding stress-strain data from step S1 and step S2 as samples; S3.2, according to the time and space position, each metallographic photo is matched with its corresponding stress and strain data through the time and space registration algorithm; S3.3, converting the metallographic photographs into a tensor format used for machine learning, and also converting the stress-strain data into a tensor format; S3.4, dividing the processed tensor data into a training set and a test set according to the required ratio; S3.
5. Select a relational database management system, define the table structure, and enter the converted image tensor and stress-strain data tensor into the database to form a microstructure-stress-strain field database.
4. The material tensile properties prediction method based on nanoindentation and machine learning according to claim 3, characterized in that: In S3.2, each metallographic photograph is matched one by one with its corresponding stress-strain data by using a spatiotemporal registration algorithm, including the following steps: S3.
21. Verify that the timestamps of each metallographic photograph and the corresponding stress-strain data are accurately recorded and synchronized with each other; S3.
22. Based on the experimental setup, preliminarily estimate the spatial position relationship between the metallographic photographs and the stress-strain cloud map; S3.23, use the feature detection algorithm SIFT to extract stable feature points from metallographic photos; S3.24, matching the two sets of feature points to find the best correspondence; S3.25, calculating a geometric transformation model according to the matched feature points; S3.26, applying the calculated transformation to the stress-strain contour data to align them spatially with the metallographic photograph; S3.
27. Using mutual information as a metric, the transformation parameters are adjusted through an optimization algorithm until the best match is achieved.
5. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 4, characterized in that: In S3.27, the mutual information is: ; in, Represents the pixel value distribution in the metallographic photograph; Represents the stress value distribution in the stress-strain cloud diagram; Indicates the probability of a certain pixel value appearing in the metallographic photograph; Indicates the probability of a certain stress value appearing in the stress-strain cloud diagram; It indicates the probability of co-occurrence of pixel values and stress values at the same position in the metallographic photograph and the stress-strain cloud map; Represents all possible pixel values in the metallographic photograph; Represents all possible stress values in the stress-strain cloud diagram; Represents a specific pixel value in a metallographic photograph; Represents a specific stress value in the stress-strain cloud diagram.
6. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 5, characterized in that: In S4, based on the microstructure-stress-strain field database, the U-Net deep learning framework is adjusted and optimized to predict the tensile properties of the material, and a stress-strain cloud map and curve are provided, including the following steps: S4.1, load the training set and test set from the constructed microstructure-stress-strain field database; S4.2, select the U-Net architecture consisting of an encoder and a decoder as the starting point, and the encoder and decoder are connected at both ends through a skip connection; S4.3, adjusting the encoder and decoder; S4.4, define an error function to measure the difference between the predicted stress and strain values and the true values; S4.
5. Determine the model hyperparameters, train the model based on the training set, monitor the changing trend of the training loss, and save the parameters after the training is completed; S4.6, performing model evaluation based on the test set in the database constructed in step S3; S4.
7. Use the trained model to predict the new metallographic photograph, output the corresponding predicted stress-strain cloud map, and draw the stress-strain curve based on the predicted stress-strain value.
7. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 6, characterized in that: In S4.3, the encoder and the decoder are adjusted, including the following steps: S4.31, adjust the encoder to use a 3×3 convolution kernel in each convolution layer, with a step size of 1, and use the same padding method for padding. The weights of each layer are initialized to normal distribution random values with a mean of 0 and a standard deviation of 0.02; S4.
32. ReLU is used as the activation function in the encoder, and the maximum pooling method is used to gradually reduce the spatial dimension of the input; S4.33, adjust the decoder to use a 2×2 convolution kernel with a stride of 2 in each deconvolution layer; S4.
34. Concatenate the feature map in the encoder with the feature map of the corresponding level in the decoder. If the size after deconvolution does not match, use bilinear interpolation to adjust it to the appropriate size.
8. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 7, characterized in that: In S4.32, a maximum pooling method is used to gradually reduce the spatial dimension of the input, including the following steps: S4.321, performing image segmentation on the pre-processed metallographic photograph; S4.
322. Select pooling window size ; S4.
323. Determine the distance the pooling window moves each time ; S4.324, for each channel Traverse the entire input image, for position The maximum value is calculated by the maximum pooling formula, and the maximum pooling formula is optimized according to the directional characteristics of the grain boundaries in the metallographic photos; S4.325, place the maximum value in the new output activation map At the corresponding position in , a downsampled image is formed; S4.
326. After maximum pooling, a new feature map is obtained, and the spatial dimension of the new feature map is smaller than the original input.
9. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 8, characterized in that: In S4.324, the maximum pooling formula is: ; in, Indicates that the output feature map of a pooling operation in a certain layer of the U-Net model is at position and Channel The value of Indicates the height of the pooling window; Indicates the width of the pooling window; Indicates the step size of the pooling window; Indicates the channel index; Represents the row offset within the pooling window; represents the column offset within the pooling window; According to the directional characteristics of grain boundaries in metallographic photos, the maximum pooling formula is optimized: ; ; in, Indicates that the output feature map after optimization is at position and Channel The value of represents the direction-sensitive weight of the grain boundary; represents the adjustment coefficient of the directional weight; Indicates the first The gradient direction of pixels; represents the main direction angle; Represents the weight adjustment coefficient of the gradient amplitude; Indicates the pixels in the metallographic photo Point The gradient value of the direction; Indicates the pixels in the metallographic photo Point The gradient value of the direction.
10. The method for predicting material tensile properties based on nanoindentation and machine learning according to claim 9, characterized in that: In S4.4, the error function is: ; in, represents the average mean square error of all samples; represents the total number of samples; Indicates the number of frames per sample; Indicates The sample in The true stress-strain values of the frame; Indicates The sample in Predicted stress-strain values of the frame; Indicates the sample index; Indicates the frame index.
Citation Information
Patent Citations
Method for predicting tensile property of metal material based on 2D microstructure
CN113252447A
Object macroscopic physical attribute prediction method and system based on deep learning
CN114388076A
Method for identifying small particles in pixels of metallographic image based on improved U-net network
CN116403212A
Method for inverting strain rate effect of fragile material based on data processing
CN118919003A
Prediction method of uniform extension and prediction program for uniform extension
JP2012104042A