Research Article

Comparison and analysis of prediction accuracy between traditional machine learning algorithms and XGBoost algorithm in music emotion classification

Mengxi Yang*
Changchun Institute of Education

* Corresponding author: [email protected]

Abstract

Music emotion classification refers to determining the emotional types of music, such as happiness, sadness, anger, and passion, based on aspects like rhythm, melody, and tone. The development of artificial intelligence can be applied to music recommendation by employing machine learning algorithms to ascertain emotional attributes of music, enabling precise music suggestions for users to enhance their musical experience. This paper compares and analyzes the classification performance of traditional Random Forest machine learning algorithms and the XGBoost model on a Turkish music emotion dataset. We selected a comprehensive dataset from Kaggle, containing a vast array of music samples and their corresponding emotional labels, making it an extensive music emotion classification dataset. From the experimental results, it's evident that the traditional Random Forest machine learning model outperforms the XGBoost model in terms of accuracy, precision, and recall. The accuracy of the traditional Random Forest machine learning model stands at 80.8%, whereas the XGBoost model's accuracy is 75%. The recall rate for the traditional Random Forest machine learning model is 80.8%, while for XGBoost, it's 77.2%. The F1 score for the traditional Random Forest machine learning model is 80.5%, whereas for XGBoost, it's 75.3%. These parameters indicate that the traditional Random Forest machine learning model exhibits superior predictive performance in music emotion classification. However, the XGBoost model possesses its own advantages, such as faster learning and prediction speeds, high accuracy, and strong generalization capabilities. In summary, the traditional Random Forest machine learning model demonstrates better robustness and interpretability, effectively handling samples with noise and missing data, thus finding widespread practical application. On the other hand, the XGBoost model excels in rapid training and prediction, coupled with higher accuracy and versatility, making it advantageous in dealing with large datasets. The research outcomes of this paper hold significant importance for the study and application of music emotion classification. The experimental results presented herein offer valuable insights for researchers and practitioners, aiding them in selecting appropriate machine learning models, optimizing, and adjusting them to achieve the best classification results.

Keywords: Machine Learning Classification; XGBoost; Prediction Accuracy
Published: April 30, 2024
DOI: 10.54254/2755-2721/57/20241316
Volume: ACE Vol.57
pp. 98-103
Download PDF

References

  1. Feng G, Zhiyuan L, Xiaoliang L, et al. Does air pollution influence music sentiment? Measuring music sentiment by machine learning[J]. Journal of Asian Economics,2023,87.
  2. Sanchali D, K. B B, Swapan D. Retraction Note to: Building a computational model for mood classification of music by integrating an asymptotic approach with the machine learning techniques[J]. Journal of Ambient Intelligence and Humanized Computing,2022,14(Suppl 1).
  3. Yu X, Fumei X. Study on Music Emotion Recognition Based on the Machine Learning Model Clustering Algorithm[J]. Mathematical Problems in Engineering,2022,2022.
  4. Zijin W. Research on Automatic Classification Method of Ethnic Music Emotion Based on Machine Learning[J]. Journal of Mathematics,2022,2022.
  5. Quasim T M, Alkhammash H E, Khan A M, et al. Emotion-based music recommendation and classification using machine learning with IoT Framework[J]. Soft Computing,2021,25(18).
  6. S S U, P K. A review on machine learning based counterfeit integrated circuit detection[J]. Engineering Research Express,2023,5(4).
  7. Selini N H, Guido C, Constantinos A. Machine learning for activity pattern detection[J]. Journal of Intelligent Transportation Systems,2023,27(6).
  8. Chen W, Huiying Y, Huafeng L, et al.Anthropogenic contributions to antibiotic resistance gene pollution in household drinking water revealed by machine-learning-based source-tracking[J].Water Research,2023,246
  9. Li, Y., Nie, X., and Huang, R 2018 Expert Systems with Applications, 96, 261-270.
  10. Goh, K. L., and Singh, A. K 2015 Procedia Computer Science, 70, 434-441.