A musical model training method, comprising: acquiring an MIDI music data set, the MIDI music data set comprising a plurality of MIDI music scores (S11); extracting a feature vector of each of the MIDI scores (S12); inputting the feature vectors into a structured support vector machine for training to obtain a musical model (S13), comprising: constructing a discriminant function f(x; w), x being a feature vector, w being a parameter vector, outputting a data value formula (I) of the maximized discriminant function f(x; w) as a predicted value; calculating the predicted value and a real value according to a preset loss function formula (II), wherein P is a probability distribution of data and is replaced with an empirical risk formula (III) obtained through calculation by training sample data; using an optimization formula (IV) of an SVM to solve the unique parameter vector ω, such that the empirical risk formula (III) by training sample data is zero; obtaining the discrimination function f(x; ω) by means of the solution, and finally outputting a music time sequence. The present invention further provides a music creation method and device, a terminal, and a storage medium. The present invention is the first example of using artificial intelligence to train a musical model, and the trained musical model can improve the feature extraction capability of MIDI music scores.
MUSICAL MODEL TRAINING METHOD, MUSIC CREATION METHOD, DEVICES, TERMINAL AND STORAGE MEDIUM