Next Article in Journal
Effect of Compressive Stress on Copper Bonding Quality and Bonding Mechanisms in Advanced Packaging
Previous Article in Journal
Enhancing Mechanical Properties and Microstructures of Mass-Manufactured Sand Concrete by Incorporating Granite Powder
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Predictive Modeling of Vickers Hardness Using Machine Learning Techniques on D2 Steel with Various Treatments

by
Claudia Lorena Mambuscay
1,2,
Carolina Ortega-Portilla
3,
Jeferson Fernando Piamba
1,2 and
Manuel Guillermo Forero
1,*
1
Semillero Lún, Facultad de Ingeniería, Universidad de Ibagué, Ibagué 730002, Colombia
2
Semillero NOVAMAT, Facultad de Ciencias Naturales y Matemáticas, Universidad de Ibagué, Ibagué 730002, Colombia
3
CONAHCYT-Centro de Ingeniería y Desarrollo Industrial (CIDESI), Santiago de Querétaro 76125, Mexico
*
Author to whom correspondence should be addressed.
Materials 2024, 17(10), 2235; https://doi.org/10.3390/ma17102235
Submission received: 9 April 2024 / Revised: 29 April 2024 / Accepted: 4 May 2024 / Published: 9 May 2024

Abstract

:
Hardness is one of the most crucial mechanical properties, serving as a key indicator of a material’s suitability for specific applications and its resistance to fracturing or deformation under operational conditions. Machine learning techniques have emerged as valuable tools for swiftly and accurately predicting material behavior. In this study, regression methods including decision trees, adaptive boosting, extreme gradient boosting, and random forest were employed to forecast Vickers hardness values based solely on scanned monochromatic images of indentation imprints, eliminating the need for diagonal measurements. The dataset comprised 54 images of D2 steel in various states, including commercial, quenched, tempered, and coated with Titanium Niobium Nitride (TiNbN). Due to the limited number of images, non-deep machine learning techniques were utilized. The Random Forest technique exhibited superior performance, achieving a Root Mean Square Error (RMSE) of 0.95, Mean Absolute Error (MAE) of 0.12, and Coefficient of Determination ( R 2 ) ≈ 1, surpassing the other methods considered in this study. These results suggest that employing machine learning algorithms for predicting Vickers hardness from scanned images offers a promising avenue for rapid and accurate material assessment, potentially streamlining quality control processes in industrial settings.

1. Introduction

Thin film coatings are formed by the controlled deposition of atoms onto the surface of another material, known as the substrate (see Figure 1). This process aims to enhance the substrate’s properties and extend its lifespan. Several factors influence the resulting properties of the coating, including the substrate’s surface roughness, hardness, chemical composition, and material type (ceramic, metallic, polymer, or composite). Additionally, deposition parameters such as nitrogen flow, substrate temperature, deposition time, and thickness play a crucial role [1,2]. Given the multivariable nature of this process, these factors directly impact the coating properties, necessitating careful design and a potentially large number of experiments to fully understand the influence of each parameter.
Therefore, the use of machine learning (ML) techniques helps reduce the number of experiments required to obtain the desired result, such as elemental chemical composition, phases, or specific material properties [3]. ML techniques also enable the classification of material defects, such as fractures or surface stains [4,5,6], or the prediction of coating properties like hardness, friction coefficient, corrosion rate, based on deposition parameters [7,8,9]. One way to control material quality and ensure it meets the appropriate characteristics for its application is through the Vickers hardness test [10]. This test involves measuring the plastic deformation or indentation mark produced on the surface after applying a load with a pyramidal diamond indenter, and the hardness value is determined by Equation (1).
H V = 0.1891 F ( N ) D 2 ( mm ) 2
where D is the average length of the diagonals, and F is the load applied by the indenter [11].
The use of machine learning techniques has increased in recent years, as they are employed to optimize, monitor, and control industrial processes. These algorithms possess the capability to learn and adapt to dynamic systems [4]. For instance, Martins et al. developed an algorithm to automatically inspect surface defects in rolled steel, classifying issues such as oxidation, exfoliation, and waveform defects using computer vision and neural networks, achieving an accuracy of 87%, ensuring high-quality steel production [6]. Furthermore, the study and determination of adhesion strength between the coating/substrate system are of great importance as they allow the estimation of the quality and the type of deformation exhibited by the coating. Bastian Lenz et al. utilized convolutional neural networks to classify the type of adhesion present in a set of Rockwell indentation images, showing promising results for automated industrial applications [5].
The comparison of machine learning techniques is of great importance to determine the approach that exhibits higher performance, and shorter execution time. Mohamad et al. predicted the hardness performance of TiAlN coatings using support vector machine (SVM), artificial neural network (ANN), and RSM-fuzzy. Parameters such as sputtering power, polarization voltage, and substrate temperature were used as input, where the SVM model showed better approximation to experimentally obtained hardness results compared to other study methods [8]. Wen et al. implemented an algorithm to search for high-entropy alloys with high hardness in an Al-Co-Cr-Cu-Fe-Ni system. They predicted material hardness based on composition and other descriptors (atomic radii, valence electrons, among others) using machine learning techniques such as linear regression, polynomial regression, support vector regression (SVR) with linear, polynomial, and radial kernels, regression tree, backpropagation artificial neural network (ANN), and k-nearest neighbors (KNN). SVR with a radial kernel showed lower prediction error compared to other techniques [9]. Waleed et al. implemented machine learning techniques such as multivariable linear regressor (LR), Gaussian process regressor (GPR), and SVR to predict properties of AA6061 compounds, including relative density, hardness, grain size, among others. The goal was to optimize input parameters such as the percentage of silicon carbide particles (SiCp), pressure for high torsion, and number of revolutions. The results indicated that SVR demonstrated better performance in predicting these properties [12]. Similarly, Keya Fu et al. utilized machine learning techniques such as random forest (RF), k-nearest neighbors (KNN), linear regression (LR), XGBoost, light gradient boosting machine (LightGBM), and an artificial neural network (ANN) to predict the tensile strength of aluminum alloys based on their elemental chemical composition and grain size. The XGBoost technique yielded better prediction results compared to other studied techniques [13].
On the other hand, researchers have implemented image processing methods and machine learning techniques for the determination of Vickers hardness. Polanco et al. estimated the Vickers hardness value using image processing methods to detect the corners of the indentation imprint, achieving a maximum error of 4.5% compared to manually obtained values [10]. Dovale et al. used a gradient boosting regressor (GBR) to predict hardness based on mechanical properties such as bulk modulus (B), shear modulus (G), Young’s modulus (Y), and Poisson’s ratio ( ν ). They also implemented the classification model (GBC) to predict the best relationship for calculating hardness with these input variables [14]. Jeon et al. employed support vector regression (SVR), k-nearest neighbors (kNN), random forest regression (RFR), and artificial neural networks (ANN) to predict the hardness of low-alloy steels under various tempering conditions such as temperature, holding time, and alloy composition. RFR showed the best R 2 value of 0.9966 compared to other machine learning models [15].
Swetlana et al. implemented image processing to extract microstructural descriptors such as phase distribution, volume fraction, number and size of particles, elemental chemical composition, temperature, and annealing time. These descriptors were used and combined in three different datasets to predict Vickers hardness using Gaussian process regression (GPR), achieving mean squared errors between 0.59 and 0.15 [16]. Privezentsev et al. developed software with indentation images that binarizes, filters, and calculates geometric characteristics of the image using artificial neural networks (ANN). They found that the differences in geometric parameters of the indentation imprint calculated manually compared to the software did not exceed 4% [17]. Tanaka et al. implemented two automatic methods based on convolutional neural networks (CNNs), using images with ideal surfaces, rough surfaces, distorted indentations, and cracks as inputs to measure indentation diagonals and determine Vickers hardness automatically and robustly. They reported errors between 0.1% and 6% in Vickers hardness value, indicating that their method allows for precision close to that of a human operator [18]. Buitrago et al. employed CNNs to determine the Vickers hardness of D2 steel and TiNbN coating by predicting the position of the corners of the indentation imprint, obtaining errors between 0.17% and 5.98% [19].
According to the studies presented previously, it can be observed that machine learning techniques are used to predict Vickers hardness based on material characteristics such as chemical composition, morphology, and material properties. Additionally, these techniques have been implemented to detect the indentation imprint or its corners, thereby determining the value of Vickers hardness.
In this work, a new method of predicting Vickers hardness is implemented without the need to measure the diagonals of the indentation imprint. This is achieved from image conditions such as scale, whether the analyzed image presents coating or not, applied force, and scanning of the indentation imprint image in grayscale. This study employs machine learning techniques such as Decision Tree (DT), AdaBoost, Extreme Gradient Boosting (XGB), and Random Forest (RF), with the aim of identifying the most suitable machine learning technique for predicting Vickers hardness.

2. Materials and Methods

2.1. Materials

Fifty-four Vickers indentation images of commercially available D2 steel, water-quenched from 1000 °C, tempered at 400 °C for 90 min, and TiNbN coatings deposited by Arc-PVD at varying substrate temperatures ( T s = 200 °C, 400 °C and 600 °C) were analyzed. The indentation images of the coating, the Vickers hardness and the elemental chemical composition were obtained from previous studies [19,20]. This type of material is implemented as a cutting tool, which must have high hardness and wear resistance. Table 1 shows the chemical composition of the coating and the average Vickers hardness of the study materials using a load of 10 N.
Each image was obtained under a distinct applied load. These images were obtained using two optical microscopes: the OLYMPUS UPRIGHT BX51FM (OLYMPUS, Tokyo, Japan), equipped with a 10.2 Mpx SC100 camera utilizing CMOS technology, providing a magnification of 20 μ m and dimensions of 3840 × 2748 px (see Figure 2a–c); and the OLYMPUS DSX500i, featuring an 18 Mpx CCD camera, offering a magnification of 10 μ m and dimensions of 1194 × 1194 px (see Figure 2d–g). Rotations were performed every 5° from 0° to 360° and horizontal mirroring was applied to each rotation to increase the data diversity and reduce the effects of directional bias in the indentation images. This resulted in a total of 7776 images, which represents a 144-fold increase from the original database size of 54 images.
A database was constructed to predict Vickers hardness from indentation imprints. Descriptors include scale, coating presence (binary encoded), applied load (2, 3, 5, or 10 N), and grayscale indentation images. The output variable is Vickers hardness, calculated from the indentation image using established methods (see Table 2).
To determine the image size yielding the highest performance, and considering each pixel as a descriptor, the resizing process also aimed to expedite computation and ensure uniform image dimensions for optimal performance. Indentation images were therefore resized to relatively small dimensions of 10 × 10 , 25 × 25 , 50 × 50 , 75 × 75 , and 100 × 100 pixels. Decision trees were utilized, trained on 80% of the dataset and validated on the remaining 20%. To assess the performance of machine learning models, metrics such as RMSE, MAE and R 2 were used:
  • Root Mean Square Error (RMSE): It is the square root of the Mean Square Error (MSE), measures the square of the differences between predicted and actual values (see Equation (2)).
  • Mean Absolute Error (MAE): It is the average of the absolute differences between predicted and actual values (see Equation (3)).
  • The coefficient of determination ( R 2 ): Provides information on how well a model’s predictions fit the actual data (see Equation (4)). If R 2 1, it indicates that the model explains or fits the data well; otherwise, if R 2 <= 0, it indicates that the model does not fit the data.
R M S E = M S E = 1 n i = 1 n ( y i y ^ i ) 2
M A E = 1 n i = 1 n | y i y ^ i |
R 2 = 1 i = 1 n ( y i y ^ i ) 2 i = 1 n ( y i y ¯ i ) 2
where n is the number of observations, y i is the actual value of the dependent variable, y ^ i is the predicted value by the model, and y ¯ i is the mean value of the actual values.
The Table 3 summarizes the results, encompassing training time ( T i m e T r a i n ), validation time ( T i m e T e s t ), root mean square error (RMSE), mean absolute error (MAE), and coefficient of determination ( R 2 ). Notably, the highest performance was achieved when the image size was 50 × 50 pixels, indicating its suitability for this study (see Figure 3).

2.2. Methods

Developing performance and efficient methods for predicting Vickers hardness values is crucial for material science and engineering applications. Considering the small data size, we focused on algorithms known for their robustness and ability to handle smaller datasets. We specifically investigated four prominent techniques: Decision Tree (DT), Adaptive Boosting (ADABoost), Extreme Gradient Boosting (XGBoost), and Random Forest (RF).
  • Decission Tree (DT): DT is a supervised learning algorithm that builds classification and regression models using a hierarchical tree structure. It recursively partitions the dataset into smaller subsets based on specific features, eventually reaching leaf nodes with predicted target values. Key parameters for DT include maximum tree depth, which controls the complexity of the tree, and the splitting criterion, which determines the best feature and threshold for each split. Common criteria include Friedman Mean Squared Error (MSE), squared error, and absolute error [21,22].
    -
    Friedman MSE: This method utilizes the mean squared error with Friedman’s improvement score for potential splits.
    -
    Squared Error: The mean squared error serves as the feature selection criterion, aiming to minimize the L2 loss by assessing the reduction of variance at each terminal node.
    -
    Absolute Error: The mean absolute error minimizes the L1 loss by utilizing the median of each terminal node.
  • Adaptive Boosting or ADABoost: It is a meta-estimator that incrementally grows in complexity with each boosting iteration. It employs small decision tree estimators as weak learners, which are added sequentially. Each subsequent model aims to correct the predictions of its predecessor, thereby enhancing overall predictive performance [23].
  • Extreme Gradient Boosting or XGBoost: XGBoost is a method designed for improving Gradient Boosting. It utilizes a gradient descent algorithm to minimize the loss when adding new models. In regression tasks, XGBoost employs small decision trees, where each new tree predicts the residuals or errors of the previous trees. These predictions are then combined with the previous tree to make the final prediction [24].
  • Random Forest or RF: Random Forest involves building prediction models in classification or regression from a set of decision trees without interaction between them. Key parameters include the criterion, which employs functions like Friedman MSE, squared error, and absolute error, the maximum depth of each tree, and the number of estimators, referring to the number of trees in the forest [25].
The dataset was split into training (60%), tuning (20%), and testing (20%) sets. Grid Search was employed to identify the optimal hyperparameter configuration for the chosen machine learning model. Cross-validation was performed using 5 folds, repeated 5 times. The average performance over the 5 folds was used to select the best hyperparameter configuration. The flowchart describing the aforementioned methodology is shown in Figure 4. Python 3.11.5 and scikit-learn were used for implementation on a computer with 12 GB RAM, an 11th Gen Intel® Core™ i5-1155G7 CPU @ 2.50 GHz, and Windows 11.

3. Results and Discussion

3.1. Hyperparameters Tuning

For the hyperparameters fit of the different models studied, the criterion, maximum depth of the decision tree, and the number of estimators for random forests, ADABoost, and XGBoost were considered. Figure 5 depicts plots of the tuned hyperparameters for each machine learning technique with the best-selected values. Table 4 presents the obtained values.

3.2. Model Testing and Validation

Once the tuning hyperparameters were identified, the machine learning techniques were trained. The model with the best performance was then used for validation with the test set. Table 5 shows the results of training score (Train score), test time, Root Mean Square Error (RMSE), Mean Absolute Error (MAE), and R 2 for each model.
As shown in Table 5, the training score values for all models are close to 1, indicating successful learning. However, the validation results reveal that DT, XGBoost, and RF outperform ADABoost. This is because ADABoost uses decision trees with a maximum depth of 3. According to the DT tuning plots (see Figure 5), DT achieves better R 2 values for depths higher than 10. Consequently, ADABoost exhibits higher RMSE and MAE errors, suggesting that deeper parameter tuning is crucial for improved predictions.
While the R 2 values for DT, XGBoost, and RF are similar, the Random Forest (RF) model demonstrates the best fit in the test results, followed by XGBoost and DT. This is corroborated by its lower RMSE values, as RMSE is sensitive to outliers and penalizes significant discrepancies between predicted and actual values.
Figure 6 presents the prediction vs. true value plots for all machine learning techniques. It is evident that the predictions for DT, RF, and XGBoost align well with the true values compared to ADABoost.
The Random Forest machine learning technique demonstrated superior performance. This model was utilized to forecast the Vickers hardness value using 10 images not included in the database, with the objective of assessing the model’s efficacy in Vickers hardness value prediction. The error percentage for these images ranged from 0.43% to 6.88%, with an average execution time of 0.14 ± 0.10 s.
Previous studies employing image processing techniques, like those by Polanco et al. [10], reported hardness measurement errors ranging from 0.32% to 4.5% for both manual and their proposed methods, with an average processing time of 2.05 s. Similarly, Buitrago et al. [19] utilized convolutional neural networks (CNNs) and achieved manual hardness errors between 0.17% and 5.98%, with an average execution time of 6 s. Our proposed method demonstrates comparable error margins to these existing approaches, while significantly reducing processing time, thereby leading to lower computational costs.
As depicted in Table 6 and Table 7, as the indentation size increases significantly relative to the pore size and if background noise diminishes, the model’s performance improves, as evident in Table 6 and Table 7.
As observed, the results obtained with this novel technique, which circumvents the calculation of diagonal lengths to determine hardness value, are akin to those obtained with corner detection-based methods, thus opening new avenues for material characterization based on Vickers hardness.
Despite the limited number of images contained in the database and the low diversity of the study materials, results with an error rate of less than 6.88% were obtained. One way to improve these results in the future is to expand the database to enable better machine learning.

4. Conclusions

  • In this work, a new method based on machine learning techniques was developed to predict the Vickers hardness value from the indentation image, applied load, whether it has a coating or not, and the image scale. The method achieved low RMSE and MAE errors (095 and 0.12 respectively), with an R 2 close to 1 when employing the Random Forest technique.
  • Evaluating the size of the image in the database is crucial since each pixel of the image acts as a descriptor. A larger image introduces redundant information or noise, leading to high RMSE and MAE errors and increasing computation time. Conversely, a very small image can result in a significant loss of information, making learning challenging. Therefore, an image size of 50 × 50 pixels reduces computation time and yields good results RMSE 0 , MAE 0 , and R 2 1 . This size minimizes information loss, facilitating effective data learning.
  • In the metal-mechanic industry, material characterization is crucial. By determining the Vickers hardness value, it is possible to assess the quality of the material, whether it has undergone heat treatment, and if the coating is suitable for specific applications. This prevents the material from fracturing or deforming during short-term operation. Therefore, the proposed method charts a new course, diverging from traditional reliance on corner detection, for characterizing materials based on Vickers hardness, generating more efficient quality control and greater reliability of the final product.

Author Contributions

Conceptualization and supervision, M.G.F. and J.F.P.; methodology, validation, and formal analysis, M.G.F., J.F.P. and C.L.M.; software development, M.G.F. and C.L.M.; image acquisition and data curation, C.L.M., J.F.P. and C.O.-P.; writing and writing—review, editing, and visualization, all authors, project administration J.F.P. All authors have read and agreed to the published version of the manuscript.

Funding

This work is partially supported by “El Patrimonio Autónomo Fondo Nacional de Financiamiento para la Ciencia, la Tecnología y la Innovación Francisco José de Caldas” CONV CONT. No. 477-2023.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The data presented in this study are available upon request to the corresponding author. The data are not available to the public because they are preliminary results of an ongoing research project carried out in collaboration between CONAHCYT and the Universidad de Ibagué. Furthermore, this information will be used in future technological developments and will be subject to intellectual property protection.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Albella, J.M. Láminas Delgadas y Recubrimientos. Preparación, Propiedades y Aplicaciones; Consejo Superior de Investigaciones Científicas: Madrid, Spain, 2003; p. 704. [Google Scholar]
  2. Baptista, A.; Silva, F.; Porteiro, J.; Míguez, J.; Pinto, G. Sputtering Physical Vapour Deposition (PVD) Coatings: A Critical Review on Process Improvement and Market Trend Demands. Coatings 2018, 8, 402. [Google Scholar] [CrossRef]
  3. Ohkubo, I.; Hou, Z.; Lee, J.; Aizawa, T.; Lippmaa, M.; Chikyow, T.; Tsuda, K.; Mori, T. Realization of closed-loop optimization of epitaxial titanium nitride thin-film growth via machine learning. Mater. Today Phys. 2021, 16, 100296. [Google Scholar] [CrossRef]
  4. Wuest, T.; Weimer, D.; Irgens, C.; Thoben, K.D. Machine learning in manufacturing: Advantages, challenges, and applications. Prod. Manuf. Res. 2016, 4, 23–45. [Google Scholar] [CrossRef]
  5. Lenz, B.; Hasselbruch, H.; Mehner, A. Automated evaluation of Rockwell adhesion tests for PVD coatings using convolutional neural networks. Surf. Coat. Technol. 2020, 385, 125365. [Google Scholar] [CrossRef]
  6. Martins, L.A.; Pádua, F.L.; Almeida, P.E. Automatic detection of surface defects on rolled steel using Computer Vision and Artificial Neural Networks. In Proceedings of the IECON Proceedings (Industrial Electronics Conference), Glendale, AZ, USA, 7–10 November 2010; pp. 1081–1086. [Google Scholar] [CrossRef]
  7. Dobrzański, L.; Staszuk, M.; Honysz, R. Application of artificial intelligence methods in PVD and CVD coatings properties modelling. Arch. Mater. Sci. Eng. 2012, 58, 152–157. [Google Scholar]
  8. Mohamad, M.A.; Ali, N.A.; Haron, H. Computational Intelligence Approach for Predicting the Hardness Performances in Titanium Aluminium Nitride (TiA1N) Coating Process. Int. J. Artif. Intell. Expert Syst. 2014, 5, 1–14. [Google Scholar]
  9. Wen, C.; Zhang, Y.; Wang, C.; Xue, D.; Bai, Y.; Antonov, S.; Dai, L.; Lookman, T.; Su, Y. Machine learning assisted design of high entropy alloys with desired property. Acta Mater. 2019, 170, 109–117. [Google Scholar] [CrossRef]
  10. Polanco, J.D.; Jacanamejoy-Jamioy, C.; Mambuscay, C.L.; Piamba, J.F.; Forero, M.G. Automatic Method for Vickers Hardness Estimation by Image Processing. J. Imaging 2023, 9, 8. [Google Scholar] [CrossRef]
  11. ASTM E92-17; Standard Test Methods for Vickers Hardness and Knoop Hardness of Metallic Materials. ASTM International: West Conshohocken, PA, USA, 2017; pp. 1–27. [CrossRef]
  12. El-Garaihy, W.H.; Alateyah, A.I.; Shaban, M.; Alsharekh, M.F.; Alsunaydih, F.N.; El-Sanabary, S.; Kouta, H.; El-Taybany, Y.; Salem, H.G. A Comparative Study of a Machine Learning Approach and Response Surface Methodology for Optimizing the HPT Processing Parameters of AA6061/SiCp Composites. J. Manuf. Mater. Process. 2023, 7, 148. [Google Scholar] [CrossRef]
  13. Fu, K.; Zhu, D.; Zhang, Y.; Zhang, C.; Wang, X.; Wang, C.; Jiang, T.; Mao, F.; Zhang, C.; Meng, X.; et al. Predictive Modeling of Tensile Strength in Aluminum Alloys via Machine Learning. Materials 2023, 16, 7236. [Google Scholar] [CrossRef] [PubMed]
  14. Dovale-Farelo, V.; Tavadze, P.; Lang, L.; Bautista-Hernandez, A.; Romero, A.H. Vickers hardness prediction from machine learning methods. Sci. Rep. 2022, 12, 22475. [Google Scholar] [CrossRef] [PubMed]
  15. Jeon, J.; Seo, N.; Son, S.B.; Lee, S.J.; Jung, M. Application of machine learning algorithms and shap for prediction and feature analysis of tempered martensite hardness in low-alloy steels. Metals 2021, 11, 1159. [Google Scholar] [CrossRef]
  16. Swetlana, S.; Khatavkar, N.; Singh, A.K. Development of Vickers hardness prediction models via microstructural analysis and machine learning. J. Mater. Sci. 2020, 55, 15845–15856. [Google Scholar] [CrossRef]
  17. Privezentsev, D.G.; Zhiznyakov, A.L.; Kulkov, Y.Y. Automation of measuring microhardness of materials using metal-graphic images. In Proceedings of the 2019 International Russian Automation Conference, RusAutoCon 2019, Sochi, Russia, 8–14 September 2019; pp. 1–5. [Google Scholar] [CrossRef]
  18. Tanaka, Y.; Seino, Y.; Hattori, K. Automated Vickers hardness measurement using convolutional neural networks. Int. J. Adv. Manuf. Technol. 2020, 109, 1345–1355. [Google Scholar] [CrossRef]
  19. Buitrago Diaz, J.C.; Ortega-Portilla, C.; Mambuscay, C.L.; Piamba, J.F.; Forero, M.G. Determination of Vickers Hardness in D2 Steel and TiNbN Coating Using Convolutional Neural Networks. Metals 2023, 13, 1391. [Google Scholar] [CrossRef]
  20. Gonzalez-Carmona, J.M.; Mambuscay, C.L.; Ortega-Portilla, C.; Hurtado-Macias, A.; Piamba, J.F. TiNbN Hard Coating Deposited at Varied Substrate Temperature by Cathodic Arc: Tribological Performance under Simulated Cutting Conditions. Materials 2023, 16, 4531. [Google Scholar] [CrossRef]
  21. Loh, W.Y. Classification and regression trees. In Wiley Interdisciplinary Reviews: Data Mining and Knowledge Discovery; John Wiley & Sons: Hoboken, NJ, USA, 2011; Volume 1. [Google Scholar] [CrossRef]
  22. Pedregosa, F.; Varoquaux, G.; Gramfort, A.; Michel, V.; Thirion, B.; Grisel, O.; Blondel, M.; Prettenhofer, P.; Weiss, R.; Dubourg, V.; et al. Scikit-learn: Machine Learning in Python. J. Mach. Learn. Res. 2011, 12, 2825–2830. [Google Scholar]
  23. Friedman, J.; Hastie, T.; Tibshirani, R. Additive logistic regression: A statistical view of boosting (With discussion and a rejoinder by the authors). Ann. Stat. 2000, 28, 337–407. [Google Scholar] [CrossRef]
  24. Chen, T.; Guestrin, C. XGBoost: A Scalable Tree Boosting System. In Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD ’16, San Francisco, CA, USA, 13–17 August 2016. [Google Scholar] [CrossRef]
  25. Breiman, L. Random Forests. Mach. Learn. 2001, 45, 5–32. [Google Scholar] [CrossRef]
Figure 1. Thin film coating on substrate.
Figure 1. Thin film coating on substrate.
Materials 17 02235 g001
Figure 2. Indented images showcase various treatments of D2 Steel: (a) untreated, (b) quenched, (c,d) tempered, alongside TiNbN coating at different substrate temperatures (Ts): (e) Ts = 200 °C, (f) Ts = 400 °C, and (g) Ts = 600 °C.
Figure 2. Indented images showcase various treatments of D2 Steel: (a) untreated, (b) quenched, (c,d) tempered, alongside TiNbN coating at different substrate temperatures (Ts): (e) Ts = 200 °C, (f) Ts = 400 °C, and (g) Ts = 600 °C.
Materials 17 02235 g002
Figure 3. Effect of Image Size on Coefficient of Determination (R2) (Blue Line) and Root Mean Square Error (RMSE) (Red Line).
Figure 3. Effect of Image Size on Coefficient of Determination (R2) (Blue Line) and Root Mean Square Error (RMSE) (Red Line).
Materials 17 02235 g003
Figure 4. Flowchart of the proposed approach.
Figure 4. Flowchart of the proposed approach.
Materials 17 02235 g004
Figure 5. Tuned hyperparameters for each machine learning technique (a) DT, (b) ADABoost, (c) XGBoost and (d) RF.
Figure 5. Tuned hyperparameters for each machine learning technique (a) DT, (b) ADABoost, (c) XGBoost and (d) RF.
Materials 17 02235 g005
Figure 6. Prediction vs. true value plots for all machine learning techniques (a) DT, (b) ADABoost, (c) XGBoost and (d) RF.
Figure 6. Prediction vs. true value plots for all machine learning techniques (a) DT, (b) ADABoost, (c) XGBoost and (d) RF.
Materials 17 02235 g006
Table 1. Chemical composition of the TiNbN coating and average Vickers hardness of each material [19,20].
Table 1. Chemical composition of the TiNbN coating and average Vickers hardness of each material [19,20].
MaterialTi (at%)Nb (at%)N (at%) HV 10 N
D2 Steel 243.25 ± 2.45
D2 Quenched 787.05 ± 6.25
D2 Tempered 573.17 ± 55.72
TiNbN 200 °C57.86 ± 7.280.21 ± 0.0141.93 ± 7.271009.21 ± 14.53
TiNbN 400 °C51.06 ± 0.570.18 ± 0.0248.76 ± 0.58846.24 ± 49.16
TiNbN 600 °C44.72 ± 3.090.15 ± 0.0255.12 ± 3.08844.35 ± 49.02
Table 2. Descriptors and Hardness measures included in the database.
Table 2. Descriptors and Hardness measures included in the database.
Scale ( μ m)Coating
Yes = 1
No = 0
Load (N)Gray Image
Pixel (1,1) … Pixel (n,n)
Hardness Vickers
(HV ± 0.05 )
10
10
0
0
10
2
154
162
155
156
533.75
672.57
10
10
1
1
10
5
172
173
174
171
1001.03
1504.19
10
10
1
1
2
10
174
178
161
130
1474.07
808.35
10
10
1
1
3
10
176
171
163
169
1381.19
806.19
20
20
0
0
10
10
205
208
254
254
612.50
793.30
Table 3. Time, root mean squared error (RMSE), mean absolute error (MAE) and coefficient of determination results obtained with the five databases constructed by changing the input image size.
Table 3. Time, root mean squared error (RMSE), mean absolute error (MAE) and coefficient of determination results obtained with the five databases constructed by changing the input image size.
Image Size (px) Time Train (s) Time Test (s)RMSEMAE R 2
10 × 100.190.002.740.100.99995
25 × 251.130.001.960.090.99997
50 × 504.700.021.54 × 10 12 1.15 × 10 12 1.00
75 × 7511.170.025.550.270.99978
100 × 10020.680.034.780.290.99984
Table 4. Average score for selected tuning hyperparameters.
Table 4. Average score for selected tuning hyperparameters.
ML 1CriterionMax DepthEstimatorsMean Score
DTSquared Error10 0.9997
ADABoost 700.9801
XGBoost 200.9999
RFSquared Error30300.9999
1 ML: Machine Learning.
Table 5. Results of train score, test time, R 2 , MAE, and RMSE for each model.
Table 5. Results of train score, test time, R 2 , MAE, and RMSE for each model.
MLTrain ScoreTimes Test (s)RMSEMAE R 2
DT1.000.021.940.210.99997
ADABoost0.981.1753.1043.190.98085
XGBoost1.000.021.710.710.99998
RF1.000.060.950.120.99999
Table 6. Vickers hardness prediction of coating using random forest.
Table 6. Vickers hardness prediction of coating using random forest.
ImageScale ( μ m)CoatingLoad (N)HV TrueHV Predict%Error
Materials 17 02235 i00110110931.31992.936.62
Materials 17 02235 i00210151108.421100.930.68
Materials 17 02235 i00310151104.341099.420.45
Materials 17 02235 i00410110801.35838.914.69
Materials 17 02235 i00510131269.001356.376.88
Table 7. Vickers hardness prediction of steel using random forest.
Table 7. Vickers hardness prediction of steel using random forest.
ImageScale ( μ m)CoatingLoad (N)HV TrueHV Predict%Error
Materials 17 02235 i00610110931.31992.936.62
Materials 17 02235 i00710151108.421100.930.68
Materials 17 02235 i00810151104.341099.420.45
Materials 17 02235 i00910110801.35838.914.69
Materials 17 02235 i01010131269.001356.376.88
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Mambuscay, C.L.; Ortega-Portilla, C.; Piamba, J.F.; Forero, M.G. Predictive Modeling of Vickers Hardness Using Machine Learning Techniques on D2 Steel with Various Treatments. Materials 2024, 17, 2235. https://doi.org/10.3390/ma17102235

AMA Style

Mambuscay CL, Ortega-Portilla C, Piamba JF, Forero MG. Predictive Modeling of Vickers Hardness Using Machine Learning Techniques on D2 Steel with Various Treatments. Materials. 2024; 17(10):2235. https://doi.org/10.3390/ma17102235

Chicago/Turabian Style

Mambuscay, Claudia Lorena, Carolina Ortega-Portilla, Jeferson Fernando Piamba, and Manuel Guillermo Forero. 2024. "Predictive Modeling of Vickers Hardness Using Machine Learning Techniques on D2 Steel with Various Treatments" Materials 17, no. 10: 2235. https://doi.org/10.3390/ma17102235

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop