hierarchical music structure analysis, modeling and

156
Hierarchical Music Structure Analysis, Modeling and Resynthesis: A Dynamical Systems and Signal Processing Approach. by Victor Gabriel Adin B.M., Universidad Nacional Aut6noma de Mexico (2002) Submitted to the Program in Media Arts and Sciences, School of Architecture and Planning, in partial fulfillment of the requirements for the degree of Master of Science at the MASSACHUSETTS INSTITUTE OF TECHNOLOGY September, 2005 @ Massachusetts Institute of Technology 2005. All rights reserved. Author ................................................... Program in Media Arts and Sciences August 5, 2005 Certified by ............. Barry L. Vercoe Professor of Media Arts and Sciences Thesis Supervisor A ccepted by........... ................ Andrew B. Lippman Chairman, Departmental Committee on Graduate Students MASSACHUSETTS INSTTUTE IROTCH OF TECHNOLOGY SEP 2 6 2005 UBRARIES

Upload: others

Post on 25-May-2022

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Hierarchical Music Structure Analysis, Modeling and

Hierarchical Music Structure Analysis,Modeling and Resynthesis: A Dynamical

Systems and Signal Processing Approach.

by

Victor Gabriel Adin

B.M., Universidad Nacional Aut6noma de Mexico (2002)

Submitted to the Program in Media Arts and Sciences,School of Architecture and Planning,

in partial fulfillment of the requirements for the degree of

Master of Science

at the

MASSACHUSETTS INSTITUTE OF TECHNOLOGY

September, 2005

@ Massachusetts Institute of Technology 2005. All rights reserved.

Author ...................................................Program in Media Arts and Sciences

August 5, 2005

Certified by .............Barry L. Vercoe

Professor of Media Arts and SciencesThesis Supervisor

A ccepted by........... ................Andrew B. Lippman

Chairman, Departmental Committee on Graduate Students

MASSACHUSETTS INSTTUTE IROTCHOF TECHNOLOGY

SEP 2 6 2005

UBRARIES

Page 2: Hierarchical Music Structure Analysis, Modeling and

2

Page 3: Hierarchical Music Structure Analysis, Modeling and

Hierarchical Music Structure Analysis, Modelingand Resynthesis: A Dynamical Systems and

Signal Processing Approach.by Victor Gabriel AdAn

Submitted to the Program in Media Arts and Sciences,School of Architecture and Planning, on August 5, 2005,

in partial fulfillment of the requirementsfor the degree of Master of Science

AbstractThe problem of creating generative music systems has been approachedin different ways, each guided by different goals, aesthetics, beliefs andbiases. These generative systems can be divided into two categories:the first is an ad hoc definition of the generative algorithms, the sec-ond is based on the idea of modeling and generalizing from preexistentmusic for the subsequent generation of new pieces. Most inductive mod-els developed in the past have been probabilistic, while the majority ofthe deductive approaches have been rule based, some of them with verystrong assumptions about music. In addition, almost all models havebeen discrete, most probably influenced by the discontinuous nature oftraditional music notation.We approach the problem of inductive modeling of high level musicalstructures from a dynamical systems and signal processing perspective,focusing on motion per se independently of particular musical systemsor styles. The point of departure is the construction of a state spacethat represents geometrically the motion characteristics of music. Weaddress ways in which this state space can be modeled deterministically,as well as ways in which it can be transformed to generate new musicalstructures. Thus, in contrast to previous approaches to inductive musicstructure modeling, our models are continuous and mainly deterministic.We also address the problem of extracting a hierarchical representationof music from the state space and how a hierarchical decomposition canbecome a second source of generalization.

Thesis supervisor: Barry L. Vercoe, D.M.A.Title: Professor of Media Arts and Sciences

Abstract 3

Page 4: Hierarchical Music Structure Analysis, Modeling and
Page 5: Hierarchical Music Structure Analysis, Modeling and

Thesis Committee

Thesis supervisor ..........Barry L. Vercoe

Professor of Media Arts and SciencesMassachusetts Institute of Technology

T hesis reader .....................................................................Rosalind Picard

Professor of Media Arts and SciencesMassachusetts Institute of Technology

Thesis reader. .............Robert Rowe

ProfessorNew York University

Thesis Committee 5

Page 6: Hierarchical Music Structure Analysis, Modeling and

6

Page 7: Hierarchical Music Structure Analysis, Modeling and

Acknowledgments

I would first of all like to thank my advisor, Barry Vercoe, for takingme into his research group and providing me with a space of completecreative freedom. None of this work would have been possible withouthis kind support.

Many thanks to the people who took the time to read the drafts ofthis work and gave me invaluable criticisms, particularly my readers:Professors Rosalind Picard, Robert Rowe and again Barry Vercoe.

Many special thanks go to the other Music, Mind and Machine groupmembers: Judy Brown, Wei Chai, John Harrison, Nyssim Lefford, andBrian Whitman for being such incredible sources of inspiration andknowledge.Special thanks to Wei for her constant willingness to listen to my mathquestions and for her patience. To Brian for being my second "advi-sor". His casual, almost accidental lessons gave me the widest map ofthe music-machine learning territory I could have wished for. Thanks toJohn for being a tremendous "officemate" and friend. His intelligence,skepticism and passion for music and technology made him a real plea-sure to work with and a constant source or inspiration.

Many other Media Lab members deserve special mention as well: Thanksto Hugo Solis for helping me with my transition into the lab, doingeverything from paper work to housing. I probably wouldn't have comehere without his help. Also thanks to all 45 Banks people for being suchwonderful friends and roommates: Tristan Jehan, Luke Ouko, CarlaGomez and again, Hugo.

In addition I have to thank all the authors cited in this text. This thesiswouldn't have been without their work. I want to give special thanksto Bernd Schoner for his beautiful MIT theses. They were a principalsource of inspiration and insight for the present work.

Acknowledgments

Page 8: Hierarchical Music Structure Analysis, Modeling and

My greatest gratitude to my family. Their examples of perseverance andfaith dfsfdhave been my wings and strength.

Last but certainly not least, I want to thank my dear wife "Cosi" forher love and support (and her editing skills). She is the most importantrediscovery I have madfde in my search for the meaning of it all.

8 Acknowledgments

Page 9: Hierarchical Music Structure Analysis, Modeling and

Table of Contents

1 Introduction and Background 111.1 M otivations . . . . . . . . . . . . . . . . . . . . . . . . . . 111.2 Generative Music Systems and Algorithmic Composition . 121.3 M odeling . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

1.3.1 Models of Music . . . . . . . . . . . . . . . . . . . 141.3.2 Our Approach to Music Structure Modeling . . . . 18

2 Musical Representation 21

3 State Space Reconstruction and Modeling 253.1 State Spaces . . . . . . . . . . . . . . . . . . . . . . . . . . 253.2 Dynamical Systems . . . . . . . . . . . . . . . . . . . . . . 26

3.2.1 Deterministic Dynamical Systems . . . . . . . . . . 273.2.2 State Space Reconstruction . . . . . . . . . . . . . 283.2.3 Calculating the Appropriate Embedding Dimension 293.2.4 Calculating the Time Lag r . . . . . . . . . . . . . 31

3.3 M odeling . . . . . . . . . . . . . . . . . . . . . . . . . . . 333.3.1 Spatial Interpolation = Temporal Extrapolation . 33

4 Hierarchical Signal Decomposition 434.1 Divide and Conquer . . . . . . . . . . . . . . . . . . . . . 43

4.1.1 Fourier Transform . . . . . . . . . . . . . . . . . . 444.1.2 Short Time Fourier Transform (STFT) . . . . . . . 444.1.3 Wavelet Transform . . . . . . . . . . . . . . . . . . 454.1.4 Data Specific Basis Functions . . . . . . . . . . . . 494.1.5 Principal Component Analysis (PCA) . . . . . . . 54

4.2 Sum m ary . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

5 Musical Applications 575.1 Music Structure Modeling and Resynthesis . . . . . . . . 58

5.1.1 Interpolation . . . . . . . . . . . . . . . . . . . . . 595.1.2 Abstracting Dynamics from States . . . . . . . . . 625.1.3 Decompositions . . . . . . . . . . . . . . . . . . . . 66

Contents 9

Page 10: Hierarchical Music Structure Analysis, Modeling and

5.2 Outside-Time Structures . . . . . . . . . . . . . . . . . . . 695.2.1 Sieve Estimation and Fitting . . . . . . . . . . . . 69

5.3 Musical Chimaeras: Combining Multiple Spaces . . . . . . 70

6 Experiments and Conclusions 796.1 Experim ents . . . . . . . . . . . . . . . . . . . . . . . . . . 79

6.1.1 Merging Two Pieces . . . . . . . . . . . . . . . . . 796.2 Conclusions and Future Work . . . . . . . . . . . . . . . . 91

6.2.1 System's Strengths, Limitations and Possible Re-finem ents . . . . . . . . . . . . . . . . . . . . . . . 92

Appendix A Notation 95

Appendix B Pianorolls 97B .1 Etude 4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97B .2 Etude 6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99B.3 Interpolation: Etude 4 . . . . . . . . . . . . . . . . . . . . 101B.4 Combination of Etudes 4 and 6, Method 1 . . . . . . . . . 109B.5 Combination of Etudes 4 and 6, Method 2 . . . . . . . . . 119B.6 Combination of Etudes 4 and 6, Method 3 with Compo-

nents Modeled Jointly . . . . . . . . . . . . . . . . . . . . 129B.7 Combination of Etudes 4 and 6, Method 3 with Compo-

nents Modeled Independently . . . . . . . . . . . . . . . . 139

Appendix C Experiment Forms 149

Bibliography 153

10 Contents

Page 11: Hierarchical Music Structure Analysis, Modeling and

CHAPTER ONE

Introduction and Background

1.1 Motivations

There are two motivations for the present work: the first motivationcomes from my interest in music analysis. Several music theories havebeen developed as useful tools for analyzing and characterizing music.Most of these theories, such as Riemann's theory of tonal music, Schenke-rian analysis [31] and Forte's atonal theory, are specific to particularstyles or systems of composition. It would be interesting to see the de-velopment of an analytical method useful for any kind of music. Thismethod would have to be based on features that are present in all music,the element of motion being the only constant characteristic. Thus, myinterest in finding a more general method of musical analysis applicablefor a variety of music has motivated me to classify music in terms ofthe different kinds of motion it manifests, encouraging me to define ataxonomy of motion. While the importance of motion in music is obvi-ous, no work that I know of has systematically studied music from thisperspective.

The second motivation comes from my interest in understanding the be-havior of my musical imagination. The process of composing usuallyincludes writing or recording the imagined sound evolutions as they arebeing heard in one's mind. Multiple paths and combinations are ex-plored during the process of imagining new music, so that the score weultimately write is but an instance of the multiple combinations exploredin one's mind. It is also a simplification of the imagined music becausethe representation we use to record the imagined sound evolutions isincomplete. In other words, we are unable to represent accurately ev-ery detail of the imagined universe. Thus, this representation is like aphotograph of the dynamic, ever-changing world of the imaginary. Why

Page 12: Hierarchical Music Structure Analysis, Modeling and

decide on one sequence or combination over another? Is there a singlebest sequence, a better architecture? My personal answer to this ques-tion is no. This has led me to become interested in pursuing the creationof a meta-music: a system that generates the fixed notated music alongwith all its other implied possibilities.

1.2 Generative Music Systems and Algorithmic Com-position

Algorithmic composition can be broadly defined as the creation of algo-rithms, or automata in general, designed for the automatic generation ofmusic.1 In other words, in algorithmic composition the composer doesnot decide on the musical events directly but creates an intermediarythat will choose the specific musical events for him. This intermediarycan be a mechanical automaton or a mathematical description that con-strains the possible musical events that can be generated. The definitionhere is deliberately broad to suggest the continuous spectrum that existsin the levels of detachment between what the composer creates and theactual sounds produced.2

Every algorithmic composition approach can be placed in a continuumbetween ad hoc design and music modeling. Ad hoc designs are thosewhere the composer invents or borrows algorithms with no particularmusic in mind. The composer doesn't necessarily have a mental imageof what the musical output will be. The approach is something like:"Here's an algorithm, and I wonder what this would sound like." Inmusic modeling, the composer deliberately attempts to generalize themusic he hears in his mind, so the algorithm is a deliberate codificationof some existing music.

We find examples of ad hoc approaches as early as 1029 in music theoristGuido D'Arezzo's Micrologus. Guido discusses a method for automati-cally composing melodies using any text by assigning each note in thepitch scale to a vowel [26]. Because there are more pitches than vowels,the composer is still free to choose between the multiple pitch optionsavailable. Similarly, Miranda borrows preexisting algorithms from cellu-lar automata and fractal theory for automatic music generation [28].

'For a complete definition of algorithm and a discussion of how they relate to musiccomposition, see [26].

2One could argue that any composition is algorithmic since the composer does notdefine the specific wave-pressure changes, only the mechanisms to produce them.

12 Introduction and Background

Page 13: Hierarchical Music Structure Analysis, Modeling and

While inventing ad hoc algorithms for music composition is a fascinatingendeavor, in this work we are interested in learning about our intuitivemusical creativity and developing a generative system that grows frommusical examples. Thus, we discuss the design of a generative musicsystem based on modeling existent music.

1.3 Modeling

All models are wrong, but some are useful.

George E.P. Box

There are no best models per se. The most effective model will dependon the application and goal. Different goals suggest different approachesto modeling. As expressed by our motivations, our models intend toserve a double purpose: the first is to obtain some understanding aboutthe inner workings of a given piece and, hopefully, gain insight intothe composer's mind. The second is for the models to be a powerfulcomposition tool. It is difficult, if not impossible, to come up with amodel that achieves these two goals simultaneously for a variety of piecesbecause a generative model might not be the most adequate for analysisand vise versa. Music structure is so varied, so diverse, that it seemsunlikely that a single modeling approach could be used successfully forall music and for all purposes.

What are the criteria for choosing a model? Is the model simple? TheMinimum Description Length principle [33], which essentially definesthe best model as that which is smallest with regards to both form andparameter values, is a measure of such a criterion. Other criteria toconsider are:

Robustness: Does it lend itself well to a variety of data (e.g. musicalpieces)?Prediction: Can it accurately predict short term or long term events?Insight: Does it provide new meaningful information about the data?Flexibility: As a generative system, what is the range or variety of newdata that the model can generate?

1.3 Modeling 13

Page 14: Hierarchical Music Structure Analysis, Modeling and

1.3.1 Models of Music

Deduction vs. Induction

Brooks et al. describe two contrasting approaches to machine modeling:the inductive and the deductive [4]. Essentially, the difference lies in whoperforms the analysis and the generalization: the human programmer orthe machine. In a deductive model, we analyze a piece of music anddraw some rules and generalizations from it. We then code the rulesand generalizations and the machine deduces the details to generate newexamples. In an inductive approach, the machine does the generalization.Given a piece (or set of pieces) of music, the machine analyzes and learnsfrom the example(s) to later generate novel pieces.

While many pieces may share common features, each piece of music hasits own particular structure and "logic". A deductive approach impliesthat one must derive the general constants and particularities of a pieceor set of pieces for the subsequent induction by the machine. This is atime-consuming task that could only be done for a small set of piecesbefore one's life ended. The classic music analysis paradigm is at the rootof this approach. One can certainly learn a lot about music in this way,but it seems to us that attempting to have the machine automaticallyderive the structure and the generalization is not only a more interestingand challenging problem, it also might shed light about the way we learnand about human cognition in general. This approach also encouragesone to have a more general view regarding music and to be as unbiased aspossible (hopefully changing our own views and biases in the process).In a deductive approach we are filtering the data. We are telling themachine how to think about music and how to process it. In an inductiveapproach the attempt is to have the machine figure out what music is.

We could alternatively attempt to model our own creativity directly, butit seems to us that the "logic" or structure and generative complexity ofthe highly subconscious and hardly predictable creative mind is at a farreach from our conscious self probing and introspection. 3 Rather thanasking ourselves what might be going on in our mind while we imagine anew piece of music and trying to formalize the creative process, we canlet our imagination free, without probing, and then have the machineanalyze and model the created object.

3This nebulous and partly irrational experience of the imaginary has been expressedmany times by different composers, for example [34, 15].

14 Introduction and Background

Page 15: Hierarchical Music Structure Analysis, Modeling and

Continuous vs. Discontinuous

Most generative music systems and analysis methods assume a discrete

(and most times finite) musical space.4 This is a natural assumptionsince the dominating musical components in western music have beenrepresented with symbols for discrete values. 5 The implication is thatmost models of music depart from the idea that a piece is a sequence ofsymbols taken from a finite alphabet. Almost all the generative systemswe are aware of are discrete ([21] [4] [19] [38][12] [8][9][41] [7][32] [30] [29][3]).This thesis, however, proposes a continuous approach to modeling musicstructure.

Deterministic vs. Probabilistic

There is no way of proving the correctness of the position of'determinism' or 'indeterminism'. Only if science were

complete or demonstrably impossible could we decide suchquestions.

Mach (Knowledge and Error, Chapt XVI.11)

Should a music structure model be deterministic or stochastic? Con-sider two contrasting musical examples: on one extreme there is SteveReich's Piano Phase. The whole piece consists of two identical periodicpatterns with slightly different tempi (or frequencies).6 Piano Phase canbe straightforwardly understood as a simple linear deterministic station-ary system. On the other extreme we can place Xenakis' string quartetST/4, 1-080262. It would make sense to model ST/4, 1-080262 stochas-tically since we know it was composed in this way! In between these twoextremes there are a huge variety of compositions with much more com-plex and intricate structures. There may be pieces that start with clearlyperceivable repeating patterns and that gradually evolve into somethingapparently disorganized. A piece like this might best be modeled as acombination of deterministic and stochastic components that are a func-

4 Since the classical period, notation for loudness has commonly included symbolsfor continuous transitions, but loudness is typically not considered important enoughto be studied. If it is, its continuous nature is typically ignored.

5 Indeed, the recurrent inclusion of the continuum in notated pitch space (start-ing probably with Bartok, continuing with Varese and Xenakis, and culminating inEstrada) has made it difficult or impossible for some music theoretic views to approachthese kinds of music.

6 The point of the piece is the perception of the evolution of the changing phaserelationships between the two patterns.

1.3 Modeling 15

Page 16: Hierarchical Music Structure Analysis, Modeling and

tion of time. In addition, these combinations may occur at multipletime scales, in which case it would be better modeled as a combinationof a deterministic component at one level, and a stochastic componentat another. Thus, rather than trying to find a single global model for awhole piece, we might want to model a piece as a collection of multiple,possibly different, models.

Brief Thoughts on Markov Models

It is intriguing to see how the great majority of the inductive machinemodels of music are discrete Markov models. Remember that an kthorder Markov model of a time series is a probabilistic model where theprobability of a value at time step n + 1 in a sequence s is given bythe k previous values: p(sn+1IP(sn, Sn-1, .. , Sn-k+1). Why discrete andwhy Markovian? Several papers on Markov models of music are basedon the problem of reducing the size and complexity of the conditionalprobability tables by the use of trees and variable orders([41] [3] [30]).Again, the discrete nature of the models most probably comes from theview of music as a sequence of discrete symbols taken from an alphabet.Why not model the probability density functions parametrically, as withmixtures of gaussians?

Are Markov models really good inductive models of music? What kindof generalization can they make? Most applications of discrete Markovmodels estimate the probability functions from the training data. Usu-ally, zero probabilities are assigned to unobserved sequences. If this isthe case, it is impossible for a simple kth order Markov model to gener-ate any new sequences of length k + 1. All new and original sequenceswill have to be of length k +2 or greater. Take for example the followingsimple sequence which we assume to be infinite:

1, 2,3,2,1,2,3, 2,1,2,3,2,... (1.1)

A first order model of this sequence can be constructed statistically bycounting the relative frequencies of each value and of each pair of values.The relative frequencies of all possible pairs derived from this sequencecan be easily visualized in the following table, where each fraction in thetable represents the number of times a row value is immediately followedby a column value, divided by the total number of consecutive value orsample pairs found in the sequence. From these statistics we can nowderive the marginal probabilities of individual values, and by Bayes' rule

16 Introduction and Background

Page 17: Hierarchical Music Structure Analysis, Modeling and

Table 1.1: Relative frequency of all pairs of values found in sequence 1.1

1 2 31 0 1/4 02 1/4 0 1/43 0 1/4 0

we find the conditional probabilities:

P(Sn+1ls ) = P(Sn+1, Sn)

p(Sn)

From this table we can see that new sequences generated by this jointprobability function will never produce pairs (1,1), (1,3), (3,1), (3,3),(2,2) or extrapolate to other values, such as (4,5). In other words, alllength 2 sequences that this model can generate are strictly subsets ofsequence 1.1, while those of length 3 or greater may or may not appear inthe original sequence. To overcome this limitation one could give unob-served sequences a probability greater than zero, but this is essentiallyadding noise. Looking at generated sequence segments of length 3 orgreater we may now wonder how these are related to the original train-ing pieces. The limitation of this model soon becomes apparent. Newsequences generated from this model will have some structural resem-blance to the original only at lengths 1 < k + 1 (1 < 2 in this example),but not at greater lengths. From the first order model in the presentexample it is possible to obtain the following sequence:

1, 2,3,2, 3, 2,1,2,3,2,1,2,1,2,1,2,1,2,3,2,3,2, 1, 2,3,2,1, ...

Because p(312) = p(112) = 0.5, the generated sequence will fluctuatebetween 1 and 3 with equal probabilities every time a 2 appears. Thismisses what seems to be the essential quality of the sequence: its peri-odicity. Increasing the order of the model to 2, we are able to capturethe periodicity unambiguously. But what generalization exists? Now themodel will generate the whole original training sequence exactly. Thisis the key idea we explore in this work. We want the model to be ableto abstract the periodicity and generate new sequences that are differ-ent from the original but that have the same essentially periodic quality.This information can be obtained by looking for structure and patternsin the probability functions derived from the statistics, but in this workwe will present a different approach.

1.3 Modeling 17

Page 18: Hierarchical Music Structure Analysis, Modeling and

One more problem is that of stationarity. In our example the sequencerepeats indefinitely, making a static probabilistic model adequate. Butmusic continuously evolves and is very seldomly static. Sequences gener-ated with a simple model like the one discussed above may resemble theoriginal at short time scales, but the large scale structures will be lost.This problem could be addressed by dynamically changing the proba-bility functions, i.e. with a stochastic model. Modeling non-stationarysignals can also be done through a hierarchical representation, where theconditional probabilities are estimated not only sequentially, but also ver-tically across hierarchies. Some concrete applications of this approachcan be found in image processing [10], and to our knowledge, there havenot been similar approaches in music modeling. Similar problems havebeen observed using other methods such as neural networks [29], wherethe output sequences resembled the original training sequence only lo-cally due to the note-to-note approach to modeling.

The Markov model example we have given here is certainly extremelysimplistic, but hopefully it makes clear some of the problems of thisapproach to music modeling for the purpose of generating novel pieces.

1.3.2 Our Approach to Music Structure Modeling

As suggested in our motivations, our main interest is the abstractionof the essential qualities of the dynamic properties of music and theiruse as sources for the generation of novel pieces. By dynamics we meanthe qualitative aspects of motion in music, rather than the loudnesscomponent as is usually used by musicians. Here we approach musicalsequences in a similar way as a physicists would approach the motion ofphysical objects.

The notion of the dynamical properties of a musical sequences is ratherabstract, and we hope to clarify it with a concrete example. First, con-sider the following question: why can we recognize a tune even whenreplacing its pitch scale (e.g. changing from major to minor), or whenthe pitch sequence is inverted? What are the constants that are pre-served that allow us to recognize the tune?

Take for example the first 64 notes (8 measures) of Bach's Prelude fromhis Cello Suite no.1 (Figure 1-1). There are multiple elements that wecan identify in the series: the pitches, the durations, the scales and har-monies the pitches imply, the pitch intervals and the temporal relation-ships between these elements. How can we characterize these temporal

18 Introduction and Background

Page 19: Hierarchical Music Structure Analysis, Modeling and

Prelude.AO,"-. -0

3PAP~~~F f fA A A

FS

7

60

58

56

54

52

50

48

46

44

Note Number

Figure 1-1: Top: First 8 measures of Bach's Prelude from Cello Suiteno.1. Bottom: Alternative notation of the same 8 measures of Bach'sPrelude. Here the note sequence is plotted as connected dots to makethe contour and the cyclic structure of the sequence more apparent.

1.3 Modeling 19

Is - Is M

Page 20: Hierarchical Music Structure Analysis, Modeling and

relationships? Can we say something about the regularity/irregularityof the sequence, the changes of velocity, the contour? An abstract rep-resentation of the motion in Bach's Prelude might look something like

(up, up, down, up, down, up, down, down, ... ) repeating several times.This is a useful but coarse approximation, preserving only the orderingof intervals. We might also want to preserve some information about thesize of the intervals, their durations and the quality of the motion fromone point to the next: is it continuous, is it discrete? Whatever the case,we see from Figure 1-1 (Bottom) that this general sequence is the onlystructure in the Prelude fragment, repeating and transforming graduallyto match some harmonic sieve that changes every two measures. Everytwo measures the sequence is slightly different, but in essence the type ofmotion of the eight measures is the same. Thus, we can consider the se-quence as being composed of two independent structures: the dynamicsand the sieves though which these are filtered or quantized.

In this thesis we focus on the analysis and modeling of these dynamicproperties. We address ways in which we can decompose, transform,represent and generalize the dynamics for the purpose of generating newones. Rather than trying to extend on the Markovian model as suggestedabove, we approach the problem from a deterministic perspective. Weexplore the use of a method that allows for a geometric representationof time series, and discuss different ways to model and generalize thegeometry deterministically.

20 Introduction and Background

Page 21: Hierarchical Music Structure Analysis, Modeling and

CHAPTER TWO

Musical Representation

Structure in music spans about seven orders of magnitude, from approx-imately 0.0001 seconds ( 1 Oz) to about 1, 000 seconds (~ 17 min.) [11].In the present work we focus on the upper four orders (between 0.1 secs.and 1,000 secs.) for two reasons: One, these orders correspond to thosetypically represented in musical scores. Second, there is a clear differ-ence between the way we perceive sound below and above approximately0.02Hz.

Below this threshold, we hear pitch and timbre, and above it we hearrhythm and sound events or streams. The perception can be so clearlydifferent that they feel like two totally independent things: a high-levelcontrol signal driving high-speed pressure changes. These high-level con-trol signals are what we are interested in modeling and transforming.Thus, the musical representations we will use are not representations of

the actual sound, but abstract representations of these high-level signals.

As of today, it is still very difficult to extract these high level controlsignals from the actual audio signal. Good progress has been made intracking the pitch of individual monophonic instruments and in somespecial cases from polyphonic textures. But the technology is still farfrom achieving the audio segregation we would like. Therefore, exceptfor simple cases where the evolution of pitch, loudness and some timbralfeatures can be relatively well extracted (such as simple monophonicpieces), our point of departure is the musical score.

Two basic types of scores exist. In the first, the score represents the

evolution of perceptual components, such as pitch, loudness, timbre, etc.In the second, traditionally called tablature notation, the score is a rep-

resentation of the performance techniques required to obtain a particular

Page 22: Hierarchical Music Structure Analysis, Modeling and

sound. In essence they are both control signals driving some salient fea-ture of sound or some mechanism for its production. There are severalways in which these high level control signals can be represented beforebeing modeled and transformed. Some representations will be more ap-propriate than others depending on their use and the type of music tobe represented.

Representation of Time

The simplest and most common way of representing a digitized scalarsignal is as a succession of values at equal time intervals:

s[n] = so, si, ... , sn (2.1)

Since it is assumed that all samples share the same duration, this infor-mation need not be included in the series.

The same is true for a multidimensional signal where each dimensiondescribes the evolution of a musical component. For example, a seriesdescribing the evolution of pitch, loudness and brightness might look likethis:

Po, P1, .- ,- Pns[n]= lo, ii, ... , in (2.2)

bo, bl, ...,I bn

For the specific case where there is more than one instrument or soundsource, as in a three voice fugue, a chorale or even possibly an entireorchestra, the series can again be extended as:

Pa,0, Pa,, . -- , Pa,n

1a,,7 ia,1, -. - I la,nba,o, ba,1, . . , ba,n

Pb,0Pb,b,1, - - - , Pb,n

s[n] = lb,O, 1b,1, . . . , lb,n (2.3)bb,o, bb,1, - - , n

Pm, Pm,1, --- , Pm,n

1m,0, lm,1, . - - , m,n

_ bm,o, bm,1, ... , bm,n

While this is a simple representation scheme, it is not necessarily the bestin all cases. The problem with this representation has to do primarily

22 Musical Representation

Page 23: Hierarchical Music Structure Analysis, Modeling and

with the temporal overlapping of events. Consider a polyphonic instru-ment such as the piano. With this instrument it is possible to articulatemultiple notes at the same time. How should we represent a sequence ofpitches that overlap and start and end at different times? An alternativeis to have a series that has as many dimensions as the number or keys inthe piano, where each dimension represents the evolution of the velocityof the attack and release of each key:

s[n] V20 V2,1= . (2.4)

_ Vm,0, Vm,1, ... , Vm,n .

How could we reduce the number of dimensions and still have a meaning-ful representation? A tempting idea might be to separate a piano pieceinto multiple monophonic voices and to assign each voice to a dimensionin a multidimensional polymelodic series as in 2.3. But in addition tobeing an arbitrary decision in most cases (not all piano pieces are con-ceived as a counterpoint of melodies), the main problem is that even insingle melodic lines there may still be overlaping notes through legatis-simo articulation.

An alternative representation is the Standard Midi File (SMF) approach,where time is included explicitly in the representation by indicating theabsolute position of each event in time or the time difference: the InterOnset Interval (101). In addition to this time information there are theduration of each event and the component values. The most economicalform of this representation, Format 0, combines all separate sources orinstruments into a few dimensions, one of which specifies the instrumentto which the event corresponds. The following is an example of thisformat, where ioi stands for Inter Onset Interval, d for duration, p for

pitch, v for velocity (or loudness) and ch for channel (or instrument):

zozO, z ... , zozn

d0, d1, - - ns[n] = p0, pi, ... , pn (2.5)

Vo, V1, -... , Vn

L cho, chi, ... , chn .

With this format we can now represent overlapping events with only a

few dimensions. This is an adequate representation for the piano, dueto the discrete nature and limited control possibilities of the instrument.

Yet, it is far from being a good numeric replacement for a traditional

Page 24: Hierarchical Music Structure Analysis, Modeling and

music score in general, the main problem being the loss of independencebetween the multiple parameters. Because the explicit representation oftime intervals can be useful, we can still take advantage of this feature bydefining pairs of dimensions for each parameter: one for the parametervalues and another for their durations. Besides providing some insightinto the rhythmic structure of a sequence, it can also significantly reducethe number of data samples:

Po, Pi, ... , Pn

d0 , d1 , ... , ns [n] = (2.6)

vo, V1, ... , vn

_ d0 , d1 , . . . , dn _

While this representation lends itself best for discrete data, we can as-sume some kind of interpolation between key points and still make ituseful for continuous data.

Summary

There are multiple ways in which musical data can be represented. Dif-ferent representations have different properties: some provide compactrepresentations, while others are more flexible. In addition, some maybe more informative about certain aspects of the music than others. Thechoice of representation will also depend on the type of transformationwe are interested in applying to the data. In the present work we usethese three basic representations (constant sampling rate representation,variable sampling rate representation, and SMF Format 0) in differentsituations for the purpose of analysing and generating new musical se-quences.

24 Musical Representation

Page 25: Hierarchical Music Structure Analysis, Modeling and

CHAPTER THREE

State Space Reconstruction andModeling

3.1 State Spaces

One of the most important concepts in this work is that of state space

(or phase-space). A state space is the set of all possible states or con-figurations available to a system. For example, a six sided die can be inone of six possible states, where each state corresponds to a face of thedie. Here the state space is the set of all six faces. As a musical exam-ple consider a piano keyboard with 88 keys. All possible combinationsof chords (composed from 1 to 88 keys) in this keyboard constitute thestate space, and each chord is a state. These two examples constitutefinite state spaces because they have a finite number of states. Somesystems may have an infinite number of states; for example a rotatingheight adjustable chair. A chair that can rotate on its axis and thatcan be raised or lowered continuously has an infinite number of possiblepositions. Yet, in practical terms, many of these positions are so close toeach another that sometimes it makes sense to discretize the space andmake it finite (for example, by grouping all rotations within a range of7r radians into one state). While this system has an infinite number ofpossible states, it has only two degrees of freedom: up-down motion andazimuth rotation.

State spaces can be represented geometrically as multidimensional spaceswhere each point corresponds to one and only one state of the system. Inthe chair example, since only two degrees of freedom exist, we can rep-resent the whole state space in a two dimensional plane. Yet, we mightlike to keep the relations of proximity between states in the representa-tion as well. Therefore we embed the two dimensional state space of the

Page 26: Hierarchical Music Structure Analysis, Modeling and

rotating chair in a three dimensional space in such a way that the statesthat are physically close to each other are also close in state space. Thisresults in a cylinder, and is a "natural" way of configuring the points inthe state space of the chair.

An analogous musical example is that of pitch space. This one-dimensionalspace can be represented with a line, ranging from the lowest perceivablepitch to the highest. But this straight line is not a good representationof human perception of pitch in terms of similarity. Certain frequencyratios like the octave (2:1) are perceived to be equivalent or more closelyrelated to each other than, for example, minor seconds. In 1855 Dro-bisch proposed representing pitch space as a helix, placing octaves closerto each other than perceptually more distant intervals [35]. Thus, wehave a similar case to that of the chair, where a low dimensional space isembedded in a higher dimensional euclidean space to represent similarstates by proximity (Figure 3-1).

g# g#

Figure 3-1: Helical representation of pitch space. A one-dimensionalline is embedded in a three-dimensional euclidean space for a betterrepresentation of pitch perception.

3.2 Dynamical Systems

We have discussed the notion of state space and have given a few exam-ples of their representation. But for the case of music, it is the temporalrelationships between states that we are most interested in (i.e. their dy-namics), rather than the states themselves. Given this interest, it comes

26 State Space Reconstruction and Modeling

Page 27: Hierarchical Music Structure Analysis, Modeling and

as no surprise that our first approach to studying the qualitative char-acteristics of motion in music comes from the long tradition of the studyof dynamical systems in physics. We will not discuss here the historyof this vast discipline, but only present some key ideas and importantresults that will help us analyze, model and generalize musical structuresfrom which we will hopefully generate novel pieces of music.

3.2.1 Deterministic Dynamical Systems

We ought then to regard the present state of the universe asthe effect of its anterior state and as the cause of the one

which is to follow. Given for one instant an intelligencewhich could comprehend all the forces by which nature is

animated and the respective situation of the beings whocompose it -an intelligence sufficiently vast to submit thesedata to analysis- it would embrace in the same formula themovements of the greatest bodies of the universe and thoseof the lightest atom; for it, nothing would be uncertain and

the future, as the past, would be present to its eyes.

Pierre-Simon Laplace (Philosophical Essay on Probabilities,II. Concerning Probability)

A deterministic dynamical system is one where all future states areknown with absolute certainty given a state at an instant in time. Ifthe future state of a system depends only on the present state, indepen-dently of the time at which the state is found, then the system is saidto be autonomous. Thus, the dynamics of an autonomous system aredefined only in terms of the states themselves and not in terms of time.

In the case of an m-dimensional state space, the dynamics of an au-tonomous deterministic system can be defined as a set of m first-orderordinary differential equations for the continuous case (also called a flow)[22]:

- x(t) = f(x(t)), t E R (3.1)dt

or as an m-dimensional map for the discrete case:

xn+1 = F(xn), n E Z (3.2)

3.2 Dynamical Systems 27

Page 28: Hierarchical Music Structure Analysis, Modeling and

3.2.2 State Space Reconstruction

What if we know nothing about the nature of a system, and all we haveaccess to is one of its observables? Consider for example the flame of acandle as our system of interest. Suppose that, similarly to Plato's caveof shadows from his Republic, Book VII, we do not see the candle directly,but only the motion of shadows of objects projected on the wall. Thus,we have a limited amount of information about the candle's motion andall its degrees of freedom. Can we infer the motion of the candle's flamein its entirety from the motion of the shadows?

Suppose now that our observation is a piece of music; it is the shadowmoving on the wall. We now want to know what the nature of the "sys-tem" that generated the given piece of music is. Can we automaticallyinfer the hidden structure of the mind responsible for the generation ofthe piece and, from this structure, generate other musical possibilities?Evidently, in the context of this work, this example should not be takenliterally, but you get the idea.

We now state the question more formally. Given a series of observationss(t) = h(w(t)) that are a function of the system W, is it possible toreconstruct the dynamics of the state space of the system from theseobservations? Can we find h 1 (s(t))? If s(t) is a scalar observation se-quence, is it possible to recover the high dimensional state space thatgenerated the observation? Takens' theorem [40] states that it is pos-sible to reconstruct a space X E Rm that is a smooth differomorfism(topologically equivalent) of the true state space W E Rd by the methodof delays. This method consists of constructing a high dimensional em-bedding by taking multiple delays of s(t) and assigning each delay to adimension in the higher dimensional space X:

x (t) =(s(t), s(t - -r), . . . , s(t - (m - 1)r))

= (h(w(t)), h(w(t - T)),... , h(w(t - (m - 1)T))

H(w(t))

The theorem states that this is true if the following conditions are met:

1. System W is continuous with a compact invariant smooth manifoldA of dimension d, such that A contains only a finite number ofequilibria, contains no periodic orbits of period T or 2T and containsonly a finite number of periodic orbits of period pT, with 3 < p <M.

28 State Space Reconstruction and Modeling

Page 29: Hierarchical Music Structure Analysis, Modeling and

2. m>2d+1.

3. The measurement function h(w(t)) is C2.

4. The measurement function couples all degrees of freedom.

The condition that m > 2d + 1 guarantees that the embedded manifolddoes not intersect itself. In many cases a value of m smaller than 2d +1 will work because the number of effective degrees of freedom of thesystem may be smaller due to dissipation or correlation between thedimensions in state space [37].

3.2.3 Calculating the Appropriate Embedding Dimension

How do we decide on a good dimension m for the embedding? Howdo we know if the dimensionality we've chosen for the embedding ishigh enough to capture all the degrees of freedom of the system? Fordeterministic time series we want each state to have a unique velocityassociated with it, i.e. if Xn = Xk then F(x,) = F(Xk). This impliesthat for the case of continuous time series, trajectories should not crossin state space. In other words, points that are arbitrarily close to eachother, both in space and time, will have very similar velocities.

Correlation Sum

A simple way of estimating a good embedding dimension for state spacereconstruction of deterministic systems is to find points that overlap orthat are closer than E to each other. The correlation sum simply countsthe number of distances smaller than 6 between all pairs of points (xi, x3 ).

2 N-1 N

C(6) = N(N -) (E - ||xi -xI|) (3.3)i=1 j=i+1

Here E(x) is the Heaviside function, which returns 1 if x > 0 and 0if x ; 0. Throughout the text we use the Euclidean distance metric:

|x - y11 = iy) 2 +...+(m-m) 2 .

A good embedding dimension will be one where the correlation sum isvery small in proportion to the total number of points. Because it isnot clear what a good choice of E is, the correlation sum is evaluated fordifferent values of E and different embedding dimensions m. Specifically

3.2 Dynamical Systems 29

Page 30: Hierarchical Music Structure Analysis, Modeling and

for discrete series, with e smaller than the quantization resolution 6 wecan count the number of points that fall in the same place. Thus, whenwe want a strictly bijective relation between the embedded trajectory andthe observation sequence, we choose the smallest embedding dimensionwhere the correlation sum equals zero, for e < J. i.e. C(e < 6) = 0.

False Nearest Neighbors

A more sophisticated method for estimating the embedding dimensionis the false nearest neighbors method [23]. This algorithm consists ofcomparing the distance between each point and its nearest neighbor inan m-dimensional lag space to the distance of the same pair of points inan m + 1-dimensional space. If the distance between the pair of pointsgrows beyond a certain threshold after changing the dimensionality ofthe space, then we have false nearest neighors. Kantz [22] gives thefollowing equation for their estimation:

(m+1) (m1 ) )Zain ( _ r) ~) 1(m ) )1

Eanln a m> > - r 1 r -|| -x1)Xfnn (r ) =M ( )

(3.4)Where x(m) is the closest neighbor of xm in m dimensions and o isthe standard deviation of the data. The first Heaviside function in thenumerator counts the neighbors whose distance grows beyond the thresh-old r, while the second one discards those whose distance was alreadygreater than -/r. Cao [5] proposed a more elegant measure of falsenearest neighbors. He further eliminates threshold value r by consider-ing only the average of all the changes in distance between all points asthe dimension increases, and then taking the ratio of these averages. Hedefines the mean

+1 ||Xm 1) - (m+1)

E[m] = IIx~m) (3.5)all n Xn - (1)n|

and E1(m) = E[m + 1]/E[m] as the ratio between the averages of con-secutive dimensions. The ratio function E1(m) describes a curve thatgrows slower as m increases, asymptotically reaching 1. The value of mwhere the growth of the curve is very small is the embedding dimension

30 State Space Reconstruction and Modeling

Page 31: Hierarchical Music Structure Analysis, Modeling and

we are looking for.' Typically the value selected is slightly above theknee of the curve (Figure 3-2).

0.9-

0.8-

0.7-

W 0.6-

0.5-

0.4-

0.3

2 4 6 8 10 12 14 16 18 20Dimension (m)

Figure 3-2: Example of a typical behavior of E1(m). The function

reaches 1 asymptotically, and a good choice for the embedding di-

mension is above the knee of the curve, where its velocity decreases

substantially.

3.2.4 Calculating the Time Lag T

While Taken's theorem tells us what the minimum embedding dimensionfor state space reconstruction should be, it says nothing about how tochoose the delay T for the embedding. In theory, the choice of T isirrelevant since the reconstructed state space is topologically equivalentto the system's manifold. In practice, though, factors such as observationnoise and quantization make it necessary to find a good choice of T formodel estimation and prediction.

To better understand what a good choice of r would be, we take asexample one of the most popular systems in nonlinear dynamics: the

'This assumes that the time series comes from an attractor. If the series is noise

for example, El(m) will never converge.

3.2 Dynamical Systems 31

Page 32: Hierarchical Music Structure Analysis, Modeling and

Lorenz attractor. The dynamics of the system are defined as

= (y - x)

y px - y-xz

z -#3z+xy

Figure 3-3 shows 4000 points of the trajectory of this attractor, withparameters o = -10, p = 28, # = -2.666..., and initial position x = 0,y = 0.01 and z = -0.01. Suppose our only observable is the x axis ofthe system (Figure 3-4). We construct the lag space from this observ-able as x,, (Xn, xn-r, Xn2T). Figure 3-5 shows the reconstructed

50

40,

30

10,

0

-1050

0

y -50 -20 -10 0 10 20

x

Figure 3-3: Lorenz attractor with parameters o= -10, p 28, #3-2.666....

state space from x for different values of T. For TF 1, all the points inthe reconstructed space fall along the diagonal. T = 1 is clearly smallbecause the coordinates that compose each point are highly correlatedand almost identical. As T is increased, the embedding unfolds to revealthe structure of the attractor, which is clearest for values of -r between8 and 14. As T continues to increase, the geometry gradually distortsto an overcomplicated structure. While visual inspection is a good wayof estimating the delay parameter, in many cases the dimensionality ofthe state space must be greater than three (apart from the fact that weignore the shape of the real state spaces that generated the observation).Thus, a quantitative measure to estimate the appropriate value of T is re-quired. The method we will use is based on the above observation aboutthe correlation that exists between coordinates in the reconstructed state

32 State Space Reconstruction and Modeling

Page 33: Hierarchical Music Structure Analysis, Modeling and

Figure 3-4: Evolution of the x dimension (our observation) of theLorenz system. The abscissa shows the sample steps of the sequenceswhile the ordinate shows the actual value of the x axis of the Lorenzattractor.

space. If coordinates are highly correlated, then the reconstructed tra-jectory will fall along the main diagonal of the space. This means thatwe want to find a r large enough to make the correlations minimal yetsmall enough to avoid distortion of the reconstructed trajectory. A mea-sure of the mutual information between a series and itself delayed by T

provides us with a reasonable answer to this question [24]. Let p,, (i) bethe probability that the series s[n] takes the value i at any time n, and

ps(,sn_-(i, j) be the probability that the series s[n] takes the values i attime n and j at time n - r for all n. The mutual information is then:

I(sn; sn--) = psn,sn_(i, j) log 2 P.,(W (3.6)

Figure 3-6 is a plot of the mutual information of the observation x ofthe Lorenz system as a function of T. The first minimum of the mutualinformation function is our choice of r.

3.3 Modeling

3.3.1 Spatial Interpolation = Temporal Extrapolation

A trajectory in the reconstructed state space informs us about statesvisited by the system, as well as their temporal relationships. How dowe generate new trajectories (new state sequences) that have similardynamics to the reconstructed state space trajectory? What other statesequences are implied by this trajectory? Given a new state xn not found

3.3 Modeling 33

Page 34: Hierarchical Music Structure Analysis, Modeling and

x[n] -10 U xtni -10x[n-taul x[n-taul

15 1510 10

5-

0, 0,

x -5, x -5,

-10 -10,

15 -15

-10 -100 010 10

-10 0 10 -10 0 10x[n] x[n-tauj xln-tau]

15, 15

10, 10

- 5, - 5

n0 0 C 0

x -5, -5

-10, -10

-15, -15

-10 -10

010 010L-10 0 10 -10 0 10

x[n-tauj x[n-tau]

15 15

10 10

5 - 502 0

-5 -5

-100-10,-1-15

-15,

-10 -10 L

xn 10 -10 0 10 xn 10 -10 0 10

x[n-tau] x[n-tau]

Figure 3-5: Three-dimensional embedding of the observable x[n] bythe method of delays with different values of T. From top to bottom,left to right: T = 1,r = 2,F = 4,rT= 8,r = 1 4 ,r = 2 0,T= 32 ,T= 64.

34 State Space Reconstruction and Modeling

Page 35: Hierarchical Music Structure Analysis, Modeling and

6.5

6

5.5

-5

4.5

4-

3.5

0 20 40 60 80 100 120time laq (Tau)

Figure 3-6: Estimation of the value for r by mutual information. The

first local minimum is the best estimate of r.

in the original state space trajectory, what would be the "natural" orimplied sequence of states xn+1, Xn+2, Xn+3 ... ? Paraphrasing in more

musical terms, if our state space is a reconstruction of an actual piece ofmusic, how do we generate new pieces of music that have similar motioncharacteristics to the original piece, yet different at the same time? Whatother musical sequences are implied by the structure of the embeddingof the original piece?

These questions are intimately related to the problem of prediction, andin a reconstructed state space prediction becomes a problem of interpola-tion [39]. There are multiple ways to interpolate the space and differentmodeling techniques can be used. We can consider a single global pre-

dictor valid for all xn, or a series of local predictors which are valid only

locally in the vicinity of the point of interest.

Local Linear Models

Probably the simplest interpolation method is the method of analoguesproposed by Lorenz in 1969 [25]. Let x(i)n be the ith nearest neigh-bor of xn. The method of analogues consists of finding the nearestneighbor x(1)n to xn, and equating xn,+1 to X(l)n+1. In other words,F(xa) = F(x(1)nl).An obvious improvement over this method is to calcu-late xn+1 from a number of nearest neighbors. The number of neighborscan be defined by a radius e around the point xn (in which case this

number would vary depending on the density of the state space around

xn), or by choosing a fixed number on neighbors N. For both cases,

the combination of the neighbor points of xn can be weighted by their

distances to xn. An estimation of xn+1 from the weighted average of the

3.3 Modeling 35

Page 36: Hierarchical Music Structure Analysis, Modeling and

N nearest neighbors of x, can be expressed as

N

F(xn) = F(xtiyn)#(||xn -- x(i)n 11) (3.7)

i=1

where # is a weighting function [25]. In our present implementation # isdefined as

Ji .N =1||Xn - X(i)n1iP#i = with Ji = 1 H - X()n P (3.8)

_ 6=1 ||xn - x()n||P

where p is a parameter used to vary the weight ratios of the states X(i)ninvolved.

F(xn) = #1F(x(1)n) + #2F(x(2)n) + ... + #NF(x(N)n)

(.) returns values between 0 and 1, and #(1) + 0(2) + .. . + #(N) -In other words, only the relative distances between point xn and itsN nearest neighbors are considered, not their absolute distance. As asimple example of how this method performs, we calculate the flow ofthe entire state space by applying this formula to equally spaced pointsin the space. The two dimensional state space was constructed froma sinusoid sin(27r40n)10 + 13 using the method of delays, with r = 6.Figure 3-7 shows the original time series s[n] and Figure 3-8 the result ofthe interpolation of the reconstructed state space. In this figure we see

20-

15-

10-

5

01'0 10 20 30 40 50 60 70 80 90 100

Figure 3-7: Series s[n]= sin(27r40n)10 + 13 with 25 samples per cycle.

that all the points in state space converge to the original trajectory. Interms of the generation of new trajectories with similar characteristics tothe original, this result is not useful. We want states in our reconstructedspace to behave similarly to their nearest neighbors, not to be followedby the same states as their neighbors. Therefore, we modify our function

36 State Space Reconstruction and Modeling

Page 37: Hierarchical Music Structure Analysis, Modeling and

25

10 - ~-

0 5 10 15 20 25s[n]

Figure 3-8: Flow estimation of state space by averaging the predic-tions of the nearest neighbors. Parameters: N = 3, p = 2, T = 6.

by replacing F(x(i)n) with Sci), = F(x(i)nl) - X(i)n. Thus we calculatethe velocity of point xn as the weighted average of the velocities of theN closest points to it.

N

F(xn) = Xn + Z x(i)n IlXn - X(i)n||) (3.9)i=1

Figure 3-9 shows the estimated flow from this method.

When the observable signal s[n] is by nature discontinuous (Figure 3-10),so will the reconstructed state space trajectory. In this case, using a largeN will smooth out the interpolated space, distorting the characteristicangularity of the original trajectory (Figure 3-11). The interpolationfunction is an averaging filter smoothing the state space dynamics. Itis basically a Moving Average (MA) filter with coefficients changing ateach new estimation point. Obviously, using only one nearest neighborwill preserve the angularity of the trajectory since no filtering takes place(Figure 3-12). A nice middle point between a totally curved (smooth)space and a linear one is the use of a large number of nearest neighborsN together with an equally high p exponent. This results in a generallystraight flow but with rounded corners (Figure 3-13).

The signals used in these examples are distant from actual music, buttheir simplicity makes the understanding and visualization of the con-cepts presented easier. In Chapter 5 we will use real music; for now just

3.3 Modeling 37

Page 38: Hierarchical Music Structure Analysis, Modeling and

10 is 20 25e(n)

Figure 3-9: Flow estimation for the state space by weighted average

of nearest neighbor velocities. Parameters: N = 3, p = 2, r = 6.

o * 1 20 N8 3 0 3 40 48 50

Figure 3-10: Signal s[n] = 5,8,11,14,11,8,5,8,11,14, 11,8,5...

keep in mind that the observation signal s1n] can be any musical compo-

nent such as pitch, loudness, 101, etc., or, as discussed in the previouschapter, even multidimensional signals composed of all these parameterssimultaneously.

We have focused on a particular implementation of local linear modelsas a way of generalizing the reconstructed state space dynamics. Wehave also discussed the effect different parameter values have on the

state space interpolation. The implications these have on reconstructedspaces from actual music will be discussed in Chapter 5.

38 State Space Reconstruction and Modeling

\%\

Page 39: Hierarchical Music Structure Analysis, Modeling and

4 1 1

/ 9 9

- -

2 - -. - -

0 2 4 6 8 10 12 14 16sini

Figure 3-11: Flow estimation of state space by nearest neighbor

velocities. Parameters : N = 8, p = 2, r = 1.

3.3 Modeling 39

Page 40: Hierarchical Music Structure Analysis, Modeling and

''N

X

X

XX

XX

XXX

/* /

7 / N

X

/

/

4 4

* /5

o

'Ne

o[1

+ulsr

bea)U)

a)a)

co

-o

I..)

b0

00s

bOC

. 0

q

k~

k/7

4 4

Nll

N- N

i,

IN\

A'

/

* '

./

/

'\'~

V\

P

C-O00CC0 (/)C0U0.

[I+uls

Page 41: Hierarchical Music Structure Analysis, Modeling and

Q.n

(D(

w.

(D C,,

04

%N

N

f

II 1

/

0 4

/*

1

~ k1

II /y

N

Page 42: Hierarchical Music Structure Analysis, Modeling and

42 State Space Reconstruction and Modeling

Page 43: Hierarchical Music Structure Analysis, Modeling and

CHAPTER FOUR

Hierarchical Signal Decomposition

4.1 Divide and Conquer

Signal analysis can be characterized as the science (and art) of decom-position: how to represent complex signals as a combination of multiplesimple signals. From a musicological perspective, it can be thought ofas reverse engineering composition. The power and usefulness of hav-ing a signal represented as a combination of simpler entities is easy tosee. Once a decomposition is achieved, we can modify each componentindependently and recompose novel pieces that may share similar charac-teristics with the original. Just as with modeling, the best decompositiondepends on its purpose. For the purpose of musical analysis, we wouldlike the decomposition to be informative of the signal at hand and forit to be perceptually meaningful. For the purpose of re-composition, wewould like the decomposition to allow for flexible and novel transforma-tions.

How can we decompose our signal in a meaningful way? Different char-acteristics of a signal may suggest different decomposition procedures.Frequently, a signal can be separated into a deterministic and a stochas-tic component. More specific components might be a trend, which is thelong term evolution of the signal, or a seasonal: the periodic long termoscillation[6]. Thus, multiple hierarchical overlapping structures may oc-cur simultaneously. Particularly within the seven orders of magnitudespanned by music (see Chapter 2), these structures can vary tremen-dously from one time scale to the next.

Because of the relevance of hierarchic structure to music and music per-ception, this chapter will focus on decomposition methods that reveal

Page 44: Hierarchical Music Structure Analysis, Modeling and

structure at different time scales. Before discussing these methods, wegive a brief summary of some preliminary developments.

4.1.1 Fourier Transform

By far the most popular representation of a signal as a combination ofsimple components is the Fourier transform. This transform consists ofrepresenting a signal as a combination of sinusoids of different frequency,amplitude and phase. While it is a powerful linear transformation, it'snot without its limitations. Because the basis functions of this transfor-mation are the complex exponentials (eiwt) defined for -oc < t < o, thetransform results in a representation of the relative correlation of eachof the sinusoids over the whole signal, with no information about howthey might be distributed over time. This is fine for stationary signals,but music is almost never stationary. Thus, the Fourier transform is notan optimal representation of music.

4.1.2 Short Time Fourier Transform (STFT)

In 1946 Gabor proposed an alternative representation by defining ele-mentary time-frequency atoms. In essence, his idea was to localize thesinusoidal functions in order to preserve temporal information while stillobtaining the frequency representation offered by the Fourier transform.This localization in time is accomplished by applying a windowing func-tion to the complex exponential

9u, (t) = g(t - u)e. (4.1)

Gabor's windowed Fouried transform then becomes

Sf(u, ) = f(t)g(t - u)e~*dt. (4.2)

The energy spread of the atom gug can be represented by the Heisenbergrectangle in the time-frequency plane (Figure 4-1). gug has time width ut

and frequency witdh o-, which are the corresponding standard deviations[27]. While one would like the area of the atoms to be arbitrarily smallin order to attain the highest possible time-frequency resolution, theuncertainty principle puts a limit to the minimum area of the atoms at

-1

44 Hierarchical Signal Decomposition

Page 45: Hierarchical Music Structure Analysis, Modeling and

gu,~t)

tU

Figure 4-1: A Heisenberg rectangle representing the spread of a Gaboratom in the time-frequency plane.

4.1.3 Wavelet Transform

While the STFT offers a solution to the problem of decomposing non-stationary signals, it still isn't the most optimal representation of ourdata for the following reasons:

1. Many musical high level signals are discontinuous by nature. Thechoice of a continuous basis is not necessarily the optimal choice.

2. At high levels of musical structure, the concept of frequency haslittle or no meaning.

3. The STFT does not give us information about the structure of a

signal at different time scales.

The development of a method for multi-resolution analysis is necessarywhen dealing with perceptually relevant data. Our hearing apparatus hasevolved to extract multi-scale time structures from sound. Inspired bythe function of the cochlea, Vercoe implemented multi-resolution soundanalysis in Csound [42] by exponentially spacing Fourier matchings. Inthe early 1900s, Schenker proposed what is arguably his main contri-bution to music analysis: the abstraction of musical structures fromdifferent Schichten, or layers at multiple scales [31]. Yet, Schenker'sanalysis defines the multi-scale structures in terms of tonal harmonic

4.1 Divide and Conquer 45

Page 46: Hierarchical Music Structure Analysis, Modeling and

functions and certain specific voice leadings. Here we would like to ex-tract the multi-scale representation more generally in terms of motionand, in addition, automatically. Thus, we import the general purposetools traditionally used in the micro-world of sound to the macro-worldof form.

As a natural extension of the STFT, the wavelet transform was developedas a way to obtain a more useful multi-resolution representation. Like theSTFT, the wavelet transform correlates a time-localized wavelet function0(t) with a signal f(t) at different points in time, but in addition thecorrelation is measured for different scales of 0 to achieve a multi-scalerepresentation. Thus, the wavelet transform of f(t) at a scale s andposition u is given by

Wf(u, s) j f(t)4* dt. (4.3)

Wavelets are equivalent to hierarchical low-pass and high-pass filterbankscalled quadrature mirror filters [18]. A signal is passed through bothfilters. Then the output of the low-pass filter is again passed thoughanother pair of low-pass and high-pass filters and so on recursively (Fig-ure 4-2). The outputs of the high-pass filters are called the details of thesignal and the outputs of the low-pass filters are called the approxima-tions.1 The number of filter pairs used in this recursive process definesthe number of scales in which the signal is represented.

While the "Gabor atoms" of a STFT are windowed complex exponen-tials, the development of the wavelet transform has introduced a widevariety of alternative basis functions. The first mention of wavelets isfound in a thesis by Haar (1909) [20]. The Haar wavelet is a simplepiecewise function

1 if 0 < t <1/2(t)= -1 if 1/2 < t <1

0 otherwise

that when scaled and translated generates an orthonormal basis:

Oj,n M -t) ( 2in)

V/2-i 2i (j,n)EZ2

For a detailed discussion about the relationship between quadrature mirror filtersand wavelets, see [27].

46 Hierarchical Signal Decomposition

Page 47: Hierarchical Music Structure Analysis, Modeling and

detail 1

detail 2

detail 3

low-pass high-pass detail 4

low-pass approximation 4

Figure 4-2: Recursive filtering of signal s[n] through pairs of high-passand low-pass quadrature mirror filters.

Because of the discontinuous character of the Haar wavelet, smooth func-tions are not well approximated. Its limitation started the investigationof alternative wavelets, and many varieties with different properties havebeen invented since. Probably the most popular are the Daubechies fam-ily of wavelets. The Daubechies 1 wavelet basis is the same as Haar's,and the family becomes progressively smoother as its number increases.

How then do we choose a wavelet type? What is the best set of waveletbasis? Evidently, the definition of "best" depends on our goal. If ourgoal were compact representation, then we would want a basis that usedthe least number of wavelets without losing much information. The use-fulness of this is obvious for compression and noise reduction, but thechoice of a wavelet basis that provides the most economical representa-tion may also help us understand the nature and intrinsic properties ofa given signal. A common measure of how well a limited set of waveletsdescribes a given signal is by a linear approximation. Given a waveletbasis B = {#0}, a linear approximation sM of a signal s is given by theM larger scale wavelets [27]:

M-1

sM (s, n (4.4)n=o

4.1 Divide and Conquer 47

Page 48: Hierarchical Music Structure Analysis, Modeling and

The accuracy of the approximation is typically measured as the squarednorm of the difference between the original signal and the approximation:

+00

E[M] =s - SM112 = S (8,On)12 (4.5)n=M

Figures 4-3 and 4-4 show wavelet decompositions of Bach's Prelude fromCello Suite no. 1. Both show the largest approximation and the detailsat all four levels. For Figure 4-3 we used Daubechies 1 wavelet, andDaubechies 8 for Figure 4-4. Measuring the approximation for sM = a4in both cases with equation 4.5, we get e = 117.2 with Daubechies 8and E = 122.69 with Daubechies 1. Thus, Bach's prelude is better

Decomposition at level 4 a4 + d4 + d3 + d2 + dl

s 50

a4

4

d 3d 2

-5

d 3 20 'R17TT'![ *

2 0

100 200 300 400 500 600

Figure 4-3: Pitch sequence of Bach's Prelude from Cello Suite no. 1and its wavelet decomposition using Daubechies 1 wavelets. s is theoriginal pitch sequence, a4 the approximation at level 4 and dn arethe details at level n. The sequence is sampled every sixteenth note.

approximated with the Daubechies 8 wavelet. Notice though that thedecompositions of the signal using Daubechies 8 are always smooth, while

those with Daubechies 1 are not. If the discontinuous character of theprelude is important to preserve, then Daubechies 1 is a better choice ofwavelet. Because our goal is to generate new pieces and not to compressthem, this qualitative criterion is certainly more useful to us. In the nextchapter we will exploit the continuous quality of Daubechies 8 to obtainmusical variations with similarly smooth characteristics.

Hierarchical Signal Decomposition

Page 49: Hierarchical Music Structure Analysis, Modeling and

Decompostion atIlevel4: a n4 +d4 +d3 +d2 +dl

60

S 50

so

40

d 2

-5

d 3 0

100 200 300 400 500 600

Figure 4-4: Pitch sequence of Bach's Prelude from Cello Suite no. 1and its wavelet decomposition using Daubechies 8 wavelets. s is the

original pitch sequence, a4 the approximation at level 4 and da arethe details at level n. The sequence is sampled every sixteenth note.

4.1.4 Data Specific Basis Functions

As we saw in Chapter 3, state space reconstruction by the method ofdelays allows us to uniquely represent each step in a given sequence asa function of multiple variables: sa = h(xn) = h(x1, x2, . .. , x1n). h(xn)must then be defined as a combination of the components of xa, for ex-ample sa = a1(xn) + a2(xnl) ± . . . + an(x-) or a1(xfl)a2(xnl) . . . an(xn) ormay have one of many other forms. Can the structure of the manifoldthat results from the embedding tell us something about the structure ofh(xn) and its variables, and as a consequence on the observation signalso? It turns out that similarly to the wavelet transform, a lag space rep-resentation automatically recovers structure at different time scales. Thisis one of the most important observations regarding state space recon-struction by the method of delays. As an example, consider the followingsignal: sin(2ir10t) + sin(27r47t)/4 (Figure 4-5). This signal can be seenas a fast oscillation "riding" on a slow oscillation. In a three-dimensionallag space (Figure 4-6), this simple linear combination of two sinusoidsbecomes a torus, and the two levels of motion (a global cycle and a localcycle) are clearly distinguishable. In Chapter 3 we assumed all alongthat the systems we were dealing with were autonomous, yet a statespace trajectory such as this one can be interpreted as an autonomousdynamical system being driven by another system. How do we separatethese two systems? Because the state space is reconstructed by assigning

4.1 Divide and Conquer

Page 50: Hierarchical Music Structure Analysis, Modeling and

Figure 4-5: Top: sin(27r10t) and sin(27r47t)/4.sin(27r47t)/4.

0.5,

0C\j

Bottom: sin(27rl0t) +

Figure 4-6: Three dimensional state space reconstruction of sin(27rl0t)+sin(27r47t)/4, with r = 220.

Hierarchical Signal Decomposition

Page 51: Hierarchical Music Structure Analysis, Modeling and

delayed versions of a single signal to each coordinate, they all have thesame information delayed by some r time. In other words, projecting theembedding onto any of the three dimensions will yield the same signal.A careful observation of the torus in three-dimensions reveals that by ro-tating the structure in such a way that the maximal variances are alignedwith the axes of the space, the previously redundant dimensions becomedecorrelated, separating the two sinusoids almost completely (Figure 4-7). Figure 4-9 plots the two signals resulting from the projection on twoof the three orthogonal axes after rotating the torus. The method of

1,

-1 -0.5 0 0.5 1 1.5s(t-tau)

Figure 4-7: PCA on the torus resulting from the state space recon-struction of sin(27r10t) + sin(27r47t)/4, with r = 220.

Figure 4-8: Two component dimensions of the state space reconstruc-tion of sin(27r10t) + sin(27r47t)/4 (with T = 220) after PCA transforma-tion.

4.1 Divide and Conquer 51

Page 52: Hierarchical Music Structure Analysis, Modeling and

delays therefore provides a means for decomposing our signal into a "nat-ural" set of hierarchical basis functions. In other words, the functionsare derived from the data rather than selected a priori. The transforma-tion that rotates the state space trajectory so that dimensions becomedecorrelated is called Principal Component Analysis. In Chapter 3 wesaw that the interpolation of the state space manifold "sketched" by thereconstructed trajectory is a way of generalizing the dynamics of a signal.These recovered basis functions are the other half of the generalizationof the structure. These building blocks are independent entities thatcan be modified and recombined to generate new state space geometrieswhile preserving its identity (its "torusness"). For example, multiply-ing the amplitude of the first sinusoid by 5 results in the state spacetrajectory shown in Figure 4-9. This is a simple example by which we

-55

0

s(t-tau) 5 -5

Figure 4-9: Three dimensional state space reconstruction of

sin(27rl0t)5 + sin(27r47t)/4, with T = 220.

illustrate concepts and tools for music structure generalization. In thenext chapter we will use them to generate new pieces of music.

For completeness, we compare PCA with the wavelet transform usingagain Bach's Prelude. We arbitrarily choose eight dimensions for theembedding of the Prelude, and r = 1. Figure 4-10 shows the bases re-sulting from applying PCA to the lag space and projecting the trajectoryon each of the dimensions.

52 Hierarchical Signal Decomposition

Page 53: Hierarchical Music Structure Analysis, Modeling and

7011

00 100 200 300 400 500 600 700

0

0

0 I

0 100 200 300 400 500 600 70050

0-0

0 100 200 300 400 500 600 700

0

-2

20 100 200 300 400 500 600 7000 -

-20

200 100 200 300 400 500 600 700

-200 100 200 300 400 500 600 700

501

-200 100 200 300 400 500 600 700

Figure 4-10: Pitch sequence of Bach's Prelude from Cello Suite no.1and each of the eight principal component extracted from an eightdimensional lag space. s is the original pitch sequence, P~n the nth

principal component. The sequence is sampled every sixteenth note.

4.1 Divide and Conquer 53

Page 54: Hierarchical Music Structure Analysis, Modeling and

4.1.5 Principal Component Analysis (PCA)

The main purpose of Principal Component Analysis is that of decorre-lating a set of correlated variables. As already suggested, the variableswe are interested in decorrelating are the dimensions of a lag space. Wewant each of the dimensions to become as independent as possible sothat each provides unique information about the state space trajectory.

We have seen that a careful rotation of the lag space can separate thedifferent scale dynamics of a signal s[n]. But how do we do this mathe-matically? Essentially what we want is that the m dimensions that makeup the lag space trajectory be as independent and as informative as pos-sible. PCA is the process of obtaining linear independence between them vectors zi,z 2, ... , Zm, i.e. if a1zi + a 2z 2 + . . + amzm = 0 then ai = 0for all i. Statistically, m variables are linearly independent if their co-variances equal zero. Given that the m length observation vectors x arevertical, their covariance matrix is defined as:

C, = E[(x - E[x])(x - E[x])T]

We want a transformation y = Mx such that Cy becomes the identitymatrix.

In relation to x, the covariance matrix of y is

Cy = E[(y - E[y])(y - E[y])T]= E[(M(x - E[x]))(M(x - E[x]))T]

= E[(M(x - E[x]))((x - E[x]) T M T )

= ME[(x - E[x])(x - E[x])T]MT

= MCxMT

Choosing M to be the eigenvectors of Cx is the transformation thatmakes Cy the identity matrix, rendering the dimensions of the lag spacelinearly independent.

Yet, it is important to be aware of the assumptions and limitations ofthis trasformation[36].

1. Linearity. The state space manifold resulting from a time lag em-bedding may (and many times is) curved and twisted. In order toavoid redundancy, a nonlinear transformation would be requiredprior to applying PCA . In the sum of sinusoids example, the com-

Hierarchical Signal Decomposition

Page 55: Hierarchical Music Structure Analysis, Modeling and

ponents were by definition linearly independent, which allowed usto separate them well. Unfortunately, this is rarely the case.

2. The principal components are orthogonal. Related to the problemof linearity, it is possible too that the points in lag space resultin distributions whose axis are not perpendicular to each other.Thus, while PCA may decorrelate some axes, it may not decorrelateothers.

3. Large variances reflect important dynamics. For the purpose of di-mensionality reduction, PCA assumes that the important informa-tion is in the parameters (or dimensions) with the greatest variance,while those with the least variance are discarded as insignificant ornoise. In the Bach example, the large scale dynamics are the oneswith the greatest variance, but this is not necessarily always thecase (although it usually is).

While PCA has its own limitations, it is still a useful transformation thatcan allow us to extract and modify dynamics at different time scales.Other more robust transformations attempt to achieve statistical inde-pendence between all the variables (p(xi, xz) = p(xi)p(xj)), rather thanjust linear independence. The approaches that fall into this category arecalled ICA: Independent Component Analysis. We will not deal withthis family of transformations here.

4.2 Summary

The possibility of representing a signal as a combination of simpler basisfunctions is a second level of generalization. This decomposition allowsus to transform the state space trajectory with much more flexibilityand, by implication, the original observable sequence as well.

Applying PCA on the lag space results in a set of useful basis functionsthat reveal hierarchical structures in a similar way the wavelet transformdoes. The simplicity of PCA over that of wavelets is another attractivefeature. On the other hand, having an analytical description of thewavelet basis can give us more control over the type of decompositionsand transformations we may perform. In the following chapter we willapply both transformations to concrete musical examples.

4.2 Summary 55

Page 56: Hierarchical Music Structure Analysis, Modeling and

56 Hierarchical Signal Decomposition

Page 57: Hierarchical Music Structure Analysis, Modeling and

CHAPTER FIVE

Musical Applications

We have presented some theoretical background, tools and methods use-ful for the analysis, modeling and resynthesis of music, and are ready togive them some concrete applications. We have also mentioned how eachof the methods provides some aspect of the generalization necessary foran inductive model. We now summarize the three types of generalizationdiscussed:

1. State space interpolation (Chapter 3): The recovered statespace trajectory by the method of delays serves as a kind of "wire-frame" that suggests the existence a full hyper-surface or manifoldthat can be estimated by interpolation. New trajectories that fallon the manifold and follow its flow constitute the generalization.By following the flow, new pieces with similar dynamics and statescan be generated.

2. Abstraction: states vs. dynamics (Chapter 3): The recov-ered state space trajectory provides information about the statesvisited by the trajectory and the dynamic relationships betweenthese states. Each of these two pieces of information can be sepa-rated and varied independently for the generation of new music.

3. Decomposition (wavelets, PCA, ICA) (Chapter 4): Eitherthrough wavelets or through PCA or ICA, it is possible to decom-pose a musical sequence into hierarchical, simpler, and meaningfulcomponents. These decompositions reveal embedded dynamics andprovides an additional level of understanding of musical structureand flexibility for subsequent transformations.

All three aspects can be used as tools in music analysis and synthesis, andmay be combined in many different ways. Here, we can only give a few ex-

Page 58: Hierarchical Music Structure Analysis, Modeling and

amples of their use and suggest some other possibilities. Sound files fromthe examples discussed in this chapter as well as additional relevant ma-terial can be found at http: / /www.media.mit.edu/~vadan/msthesis.

5.1 Music Structure Modeling and Resynthesis

Combined Components vs. Independent Components in MultidimensionalSignals

When considering the multiple components of a piece of music, we canopt to model their dynamics independently or collectively. Keepingthings separate gives us more control over the variety of transforma-tions we can apply to music, but modeling all components collectivelyallows us to generate new trajectories that preserve their aggregate dy-namics in the original training piece. The state space reconstruction ofthese two approaches is depicted in Figure 5-1.

1 AA /\SSRIn]:~ ~ ~ i[n]: Aa zzs n 5V n

sinn: i:n]

SSR

sin SSR n

Figure 5-1: Top: The aggregate dynamics of all the musical compo-nents such as pitch, loudness and 10I are modeled jointly by con-structing a single state space. Bottom: Multiple state spaces arereconstructed and modeled from each component independently.

Musical Applications

Page 59: Hierarchical Music Structure Analysis, Modeling and

For the purpose of state space reconstruction, a multidimensional signal

Si,0, si,1, ... , s1,ns2,0, s2,1, - - -, s2,nl

[n] = . (5.1)

_ sl,0, s1,11 - 81 , s,n _

can be treated in essentially the same way as a scalar signal. Eachpoint in state space is defined as a set of delays of each of the signal'scomponents:

x[n] = (s1[n],s1[n-Tr],...,s1[n-(m-1)r],s2[n],s2[nr-r],...,

s2[n - (M - 1)r], ... , si[n], si[n - r), ... , sl[n - (m - 1)-..2)

The reconstructed state space has dimension 1m. As can be seen inthe previous equation, the resulting state space is an aggregate of theindividual state spaces of each component in the signal s[n]. Thus, adifferent T can be chosen for each component si[n]. Since the valueranges of the components si[n] will usually differ widely, it is importantto whiten the reconstructed state space to avoid having dimensions thatare too flat relative to others. Having different variances for the differentdimensions will distort the map or flow estimation since our weightingand averaging functions rely on euclidian distances. After estimating anew trajectory, we must de-whiten the data.

5.1.1 Interpolation

As we reviewed in Chapter 3, the type of interpolation we perform on thereconstructed state space can greatly affect the qualitative characteristicsof the estimated flow. Thus, a careful choice of the state space modelparameters can be crucial to obtain good musical output. For the case ofthe local linear models discussed in Chapter 3, there are two parametersto consider: the number of nearest neighbors and the p exponent inEquation 3.8 (i.e. the weight of each neighbor as a function of theirdistance). In addition to whatever modeling technique we use, thereis the choice of embedding dimension and the initial state x0 for theestimation of a new trajectory.

As a concrete example of how the different parameters affect the inter-polation and thus the outcome of new musical pieces we use Ligeti'sPiano Etude no.4 Book 1 (Figure B-1). We combine pitch, loudness,I01 and duration in a single lag space and estimate a new trajectory

5.1 Music Structure Modeling and Resynthesis 59

Page 60: Hierarchical Music Structure Analysis, Modeling and

for multiple combinations of the parameters already discussed. For eachnew trajectory estimated we systematically vary one parameter value ata time. The embedding dimensions explored are 2, 4, 6, 8 per parame-ter. So, given that we are embedding four parameters together, the lagspaces actually have 8, 16, 24, and 32 dimensions. The number of near-est neighbors used are 2, 4, 6, and 8, and values of the exponent p are 2,16, 64, and 128, As the initial condition we always use the mean of thespace. Figure B.3 in Appendix B shows the new generated sequences inpianoroll representation. All sequences are 500 notes long.

Number of Neighbors and the p Exponent From the pianorollplots of the generated pieces we see that for very high values of p, par-ticularly p = 128, the resulting sequences are almost identical to somefragment of the original Etude. This is because for such high valuesof p the nearest neighbor to the point being estimated will have muchgreater weight in defining its behavior than the more distant points.Thus, no matter how many neighbor points are considered in the esti-mation, having p = 128 is practically the same as considering only onenearest neighbor. The resulting trajectories are then transposed copiesof the original trajectory. The other problem with using only one neigh-bor or too high a value for p is that, particularly for embeddings withinsufficient dimensions, it is very likely that the estimated trajectory willfall in an infinite loop. In Figure B.3 we see several instances of this.The second half of panels two and three (from left to right, top to bot-tom), as well as panel eight are examples of this. Ideally we want touse several neighbors for the interpolation to be more accurate. But,as discussed in Chapter 3, the use of more than one nearest neighborresults in smoothed out maps, distorting the originally angular qualityof discontinuous dynamics. Thus, a careful balance between the numberof nearest neighbors and the values of the exponent p must be found inorder to produce novel yet sharp interpolations. Naturally, if the originalseries where continuous, then the choice of number of neighbors wouldnot be a problem.

Dimensionality of the Embedding In Chapter 3, we discussed therequirement of finding a high enough dimension for the embedding to beable to capture all the degrees of freedom of a continuous autonomoussystem, and for a bijective relation to exist between the observation se-quence s and the state space trajectory x. What are the implications ofthe embedding by the method of delays on discontinuous series? Mainly

Musical Applications

Page 61: Hierarchical Music Structure Analysis, Modeling and

that trajectories may cross without violating the bijective relation be-tween the state space trajectory and the observation sequence becausetrajectory crossing of discontinuous series does not imply an overlap ofpoints. Thus, the embedding dimension for discontinuous sequences canbe smaller and still be good for the generation of new sequences. Fromthe plots in Figure B.3 we can see that, in general, large scale dynamicsfrom low dimensional embeddings (2 or 4) are rather chaotic comparedto those of high dimensional ones.1 To understand why this is the case,consider the nature of the reconstruction by the method of delays. Eachstate in lag space is defined as a set of ordered values taken from theobservation sequence. If the embedding dimension m = 2, we defineeach state as a set of two values in the observation. Setting T = 1, forexample, defines each state as two successive values of the observationsequence. Choosing a four dimensional embedding would give us a mapof all the four value combinations found in the sequence. Evidently,one state might be visited more than once if the dimensionality is nothigh enough. It should be clear that the higher the dimensionality of thespace, the sparser it will be. If the dimension is too high, very few pointswill occupy the space, and different trajectory segments will be at a bigdistance from each other, making their interaction for the generation ofnew trajectories more difficult. If the dimensionality is small, the spacewill be very dense and points may fall on top of each other. Here, newtrajectories will be estimated from several trajectory segments that areclose to each other in the embedding, but not necessarily close tempo-rally in the original sequence. Thus, these points may have very differentvelocities.

Initial State This is the most difficult parameter to estimate in termsof the predictability of the output. Evidently, choosing any of the pointsthat fall in the embedded trajectory as initial state will result in theoriginal music sequence from that point on. The actual estimation ofnew states begins when the end of the trajectory is reached. In timeseries prediction this is the natural point to begin the estimation of anew trajectory. But for the purpose of generating novel trajectorieswithout forecasting motivations, any point in the state space that doesnot fall on the original trajectory will do. A reasonable thing to do mightbe to select the initial state at random, but for the purpose of evaluating

'This is similar to what happens with Markov models, where small order modelsresult in sequences that are locally similar to the original but globally unrelated, whilehigher order models yield sequences that preserve the structures of the original pieceat higher scales.

5.1 Music Structure Modeling and Resynthesis 61

Page 62: Hierarchical Music Structure Analysis, Modeling and

parameter values and dimension sizes, it is best to choose a constantinitial state.

There is only so much we can do by modeling all the components to-gether. The lack of control on the independent parameters and the lim-ited number of variables in the local linear models used make it difficultto produce novel pieces that are clearly different from the training piece.Because the training piece in its entirety is modified by only a few pa-rameters, the new generated pieces are coarse variations on the original.In order to produce more refined transformations, we must make use ofthe decomposition methods discussed in the previous chapter.

5.1.2 Abstracting Dynamics from States

Rotations

A geometric interpretation of the reconstructed state space suggests avariety of transformations of the musical data. Simple transformationslike rotations have been used as generators of musical variation [43, 16,1]. In fact, the classical transformations of inversion, retrograde andretrograde inversion found in western music since the 16th century canbe understood as four simple space-time transformations: 180' rotationsin two-dimensional lag space and temporal reversing.

In Chapter 4 we reviewed how PCA on a reconstructed state space isnothing more than a special purpose rotation for decorrelating the com-ponent dimensions. But more generally, rotations can be interpreted asa way of changing the states visited by a dynamical system while keepingthe dynamics unchanged. Thus, a state space trajectory defines a set ofpossible state sequences that share the same dynamics.

If the purpose of the embedding is the application of geometric trans-formations exclusively, then the requirements for a proper embeddingfor state space reconstruction (see Chapter 3) can be ignored, and alldimensions m > 2 are useful. In this interpretation the dimension of theembedding defines the possible degrees of transformation. The numberof degrees of freedom of a rotation is defined by the dimensionality of thespace. For an m-dimensional space, there are C(m) planes of rotation[2]. Thus, higher dimensional spaces have the potential for a greatervariety of transformations.

62 Musical Applications

Page 63: Hierarchical Music Structure Analysis, Modeling and

A rotation is a linear combination of the m elements defining each pointin lag space. For example, given a series s[n], we embed it by the methodof delays with a delay of T and dimension m = 3. We get the embeddedtrajectory x[n], so that each point in the m-dimensional space is xn =(sn, s-7-, sn-2). If we apply a rotation of angle 6 to the sn-2r axis ofthe embedding space, we get:

cos 0 sinG 0 ]xc = [ Sn sn-,r sn-2r ] -sin 0 cos 0 0 (5.3)

0 0 1

= (cos Osn - sin s--r, sin 9sn + cos Osn-r, Sn-2r)

These rotations can be applied to the lag space of any musical com-ponent independently or to that of the combined components. In thiscase the components will be combined, so that pitch, for example, willbe a combination of pitch, rhythm, etc. As an example of rotating the

Courante.

Id I I I I I do.. aI..

-3 J33

Figure 5-2: First six measures of Bach's Courante from Cello Suite

no.4.

lag space of a single component we take the first six measures of Bach'sCourante from Cello suite no.4. We consider only one component: theInter Onset Interval (which in this case is the same as the duration ofeach note) .2 We embed the sequence in three-dimensional lag space(Figure 5-3). We explore all 64 combinations of 90' rotations in thisthree-dimensional space and plot the projections of each rotation. Ascan be seen in Figure 5-4, many resulting patterns are identical. Onlysix patterns are actually different (Figure 5-5). Thus, with 900 rota-tions we obtain only five new sequences out of a total of 64 rotations. Weare curious to know what other patterns might be obtained from otherrotations, so we compare the projections of all 512 450 rotations. Out

2While the trill "embellishment" in measure 4 is not written out explicitly, it is an

important element of the rhythmic sequence. Thus, in the electronic score we write it

out as 32nd notes.

5.1 Music Structure Modeling and Resynthesis 63

Page 64: Hierarchical Music Structure Analysis, Modeling and

1 ,0.9

0.8

0.7

0.6

1

.0.5-

0.4.

0.3n

0.2 3

0.8b

0.6

0.4A 0.8

.. . . . 0.60.2 0.4

s[n+Taul 0.2

Figure 5-3: Three-dimensional embedding of 101sures of Bach's Courante from Cello Suite no.4.

00 00 0 0 0

0 ~ ~ ~ 00 00 00 0 0:0 0: 0 0 0:0 :017 I 18I

of the first six mea-

10Time in quarter note units

Figure 5-4: Projections of all 64 900 rotations of the three-dimensionalembedding of the 101 from Bach's Courante.

64 Musical Applications

Page 65: Hierarchical Music Structure Analysis, Modeling and

04 0 44 . 4-444444 44 444 .260 . 121:4 . 4 4 1644 4 18 .

of the4embedding. Patr number~ 4 is Bachs orgina4 rhyhmi

.. . . . . ...~44444.44.4...44444444444: 44444-4-444..........

1 44404444:446444. .4.:.4.:.4.4.4.4-.-.4.4.4.4.4. 4

E 00 00 2 - 4 ... 800 0 10 12 14 16 1

sequence.

of 512, 26 (including the original) are distinct. Figure 5-6 is a plot ofall 26 non-repeating patterns. Figure 5-7 shows patterns no.1 and no.25in musical notation. They are approximations quantized to the 64th

note, particularly in cases where no clear rational proportion was found.From our interpretation the rhythmic pattern in Bach's Courante is

4~~~~~~~~ .~ .. 4 4 .4~44. . .. ... . .4-4- .4444. 444.

0 2 4 6 8 10 12 14 16 18

Time in quarter note units

Figure 5-6: Nh i on-repeating patterns resulting from ll51'4 rota-n

tosof thethe-iesoaIO embedding. Pattern number 14 is Bc' rgnlryhi

Bah'e oignaehyhmcceqene

oof a fam(ilydn opathersgthat) sare aiticmmo stuct.Hre we lto

rathe thannrpatiiscreterphb. Wue have generaten new duatins not

petin theurigal s.Tequaee aspwellmasionw squnies thathe at

simil arstrcurey to theee orial Beas rthesenew sequetince ware om-d

bin u trpeationso the vleofaorginalc sequenen tis geative aprachi

5.1 Music Srcu Modeling -- 0and--4 Resnthsi 65000......

.4.4:.944 40.-..*. 4444:4.010 444... 0- 444444.44.4-0--0-** 4-4-444 :4-4-0

000004.0 4. 0' 04 4 ~ 4 4 44... 444.440,0-0.44444 4444

.4.4*.O .4 .4 4.4. .4. .4 Ow..44. 4. .4 04 -4 4- 44 44 4.44.4.

1 .0OOO 0 44444440.o :-0-- ow 40 04 0..:44444 0~~~~4 4 4.444:40. 444:44444. 4 . . . 4 4 4 4 J 4 4 4 4 . 4 4 4 4 4 4 . . 4 4 . 4 440 .

.4.40 - :04- 4 0 :4:444 - 04.. 4. 44-4.44444 .444444444..0.4 -4 - 444444 .4. 4.4 44.40 444 4.00* .044. 4-- - .4O '..4.0 . 44..

.0!0 4. ;... .4. 0 . 4.-0 .10 40 440*0 *. . 0.4 4 4 4 .. .... 4 -0. ...4

0 2 4 6 8 10 12 14 18 18Time in quarter note units

Figure 5-6: Non-repeating patterns resulting from all 512 450 rota-tions of the three-dimensional 101 embedding. Pattern number 14 isBach's original rhythmic sequence.

one of a family of patterns that share a common structure. Here wesee one of the advantages of considering musical space as a continuumrather than a discrete alphabet. We have generated new durations notpresent in the original sequence, as well as new sequences that have asimilar structure to the original. Because these new sequences are com-binations of the values of an original sequence, this generative approach

5.1 Music Structure Modeling and Resynthesis 65

Page 66: Hierarchical Music Structure Analysis, Modeling and

Pattern no.1

Pattern no.25

___~2221__rnm _Lj ____

Figure 5-7: Musical notation of patterns no.1 and no.25 from the 26non-repeating patterns resulting from 45' rotations of the embeddedIOIs.

can be called combinatorial as opposed to systems based on discreteMarkov models such as the one we discussed in Chapter 1, which aretypically permutational. For an additional example in pitch space seehttp: //www.media.mit.edu/~vadan/msthesis.

5.1.3 Decompositions

The top portion of Figure 5-8 shows a fragment of Ligeti's Etude no.4book 1 in pianoroll representation. 3 The Etude is composed of two lay-ers. One consists of an ostinato characterized by an ascending patternwith a regular rhythm. The other is a homorhythmic polyphonic texture.Throughout the piece, the ostinato is transposed up and down in jumpsof one or more octaves. We want to transform Ligeti's Etude so that itsglobal pitch dynamics become continuous. For this we wavelet transformthe pitch sequence of Ligeti's Etude using Daubechies 8 wavelet. The de-composition is done at 7 levels. After decomposing the signal we performa 4-dimensional state space reconstruction of the largest scale approx-imation and rotate it by 7r radians on each of the six rotation planes.We then project the rotated trajectory back to a single dimension andinverse wavelet transform it to recover the complete pitch sequence ofthe Etude. Figure 5-9 depicts this process. Because the Daubechies 8wavelet is smooth, the resulting transformation is smooth as well. Thebottom of Figure 5-8 depicts the result of the transformation.

3 This pianoroll plot was generated using the MATLAB MIDI toolbox.[13]

66 Musical Applications

Page 67: Hierarchical Music Structure Analysis, Modeling and

C8

G7# -/:D7# ---A6# -F6 - " I/. .. -

CfC 6 T711 7..

G5 - - * " .

A1#A

Time i beat

D7 -. ..- -

......... -.E4 - -6

E6.. ...... e'.......I - 6b"

A11

-E1 - ".5-

B0F --

50 100 150 200 250 300 350 400 450 500 550

Time in beats

07

CD A6

Figure 5-8: Top: Fragment from Ligeti's Piano Etude no.4, Book 1. Bottom: Etude no.4 after a ir radians rotation

of the state space reconstruction of the 7th level approximation using Daubechies 8 wavelet.

Page 68: Hierarchical Music Structure Analysis, Modeling and

U)C0

C5

CLa.

a2 ---- ------ -- 2DW

T

i

a2 ---- .... 9

Figure 5-9: Diagram of the transformation process used to vary and render continuous the large scale pitch contour

of Ligeti's Etude. First, the pitch sequence is discrete wavelet transformed. Then, the largest scale approximation is

embedded in three-dimensional lag space and rotated to obtain a variation of the original trajectory. Finally, after

replacing the original approximation with the variation, the decomposition is inverse discrete wavelet transformed.

Page 69: Hierarchical Music Structure Analysis, Modeling and

5.2 Outside-Time Structures

In this work we have focused our attention on the dynamic propertiesof music, and have pointed out the advantage of considering the musicalspace as a continuum rather than a discrete alphabet. But in additionto the temporal aspects of music, a lot of the quality of a piece comesfrom its "outside time" structures [43] as well. These consist of the sievesthrough which the different musical components are discretized. For ex-ample, a piece sieved through a major scale feels very different from thesame piece sieved though a Phrygian scale. While the hard distinctionbetween in-time and outside-time may sometimes be inaccurate (modesare a case where the sieve is dynamically defined), the distinction pro-vides a simple way of modeling music structure.

5.2.1 Sieve Estimation and Fitting

Both for practical as well as perceptual reasons, it is many times use-ful to consider scales as cyclic structures. In Chapter 3 we mentionedhow the helical pitch space is a better representation of pitch perceptionthan a straight line. By collapsing the helix into a circle we can reducethe infinite number of steps in the helical staircase to a compact setof equivalent pitches classes. Indeed, in musical pitch theories such asForte's [17] or Estrada's [14], there is the notion of octave equivalence.This notion allows the reduction of the pitch space into a small set ofpitch classes. This is simply a modulo operation on the pitch space, andmod 12 is the modulo typically used for the twelve tone equal temperedscale. Similarly, we may define a time sieve in the rhythmic dimension(IOIs) via a modulo. If there exists a clear beat or higher rhythmicstructure like a meter, then we can reduce all the 101 to a time sievemodulo the meter. Thus, the same helical structure used for pitch spacecan be used to represent similarity (or equivalence) between events inrelation to their placement in time. Figure 5-10 depicts an example ofthis representation for a triple-time meter.

Here we take a simple statistical approach to sieve modeling by comput-ing a histogram of the values found in each of the musical components. 4

Essentially, the histogram of each component is the model of the sieve.To sieve a newly generated trajectory we take two measurements intoconsideration:

4 Contrary to traditional tonal music theory, where a scale in pitch space is definedby the underlying functional harmony, all pitches found in a piece are considered partof the scale.

5.2 Outside-Time Structures 69

Page 70: Hierarchical Music Structure Analysis, Modeling and

I 2 3 4

Figure 5-10: A helical time line representing equivalent points in ameasure in triple-time.

1. The relative frequencies rf(Ek) and rf(Ek+1) of each of the twoscale values Ek and Ek+1 surrounding point s, in the new series.i.e. Ek < sn < Ek+1-

2. The relative distance between the point to be fitted, s, and eachof its surrounding scale values. i.e. IIEk - | and ||Ek+1 - Sn i-

The complete equation used to replace the estimated value by that ofthe sieve is:

Ek

rf (Ek)P rf (Ek+l)p

||Ek - n|| ||Ek+1 - Qn1Ek+1

We use the exponent p to adjust the weights of the relative frequenciesversus the distances. If the distance between the generated point sn andits surrounding sieve points is considered to be more important thantheir relative frequencies, then we use a low value for p and vise versa.

5.3 Musical Chimaeras: Combining Multiple Spaces

An interesting problem in automatic music generation is that of combin-ing two or more pieces to generate a new one. This is not a trivial task,and in the context of the present work the most natural thing to do isto combine the reconstructed state spaces. There are three basic waysof doing this:

70 Musical Applications

Page 71: Hierarchical Music Structure Analysis, Modeling and

Method 1: Generate a new trajectory from the average of the flowsestimated for each of the embeddings:

zn+ = aF(xn) + bF(yn). (5.4)

In this approach we estimate the behavior of a point in each of the sep-arately reconstructed state spaces. The estimated velocities are thenaveraged to obtain the behavior of the new point resulting from thecombination. The nature of this method suggests considering the combi-nation of two pieces as a mixture where we can control the percentagesof each piece in the mix. For example, in a two piece mixture, we couldcombine 90% of piece 1 and 10% of piece 2 simply by weight the esti-mated velocity vectors for each piece: zn+ 1 = 0.9F(xn)+0.1F(y,). As inmethod 1, all the embeddings must have the same number of dimensions.

Method 2: Estimate a new trajectory from the superposition of the em-bedded trajectories:

zn+1 = F(xn, y). (5.5)

All spaces must have the same dimensionality. The dimensionality nec-essary to capture the degrees of freedom of one piece will usually besmaller than that necessary for all the pieces combined. Thus, we es-timate the embedding dimension necessary for all the combined piecesby taking them as a single sequence. Once the embedding is made, weiteratively compute zn+1-

For methods 1 and 2 we can ask the following questions: how should thespaces be overlapped? Should they be overlapped without alteration orshould they be transformed in some way; maybe translated so that theyshare the same centroid or rotated using PCA so that their principalcomponents are aligned? Again, the goal of merging two or more piecesis an important determinant of the approach to be taken. If our goalis to keep each of the training pieces as clearly perceivable as possible,then the geometric transformations just mentioned must be avoided orkept to a minimum.

Method 3: Construct a state space from both pieces directly:

x = (Sln-(m-1)r, s 2 n-(m-1)r, Sln-(m-2)r, s2n-(m-2)r, - -

sln-r, s2n-r, s1n, s2,) (5.6)

In this approach instead of superposing two m-dimensional spaces, wecreate a new l+n-dimensional space by combining an I and a n-dimensional

5.3 Musical Chimaeras: Combining Multiple Spaces 71

Page 72: Hierarchical Music Structure Analysis, Modeling and

spaces. Thus, in this method the number of dimensions for the recon-structed state space of each piece may be different. While in methods1 and 2 each lag space dimension is a combination of both trainingpieces, in method 3 half of the dimensions are defined by one piece andhalf by the other. Thus, each point in the lag space is defined by bothpieces. The difference is important because our new observation will bea projection of the lag space onto one dimension per component. Whatdimension should this be? Should it belong to training piece 1 or piece2? The piece to which the projection dimension belongs to will domi-nate the new output. This can be seen as the carrier piece, while theother is the modulator. As discussed in Chapter 4, this approach can beinterpreted as two systems driving each other.

To show how each of these methods performs, we combine two pieceswith each of the three methods. We are particularly interested now intrying to preserve clearly perceivable characteristics from the two train-ing pieces. Thus, we do not alter the embeddings of any of the piecesin any way prior to their combination. The pieces we use are Ligeti'sPiano Etudes 4 and 6 from Book 1. Again, in order to see how thesethree methods behave under different parameter configurations, we sys-tematically explore several values for the three parameters: embeddingdimension, the number of nearest neighbors, and the the weight of theneighbors relative to their distance (the p exponent). We generate 500points (notes) for each test, again using the mean of the reconstructedtrajectory as the initial point.

Method 1 This method seems to be the one less likely to work. Look-ing at Figure B.4 and listening to the sequences generated with thismethod we see that there is little resemblance between these and theoriginal Etudes. The pieces generated are noisy. In other words, thereis little structure and the music sounds quite random. This is especiallytrue for low dimensional embeddings. As the embedding dimension in-creases, though, the global dynamics become more varied and interesting.Yet, the local dynamics are usually very irregular and the source piecesimperceptible. Imagine embedding many pieces of music, each in theirown state space. What is the velocity of a single point in each of thespaces? We will most likely discover these velocities to be very different.Averaging these estimated velocities will then result in unpredictabledynamics and possibly neutralization due to opposing velocities.

72 Musical Applications

Page 73: Hierarchical Music Structure Analysis, Modeling and

Method 2 The choice of the number of nearest neighbors in the lagspace interpolation is important in defining the mixture of the pieces.If only one neighbor is used, the dynamics of each point will be definedby only one of the pieces being combined. The greater the number ofnearest neighbors, the greater the chances that the behavior of a pointwill be defined by points from the two training pieces. The p exponentequally affects the mixture. As we have seen, too high a value of p willhave practically the same result as using only one nearest neighbor sincethe weights of distant points will be very small compared to those ofnearby points.

Figure 5-11 is a pianoroll plot of a 500 notes sequence generated fromthe mixture. The parameters used to generate this result were p =

200, number of neighbors=11, and embedding dimension=3. What is

A7 -E7 - -B6 - * "

E2 - -

C6#B51-

D5#

A# -

A0 50 10 15 20 25lime in beats

Figure 5-11: Mixture of Ligeti's Etudes 4 and 6 Book 1 using method

2, with parameters p =200, number of neighbors=11, and embeddingdimension=3.

characteristic about this method is the fact that it tends to behave like acollage, deserving the chimaera alias (this can clearly be seen in Figure 5-

11). This is because in the superposition of the two state spaces, thetrajectories from both pieces will not always be close to each other.At some point in the combined space, trajectories will diverge, while atothers they will cross or pass close to each other. Thus, at some momentsthe new estimated trajectory will be dominated by one piece; at placeswhere the trajectories of the training pieces meet there will be a mixture

and/or a shift of dominance in the estimation from one piece to the other,making the resulting sequence a kind of splice and mix, and reordering

5.3 Musical Chimaeras: Combining Multiple Spaces 73

Page 74: Hierarchical Music Structure Analysis, Modeling and

of fragments of the training pieces. Naturally, the degree to which pieceswill be combined depends on their degree of similarity. Similar statesbetween pieces will be close to each other, while states that are notsimilar will be apart. It is important, then, to find a representation thatwill make the spaces overlap as much as possible, but, again, withoutaltering them since we want to be able to hear the original training piecesin the new piece. Therefore, we modify the components of the sequence(pitch, loudness, 101, duration) of the training pieces so that they matchas much as possible without altering perceptual features. For example, ahistogram of the 101 of Etude 4 shows that the most frequent 101 valuesis 0.5 (a quarter note), while that of Etude 6 is 0.25 (an eight note)(Figure 5-12). Because the difference can be interpreted simply as that

Etude 4 Etude 6

1600

1400

1200

1000

800

600

400

200

2000

1500

1000

500

0 0.5 1 1.5 2 2.5 3 3.5 4 0 0.5 1 1.5 2 2.5101 in Quarter Notes 101 in Quarter Notes

Figure 5-12: Histogram of 10I of Ligeti's Etudes 4 and 6.

of tempo, (which generally is not a defining characteristic of the pieceunless the difference between tempi is too great) we scale the 101 of oneof the Etudes to equal that of the other. A similar transformation canbe applied to the pitch component. If the register is not something wemay consider very important, we can use the sequence of pitch intervals(the Inter Pitch Interval) simply by taking the difference of the pitchsequence. We don't do this in the present example though, keeping theoriginal pitch sequences unchanged.

The dimensionality of the superimposed spaces is also an important fac-tor defining the degree to which the new estimated trajectory will be acombination of the two training trajectories. Since each point is definedby a sequence of notes in the training pieces, the higher the dimensional-ity of the state spaces, the less likely it will be that points from differentpieces will be close to each other. Thus, the best results are obtainedwhen the dimensionality of the embedding is low. On the other hand,

74 Musical Applications

Page 75: Hierarchical Music Structure Analysis, Modeling and

as we saw before, choosing too low a dimensionality will make the highscale dynamics of the resulting trajectory more chaotic.

Method 3 The third method is probably the most intriguing. As inmethod 1, the generated sequences resulting from the combination ofboth pieces into a single state space are generally noisy. A mind experi-ment might help visualize what's happening. Recall that the embeddingof a sum of sinusoids by the method of delays results in a toroidal struc-ture (Section 4.1.4). In lag space these two sinusoids can be interpretedas two signals driving each other, in a similar way as planets pull andaffect each other's motion. Including a third dimension with its owndynamics will add an additional degree of freedom and complexity tothe system. By the Central Limit Theorem, the resulting dynamics willtend to gaussian noise as the number of dimension with independentdynamics tends to infinity.

Thus, if the dynamics of the training pieces are complex, the dynamicsresulting from their combination will be even more complex, and theresult will be noise. This method is effective only when the spaces tobe combined are relatively simple. Figure B.7 in Appendix B showsthe result of combining Ligeti's Etudes with this method for multipleparameter values. Clelarly, the resulting trajectories from this mixtureare overly noisy. But rather than embedding all the parameters of bothpieces in a single space, we can embed each of the four components (pitch,loudness, 101 and duration) independently (see bottom of Figure 5-1)and combine the spaces corresponding to the same component (figure 5-13). Figure B.7 shows several 500 note sequences generated with thisconfiguration for the same parameter combination as with methods 1and 2.

The choice on the exponent p greatly affects the output of the interpo-lation using method 3. From the multiple panels in the figures it canbe seen that no matter what the choice of dimension or number of near-est neighbors is, when p = 2 the resulting sequence is noisier than withhigher exponents. In method 3, p is clearly the most important factordetermining the degree to which the points interact, and thus, the degreeto which the pieces mix. It could be labeled the "mixing level knob" ofthe method.

5.3 Musical Chimaeras: Combining Multiple Spaces 75

Page 76: Hierarchical Music Structure Analysis, Modeling and

s [n: SS~: ~Rs [n]:

Fu n-3 E [n]: I- e sSSR

s [n]: [ n]:

What state spaces Are Made Of

In addition to the alternative ways of combining state spaces, there arealso multiple ways of defining the spaces to be combined. We have jointlymodeled the dynamics of all the components of a piece (e.g. pitch, loud-ness, brightness, IOI), and each component independently. We've alsoseen that we can decompose each component and model each of its sub-components independently. In addition, we can reconstruct a state spacefrom combinations of subcomponents derived from corresponding com-ponents of different pieces. For example, the large scale approximationsof pitch from various pieces on one side, and their corresponding detailson another (Figure 5-14). We could also take the high scale dynamicsfrom a component in one piece and the low scale dynamics from another,or even combine different components from different pieces. These moreintricate and experimental approaches may result in unique variations,but the original training pieces will most certainly be lost perceptually.

76 Musical Applications

Page 77: Hierarchical Music Structure Analysis, Modeling and

PCA

i,[ n JV

Figure 5-14: Corresponding components from different pieces are combined at different scales, but each scale is

independent from the others.

Page 78: Hierarchical Music Structure Analysis, Modeling and

78 Musical Applications

Page 79: Hierarchical Music Structure Analysis, Modeling and

CHAPTER SIX

Experiments and Conclusions

6.1 Experiments

In this work we have presented methods to generalize and extrapolatemusical structures from existing pieces for the purpose of generatingnovel music. Thus, what we might evaluate is the novelty of the piecesgenerated with these methods in relation to the source or training pieces.But testing whether a piece generated by the system is different fromthe training piece is trivial. As we showed in the previous chapter wecan generate completely new sequences with enough transformations,however arbitrary these may be. What we are actually looking for is thatambiguous middle ground where the generated pieces share structuralcharacteristics with the training piece(s) while at the same time are asnovel as possible. Clearly, this is as much a test on the system as it ison the system's user, since the art still is, after all, in the creative use ofthe tools.

6.1.1 Merging Two Pieces

In the previous chapter we discussed three ways of combining two piecesof music to generate new ones. In this chapter we present the results ofan experiment performed to evaluate how well each of the three music-merging methods is able to generate novel musical pieces while still pre-serving structural characteristics of the original training pieces.

Experiment Setup

In this experiment subjects were presented with 10 excerpts: 5 pairs,each generated with a different method:

Page 80: Hierarchical Music Structure Analysis, Modeling and

Pair 1 Using method 1 with a single state space reconstruction.

Pair 2 Using method 2 with a single state space reconstruction.

Pair 3 Using method 3 with a single state space reconstruction.

Pair 4 Using method 3 with components modeled independently.

Pair 5 Randomly, using a gaussian distribution for each musical compo-nent. The parameters of the gaussian distributions used are shownin Table 6.1.

Table 6.1: Parameters of the Gaussian distribution used for the randomlygenerated musical sequences.

We used two excerpts per generation method because each method cangenerate a wide variety of musical sequences. Using only one excerpt maygive misleading results that depend more on the particular example thanon the generation method. On the other hand, using more excerpts mighthave made the experiment too long for subjects to remain interested andattentive during the experiment.

The two pieces used as training data were Ligeti's Etudes 4 and 6, BookI. In all cases the generated sequences (including the random ones) werequantized to fit the union of the sieves of the two training pieces (seeSection 5.2). The reason for including randomly generated excerpts wasto test whether listeners confused some of the generated pieces withnoise. As we pointed out in the previous chapter, method 3 and to a lesserdegree method 1 (both with a single state space reconstruction combiningall musical components) generate noisy sequences. All excerpts werebetween 30 and 40 seconds in duration except the training pieces, whichwere presented complete.

The experiment was divided in two parts: in the first part, subjectswere asked to rate the complexity and their preference for each excerpt.They were also asked to cluster the excerpts into groups on the basis of

80 Experiments and Conclusions

p a-101 0 0.25duration 0.25 0.5pitch 60 10loudness 80 10

Page 81: Hierarchical Music Structure Analysis, Modeling and

similarity. Subjects were free to create any number of clusters between1 and 5, and their choice depended on their ability to perceived distinctgroups. Evidently, the perfect ear would have perceived the five groupscorresponding to the five generation methods used. In the second partthey were asked to evaluate the similarity between each of the excerptsand each of the training pieces. The excerpts were labeled [Fl], [F2],[F3], etc. in the forms used and were organized as shown in Table 6.2.The forms used in the experiment can be found in Appendix C.

Table 6.2: Labels used for the excerpts in the experiment form and theircorresponding Pair type (i.e. production method).

F1 excerpt from Pair 1F2 excerpt from Pair 2F3 excerpt from Pair 3F4 excerpt from Pair 5F5 excerpt from Pair 4F6 excerpt from Pair 5F7 excerpt from Pair 1F8 excerpt from Pair 2F9 excerpt from Pair 4F10 excerpt from Pair 3

Experiment Part 1 Results

None of the subjects perceived five distinct groups: 30.77% of the sub-jects distinguished four groups, 46.15% distinguished three, and 23.077%distinguished two. How were the excerpts grouped? Were the two ex-cerpts generated with the same method (and thus belonging to the samePair) actually clustered together? Table 6.3 shows the answer for eachsubject to this question. For convenience, the bottom line in the tableshows the number of clusters found by each subject. Because all of thesubjects perceived four clusters or less, there is necessarily some overlapof Pair types in every subject. Clearly, the fewer the number of clustersfound, the greater the chances that two Pairs will be clustered together.Subject no.2, for example, correctly clustered togethered the excerptsbelonging to Pairs 3, 4 and 5, but only defined two clusters total. Thismeans that at least two of these Pairs were clustered together. Whichwere clustered together? More formally, if Pair P = {Pi, P2} and Pair

6.1 Experiments 81

Page 82: Hierarchical Music Structure Analysis, Modeling and

Table 6.3: Were the two excerpts generated with the same method clusteredtogether (1=yes, O=no)?

Subject no.: 1 2 3 4 5 6 7 8 9 10 11 12 13Pair 1: 1 0 1 1 0 1 0 0 0 0 0 1 0Pair 2: 1 0 1 0 0 1 0 0 0 1 1 0 0Pair 3: 0 1 0 0 0 1 0 1 0 0 0 0 1Pair 4: 1 1 1 0 0 0 1 1 0 1 1 0 0Pair 5: 1 1 0 1 0 1 0 0 0 1 0 1 0

No. of Clusters: 4 2 3 4 4 3 3 2 3 4 3 3 2

Q = {qi, q2}, the question then is (p1 = qi) A (pi = q2) A (P2 = q2)?.Table 6.4 shows the results of this operation applied to every pair ofPairs for each subject. In this Table we see that subject no.2 clustered

Table 6.4: Which of the Pairs were consistently clustered together (1=yes,

Subject no.:Pairs 1 and 2:Pairs 1 and 3:Pairs 1 and 4:Pairs 1 and 5:Pairs 2 and 3:Pairs 2 and 4:Pairs 2 and 5:Pairs 3 and 4:Pairs 3 and 5:Pairs 4 and 5:

No. of Clusters:

1 2 3 4 5 6 70 0 0 0 0 1 00 0 0 0 0 1 00 0 0 0 0 0 00 0 0 0 0 0 00 0 0 0 0 1 00 0 0 0 0 0 00 0 0 0 0 0 00 0 0 0 0 0 00 1 0 0 0 0 00 0 0 0 0 0 0

4 2 3 4 4 3 3 2 3 4 3 3

together Pairs 3 and 5. We can see that very few Pairs were consistentlyclustered together: Pairs 3 and 4 for subject no.2 as we have just seen,and Pairs 1, 2 and 3 for subject no.6.

To see to what degree the clusters defined by the subjects were a com-bination of excerpts belonging to different Pairs, we asked the question:

82 Experiments and Conclusions

Page 83: Hierarchical Music Structure Analysis, Modeling and

Is any of the two excerpts belonging to Pair P = {p1,P2} clustered withany of the two excerpts belonging to Pair Q = {qi, q2}? More formally,(Pi = q1) V (Pi = q2) V (P2 = q1) V (P2 = q2)?. Table 6.5 shows theresults. Looking at the Tables we can see the variety of the clustering

Table 6.5: Is any of the two excerpts belonging to Pair P = {p1,P2} clus-tered with any of the two excerpts belonging to Pair Q = {qi, q2}?

Subject no.: 1 2 3 4 5 6 7 8 9 10 11 12 13Pairs 1 and 2: 0 1 0 1 1 1 1 1 1 1 1 1 1Pairs 1 and 3: 1 1 0 1 1 1 1 1 1 1 1 1 1Pairs 1 and 4: 0 1 0 1 0 1 1 1 1 0 0 1 1Pairs I and 5: 0 1 1 0 1 0 1 1 1 0 1 0 1Pairs 2 and 3: 0 1 1 1 1 1 1 1 1 0 1 1 1Pairs 2 and 4: 0 1 0 1 1 1 1 1 1 0 0 1 1Pairs 2 and 5: 0 1 1 0 1 0 1 1 1 0 0 0 1Pairs 3 and 4: 0 0 1 1 0 1 0 0 1 1 1 1 1Pairs 3 and 5: 1 1 1 0 1 0 1 1 1 0 1 0 1Pairs 4 and 5: 0 0 0 0 1 0 1 1 1 0 1 0 1

No. of Clusters: 4 2 3 4 4 3 3 2 3 4 3 3 2

results across subjects. Figure 6-1 shows graphically the clusters madeby a few subjects. On one extreme we have subject no.1 who foundfour clusters and correctly grouped the excerpts of Pairs 1, 2, 4 and 5.He/She correctly isolated Pairs 4 and 2, but clustered one of the excerptsbelonging to Pair 3 with Pair 1, and the other one with Pair 5. On theother extreme we see Subject no.13. He/She found only two clusters,and only correctly clustered together the excerpts belonging to Pair 3.The excerpts belonging to the rest of the Pairs were divided in separateclusters. Subject no.10 also did a good job in clustering the excerpts.He/She was able to discriminate the noise excerpts (Pair 5) from therest, but confused excerpts from Pair 1 with those of Pair 2, and thosefrom Pair 3 with Pair 4.

From our own observations of each of the three music-merging meth-ods presented in the previous chapter, we were expecting subjects tofrequently confuse the randomly generated excerpts (Pair 5) and thosegenerated with method 3 on a single state space reconstruction (Pair 3).Adding across subjects in Table 6.5 we see that Pair 5 was clustered withPair 1 by 8 subjects, with Pair 2 by 7 subjects, with Pair 3 by 9 subjects

6.1 Experiments 83

Page 84: Hierarchical Music Structure Analysis, Modeling and

Cluster 1 Cluster 2 Cluster 3 Cluster 4

(1,1 3 02 0 5, 3

Subject no.1

Cluster 1 Cluster 2

3,3 5,)5 1,2 4),4 1,2)

Subject no.2

Cluster 1 Cluster 2 Cluster 3

1 1 ' 5 ~ 2,2 3,5 ,

Subject no.3

Cluster 1 Cluster 2 Cluster 3 Cluster 4

(21 005 ,((4,43

Subject no.10

Cluster 1 Cluster 2

L3,3 1,2,4,5

Subject no.13

Figure 6-1: Clusters found by several Subjects.

84 Experiments and Conclusions

Page 85: Hierarchical Music Structure Analysis, Modeling and

and with Pair 4 by 6 subjects. These results match our hypothesis: Pair5 was most confused with Pair 3. However, the confusion between thegaussian noise excerpts (Pair 5) and those belonging to the rest of thePairs was more frequent and homogeneous than what we expected.

We also expected subjects to clearly distinguish the excerpts generatedwith method 3 with components modeled independently (Pair 4) fromthe rest of the groups. Again, adding across subjects in Table 6.5 we seethat Pair 4 was clustered together with Pair 1 by 8 subjects, with Pair2 by 9 subjects, with Pair 3 by 8 subjects and with Pair 5 by 6 subjects.Thus, the confusion of Pair 4 with the rest of the Pairs was also veryhomogeneous.

Why did we obtain such fuzzy results? Of course, since we discretizedall excerpts with the same sieves, they all share the same "outside time"structure. This common structure no doubt plays a big role in thesubjects perception of similarities between the noise excerpts and thetraining based ones. It is likely that the longer the musical excerpts, themore subjects rely on these "outside time" structures (which are actuallystatistics abstracted from temporal placement) for evaluating structuralsimilarities. Thus, it is likely that the sieves have a greater weight onthe perception of similarity between the excerpts than what we thought.How would the results change if we used shorter excerpts? What if wehad not sieved the gaussian excerpts? How distinguishable would theybe in this case? These questions will have to be left open for futureexperiments.

The less relevant but nonetheless interesting results were subject's per-ception of complexity and preference of each of the generated excerpts.Figure 6-2 shows the resulting means (bars) and standard deviations(lines) of complexity and preference across subjects. The most preferredexcerpts were 5, 8 and 9, which belong to Pairs 4, 2 and 4 respectively.Even so, there is a wide variance among subjects in their perception ofboth complexity and preference. There isn't a clear relationship betweenpreference and complexity, but its curious that the most preferred is alsothe most complex.

Experiment Part 2 Results

To evaluate how well each of the generated excerpts preserved structuralcharacteristics of the original training pieces, subjects were asked to ratethe similarity between each of the generated excerpts and each of the

6.1 Experiments

Page 86: Hierarchical Music Structure Analysis, Modeling and

5 -

4-

53-

C2-

0i1 2 3 4 5 6 7 8 g 10

Excerpt Number

5-

93-

~2-

01 2 3 4 5 6 7 8 9 10

Excerpt Number

Figure 6-2: Means and standard deviations across subjects of theirevaluation of Complexity and Preference for each of the excerpts.

two training pieces. Figure 6-3 shows the means (bars) and standarddeviations (lines) of the estimates across subjects.

6

S5-

4-

3-9 2-

01 2 3 4 5 6 7 8 9 10

Excerpt Number

6

w5-

13-

01 2 3 4 5 6 7 8 6 10

Excerpt Number

Figure 6-3: Means and standard deviations across subjects of the simi-larity estimates between each of the excerpts and each of the trainingpieces: Ligeti's Etude 4 and Etude 6.

86 Experiments and Conclusions

Page 87: Hierarchical Music Structure Analysis, Modeling and

The similarity estimates between the generated excerpts and Ligeti'sEtude 6 are fairly clear. With a relatively small variance, excerpt number5 comes first with the highest similarity estimate followed closely byexcerpt 8. As we see in Table 6.2, excerpt 5 belongs to Pair 4 which wasgenerated with method 3, parameters modeled independently. Excerpt8 belongs to Pair 2 which was generated with method 2, componentsmodeled jointly. It is interesting to note that these two excerpts coincidewith the two most preferred. How were the other excerpts belonging tothese pairs rated? The second excerpt belonging to Pair 4 is excerptnumber 9, which is the third most similar to Etude 6. Strangely, thesecond excerpt belonging to Pair 2 (excerpt number 2) has the secondlowest similarity to Etude 6.

How can we explain these results? As discussed in Chapter 5, in contrastto methods 2 and 1, method 3 is characterized by a dominance of onepiece. How one piece dominates over another depends on the state spacedimensions chosen for the projection of the novel trajectory. For thegeneration of the excerpts using this method we projected the newlygenerated trajectory onto the dimensions defined by the componentsof Etude 6. It is not strange then that Pair 4 resulted in the highestsimilarity estimate to Etude 6. Method 2 can best be described as a"collage" method because many times a new state space trajectory willbe defined by one of the pieces for a period of time until an intersection oftrajectories belonging to different pieces is reached, in which case theremay be a shift from one piece's dominance to the other. The reasonwhy excerpt 2 may have done so poorly is that the initial condition inthe generation of this excerpt may have fallen close to the state spacetrajectory of Etude 4 and never shifted to the trajectory of Etude 6. Inother words, this excerpt fell in a basin of attraction of Etude 4 andnever left it.

The similarity estimates between the generated excerpts and Ligeti'sEtude 4 are not so clearly different. The highest similarity scores weregiven to excerpts 7 and 8, which belong to Pairs 1 and 2, followed byexcerpt 2 belonging also to Pair 2. The lowest similarity estimates weregiven for excerpts 3 and 5, which came high in similarity with Etude6. Excerpt 3 was generated with method 3 components modeled jointly,and excerpt 5 with method 3 components modeled independently.

Which excerpt is the most similar to both training pieces? To answerthis question we calculated the mean across subjects of the product ofthe similarity estimates between a given excerpt and Etude4, and the

6.1 Experiments 87

Page 88: Hierarchical Music Structure Analysis, Modeling and

same excerpt and Etude6. More formally, let sim(a, b) be the similarityestimate between a and b. Then, the similarity between excerpt x andboth training pieces is sim(x, Etude4) - sim(x, Etude6). Figure 6-4 shows these results. Excerpt 8 is clearly the excerpt with the mostsimilarity to both Etude 4 and Etude 6. It belongs to Pair 2, and wasthus generated with method 2.

25

20-

S10 I

-51 2 3 4 5 6 7 8 9 10

Excerpt Number

Figure 6-4: Means and standard deviations across subjects of thesimilarity estimates between each of the excerpts and both trainingpieces.

It is not easy to state definite unambiguous conclusions given the resultsobtained. From the results presented we could conclude that method 2is the most successful in terms of preserving structural characteristics ofboth training pieces because excerpt 8 scored the highest in the similarityestimates of both pieces combined. Yet, excerpt 2 (also generated withmethod 2) obtained a very low combined similarity to both trainingpieces. As we mentioned in the previous chapter, a small change inthe initial condition of a state space interpolation can greatly alter theevolution of the resulting observation sequence. Thus, while method2 may be an excellent method for combining two pieces, an optimalresult may depend on the careful choice of model parameters and initialconditions.

Method 3 with components modeled independently strongly preservesstructure from one of the training pieces. Thus, rather than as a methodof combining two pieces, it might be better understood as a method ofmodulating one piece with another.

88 Experiments and Conclusions

Page 89: Hierarchical Music Structure Analysis, Modeling and

The similarity ratings between the gaussian noise excerpts (Pair 5) andthe two training pieces were surprisingly high. How is it possible thatthese excerpts were rated with comparable similarity values to thosegenerated with some of our methods, particularly methods 1 and 3 withcomponents modeled jointly? In our own perception, any of the excerptsgenerated with either method 1, 2 or 3 are clearly better at preservingstructure from the training pieces than the gaussian noise examples.Even the excerpts generated with method 3 with components modeledjointly (which we saw in Chapter 5 generates noisy sequences) have largescale evolutions that the gaussian noise excerpts don't, thus potentiallymaking them distinguishable. Could it be that we have overestimatedour methods, or could it be that we have overestimated the subjects'ability to perceive music structure, or could it be both?

Most subjects who commented on the experiment expressed their diffi-culty in distinguishing clear differences between the excerpts. Indeed, ingeneral the results from both the clustering and the similarity experi-ments reveal poorer aural discriminability than what we expected. Butthe large variances in all the results also reveal a wide range of ears.

Some subjects also talked about their experience with judging similarity.A non-musician said she noticed mood changes from excerpt to excerpt,so this was her main criterion for judging similarity. A professionalmusician said that he noticed his criteria for judging similarity changedfrom pair to pair. First he started rating the similarity between excerptswithout thinking much about it. Later, as he rationalized the task, herealized that his criteria for similarity were many, and that the weight ofeach criterion changed from excerpt to excerpt. Sometimes some featureswere more salient than others, thus influencing more his decision aboutwhat was similar.

There are clearly a large variety of perceptual approaches between differ-ent listeners. Different people focus on different aspects of a piece, andtherefore judge similarity in different terms. Each individual's percep-tion of the musical examples given is also influenced by their experiencewith music similar to the pieces used, and with music in general. It isnoteworthy that subjects no.1 and no.10 (who had the best discrimina-tion results) are professional musicians. In addition, subject no.1 wasacquainted with both training pieces. Indeed, two Mozart sonatas maysound very different to a listener acquainted with his music, while theymay sound as the same piece to an "untrained" person. Humans, justlike machines, are trained to perceive the world in different ways, and

6.1 Experiments 89

Page 90: Hierarchical Music Structure Analysis, Modeling and

the training data individuals feed on can be quite different. One man'smusic is another man's noise, and we see this in the arts continuously.For humans, too, perception requires learning.

Experiments and Conclusions

Page 91: Hierarchical Music Structure Analysis, Modeling and

6.2 Conclusions and Future Work

In this work we have presented an approach to the problem of inductivemusic structure modeling from a dynamical systems and signal process-ing perspective which focuses on the dynamic properties of music. Thepoint of departure of the approach was the reconstruction of a statespace from which to obtain essential characteristics of music's dynamics,such as its number of degrees of freedom. This multidimensional repre-sentation allowed us to obtain generalizations about the structure of agive piece of music, from which we generated novel musical sequences.We presented three main types of generalization strategies (Chapter 5):State space Interpolation, Abstraction of the dynamics from thestates and Decomposition of the musical signals using wavelets andPCA.

We used local linear models to model the reconstructed state space struc-ture deterministically because of the method's ability to generate a va-riety of transformations, its speed and simplicity. There are, of course,other ways of modeling the state space's reconstructed structure withglobal methods, such as using polynomials, neural networks or radialbasis functions. Our explorations of radial basis functions were brief, sowe did not document them here. Nonetheless, it is worth mentioningthat we abandoned this method because, in contrast to the local linearmodels used, the newly generated sequences using this method tended tofall in attractors and thus generated infinite cycles. In addition, unlessone uses almost as many radial basis functions as points in state space,the resulting interpolations are smooth. Therefore, this method is notvery useful unless one is dealing with continuous sequences only. Othermodeling strategies remain to be explored. Of particular importance isthe incorporation of stochastic methods into the overall system.

We discussed the tight relationship between states and dynamics, andhow a collection of states only allows a variety of state space paths (dy-namics) and vice versa. We demonstrated the use of rotations of thestate space to generate novel state sequences that preserve the exactsame dynamics. However, we did not explore the reverse: keeping thesame states while changing their temporal relationships. The classical

(and probably only frequently used) transformation in this respect is re-versing the sequence, but evidently other reorderings are possible. Theseremain to be explored.

6.2 Conclusions and Future Work 91

Page 92: Hierarchical Music Structure Analysis, Modeling and

By decomposing musical sequences hierarchically we were able to achievean additional level of flexibility that allowed us to perform transforma-tions at different time scales. We discussed two decomposition methods:wavelets and PCA; but we did not explore the more robust family oftransformations known as ICA. Particularly for the case of music, wherenonlinear relationships frequently exist, PCA offers a limited solution tothe problem of obtaining non-redundant decompositions. Thus, futureiterations of this work will explore more robust decomposition methods.Related to this problem is that of stream segregation discussed below.

6.2.1 System's Strengths, Limitations and Possible Refinements

In our interest to be as unbiased as possible towards music, we have triedto make our approach to music structure modeling very general. In do-ing so we have payed the price of generality. Many of the sequences thatwe have generated are rather coarse approximations that frequently misssome perceptually important characteristics. As we stated in Chapter 1,it is really not possible to model all kinds of music with a single ap-proach, so while the approach presented here may be a reasonable pointof departure for any musical piece, the particularities of each work canonly be faithfully captured with more specific and more refined methods.

What refinements could we implemented that would still be applicable toa broad variety of music? We presented methods of decomposing musicalsignals hierarchically, making it possible to transform the details or thelarge scale approximations of the dynamics of music independently. Butwe did not discuss or attempt to extract repeating patterns such as"themes" or motives that could be treated independently form othermusical materials. Thus, a further refinement of the system would be totry to find these kinds of structures, and to segment the music in moredetail. Another more ambitious task would be to segregate streams thatmay be running in parallel in a single musical component such as pitch.Musical multiplexing is quite common in monophonic pieces, and theseparation of perceivable streams or voices would allow greater controland refinement of the possible transformations applied to music.

While we briefly mentioned the possibility of modeling the dynamic prop-erties of sieves, in all the examples presented and experiments performedwe modeled the sieves as a stationary structure spanning the entirety ofthe piece(s). A more refined yet still general modeling approach wouldconsider sieves not just as stationary "outside-time" structures, but asdynamic ones as well.

Experiments and Conclusions

Page 93: Hierarchical Music Structure Analysis, Modeling and

As can be seen and heard, the approach to music structure modelingwe have presented is quite good at capturing the large scale dynamicsof music and generating novel sequences at these large temporal scales.But due to the filtering made by the local linear models, we have hadto sacrifice some of the high energy dynamics which are so clearly per-ceivable and thus fundamental, frequently making the short time-scalesequences sound unrelated to the training piece.1 Thus, we have a reversetradeoff to the one typically found in Markov models and in some music-generative applications of neural networks [29]. A possible solution tothis problem might be a more in-depth use of hierarchical decompositionof the musical sequences presented in Chapter 4. Because the high fre-quency content is removed from the large scale dynamics (e.g. waveletapproximations), we could safely use many neighbors in the state spaceinterpolation without causing any additional filtering. Meanwhile, thestate space reconstruction of the details would be interpolated with veryfew neighbors to avoid filtering high frequencies in the manner we havediscussed in the previous chapter. By combining these two models itmight be possible to obtain good small scale variations as well as largescale ones.

'Remember that, in order to reduce the filtering, we typically had to reduce thenumber of points in the velocity estimates or increase the exponent p in Equation 3.8.

6.2 Conclusions and Future Work 93

Page 94: Hierarchical Music Structure Analysis, Modeling and

94 Experiments and Conclusions

Page 95: Hierarchical Music Structure Analysis, Modeling and

Appendix A

Notation

x Scalar variable.x Vector.s[n] Discrete scalar signal.s [n] Discrete multi-dimensional signal.s(t) Continuous scalar signal.s(t) Continuous multi-dimensional signal.

(a, b) Inner product of a and b.abT Outer product of a and b, where a and b are vertical vectors.

||x -y = V/(Xi - y1)2 + ... + (m -ym) 2

C (M) = M!2"2

C2 Two times continuous differentiable function.

A Logical AND.V Logical OR.

E[x] The expected value of x.

Page 96: Hierarchical Music Structure Analysis, Modeling and

Notation

Page 97: Hierarchical Music Structure Analysis, Modeling and

Appendix B

Pianorolls

B.1 Etude 4

Page 98: Hierarchical Music Structure Analysis, Modeling and

-w

- .~ , '~" !U!!!!H''" ;

-il T " Ij~f, ol IsA P 1111!11IIIIIIIIIIII Is

m|HN """"

is.'e!i'.rl"l-....... .... ..

.'. I

so

s "4Fn' 11' 112

a II114,1 it I I 'F ll 11 111

IIIIS''I'to''''C'" "~

lil lll* 111 -1so . .......

* '*-. I

.'j. N6:'

U~4l

400 5Time in beats

00 600 700 800 9

Figure B-1: Ligeti's Etude 4, Book1.

G7#

D7#

A6#

F6

C6

G5

D5

.c A4

E4

B3

F3#

c3#

G2#

D2#

A1#

F1

C1

300

Page 99: Hierarchical Music Structure Analysis, Modeling and

B.2 Etude 6

B.2 Etude 6 99

Page 100: Hierarchical Music Structure Analysis, Modeling and

C8)

G7

E6B5

-

G4# -%.\. . -v IID4# 'P-

A -A

G2- a " -

D2 -

0 50 100 150 200 250 300 350 400 450 500Time in beats

Figure B-2: Ligeti's Etude 6, Book1.

Page 101: Hierarchical Music Structure Analysis, Modeling and

B.3 Interpolation: Etude 4

B.3 Interpolation: Etude 4 101101B.3 Interpolation: Etude 4

Page 102: Hierarchical Music Structure Analysis, Modeling and

dim=2, nn=2, p=2

G6

Ce S. . -

A5

E5

B4N I

- - ..-

CL C"i

G3# -. e

A2# -Ae ae0aF2

c2 . .11-

G3150 100 150

Time in beats

dim=2, nn=2, p=128GU -

D.1 .1-:.A5#

n Y

G4 -49 eE * / 1 1 , , I, -, .'.A3Tie etsE3 w

B2 - i e -

S. . a.

F2# -

C2# - aG1# -

D1# -

AD#0 20 4() 60 w0 100 120 140 M&

Time in beats

dim=2, nnm3, p=64

G6#

G4

E3 a82 -

F2# - -ff

G1# --

D1# -

0 20 40 60 w 100 120

Time in beats

dim=2, nn=2, p=16

G6 -AS# if, 1HNNN~i

.. ..... .G4 --

- . . . . ..4 . .

A3 !

E3 -

B2 -

F2#

C#0 50 1 1

Time in beats

dim=2, nn=3, p=2D7# -

F6 a

E4 .B3eib-

F3M

C31 . %

G2# --

D2# -

AI#0 20) 40 0 80 100 120 14()

Time in beats

dim=2, nn=-3, p=128

GSM--

D43

813

G3# -

F3

0 204w0 8 0 2

Time in beats

dim=2, nn=2, p=64

FS# -

*8 - N H H

G5 .

D ;S, -7:--ei'n-E4 y I

F30. sC3M - . .N

G2# -. .

02#

a 50 10Time in beats

dim=2, nn=-3, p=16

F6 --

G5 . .

A4 J

E4

f

P

F3#

DM

A1#0 501015

Time in beats

dim=2, nn=4, p=2

A50 --AS#

F5 -

C5

A3

E3 8 -

F2#

G1# -

0 20 40 w0 80 100 120 14 10

Time in beats

Figure B-3: Selection of generated sequences for different model parameters. The training piece is Ligeti's Etudeno.4 Book1.

Page 103: Hierarchical Music Structure Analysis, Modeling and

wLiJ

S,

et

0

a-.0

moM

0M

dbe=2, nra=4, p=16

AMl

FS - r IN

A4 I N , . o

ato .. N

E4 No

No of I.. I. No 5

FM

I-

G2#

D2 20 4 0 10 2 4

Time in beats

dim=4, nn-2, p-2D7

AS -

F~S.

G 6 N

E6m in beats

G2 -

ES 1 *S'Tm id-

. 2I 40 80 1. 1 2 140 1 d

F 1.a ." I 's

- -- --

D I " .. =i -of

AV1.- . I q .F

D2r

0 20 40 w w M 1 120 STime in beats

dim=4, nn-2, p-16 dimn-4, nn-2, p-64GSDBA7E7 S :

FBm bs

G5#

DSJF

F4-C4-G.D3A2

E2O -"

GO#DO#

0 100 200 300 400 500 00E) 700 00 0010

Time in beats

dim=4, nn=4, p=2

D7

Aas

Ell .. .

.1 .V .uII o

0, 20 40 10 1E a

T i btTime in beats Time in beats

Page 104: Hierarchical Music Structure Analysis, Modeling and

dim=4, nn=4, p=64D-'#

F60 -

GS !6'a n s"ii,

05 h .*"v "4

E4 i

83

F3#

G2#-

D2#-

10 50IS

Time in beats

dAm=4, nn=6, p=16

C7# -

A5#- - --

AFS op

Ca' Vt

AS -. ! -"-G4 "

A3 -h

E3-

F2#F2#-

Gif -

DI# --

Time in beats

dim=4, nn=8, p=2G7

D7 - I

AAS - *6 -6-% ' 64pi

Time in beats

D4# -

0 20 40 60 SO 100 120

Time in beats

dim=4, nn=4, p=128

Time in beats

dim=4, nn=6, p.64

D7# - -

. -. "..

G5 - ;

E44

F3#

G2# -

050 10 150

Time in beats

dim=4, nn=8, p.=16

F7 -

C7 -

G3O -

B4 -

A2#

F2

0 2O 4weo 6 100 120

Time in beats

I',t.

5-'

"'ii

Time in beats

dim=4, nn=6, p=128

--

est

.% -. A

.I.'-I . -

20 4w SO aw

Time in beats

dim=4, nn=8, p=64

Pa

-of -

Time in beats

dim=4, nnw=6, p=2

-

G7

D7

A6

E6

F5#

SG49

D4#

F3

c3

G2

D2

A1l

A60

F6

B3S

G5

D2#

A14

Page 105: Hierarchical Music Structure Analysis, Modeling and

c+ CA4 dim=4, nn=s, p=128 dlm=6, nra2, p=2 dist6, nn=2 p=16G7 0D7

CDA 08 , // . . . A t0 ff;fIE6 */ -111.

as . -//F

--. A- Pr

7/:6 .. Z&O0

F3 - F3 F31-$F

G2G2

D2

- 40 60 0 100 120Time in beats

dim=6, nd,2, p64n-2, p.128 dm n 5 p=2Duf

De ,

FtAB - -.*eF

9u ....

G2#6 -

JPeG I, Jp d m6 nn2 p=2

- - D7#' - -3

' ~ ~ .

c . - - - .

020 I3 a a .

E4E 84

0 20 32 at 82 10 20 0 20 40 6020 0 100a 1202Time in beats lTime in beatsTienbat

dtm6 niti, =16dtm=, 8855 =64dim=, nn2, p=165

0 3 q B3 F4

F3 03

03 - F ,a,/5D3..:

G aA /l

F61 --

214' E4

83 "0"3 "/

-F3-.- - - c $, " -Fa

40 20 22 1 0 120 0 20 40 0 0 100 A0Time in beats Time in beats

dim=, nr=5, =16dim=, nr=5, =64dim=-6, nn5, p=128

F6~G C7

D6S - .

A5

DS GS E5 . 0

A4 B4

E4~F 0 -C

B3~~~G -ED4FfP

FU 2- 40 6 0 10 %2

A6# 827A

c62' - -2 -CF2G8

G5# A5#

Al#~~ c2Al[ #

0 20 40 S0 80 10 120 0 20 40 OD 80 100 120 20 4 0 0 10

Tim i betsTime in beats Time In beats

-

.

-

-

-

Page 106: Hierarchical Music Structure Analysis, Modeling and

dim-6, nn=8, p=2F7

a'C7 -

G6 % .- % *

D6 e s

E5 %, /B4

F4# - -

IO -

Time in beats

dim6S n= 1 p128

Ft 7%1

G7M--

E3 -

86,

W1 -

Time in beats

A# -

A7 --

A2 - --

E- -? -

A4#

A2

F1# 4

F16 -

G5#

D5

A4

F6 -

A4 a

E4 20 j ef

a i es a e a Tme in b as a a

dim=6, nn=8, p=16

0 0 B 40 ;60 0 1000 1200 140 1600 1800 200(

Time in beats

dim=6, nn=11, p=2EB --B7 -

F7# --

C7#

G6t - a

D60 -

F5# -o

C5- s pt . e eG4 - a ,

A 3 - - -- - - -

0 20 40Time in beats

dim-6, nn=11, p=128

A7 -

E7 -

G5# .r''./ C'..

G3 -e be

F0 - .

A2.

E2 -

C1#GM

0 0 w 40 60 w 10 w

Time in beats$

dim=6, nn=8, p=64

dim=6, nn=11, p=16

GM -

D6# 8

C5

D4 %V :.-1,/

A3 Y t

E3me inbetB2 7F2#

,310 50 1010

Time in beats

dim=8, nn=-2, p=2

B6- &e6

C64

D3

A2

E2

F1#

0 20 40 80 80 100 120 140Time in beats

r

Page 107: Hierarchical Music Structure Analysis, Modeling and

siveq ul ouwU

ACo om d 'oI ' o I I

5a 5. -0s9

I5 le .1 --

9t' d '-.=u '.2 ipor

-'sa

.K# 00

000

-v

~ccBnod 'g99u '9=u99p

-.Mo

-- pseuun uIs .

I ..* ......-" "il " --II,

Ig~ 'muu'eum

Oa09 001 DO DP Oz

lea

-.-. p .--- j a

-st

**~ ~ -6 ,.P mwA~ ~ e

900L0 I 9W '0u9At 1

-- -;9sa

ooo me W

' ~ '~- s/ 9, ; a3

5Lo

919909 u 9-WI

sla III ow000, 09 W p z 0

..~.;it iA "a Aa40

M;5g5

~*a..4 :* -..~ ~ MA

ga

///p .. .go'% r '

9g-d '19-u '9999059

sleoq II 9901g

.,.Wy IIr .&

Fg .-. .. ..*. 1.. -9

Mtr e 0"

a - ola .

spe9q uwem N .%A:::::::: xl- -6*

=d '9=uu 9=9mp

"oe --ol

aaIa 0 --.- "

-o -0 ;P ? .1 .'P1

ona e. ik 00

* ls L .qq *.ra 50

Mt~ MI*99e4*Ysw

~0 OM

fld'EU '=o

Page 108: Hierarchical Music Structure Analysis, Modeling and

dim=8, nn=10, p=64A6# --

-- F

F6

G5

A4

., jj/1*

II

E4 in ba

B3#

G2# - I

D2AD

0 2D 40 w0 8 0 2 14

Time in beats

dim=8, nni=14, p16

FAM-

C6 - -

G5S - INI l t IIII

A4 IN IN I .

f

E4 IN INs

F3#

GF - I

Dc . - a

0 20 40 s0 80 t00 120DTime in beats

F5

Ga F ..-G4

D4 .

A3 -

E3

F20

C0#

r jiiiiiV..

V" - /e' ".- =m I

.du

dim=8, nn=14, p=2c73

Ge - %%t.3Nd3C7- o

F4n -.G .N : T -P W p % .

':,wN O~d ". " I 'Y 8I

DS 20 40%- .K I010 1

01% 1 ,1'IV 1 v

Time in beats

dim=, nn=14, p=128

GIt

A# .N. D-Va es a '% I

F5-

so fillioll

G4 - :%%v.

A21

32- a

Time in beats

Illil/ilil pen1,p=2

A3

Time in bet

00 20 40I0t010

Time in beats

dim=8, nn=14, p=64C7r

IN

A59ED .N I tii

F4# . # j IN

G I I

T as

0 20 40 60 100 12

Time in beats

Page 109: Hierarchical Music Structure Analysis, Modeling and

B.4 Combination of Etudes 4 and 6, Method 1

B.4 Combination of Etudes 4 and 6, Method 1 109

Page 110: Hierarchical Music Structure Analysis, Modeling and

din-2, nn-2, p-2

D70 -

AS, -:o .

F6 - VA'I

cT.. m [email protected]

dimA-2,1 N ., p -iISS t o

I N o IN .:i, :" ON

eI. -. s

car 3 tc 3-

dim-a, nn-S, p=128

E IN N . N s I O

F5 ,o ae a

Ls - a ... N I -

E3 3.

D1 - . - ---

I IN N

5 s t 15 2 3 0 4

Time in beats

dim=2, nn=3, p=648

A 7# - -o

FS

- mN

E43

D 5 10 15 W 5 4sTim in beats

dim=2, nn-2, p=16

C7t -

Det - N

Is I IN I

E3 -6 .I-N N

* .. No .. n

323.5 10 1 2e 25 30 35 4G4 F. I ~ im i nbas NI M. IIo,4,

dim=2, nn=3,. p=2

- I I I N I - o

-E3|4 - N

I.'D s :. s :' w s

dimn-2, n=, pU2F4

G- p1

in I i i 9 ,

dim=2,nn=3,p.128

.73y- -

. . . . l.

car 111tiie :II e iq I I i

5o 10 15 20 25 3 0 35 4o

CTime in beats

dim=2, nn-2, p=64D7* -

A6 -F6 I. IIN. 1 1 1

dIa nn-3 ON-IS

C6 . N IlvN. o./'

A4 -o I

sI

At ~ ~ ~ ~ ~ dma nn4 p=2 ' . :I I ,1

. n .. a No 331

C3'

d o2 n p.16

EN INI

ON. :Not I . e

F30- IF

0 5 10 15 2 25 30 35 4Tim in beats

dim=2, nn=4, p-26

A6s-

I a 0 N I

oas -i II .- ..

D3I - I -N, -E

Figure B-4: 500 note fragments from combinations of Ligeti's Etudes 4 and 6 Book 1 using method 1, with 20% for

Etude 4 and 80% for Etude 6. Each panel is a combination of the Etudes using different parameter values.

Page 111: Hierarchical Music Structure Analysis, Modeling and

din-2, nn-4, p.16

F4 .

- 'A

D1 5 10 15- 2N2O0 35 4 5

dim-4, nn-2, p.2

AS.r

c J1/3 . 1N:I

01 10 2 'IF 40I

Ta. imeinb'

21% 1

F6 _1 - N I i l

. y i. . .s..- n. r .1

1 ,s

4:4

AAW

dim-2, nn-4, p.64D7#-

F3B ----

-- -. -

r I .

No . . s

0 5 1. 15 20 25 30 35 4 45Tim in beats

dlm.2, nn.4, p.128

D7 ** ,...-

M NO

F3 -6

- : I No i n beats

d oM-, nn=, p.64

F6, - Ce., -,IN

r ". -..-

03 - .. ,.- - -

F3 r ",r..

E2 -i

02 -

Time in beats

dimn-4, nn=4, p-164

E4 -. ,...P

Fl - - . - ./ a p ..

0 10 20 30 40 5Tim in beats

dlm.4, nn.4, p.2

1® am

E4

is

- - -

Timeo in boas

Page 112: Hierarchical Music Structure Analysis, Modeling and

din-4, nn.4, p-64

F4 . .. m,

F. -

- 4%-

S 1. 20 3540s

Tim in beats

dim-4, nn-, p-16

.a.

4 - ., ,, .m ,- -

S y ..- . . - *--6 -V,

E3 . ." -

- --

.c ...- , - *

dim-4, nn-S, p.2E3 -

e-A-e. . aa . ..9v.

F3# -

C2*#

dim.4, nn=S, p-64

F6 -

S,. . '. ,...

..E49 . . is-

a I B

F3 . . 'i -an

0 1o 2w 4 wTim in beats

dimn-4, nn-4, p-16

F6 --

- A :.:-. . ./* w-A"-. - * Y -*9 -

- "I

- -' .

O 10 20 30 40 5

Tim in beats

dim-4, nn=-, p-2

AS,4 n-,p.2

FS

D -MM

dIE4E

5i in beats-

E4 - i

ce- -

9F.'..

. O. A

C1O

0 10 2 50 w0Tim in beats

dinm-4, nn=B, p=64

Tim in beats

Page 113: Hierarchical Music Structure Analysis, Modeling and

U..,..

ts

a-- 3-

S

NA

' ~

'1

t22

* s1

1

2

A.

ZL

h

8

.~ ..~4

.2

~~.J1

L

R.P

O-

I- .'.

OF

**U

.

P

p

..

.*

l .

..

..

I

~J e

..

..

l .

q

21

I .P

P

% M

.2

t -*

ILFl 2

4D

d

34

BA

Cobnto f

tds4ad6,Mto

1

Page 114: Hierarchical Music Structure Analysis, Modeling and

dim-6, nn-B, p-2

F5 in 1 m

- E

D4 -. -V. C N

ii "N j'.: . i i sk- il W

W

As -isesu 6

i .. \

al(a

11

G1t - -

F0 Pit15 2 5 0 3 4 5sm JC7s

F5 .5

B2 N. .t

par- ON

0 0 20 30 40) 50 00 7MTim in beats

dim-6 nn=11, p.64

GMaD7# -

-S -I

FZ6 . i.

G5 No :mrf ~'.y I

DS . shm *OAN, - .,- .11 -- 0 . gE4 .1. .a

"F.% - . .G2 .-

0 10 20 3 0 50 0Tim in beats

din=6, nn-B, p-16

A5r t a.F5 . . 'F5 iSInnEi I

. %X

Gd4,B In il p-2i%1

c5 .I . .. . 1 4111 . .. .

- - . - -

.0 5 0 Is M. 2 3 5 4 5 5

* . .

DA - -p

- % -i -7

F21

A" IS 5 10 15 20 25 0 3 4 45

Tim in beats

dim=6, nn=11, p-128

Dalg

F5S

E3WE

ca%?. " lisi ' e

Q~~~ri si is. i . 5D1s

E3 0 2 0 40 5 0 7

Tim inbets

dim.6, nn=, p.64

F.r -

.-

5,. .- - 4 -.:.tiC- :- --

Y"E - .*.-. " * -

F4 . ' e u

A,.,E2a a l

Tim in beats

dim-B, nn=11, pl16

ON

F5-h sm

dim-B nn1 .p=2

F2 . .-

*1 II-BIIis .m a -m NOE'B N OW110

Tm in beats

di m-8, nn=2, p.2

E5 --

.. - i.tg s

G1 -I .I -

0 0 15 2 I 25 30 354.4

Time" inbes

Page 115: Hierarchical Music Structure Analysis, Modeling and

--.

--

...-

-E

CJS

Jg,

, -

--

".- *

.---.-

-.

2

--

--

--

-

-6 -

.*..

.-. -.

--

-s

*4

A.K

--3

-2-.--.-..

2-

---

N-

--..-

-j

2-*.-. -.

:: -

--

EL

... .

r-

--

--

--9

. -"

-

4/

882

-a%

52

8

aaas

tPPd 404d

,3n.

%. a.

.-.

...

..

..

,

.~~

~ ~ .

........

.....9

c -

C

AtL

' 'L

WLa.

/2

* *

'''

Nt

tte

2

-.E

)NI?

?N

-I '.

-6 ..

:..

.....

*.

.......

F8

2F

~fiiff

1fi B

2 '621

fiiO

Od

F

B.4 C

ombination

of E

tudes 4 and 6, Method 1

115

Page 116: Hierarchical Music Structure Analysis, Modeling and

dim=.8, nn.10, p.64

E5 - t .I

toy

di3,-S, nn-14, p-i,

A -

W g *g * a,.

E6i

D2 Co. t-

Al

01 -Gen-

0 10 20 3 w 0 50 5 0Tim in beats

dim-8, nn=4, p-16

D5 - .r

.2t - - -A . . ..m. % 8/ .am a..

to..- " , . . . . - r- eDef " .a ."=el .... ".s a o 'a

D. '* .- , -.. f. -- .

As

E9~ N

dim=8, nn.=10, p.128

D7B -o

F6 -- *1,

CSe

G5 -

"" ... ,..a .,.%

E4 0.

Ea v ,i

01 lS.% w*so

dl.,,=B, nn.14, p-64

C7#

Is

*2 - -

42I -*-

Mo.

0 10 2M 3w SO 50 M0 7

Tim in beats

dim.10, nn=2, p.6

C76 -

Ca

as,F5b -

P.3

c .. . & .1 , . 1 "6

E4 -- , -. 1 - t- to t- o

'a'. t. -.

F,

GO

0 10 20 3M 0 5 0 7Time in beats

Page 117: Hierarchical Music Structure Analysis, Modeling and

c5, -as. -

o .. . -' . ...... .. s . i a .- . . . a *

- *2 . . aP. A . .. I .* -ia

- - - .- .. 6 . .4*

oF c3 .. . .

.2 -or s

O..

Yt. W %1, A

0%

(0

1dim.10, nn, 7, p.124

05 . - a. e . slo

.6 r3 .- ." .. 0 ,a ."

F0

e- ~ ~ ~ ~ A .s .. "".L.-.am,: . "c

so1

0 10 2w 30 0o so 10 I 4o2. 3

d~~m.10, nn.7, p.64 dim-10, nn-7, p-1 28 i-0n-I p2

ES5A.. - .-s .D

IE~F S4 1. .Ic r . ,. Im . --

Gt M -s .F3a aF..

o" "G.

J.. no D. . .

c2 El -m

F2 F3s -

DFI -

ri nbasTim in beats Tim in beats

dim-10, nn=12, p-16 dim=10, nn.12, p "6 dim-10, nn=12, p-128

10 2 4w 5wTim in beats

.. * !6 .

3 .P a s . -1.... 4-- , s. ... i.

a1 s -6 -; s

F1,

0 10 2 0 4 0 dTime in beads

dim-10, nn.2, p.128 dim-10, nn=7, p-16

10 20 3 Q 4ws o

Tim in beats

Page 118: Hierarchical Music Structure Analysis, Modeling and

dim=10, nn.17, p.16

Es

s, - -I -- ... ?- . . .,, .. * ' . """ . .. a ....

en ' . .. . '':. . . a

e, *,. F.... "

G2 * ...**AlE1l-

o -

Tim in beats

dIm=10, nn.17, p=128

i* 0

>s . ."b . . P.. %.t.

.... A -

dim=10, nn.17, p=64

C7 - -

E5 --w -

E5*t . . - .

- - - I - -. * *. - -

F2#

-a,

G1-

|-im in beats

Page 119: Hierarchical Music Structure Analysis, Modeling and

B.5 Combination of Etudes 4 and 6, Method 2

B.5 Combination of Etudes 4 and 6, Method 2 119

Page 120: Hierarchical Music Structure Analysis, Modeling and

dim=2, nn-2, p=2

D7

As

E6 -

I,

1 v

Tim in beats

din-2, nn-2, p-128

C7

Far

C-......... """'"'"""""""""""''""""""""N.H..H.H .............

dim=2,* nn ,pj4

*- -

-6 .

-. . - .. ,F6 - ". .- . . . ,. .

E4 . .

- .9d- a- a

dim=2, nn=3, p=2

* a

-7 1 2 3 4

"--

j4, so

3 -I

~:V I'sjj1flp*~r

- "" %.-- - -- "--j.l-; . . . '

E1

o 10 2 30 ao so .6!

Timle in beats

dim-2, nn=2, p=64

* 61 ....'..

* -

E4

a,

A1l0 5 10 15 20 25 30 354M 5 S

Timle in beats

dIm=2, nn=3, p=16

F6 -

I.5

s'a

AlA

C7

a .-'*-

02 - -

A3l

Timne in beats

Figure B-5: 500 note fragments from combinations of Ligeti's Etudes 4 and 6 Book 1 using method 2. Each panel isa combination of the Etudes using different parameter values.

Page 121: Hierarchical Music Structure Analysis, Modeling and

LP

d

LP

d

'

'01P

1

d

.%I

-C-* A

&

--

.-

r

WiP

d 43P

d

B.5 C

ombination

of E

tudes 4 and 6, Method 2

Wid

LP

d

121

Page 122: Hierarchical Music Structure Analysis, Modeling and

dim.4, nn=6, p.16

I I.I M s

dim.4, nn.4, p-64

- - -

I-

- s.

s-b

dim=4, nn-4, p-128

E4 -I '-

S 10 20 o 40 5

Tim in beats

dim-4, nn-, p-4

F1

: m; s.. s. I .

L !. .. O 70

r7 - .. .

E4n4 n.-6 p-i

. - -*

r~ ;s

A- -. - .

F1 s

lol

Tim in beats

dim-4, nn=6, p-207 -

E6

U

* N o - I-

r go

:;10 2± 30:w 4 so Vtodm-4, nn-6 pI

Fe.

--,

Gol i a :1 1 ."* -

E4 -

It I

o 2x 30 4 w w0 7Tim in beats

dim-4, nn=8, p=124

yIs

S.

Page 123: Hierarchical Music Structure Analysis, Modeling and

dim-6, nn-2, p.128 dim-S, nn-5, p.2

_0 10 ao aoTimne In beats

dim-6, nn-5, p-64

I I I ml fI I " 1 1

FO

m 4jl M M X..

= m

-3 -

o 10 w wTima in beats

dim-4, nn-U, pe121

- %.;f~cm :of.p I0

1*'*.

9I

as. /~'

1jlame / . ,a1*4- Mo : ps / ,.

a ml, 1' o/ F, O . t Pon*

an ~ mc nI 6ommas ms.rn

Ut l-www 1

Page 124: Hierarchical Music Structure Analysis, Modeling and

din-, nn-B, p-2

7 - Is,,E7 I B-Dar - -

yy&--. 1 IN,

cw mt a;

dim=1, nn=l, p.12

-Fm - ----- - rn

Es U s

A,

C4 -

D3

*im Unbet

A1 -F11 -

Tim in beats

dim.6, nn=11, p.-64

D5

E.-~ ~ ~ ll 1 1

0 0 20 30 - 4 0 o

Tiei ats go

dim-6, nn-S, p-16

F4 m a

BII

-11-"

E2# - a

C7 -. -

din=, nn=1, pm206 m-%

8 1 o 2 I 3 N4 o o o 7

Tim in beats

dim=.6, nn=11, p=1 28

F4

E2-

ct

Tim in beats

dim-6, nn-8, p-4

i.. '

asas

E4 vE

F. - I-car

Ifili -

Tirn in beats

dim-6, nn-11, p-16

-c'-

I1F -i

Timni bat

dimna, nn=2, p-2

rr

Fa -

-1 --

0 10 3 4

Tim in beatsdi.,nn2 .

I ins

Page 125: Hierarchical Music Structure Analysis, Modeling and

a I Al.

asa

-I- Heat-pil

.. 0 --lil fSill -

: s e uten

: ': ,

isi

9L-d 'ot-uu 'i-'wp

pji I 1.. 1:.. ...- Its I

;;-d 's-u. '8--Ip

I., -t...46

*b I I

BELid 'vuu '5-wip

----..'-

Is

pd '0L"uu 'r'nup

o r

sm Is u! I

--I

m- ";I I

* r --

*1d 'L-UU '1-16P5

161I a l

Isi

.6-d 'E , 's iI

-- --

Wirtl.F! I

a.* I

* --

e-d '-uu 'g--p

a.;i! 1iUIu~, IV' -U;; ;. w ;

r jpLL 7 -.I'--

: /s. ..".

rL."

ML-d 'z-u 1'g1-sw'll

Sieeq U1 ema

Page 126: Hierarchical Music Structure Analysis, Modeling and

n.. .*I

I~ ~ ~ :: I-. : 11o

N I

spe uti m

~ En.e.U.U1U:-- -A:&v:E. ;|-o

aLd '-uu 'at-uip

sleeq u! ewg

*1100

%

* if * * ! "

9 -d 'PL~uu '-wIp

OLA09 .0Z ol -

;%16 I/

z oofalm pg-%? --i

o s N o o 6 o

,..- -_-. o,--- --:: ---y ---

-I-

yg-d 'yL-uu 'gLmjp

spesq u! euLL

-.r * * a

md ' u 'Am

*5nozh.~oD

rfl6:.:-. -jI J

4r r0

pg-d ' L=UU '9=WIP

iiu11I! m1

f dOL~ 0C Zw O p

NEW.ii *l S IHS A I

pil I -- NI 1 *ua jjl 9

z-d z-uu 'oi-p

:1 11 o.N .f.'NUt-U in-V.,. ~ j,;

~U:U

as a p-u -~

Page 127: Hierarchical Music Structure Analysis, Modeling and

dim.10, nn-2, p.129

- -i

cuy

dim-10, nn=7, p.64

- jf -j/- '/ff, -

F3 - *

dim-la IN12 as.16N

Jl -

r 10

- Ww - ,

, : - -

I, l m%5. 0fA nn7 .6

E3 y - id ---

--

Tie inbetE4 .. la

dim.10, nn-7, p-2

F510

07 -

1aa

Tim inlbeat

-II

F4 - EU . . . . .; .

1S - M :I

INrCNi'? .. -

Tim, in beats

dim-10, nn7, p.126

1U X 1 : l

so 21111 011

F41 - -

im-la ka1.pS

D3W

in- Mi :Ma0 10 20 3w 4 s5o GTim in beats

dimm10, nn-7, p.16

E5S

1 II I

10'20 a *-ol so a

dim-ia, nn=12, p-2

Coo .4f-84i -.I o

F No No N

dim-10, nn-12, p-128

I .t ... .o I

.. l ;- -q oL

--.

Tim in beats

o 10 2 wao 4

Tim in beats

Page 128: Hierarchical Music Structure Analysis, Modeling and

sleeq U! ()411

BZL~d 'LLUU O'Imp

El~~~ Il 0~*E I I I I

I I

Ld 'z tuu IIIi 1

BILd 'L-uu 'O"'IP 116ANIU.

gj-d 'zt-uu '0L-mIP

4..ra :rm

K6;.

Z-d 'LL-uu 'OIWlP

Page 129: Hierarchical Music Structure Analysis, Modeling and

B.6 Combination of Etudes 4 and 6, Method 3 withComponents Modeled Jointly

B.6 Combination of Etudes 4 and 6, Method 3 with Components Modeled 129Jointly

Page 130: Hierarchical Music Structure Analysis, Modeling and

dim-2, nn=2, p-2

F jiu8m 4 - -~

aa

I 10 40 50 I .Tim", in beats :4, t

dim1, nv=, p ff

dIm-2, 55-32, p-14

F6-.. -

DG2 -

D2 -

so .

Tim inbe ts o

dmm.2 nn=Z, p-4

as'

as

. m : -&A o

ass=2 ts=2 0p.64 i

km. mm *as

tZi~ii ask

Ti i mm beat

dlmm2Z ms=3, p-64

''

F5 74 mm Is~~~r. fid m-~~~~~" "dd~mvmmm -Z3m mm -& m' 'm

rLa.. a '* m

mm~ '

G4

as'

Figure B-6: 500 note fragments from combinations of Ligeti's Etudes 4 and 6 Book 1 using method 3 with parametersmodeled jointly in a single state-space. Each panel is a combination of the Etudes using different parameter values.

dim-=2, nn=2, p=S

AI I

dim=2, nn=3I, p=2

as

S im Tmime inmeat

- m a #a m 4 ;W

0 10 2x 30 aTim in beats

Page 131: Hierarchical Music Structure Analysis, Modeling and

diim--a, ne-3, p-Sd

som- - e us

* As M I.;.n P e :Ka

I A-

I InIs

DW- *ass. .k j~ %

All; *0 w Y ' 5 t

or -a0s:. % V.

M P.3, A1 &Jn .. A

Ss

dIm-a, nn-4, p-2

.. I'3 1111

* IN II

IN. .'5 *.

In IdA* :;a 1 hS% 3I83 r3

1 IN 0 A ONNi..m 1

dlm-2, nn.2, p-14

::.. MM a,* ~ ~ a A, oU - f -

A * ~ *

0 10 2w 1 o"Time in beats

dim-a, nn-4, p-4

ti 7 No &

* A 1 V6. seji.

dim-2 of,4 p-ed .1 N .I

.1

illeW

-I. l s . V CN Sqt i~

on ~ .dIto1

istV At,~Us

Un in berats

dkv2 nVp6

Page 132: Hierarchical Music Structure Analysis, Modeling and

dim-4, nn=2, p.16

F- No..R c& IN No NomF6 -O

19~~- ---m w

E4 -o Noo

ATime inibeats

dIm-4, nn=, p-4

No A I I53 N 1 15 2 5 30 3 0

- .

- , -- - - - .

FM --

0 10 15 2 5 3 5 0

Tim in beats

07 - rN

-s usNO ;A a.-N

dim-4, nn=4, p.8

AF - ; -N

aM So .12as .. %A . 7%. N .. I

p I. .6'i

F6 --

I ' I

ila

o

E4 IIN I ' 1O ONN

n1 16 20 31 4 150

- N I

F4 l

dim-4, nn=4, p-2dIm., n.-, p.64

fhr- v r - -o. O n oI r

S. Ut!'r o oaM

Nm- ON1IVA

Ba - -

- -

-A---fEO 1 0 30 40 50II

dim6.4, nn.4, p-16

4 - -

'I 5 1S 15 2 2 0 5 4

- It

Time in beats

dim-4, nn.6, p.4

4x

ION

D5 1t0 20Y 30 4050AE4 ~ ~ ~ Tm Mn bea.0ts 0 o i

10 15 20 25Timea in beats

Page 133: Hierarchical Music Structure Analysis, Modeling and

dim-4, nn=6, p-8

- d .. . -

III

" E II

F. 0 a, a ssm

o 111 0

:.M.~~ ~ ~ a a fi8NI- P U U 'M .I' A

Time n bets

dIm=4, nn-, p-16

G1 a-

-r .U

2 .-.i

F21 -

D1r - -

0 5 10 s 0 5 w aTim in beats

dim.4, nn-S, p.4

*1g*~ BUS

G71-

D7

. o t

aa I

ma s it s

brim a umeTims In beats

dim-4, nn.6, p.64

"E.

--U-- a . J

DS i

--r in a

car -

o s o as

Time in beats

dim-4, nn=6, p.64

a 'h

o olo

- - -u

% 0 0

~;m m imrm~ r:

S.3

ss :s a7- .. ".0 . "B3 i N

am 16 0 al 0aar m

Tie in beats

dim-4, nn=-S, p-S

-- - -U-,- --

05 U

Ui I U U

dim-4, nn-S, p-16

- - r. UUU

SI - -..- r'--

.m

aU

Page 134: Hierarchical Music Structure Analysis, Modeling and

med '= ME~q

me, .a..V

=d &s~ -at so

*L9d 'g-uu gwp

*Lmm d ME=~ g m EuMqp

I 61ME 'o. E ' mm *us J"

if* lol. 'rfr* A--% .iL

IA C...

-'RU

%A-dw ' '.- I I

'~6 -

mge NEWgp%

fe-my .1

m/..'".

*IU m

'I' A *so I 'AF*',td If 9

*,'*'r'( -rM.P0I. M

-d 'E"u B--np

Page 135: Hierarchical Music Structure Analysis, Modeling and

o on %Io

mve~~~~o 'mm;,::No wa a N on

.Ld 'I -au 'a-nIp

.waq LA -4

09mDsga mama

** *%~ %a~~a oa

* ~ ~ I SoI* -*amm a afIN

3m3

r-d 'ttinas 'a-Ip

*w~ am wON a- - O m M O l o0

Ito

a-d a-mnoag

a,~ a! a ma

m 0 Smm, 0

In -S a

Am a tEm E

I~

an

pa-d aII-ms 'a-nip

aaaq a a a ut

Noaa!So 0 N.

st 4 -11-P

4.- No 7i

a No~

a -a l 'aa '-i

I m m ImaI Ia

-'1 6N *EIY * I *r e:M m'anmt

Bookb ON Imm

So aa s Ia a oo aiN

ma6j

U;.

B 41

S

-I A onm IN .

S- '&&-aa 'a-nip

-mU "ow 0S 0 aM 0 0

Is -

am.l a11.1

a a O a r m, a maaf Im% am

E -' a -m a ' aN i p

Page 136: Hierarchical Music Structure Analysis, Modeling and

g-d z-uu B-suip

* *1 0

*. .' .' ..

-- v .t ''" p.U- "

--U--' u ' u

p-d to~u a==,

-m at

ME~~~~~ ~ ~ O& i a 1 1 lI- "

-1 .-N on'% 'MS O

-*

-1 .1 0 j 1 IN -9

WI a vI * r *a .-p WN, on

g-d g-uu 'a-wmp

O. -- a

-..-1 '|

ON ..s -' .

I IN

A.I

"t

w

g-d 'z-uu '-uip

-d 's-uu '-tup

... .S-

god ~ li 'asu au

I * I *

-'A --7 a |1

* m I .6 -

NO: *.. d' -

* *--" .-- *

IS ~j

Or =d ', LUU 'mup

U I s

* Iii ada .41 11

-a

-onna: t U I .j5 U

% 4r*iUcg-d 'gu s=.

I S l I * d% N

U.0*

III~ ~ 1*ojby.,*

a U

- I

-N -

-1 *

--

1

Page 137: Hierarchical Music Structure Analysis, Modeling and

p-d 'pL.UU 'BW p

s qu. 'ual

is is

-1 I * 1111 UIIE U ONaIS m

*P *£ * I

N EI 1 a : N

--

gL-d 'OL-uu 'emulgp

-* .r

* U'I I~ USE I S

-d 'oL-uu 'leWip

-o -a.-

""U. *

- LI -- III

S m ' 'u .?

3- 'JEu 6-11 -

olial IIIIII6lf, ll -

%if 95 9SVIIIIoI 1 oi

EU..

-16

a a

ps~d ot1Uu a Wp

U. U * * *

EEU.

-- ; -U-Il,

* *l Tm

-i L

c

l~d 'guu 'gUWIp

mt a

hu- IIW x1

Page 138: Hierarchical Music Structure Analysis, Modeling and

dim.8, nn=14, p.16

E --

ES* .F.IN :il.E -

F4#4

F

10 2o 5040 soTim in beats

dim10, nn=2, p=2

ASE -

o S 10 15s 2 25 30 35 40 45Tim in beat.

dim.6, nn=14, p-8

so.. .E .. !

m a * I i i

. I * I

o 10w wTim in beats

dimn=, nn=14 p-64

F5 -

c ..~" ~-.6:

G- -

*g5 10 15 2 *2 30 5I 4

Tnb

Page 139: Hierarchical Music Structure Analysis, Modeling and

B.7 Combination of Etudes 4 and 6, Method 3 withComponents Modeled Independently

B.7 Combination of Etudes 4 and 6, Method 3 with Components Modeled 139Independently

Page 140: Hierarchical Music Structure Analysis, Modeling and

dim=6, nn=2, p-Bdim=6, nn=2, p-4

Tim in beats

dimaS, nn=2, p=64

dil.B, =n5, p-S

'SIt

-. %

. I Ii n s I I I V

- . 5. I.*

-pr

- -= -

Tim in beats

dim-6, nn=2, p-128

| P |

- . , -

~S:6-,"l--. -C6 . S.,.

-1

-. '. --- -

Tim in beats

dim=6, nn=5, p-16

Ir.a ...

-*. .. -5 - .. :.-.-

-P.-'I jViPS

dim-6, nn=5, p.4

as~ 1 IIt ~ 11 1 11 il

4I -

F3Il I , I VE T I

E4 ~ ~ ~ II q'1 .,

o 1. 2 1 Nip Io soI a

dlm-6, nn=5, p.64

. - -

F4

I 1n 20 3 0 0 6IN

Tim in beats

* i=6 nnl p.6

Fel - .. Am Ty 7q Is

Cal- S i .. .JISf-

5' 't5itsD5#

I

Figure B-7: 500 note fragments from combinations of Ligeti's Etudes 4 and 6 Book 1 using method 3 with componentsmodeled independently. Each panel is a combination of the Etudes using different parameter values.

dim-6, nn=2, p-16

o 10 20 30Tim in beats

Page 141: Hierarchical Music Structure Analysis, Modeling and

43#d

B.7 C

ombination

of E

tudes 4 and 6, Method 3 w

ith C

omponents M

odeled 141

Independently

4O

Nd

Page 142: Hierarchical Music Structure Analysis, Modeling and

dim-6, nn.11, p=64

- I

I. -

1 10 2M 3 w4 0Tim in b

Aaa -

dim-6, nn.11, p.128 dim.8, nn=2, p.4D.-.A70- , .

C7-- - -

a e sosI-A5 .0 Iss

all

dm=B, 88.2, p.64

G3 .

I" "sa

I3 "i-

E4 F - ..mM.

2m - -n

0 10 2w3 0 0 sTime in beats

dim-, nn., p.

F Se s e i i s I .N o ws I as is

s I o I.

E- -

E4

a- o

dim=8, nn=2, p=128

-B- - - -

I. ""I

esi aa. m 1 1%'-wilmwns,

I - IN I

0 to 2 a.o 0 s 7,0Time in beats

dim-B, nn-6, p-4

t m

'Al s 1 0

Is I

10 2 w 3 Q 4 w 5 G6OTim in beats

Timie in bas

o 10 2M 30 4

Tim in beats

Page 143: Hierarchical Music Structure Analysis, Modeling and

dim-B, nn=6, p-16

Ii I

As ... . -1

sa.

d iuim-B, sn-In, pa

Is a.'.. .... l

ES .l EE,.

Fu .. .R %, m asco

mess .. 5ii mu I, -

0 ~ ~ ~ ~ 10 ,3 1 w o

Time in beats

dima, nin10, p-4

GS I ifI mI II1I1m : 1A u

I .. IS 1 .

E4 f B

ca. -

Time in beats

dim-8, nn=10), p.64

AS

ES

Ns.al.

as ai .. 8

F2

G1

dim-B, nn-10, p-S

- -FS * . 8

a is e

E4 s

5- , E ,'

. i

-Al~ . 1 . si

- -6"

dim-, nn.6, p-128

is

" A -~. is

-.. 55.5 . -5**

= . .... %.

a*

10 2 80 70 SO SO 1oTirne in beats

dim-, nn-10, p-16

"~ J~, '. .I~~ ~ o .gi I. IN NoI Il-i

-20 4 11 mill "1 1

Page 144: Hierarchical Music Structure Analysis, Modeling and

0 10 2M o 4 ) wo Mo 7 SOTime in beats

dim-, nn=14, p.128

MI..

F5 1 -6 a-*

D4~~~ ~ !4'i'Ns Ne is NI ~ I

E - - - - .

Car -

all-

D1 -

EON0 1. 0 a 0 s o 7 o

Time in beats

dim-10, nn-2, p-16

IN N

I I , -, -IsINe

3N N'

24'7 N.

I-i1N

1#-. ditn nP

IF 'I= p

dim-B, nn-14, p.64

dim-10, nn-2, p-B

m9,m

'IN

.. PM -

IN -t. INIIN I

D4 .INmp

Faa -

ca3

klf~.. I. IN . N

Als

dim-B, nn-14, p-16

or IN a INa

Is ases n I, M Npse ll'I. IN'i

a e a mll uila ." , , I . *

aI lip I *

e a m gissa

s'-

to 2s so 7Tim in beats

0 10 2w 3Ga s OTim in beats

dimi10, nn-2, p-64

- .&.9-

. , m , ,..H

NNNN .l : IN

* ',,i '.I:t

m. ,,I.

i I

Page 145: Hierarchical Music Structure Analysis, Modeling and

dim-10, nn=7, p-4

C7

w ~ I

I I .* t

J . ... "AAS.fal- a - - e

%~ 9

.,9. , n .. ==

.4

I I

dim-I0, nn.7, p.64B

-. .16:Cal- ~ ~ 1,41

... * 11.6.

FAan .. be...s

dm- , nn1 . p- .

-M % --:-aa al

-l. i. .. ca -

-.--.B7 -

Fal .s

.as e..C72 I, a. . .

-5,-10 -n2 "...a.t,

F5 -

dim-10, nn-7, p-8

De'

. i- n.

CS'

cdim-,"o-12 -, .

as Ii

%5 . d

c4 10 x so.7

os~~Thn .. ' .be.a"..'.

dim.10, nn=7, p.1 28

G7M -

D. ..

M - - -..

. l, f . a

A1l

- 10 20 30 40 50 O MTim in beats

dim=10, nn=12, p-16

A7 - -a.. -:74E7

F6U -. m

DOu - .. " ,...

GSB 0 . .. s - .

C4 al -.

D3 "" " " -

0 10SO 7 0

Tim in bead.

dim-10, nn=7, p-16

-7 'rd

e5 ...C -E5B - a- - i

- . .. ..

Tion bootC

F3

Tin. I e

A1 - . - - --El

10 2 30 40 50 0 70Tans in beats

dim-10, nn=12, p-4

I7 -

Xs Is I. a

. Bil

E5 E

F4-U - .

0 10 20 30 4 s50 o 70Tim In beats

dim-10, nn=12, p=64

:7#

.O .

F5 P.

. s a

4. ..

-- 6"

0 10 2w 30 SO50 6

Tim in beats

Page 146: Hierarchical Music Structure Analysis, Modeling and

dim-10, nn=17, p.16

uIn .'..., .I,. *.

C7 -s . .

.asas e

Is I

E5 -

Ga4 sce....l-.

C- -

F2-a Z

0 10 20 30 40 5 60 7Tim in beats

dim.12, nn=2, p=4

dim-10, nn=17, p-4

* I~ * 1% * 1 Ism *i1I I

cea-F4 -o I Is I

03 - R -

T..mi..0 1. 0 3 4 0 6 70Tim in beats

dim-10, nn=17, p.64

A6 - *

..... .. .~ -

E5 - .. 4

ma.e

F4# PV..

DW-

o 10 203w0 5 0Tim in beats

dims-12, nn=2, p.8

F4 9

05,

Fi3 -

0 10 20 3 40 5 60 7Tim in beats

dim-10, nn=17, p=8

Fa -

G7-

W -F

I vpi9 ' ~ 1

0 10 2M 30 4Tim in beats

dim=.10, nn=17, p"128

G7# -

F6

c -

D5 -

AI3 -

17 -

F1

Iss

se m.. . ... .

3 s

-M -o -6 -

Page 147: Hierarchical Music Structure Analysis, Modeling and

dim.12, nn-2, p-128

'pF. -

F4r c V.

E2F1

c1 .

0 10 0 50 Tim in beats

dim-12, nn., p-16

II.

II *:

D10 - --

Ti4 in beats

06 I

FS -

G1Be

D1. -N 0 9I

os .

5i ibet

dim-12, nn.4, p-4

E7

Fs,- - -iG3 -\--

--

A2 - - ".. .

.- .o- -o

c4 ~ ~ i il... l.. s .

03-

3..

0 10 2w M 40 5 wTirn in beats

dim12, nn14, p.6FC

""" "". '|" I

F3 ss

- -C3 -

DO- e

E1

as-

o 10 20 3 40 50 6Tim in beats

dim.12, nn-B, p.B

. .

. .- -

0 10 20 30 4B 5 6 70Tim in beats

dim-12, nn.8, p-128

e

F53

c3 -A

E1lg

F.r

c0,..

Page 148: Hierarchical Music Structure Analysis, Modeling and

U,

'0

dim-.12, nn-14, p.16 dim=12, nn=14, p-44

dim.12, nn=14, p-128

C. .-

E B

Fu~~F - 7-.. ...- F5-. oC2 ... . s -- c5 - 4 - - . -

F5 E3

.. . .L 1. A1-- -- "- . . - w 2G4m -n "et Ti F3 -et -i in -b ~e ...ts

Page 149: Hierarchical Music Structure Analysis, Modeling and

Appendix THREE

Experiment Forms

149

Page 150: Hierarchical Music Structure Analysis, Modeling and

Experiment 2

Part 1

For each fragment answer the following questions:

1. How complex Is the fragment?2, How much do youlik this fragment?3. What group does the figmenth elonto?

After listening to al the fragments, cluster them into a maximym of five groups based on SIMILARITY. If youfeel the fragments can only be grouped in two, use only numbers I and 2; if you feel they can only be grouped inthree, use numbers 1, 2 and 3; and so on

For both complexity and preference we use a scale from 0 to 6, 0 being the least complex and leastpreferred, 6 being the most complex and most preferred.Please listen to all the musical fragments before answering the questions.

You might want to use pen and paper to take notes of the groupings you may come up with beforeputting your answers in the form.

complexity [preferenceI group

[F2]

tF5]

FIG

How familiarized are you with the music you just heard?never heard any of it before

sounds familiar

i know i've heard it before, but don't know what it is Ci know exactly what one (some) of them is (are)

(Submit Answers

O give name(s)

150 Experiment Forms

150 Experiment Forms

3

L-D

f-4 FcfA il

,L3 , D4, t-LD.-4 Fcij

Page 151: Hierarchical Music Structure Analysis, Modeling and

Part 2

Rate the SIMILARITY between each of the fragments [Fl], [F2], .., [F10] making up the rows ofthe following table, and each of the two pieces labeled [A] and [] making up the columns;0 being minimum similarity, 6 being maximun similarity.Please listen to the comparison pieces [A] and [B] carefully before you begin, and feel free togo back and listen to them as many times as you want.

[F1]D-F3 F-7[F3]

[F4]

[F6]

[F8]

How similar are [A] and [B]?

151

IExperiment 2

Page 152: Hierarchical Music Structure Analysis, Modeling and

152 Experiment Forms

Page 153: Hierarchical Music Structure Analysis, Modeling and

Bibliography

[1] V. Adan. Affine and stochastic transformations in "rotaciones".2003.

[2] A. Aguilera and R. Pdrez-Aguila. General n-dimensional rotations.In R. Scopigno and V. Skala, editors, Journal of WSCG, pages 1-8.International Conference in Central Europe on Computer Graphics,Visualization and Computer Vision, Science Press, February 2004.

[3] G. Assayag and S. Dubnov. Using factor oracles for machine impro-visation. Soft Computing, pages 1-7, 2004.

[4] F. P. Brooks, A. L. Hopkins, P. G. Neumann, and W. V. Wright. An

experiment in musical composition. In S. Schwanauer and D. Levitt,editors, Machine Models of Music. MIT Press, 1993.

[5] L. Cao. Practical method for determining the minimum embeddingdimension of a scalar time series. Physica D, 1997.

[6] C. Chatfield. The Analysis of Time Series: An Introduction. Textin Statistical Science Series. Chapman and Hall/CRC Press, 2004.

[7] D. Conklin and I. Witten. Multiple viewpoint systems for musicprediction. In Journal of New Music Research. Swets and Zeitlinger,1995.

[8] D. Cope. On algorithmic representation of musical style. In M. Bal-

aban, K. Ebcioglu, and 0. Laske, editors, Understanding Music with

AI: Perspectives on music cognition. The AAAI Press/MIT Press,1992.

[9] D. Cope. A computer model of music composition. In S. Schwanauerand D. Levitt, editors, Machine Models of Music. MIT Press, 1993.

[10] J. De Bonet and P. Viola. A non-parametric multi-scale statisticalmodel for natural images. Advances in Neural Information Process-

ing, 10, 1997.

153Bibliography

Page 154: Hierarchical Music Structure Analysis, Modeling and

[11] M. Dirst and A. Weigend. Baroque forecasting: On completing j.s. bach's last fugue. In A. Weigend and N. Gershenfeld, editors,Time Series Prediction: Forecasting the Future and Understandingthe Past, volume XV of Santa Fe Institute Studies in the Sciencesof Complexity, pages 151-172. Addison-Wesley, 1993.

[12] K. Ebcioglu. An expert system for harmonizing chorales in the styleof j.s.bach. In 0. Laske and M. Balaban, editors, Understanding Mu-sic with AI: Perspectives on music cognition. The AAAI Press/MITPress, 1992.

[13] T. Eerola and P. Toiviainen. MIDI Toolbox: MATLAB Tools forMusic Research. Department of Music, University of Jyviskyli,Finland, 2004.

[14] J. Estrada. Thiorie de la composition : discontinuum contin-uum. PhD thesis, l'Universite de Strasbourg II, Sciences Humaines,France, 1994.

[15] J. Estrada. El imaginario profundo frente a la mdisica como lenguaje.XXI Coloquio Internacional de Historia del Arte: La abolicicin delArte, 2000.

[16] J. Estrada. Focusing on freedom and movement in music: Methodsof transcription inside a continuum of rhythm and sound. In J. R.Benjamin Boretz, Robert Morris, editor, Perspectives of New Music,volume 40, pages 70-91. Perspectives of New Music, 2002.

[17] A. Forte. The Structure of Atonal Music. Yale University press,1973.

[18] N. Gershenfeld. The Nature of Mathematical Modeling. CambridgeUniversity Press, 1999.

[19] S. Gill. A technique for composition of music in a computer. InS. Schwanauer and D. Levitt, editors, Machine Models of Music.MIT Press, 1993.

[20] A. Graps. An introduction to wavelets. IEEE Computational Sci-ence and Engineering, 2(2), 1995.

[21] L. Hiller and L. Isaacson. Musical composition with a high-speeddigital computer. In S. Schwanauer and D. Levitt, editors, MachineModels of Music. MIT Press, 1993.

[22] H. Kantz and T. Schreiber. Nonlinear Time Series Analysis. Cam-bridge University Press, 2004.

154 Bibliography

Page 155: Hierarchical Music Structure Analysis, Modeling and

[23] M. B. Kennel, R. Brown, and H. D. I. Abarbanel. Determiningembedding dimension for phase-space reconstruction using a geo-metrical construction. Physics Review, 1992.

[24] D. Kugiumtzis, B. Lillekjendlie, and N. Christophersen. Chaotictime series part i: Estimation of some invariant properties in statespace. Modeling, Identification and Control, 15(4):205-224, 1994.

[25] B. Lillekjendlie, D. Kugiumtzis, and N. Christophersen. Chaotictime series part ii: System identification and predition. Modeling,Identification and Control, 15(4):225-243, 1994.

[26] D. Loy. Composing with computers: A survey of some compositionalformalisms and music programming languages. In M. Mathews andJ. Pierce, editors, Current Directions in Computer Music Research.MIT Press, 1989.

[27] S. Mallat. A Wavelet Tour of Signal Processing. Academic Press,1998.

[28] E. R. Miranda. Composing music with computers. Music TechnologySeries. Focal Press, 2001.

[29] M. Mozer. Neural network music composition by prediction: Ex-ploring the benefits of psychoacoustic constraints and multi-scaleprocessing. In N. Griffith and P. Todd, editors, Musical Networks:parallel distributed perception and performance. MIT Press, 1999.

[30] F. Pachet. The continuator: Musical interaction with style. InICMA, editor, Proceedings of ICMC, pages 211-218. ICMA, 2002.

[31] T. Pankhurst. Schenker guide.

[32] G. Rader. A method of composing simple traditional music bycomputer. In S. Schwanauer and D. Levitt, editors, Machine Modelsof Music. MIT Press, 1993.

[33] J. Rissanen. Stochastic complexity and modelling., 1986.

[34] R. Rowe. Machine Musicianship. MIT Press, 2001.

[35] R. Shepard. Pitch perception and measurement. In P. Cook, editor,Music, Cognition and Computerized Sound. MIT Press, 1999.

[36] J. Shlens. A tutorial on principal component analysis. March 2003.

155Bibliography

Page 156: Hierarchical Music Structure Analysis, Modeling and

[37] B. Shoner. State reconstruction for determining predictability indriven nonlinear acoustical systems. Master's thesis, MIT, May1996.

[38] H. Simon and R. Sumner. Pattern in music. In S. M. Schwanauerand D. A. Levitt, editors, Machine Models of Music. MIT Press,1993.

[39] L. Smith. The maintainance of uncertainty.

[40] F. Takens. Detecting strange attractors in turbulence. In LectureNotes in Mathematica. Springer, 1981.

[41] J. Trevino-Rodriguez and R. Morales-Bueno. Using multiattributepreduction suffix graphs to predict and generate music. In ComputerMusic Journal, number 25:3, pages 62-79. MIT Press, 2001.

[42] B. Vercoe. Understanding csound's spectral data types. InR. Boulanger, editor, The Csound Book. MIT Press, 2000.

[43] I. Xenakis. Formalized Music. Pendragon Press, 1992.

156 Bibliography

156 Bibliography