• 沒有找到結果。

Melody Style Analysis and Melody Style Rule Learning

4 Analysis and Learning

4.2 Melody Style Analysis and Melody Style Rule Learning

After the analysis of the musical structure, the melodies are segmented into sections. The segmented melodies are collected for the purpose of melody style mining. The design issues regarding melody style mining techniques are melody feature extraction, melody feature representation and melody style mining/classification algorithms. In a sense, most works on algorithmic music composition may be regarded as approaches to model melody styles and to generate note sequences based on the models. For example, the HMM-based approach models melody style as Hidden Markov Model where the probability of next note depends on one or more previous notes. In addition, there exist some researches on melody style analysis from symbolic music [9][18][28][39][40][41]. The work developed in MIT Media Lab. [9] employed Hidden Markov Model to model and classify the melodies of Irish, German and Austrian folk song. Melodies are represented as a sequence of absolute pitches, absolute pitches with duration, intervals and contours. Another research in CMU utilized the naïve classifier, linear and neural network respectively to recognize music style for interactive performance systems [18]. Thirteen statistical features derived from MIDI are identified for learning of music style. Kranenburg and Backer extracted 20 low level characteristics of counterpoint for polyphonic music style recognition. The K-means clustering, the k-nearest-neighbor and C4.5 classification algorithms are employed to obtain music styles [28]. In [39], 28 statistics of melody content, such as number of notes, pitch range, average of note duration, number of diatonic notes, are developed for feature representations of automatic music style recognition from symbolic representation of melodies. The Bayesian classifier, the k-nearest neighbor and the self-organizing map are applied to perform music style learning.

Most of these approaches characterize the melody style as repetition of notes or statistics of pitches which are in the level of musical surfaces. However, stylistic features that characterize the music are usually hidden from the melody surface.

We have proposed the music style mining technique to construct the melody style model for a set of music objects [40][41]. The basic idea is to utilize the chord based on harmony to extract the melody features.

A chord is comprised of a number of pitches sounded simultaneously. Accompanying chords can be used as the melody feature to characterize the melody style. Figure 9 illustrates the reason why we choose chord as the feature for melody style mining. Figure 9(a) and Figure 9(b) show two different music segments. These two segments are quite similar in terms of either note sequence or interval contour. However, the music style and feelings of them are quite different. On the contrary, both music segments composed by Bach shown in Figure 9(c) and Figure 9(d) are of the same style. The chords assigned to these two music segments are the same.

Figure 9: Examples of music segments and assigned chords [40].

To match up the chords and melody, we have developed the chord assignment method based on the music theory. This algorithm starts by the determination of the chord sampling unit. Then, for each sampling unit, sixty common chords are selected as the candidates. Each candidate is scored based on harmony and chord progression rules. The chord with the highest score is assigned to the respective sampling unit. The detailed algorithm can be found in our previously published paper [40][41].

After determining the chord respective to each sampling unit, the melody feature can be represented in the following different ways.

(1) Chord sequence: the feature of a melody is represented as a sequence of chords.

(2) Set of chord bi-grams: the feature of a melody is represented as a set of bi-grams of chords. A bi-gram is an adjacent pair of chords extracted from a chord sequence.

(3) Chord set: the feature of a melody is represented as a set of chords.

For instance, assume that in a melody of four sampling units, the chords with the highest scores are C, G, G, and C respectively. The melody feature is represented by the chord set {C, G}, the set of chord bi-grams {CG, GG, GC}, and the chord sequence <CGGC>.

In order to obtain the interesting hidden relationships between chords and music styles, we adopted two melody mining methods with respect to the melody feature representations.

Frequent Itemset If the feature of a melody is represented as a set of chord or a set of chord bi-grams,

the concept of frequent itemset mining in the association rule mining is utilized. In our work, each item

corresponds to a chord or a chord bi-gram. An itemset is frequent if the number of music examples that contain this itemset is larger than a specified minimum support minsup. Assume that there exists a frequent itemset {C, F, G} from a set of lyric-style melody examples, this represents that a great part of lyric-style melody examples consist of chords C, F and G together. The Apriori algorithm is employed to find the frequent itemsets [1]. Apriori is a well-known data mining approach originally developed for the discovery of frequent itemsets from a database of itemsets. The classic Apriori algorithm for the discovery of frequent itemsets makes multiple passes over the database. In the first pass, the support of each individual item is calculated and those above the minsup are kept as a seed set. In the subsequent pass, the seed set is used to generate new potentially frequent itemsets, namely candidate itemsets. Then the support of each candidate itemset is calculated by scanning the database. The candidates with support no less than the minsup are the frequent itemsets and are fed into the seed set that will be used for the next pass. The process continues until no new frequent itemsets are found.

Frequent Substring If the feature of a melody is represented as a sequence of chords, to find the ordered

patterns, we mine the frequent substring, by modifying the concept of sequential pattern mining in sequence data mining techniques. The substring is consecutive, which differs from the sequential patterns. A substring is frequent if the number of music examples, which are the superstrings of this substring, is larger than a specified minimum support. The frequent substring is found by modifying the join step of the Apriori-based sequential mining algorithm [2].

Music Chord set Set of chord

bigrams

Chord sequence

CGCGCC {C, G} {CG, GC} CGCGCC

CAmDmG {C, Am, Dm, G} {CAm, AmDm,

DmG}

CAmDmG

CFFCGC  {C, F, G} {CF, FF, FC,

CG, GC}

CFFCGC

AmEmFC {Am, Em, F, C} {AmEm, EmF,

FC}

AmEmFC

  

Frequent Itemset

Mining

Frequent Itemset Mining

Frequent Substring

Mining

  

{C,G}, {C,F},

{C,Am},

{CG, GC}, CGC, CG, FC {C}, {F}, {G},

{Am},

{CG}, {GC}, {FC,}

GC, C, G, F

Frequent Chord

Patterns

Figure 10: An example of melody style mining.

Given a set of music examples, the discovered frequent chord patterns constitute the music style model of user specified examples. Figure 10 gives an example of melody style mining. In this example, there are four music sections which are transformed into chord sequences. Given the minimum support 50%, eighteen frequent chord patterns are discovered and constitute the music style model.

相關文件