\pagestyle{fancy}
\cleardoublepage\chapter{Introduction}
\Quote{A journey of a thousand miles begins with a single step.}{Lao-tzu}

\section{Motivation}\label{introduction.motivation}
In today's world, a lot of information is accessible in a digital form. This is especially true for images or music. Digital music is present in our everyday life and the possibilities to handle digital music enhanced dramatically. The field of \emph{music information retrieval}\index{music information retrieval} (MIR)\index{MIR|see {music information retrieval}} allows the user to access and explore music. But why are we interested in music information retrieval? For example, the user could get additional information about melodic and harmonic structures or rhythm and tempo. This is fruitful information for music analysis. Another application is to find a convenient way to navigate inside a piece of music. This could be realized by searching for structures like similar rhythmic patterns or similar chord progressions and giving the user the opportunity to jump directly to certain similar parts. However, such purely content-based tasks are very hard. This is due to the complexity of music data.

Among the many challenges that arise with information retrieval in a piece of music, we will focus on \emph{chord recognition}\index{chord recognition} and \emph{onset detection}\index{onset detection} that are further discussed in Chapter \ref{tasks}.

In image processing\index{image processing}, there exists a wide variety of challenging tasks, such as face recognition, image denoising or problems in optic flow, to name just a few. Image denoising is concerned with enhancing the visual quality of an image as much as possible. Practical tasks in image denoising are e.g.\ in medical imaging such as MRT or ultrasound.

An interesting question is what do both worlds have in common? Image processing\index{image processing} and music processing\index{music processing} use the Fourier transform \cite{fourierfull} as an important tool. Furthermore, the concept of noise is also present in both settings whether the noise is global like Gaussian noise or locally like a black spot in a color image or a cough in a piece of music. Looking deeper in both approaches we can even find types of ``noise'' that are present (e.g.\ due to the acquisition technique) but are not necessarily perceived as such. This could be in a digital image due to the sensor of the camera or in music due to the sound produced by the mechanics of an instrument. The noise produced by a camera sensor could lead to a deterioration of colors in an image while the sound of the instrument mechanics contributes to every frequency in the spectrogram making applications in music processing probably much harder. Moreover, the spectrogram\index{spectrogram} representation (compare top of Figure \ref{cr_frequencies_chroma}) gives us -- from an image processing perspective -- a convenient and familiar way to access the audio data. Thus, we have strong evidence that image processing methods can also be applied to music data.

In this thesis, we are looking at the problems mainly from an image processing viewpoint. We apply several image processing\index{image processing} methods to spectrograms computed from the music data where we want to investigate whether we can improve the quality of the spectrogram for further processing by feature extraction methods.

Since we are investigating the topic from an image processing\index{image processing} viewpoint, we also use the terminology common in this field where terms to describe certain concepts -- such as ``noise'' -- might probably differ. An in-depth introduction to music data processing is given by Meinard M{\"u}ller in \cite{mueller}.

\section{Goals}\label{introduction.goals}
In this thesis, we want to evaluate how image processing methods can contribute to the field of music processing and analysis. We concentrate on enhancing spectrograms\index{spectrogram} computed from the music data such that the feature extraction process necessary for every MIR\index{music information retrieval} task will be more convenient. Since the spectrograms\index{spectrogram} are a graphical representation of the music data, algorithms that are well understood in the image processing context, such as diffusion processes \cite{weickert98} or non-local means \cite{buades05} can be applied to the spectrograms\index{spectrogram}.

To judge whether image processing algorithms help in this context, we mostly use them in their basic form, meaning that no improvements or simplifications based on the knowledge of music processing are involved. As a consequence, runtime is not the main concern. Nevertheless, from a practical viewpoint, short response times (ideally, close to interactive behavior) are desirable. Therefore, efficiency aspects will not be completely outside consideration, and we will favor more efficient solutions wherever this is possible without serious compromises in quality. In particular, it is often helpful to adapt the algorithms in a way that built-in fast matrix operations of MATLAB can be exploited.

We will investigate real-world example such as songs by The Beatles or classical music like Beethoven's Fifth.

\section{Contents}\label{introduction.contents}
The structure of this thesis is as follows. Chapter \ref{tasks} gives a short introduction to chord recognition\index{chord recognition} and onset detection\index{onset detection} as well as a common quality measure used in this context. Chapters \ref{diffusion}, \ref{morphology} and \ref{nlmeans} introduce the methods that are used in the experiments, i.e.\ diffusion\index{diffusion} processes, morphological\index{morphology} operations and NL-means\index{NL-means}, respectively, where Chapter \ref{modifications} gives insights in how these algorithms can be modified to adapt to the setting of chord recognition\index{chord recognition} or onset detection\index{onset detection}. Chapters \ref{chord_experiments} and \ref{onset_experiments} give a detailed overview of the experiments where different parameter settings are compared as well as how good the methods perform on the problem set. Chapter \ref{final} concludes the thesis and gives ideas for future work. An overview of the testfiles used in this thesis is given in Appendix \ref{appendix.testfiles}.