Abstract
Music instrument recognition is one of the main tasks of music information retrieval. Identification of instruments present in an audio track provides information about the composition of music. Music instrument recognition in polyphonic music is a challenging task. Existing approaches use temporal, spectral, and perceptual feature extraction techniques to perform music instrument recognition. In the proposed work, a convolutional neural network and k-nearest neighbor classifier framework are implemented to identify the musical instrument present in a monophonic audio file, and the performance of the two models is compared. The model is trained on the London Philharmonic Orchestra dataset which consists of six different classes of musical instruments. Mel spectrogram representation is used to extract features for the convolutional neural network model. For k-nearest neighbors, the Mel-frequency cepstral coefficient’s feature vectors are calculated to perform classification. This approach only works for monophonic music and cannot be used for polyphonic music. The model helps to label the unlabelled audio files so that manual annotation can be avoided. The model performed well with excellent result of 99.17% accuracy for the convolutional neural network and 97% accuracy for the k-nearest neighbor architecture.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
References
Essid, S., Richard, G., & David, B,(2005), “Instrument recognition in polyphonic music based on automatic taxonomies,” in IEEE Transactions on Audio, Speech, and Language Processing, vol. 14, no. 1, pp. 68–80.
Pham, J., Woodford, T. and Lam, J.(2009), Classification of Musical Instruments by Sound.
Mustafa Sarimollaoglu, Coskun Bayrak, (2006),” Musical Instrument Classification Using Neural Networks,”, Proceedings of the 5th WSEAS International Conference on Signal Processing, Istanbul, Turkey, pp. 151–154.
Prabhjyot Singh, Dnyaneshwar Bachhav, Omkar Joshi, Nita Patil,(2019),“Musical Instrument Recognition using CNN and SVM,” in International Research Journal of Engineering and Technology (IRJET),vol. 06, no.3, pp. 1487–1491.
IRMAS Dataset, https://www.upf.edu/web/mtg/irmas. Last accessed 12 Sept 2021
Haidar-Ahmad, Lara.(2019),“Music and instrument classification using deep learning technics”, Recall, 67(37.00), pp.80–00.
IOWA Dataset, http://theremin.music.uiowa.edu/MIS.html. Last accessed 12 Sept 2021
Y. Han, J. Kim and K. Lee,(2017), “Deep Convolutional Neural Networks for Predominant Instrument Recognition in Polyphonic Music,” in IEEE/ACM Transactions on Audio, Speech, and Language Processing, vol. 25, no. 1, pp. 208–221.
Mahanta, S.K., Khilji, A.F.U.R. and Pakray, P.,(2021),” Deep Neural Network for Musical Instrument Recognition Using MFCCs,” in Journal Computación y Sistemas, vol 25, no 2, pp. 351–360.
Hing, D.S. and Settle, C.J.(2020), Detecting and Classifying Musical Instruments with Convolutional Neural Networks.
Yun, M. and Bi, J.(2018), Deep Learning for Musical Instrument Recognition.
Liu, J., Xie, L., (2010),“SVM -based automatic classification of musical instruments,” in International Conference on Intelligent Computation Technology and Automation, vol. 3, pp. 669–673.
Prabavathy, S., Rathikarani, V.,Dhanalakshmi, P., “Classification of Musical Instruments using SVM and KNN,” in International Journal of Innovative Technology and Exploring Engineering (IJITEE), vol. 9, no. 7,pp.2278–3075.
Anhari, A.K.,(2020),” Learning multi-instrument classification with partial labels,”, arXiv preprint arXiv:2001.08864.
Philharmoic Dataset, https://philharmonia.co.uk/. Last accessed 12 Sept 2021
A. Kratimenos, K. Avramidis, C. Garoufis, A. Zlatintsi, P. Maragos, (2020) ,“Augmentation Methods on Monophonic Audio for Instrument Classification in Polyphonic Music,” in 28th European Signal Processing Conference (EUSIPCO), pp. 156–160.
A. Eronen and A. Klapuri,(2000), “Musical instrument recognition using cepstral coefficients and temporal features,” in IEEE International Conference on Acoustics, Speech, and Signal Processing. Proceedings, vol.2, pp. II753-II756.
Patil S.R., Machale S.J.,(2020),“Indian Musical Instrument Recognition Using Gaussian Mixture Model,” in Techno-societal 2018, Springer, Cham, (pp. 51–57).
A. Ghosh, A. Pal, D. Sil, S. Palit,(2018), “Music Instrument Identification Based on a 2-D Representation,” in International Conference on Electrical, Electronics, Communication, Computer, and Optimization Techniques (ICEECCOT), pp. 509–513.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2023 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this chapter
Cite this chapter
Dhivya, S., Mohandas, P. (2023). Comparison of Convolutional Neural Networks and K-Nearest Neighbors for Music Instrument Recognition. In: Biswas, A., Wennekes, E., Wieczorkowska, A., Laskar, R.H. (eds) Advances in Speech and Music Technology. Signals and Communication Technology. Springer, Cham. https://doi.org/10.1007/978-3-031-18444-4_9
Download citation
DOI: https://doi.org/10.1007/978-3-031-18444-4_9
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-18443-7
Online ISBN: 978-3-031-18444-4
eBook Packages: EngineeringEngineering (R0)