journal article·2024-07-01Open access

Automatic Composition System Based on Transformer-XL

Ze Li, Qing Huang, Xinhao Yang, Qing Chen, Li Zhang

Applied Sciences· Volume 14· Issue 13

Abstract

An automatic composition system that includes music generation and music assessment is designed in this paper. In terms of music generation, we modify the Transformer-XL model for generating music. The Mask mechanism based on Transformer-XL is improved to make the attention of model tend to pay on the bidirectional information, so that the generated popular piano music forms a coherent whole. In terms of music assessment, we combine objective and subjective assessment to judge the generated music in a comprehensive way. Meanwhile, we put forward a new objective assessment method, namely the piano roll classification scoring network. It converts music into pictures and uses classification models in the CV, enabling the network itself to classify and score the generated music. The assessment results from subjective and objective experiments show that by improving the Mask mechanism of Transformer-XL, the model is trained to be better and the generated music could achieve the effect of imitating the real music.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Music and Audio Processing · Music Technology and Sound Studies · Image Processing and 3D Reconstruction

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

School of Computer Science & Technology, Soochow University, Suzhou 215006, China

School of Electronic and Information Engineering, Suzhou University of Science and Technology, Suzhou 215009, China

School of Mechanical and Electrical Engineering, Soochow University, Suzhou 215006, China

Funding

Science and Technology Development Plan Project of Suzhou City

References (47)

Show source-provided references
1. Hernandez-Olivan, C., and Beltran, J.R. (2021). Music composition with deep learning: A review. arXiv.10.1007/978-3-031-18444-4_2 ↗
2. Briot, J.P., Hadjeres, G., and Pachet, F.D. (2017). Deep learning techniques for music generation—A survey. arXiv.
3. Multimedia intelligence: When multimedia meets artificial intelligence10.1109/TMM.2020.2969791 ↗
4. Eck, D., and Schmidhuber, J. (2002). A First Look at Music Composition Using Lstm Recurrent Neural Networks, Instituto Dalle Molle di Studi Sull’ Intelligenza Artificiale. Technical Rep. No. IDSIA-07-02.
5. Lambert, A., Weyde, T., and Armstrong, N. (August, January 25). Perceiving and predicting expressive rhythm with recurrent neural networks. Proceedings of the 12th International Conference in Sound and Music Computing, Maynooth, Ireland.
6. Choi, K., Fazekas, G., and Sandler, M. (2016). Text-based LSTM networks for automatic music composition. arXiv.
7. Sturm, B.L., Santos, J.F., Ben-Tal, O., and Korshunova, I. (2016). Music transcription modelling and composition using deep learning. arXiv.
8. Hadjeres, G., Nielsen, F., and Pachet, F. (December, January 27). GLSR-VAE: Geodesic latent space regularization for variational autoencoder architectures. Proceedings of the SSCI, Honolulu, HI, USA.
9. A hierarchical latent vector model for learning long-term structure in music
10. Dong, H.W., Hsiao, W.Y., Yang, L.C., and Yang, Y.H. (2018, January 2–7). MuseGAN: Multi-track sequential generative adversarial networks for symbolic music generation and accompaniment. Proceedings of the AAAI Conference on Artificial Intelligence, New Orleans, LA, USA.10.1609/aaai.v32i1.11312 ↗
11. Yang, L.C., Chou, S.Y., and Yang, Y.H. (2017). MidiNet: A convolutional generative adversarial network for symbolic-domain music generation. arXiv.
12. Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A.N., Kaiser, Ł., and Polosukhin, I. (2017, January 4–9). Attention is all you need. Proceedings of the Advances in Neural Information Processing Systems, Long Beach, LA, USA.
13. Radford, A., Wu, J., Child, R., Luan, D., Amodei, D., and Sutskever, I. (2019). Language Models Are Unsupervised Multitask Learners, OpenAI Blog.
14. Devlin, J., Chang, M.W., Lee, K., and Toutanova, K. (2018). BERT: Pre-training of deep bidirectional transformers for language understanding. arXiv.
15. Dai, Z., Yang, Z., Yang, Y., Carbonell, J., Le, Q.V., and Salakhutdinov, R. (2019). Transformer-XL: Attentive language models beyond a fixed-length context. arXiv.10.18653/v1/P19-1285 ↗
16. Hung, H.T., Ching, J., Doh, S., Kim, N., Nam, J., Nam, J.H., and Yang, Y. (2021). EMOPIA: A multi-modal pop piano dataset for emotion recognition and emotion-based music generation. arXiv.
17. Jiang, J., Xia, G.G., Carlton, D.B., Anderson, C.N., and Miyakawa, R.H. (2020, January 4–8). Transformer VAE: A hierarchical model for structure-aware and interpretable music representation learning. Proceedings of the ICASSP, Barcelona, Spain.10.1109/ICASSP40776.2020.9054554 ↗
18. Child, R., Gray, S., Radford, A., and Sutskever, I. (2019). Generating long sequences with sparse transformers. arXiv.
19. Theme transformer: Symbolic music generation with theme-conditioned transformer10.1109/TMM.2022.3161851 ↗
20. Dong, H.W., Chen, K., McAuley, J., and Berg-Kirkpatrick, T. (2020). MusPy: A toolkit for symbolic music generation. arXiv.
21. Wu, S.L., and Yang, Y.H. (2020). The Jazz Transformer on the front line: Exploring the shortcomings of AI-composed music through quantitative measures. arXiv.
22. Dong, H.W., Hsiao, W.Y., and Yang, Y.H. (2018, January 23–27). Pypianoroll: Open source Python package for handling multitrack pianoroll. Proceedings of the ISMIR, Paris, France.
23. Mogren, O. (2016). C-RNN-GAN: Continuous recurrent neural networks with adversarial training. arXiv.
24. Ji, S., Luo, J., and Yang, X. (2020). A comprehensive survey on deep music generation: Multi-level representations, algorithms, evaluations, and future directions. arXiv.
25. Drum rhythm spaces: From polyphonic similarity to generative maps10.1080/09298215.2020.1806887 ↗
26. Wu, X., Wang, C., and Lei, Q. (2020). Transformer-XL Based Music Generation with Multiple Sequences of Time-valued Notes. arXiv.
27. Pangestu, M.A., and Suyanto, S. (2021, January 16–18). Generating music with emotion using transformer. Proceedings of the International Conference on Computer Science and Engineering (IC2SE), Padang, Indonesia.10.1109/IC2SE52832.2021.9791928 ↗
28. Huang, Q., Yang, X., Qian, F., and Li, Z. (2021, January 22–24). Pop piano music generation with the simplified transformer-xl. Proceedings of the 33rd Chinese Control and Decision Conference (CCDC), Kunming, China.10.1109/CCDC52312.2021.9601430 ↗
29. Huang, C.Z.A., Vaswani, A., Uszkoreit, J., Shazeer, N., Simon, I., Hawthorne, C., Dai, A.M., Hoffman, M.D., Dinculescu, M., and Eck, D. (2018). Music transformer. arXiv.
30. Huang, Y.S., and Yang, Y.H. (2020, January 12–16). Pop music transformer: Beat-based modeling and generation of expressive pop piano compositions. Proceedings of the ACM, Seattle, WA, USA.10.1145/3394171.3413671 ↗
31. Yang, Z., Dai, Z., Yang, Y., Carbonell, J., Salakhutdinov, R.R., and Le, Q.V. (2019). XLNet: Generalized autoregressive pretraining for language understanding. arXiv.
32. He, K., Zhang, X., Ren, S., and Sun, J. (2016, January 27–30). Deep residual learning for image recognition. Proceedings of the CVPR, Las Vegas, NV, USA.10.1109/CVPR.2016.90 ↗
33. He, K., Chen, X., Xie, S., Li, Y., Dollár, P., and Girshick, R. (2022, January 18–24). Masked autoencoders are scalable vision learners. Proceedings of the CVPR, New Orleans, LA, USA.10.1109/CVPR52688.2022.01553 ↗
34. Heckroth, J. (1998). A tutorial on MIDI and wavetable music synthesis. Crystal Semiconductor Products Division, Cirrus Logic, Inc.
35. This time with feeling: Learning expressive musical performance10.1007/s00521-018-3758-9 ↗
36. Donahue, C., Mao, H.H., Li, Y.E., Cottrell, G.W., and McAuley, J. (2019). LakhNES: Improving multi-instrumental music generation with cross-domain pre-training. arXiv.
37. Multi-channel weight-sharing autoencoder based on cascade multi-head attention for multimodal emotion recognition10.1109/TMM.2022.3144885 ↗
38. Shaw, P., Uszkoreit, J., and Vaswani, A. (2018). Self-attention with relative position representations. arXiv.10.18653/v1/N18-2074 ↗
39. Individualized interpretation: Exploring structural and interpretive effects on evaluations of emotional content in Bach’s Well Tempered Clavier10.1080/09298215.2021.1979050 ↗
40. Exploring musical style in the anonymous and doubtfully attributed mass movements of the Coimbra manuscripts: A statistical and machine learning approach10.1080/09298215.2020.1870505 ↗
41. A multi-genre model for music emotion recognition using linear regressors10.1080/09298215.2021.1977336 ↗
42. A mathematical theory of communication10.1145/584091.584093 ↗
43. Norouzi, M., Fleet, D.J., and Salakhutdinov, R.R. (2012, January 3–6). Hamming distance metric learning. Proceedings of the NIPS, Lake Tahoe, NV, USA.
44. Music psychology and music theory: Problems and prospects10.2307/745764 ↗
45. Simonyan, K., and Zisserman, A. (2014). Very deep convolutional networks for large-scale image recognition. arXiv.
46. Howard, A.G., Zhu, M., Chen, B., Kalenichenko, D., Wang, W., Weyand, T., Andreetto, M., and Adam, H. (2017). Mobilenets: Efficient convolutional neural networks for mobile vision applications. arXiv.
47. A Comparative Study of Music Mastered by Human Engineers and Automated Services10.17743/jaes.2022.0050 ↗