Geothermal energy is a sustainable source from Earth's crust, and holds great potential for electricity generation, but corrosion poses a significant challenge. In this study, we employed a range of machine learning models, including linear regression, decision tree, k-nearest neighbors, random forest, and support vector regression to predict uniform and pitting corrosion. Despite limited data performance issues, virtual samples from a synthetic data generator improved results when combined with actual data. Fine-tuning with various hyperparameters enhanced model performance, with the decision tree proving the most effective. Exhaustive feature selection identifies key factors influencing uniform and pitting corrosion, validated by the models.