Abstract:Traditional hearing aids employ gain compensation formulas during speech amplification that are primarily designed for quiet environments, failing to meet the actual gain needs of hearing-impaired patients in diverse real-world settings. This results in patient dissatisfaction with the gain compensation and a suboptimal user experience. To address this issue, this paper proposes a GS-LGA-XGBoost algorithm that automatically adjusts the optimal gain for real-life environments. The algorithm predicts the gain at each frequency point of the hearing aid using Extreme Gradient Boosting (XGBoost), Grid Search (GS), and an improved Genetic Algorithm (LGA). A dataset comprising gain data from 1 200 ears of patients satisfied with their hearing aids, collected from actual hospitals, was used to construct three gain prediction models for soft, medium, and loud sounds. The proposed algorithm demonstrates test results on the soft, medium, and loud gain test sets that align more closely with the gain values preferred by patients. Compared to three other machine learning methods—Support Vector Regression (SVR), Random Forest (RF), and Deep Neural Network (DNN)—the proposed algorithm outperforms all of them in predicting hearing aid gain. The GS-LGA-XGBoost algorithm not only enables dynamic adjustment of hearing aid gain across different environments but also achieves high prediction accuracy, better meeting the satisfactory gain requirements of hearing-impaired patients.