4.0
|
Before Width: | Height: | Size: 2.0 MiB After Width: | Height: | Size: 2.3 MiB |
|
Before Width: | Height: | Size: 2.1 MiB After Width: | Height: | Size: 2.5 MiB |
|
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 2.2 MiB |
BIN
Bilder/fig_plot_1_wav.png
Normal file
|
After Width: | Height: | Size: 1.0 MiB |
|
Before Width: | Height: | Size: 1.0 MiB After Width: | Height: | Size: 928 KiB |
|
Before Width: | Height: | Size: 1.2 MiB After Width: | Height: | Size: 1.0 MiB |
|
Before Width: | Height: | Size: 1.3 MiB After Width: | Height: | Size: 1.2 MiB |
BIN
Bilder/fig_plot_2_wav.png
Normal file
|
After Width: | Height: | Size: 600 KiB |
BIN
Bilder/fig_target_signal_intermediate.png
Normal file
|
After Width: | Height: | Size: 335 KiB |
BIN
Bilder/fig_target_signal_simple.png
Normal file
|
After Width: | Height: | Size: 605 KiB |
@@ -42,56 +42,86 @@ The flow diagram in Figure \ref{fig:fig_lms_logic} illustrates the logical flow
|
||||
return output, coefficient_matrix
|
||||
\end{lstlisting}
|
||||
\label{fig:fig_lms_code}
|
||||
\caption{Code implementation of the LMS algorithm.}
|
||||
\caption{High-level implementation of the LMS algorithm in Python}
|
||||
\end{figure}
|
||||
\subsection{Simple LMS usecases}
|
||||
To evaltuate the general functionality and performance of the LMS algorithm from Figure \ref{fig:fig_lms_code} a set of three simple, artificial scenarios are introduced. These examples shall serve as a showcase to demonstrate the general functionality, the possibilities and the limitations of the LMS algorithm. In contrary to a more complex and realistic setup, which will be reviewed afterwards, the clean signals are available, which is in a realistic application not the case.\\ \\
|
||||
In all three scenarios, a chirp signal with a frequency range from 100-1000 Hz is used as the desired clean signal, which is then corrupted with a sine wave (Usecase 1 and 2) or a gaussian white noise (Usecase 3) as noise signal respectively. Every approach is conducted with 16 filter coefficients and a stepsize of 0.01. The three graphs in the repsective first plot show the corrputed target signal, the noise signal and the filter output. The two graphs in the respective second plot show the performance of the filter in form of the resulting error signal and the evolution of three filter coefficients over time.\\ \\
|
||||
This artificial setup could be solved analitically, as the signals do not pass seperate, different transfer functions and would not require a LSM approach, but it allows to clearly evaluate the performance of the LMS algorithm, as the clean signal is known and can be compared to the output signal of the LMS filter. \\ \\
|
||||
\subsubsection{Usecase 1: Sine noise with high frequency}
|
||||
In the first usecase, a sine wave with a high frequency of 2000 Hz, which lies outside the frequency spectrum of the chirp, is used as noise signal to corrupt the target signal. The filter output in Figure \ref{fig:fig_plot_1_sine_1.png} shows a statisfying performance of the LMS algorithm, as the noise is almost completely removed from the target signal.
|
||||
In all three scenarios, a chirp signal with a frequency range from 100-1000 Hz is used as the clean target signal, which is then corrupted with a sine wave (Usecase 1 and 2) or a gaussian white noise (Usecase 3) as noise signal respectively. Every approach is conducted with 16 filter coefficients and a stepsize of 0.01. The three graphs in the repsective first plot show the corrupted target signal, the noise signal and the filter output. The two graphs in the respective second plot show the performance of the filter in form of the resulting error signal and the evolution of three filter coefficients over time.\\ \\
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_target_signal_simple.png}
|
||||
\caption{100 - 1000 Hz chirp signal used as clean target signal in the simple LMS usecases}
|
||||
\label{fig:fig_target_signal_simple.png}
|
||||
\end{figure}
|
||||
\noindent This artificial setup could be solved analitically, as the signals do not pass seperate, different transfer functions and would not require an adaptive filter approach, but it allows to clearly evaluate the performance of the LMS algorithm, as the clean signal is known and can be compared to the output signal of the LMS filter.
|
||||
\subsubsection{Simple usecase 1: Sine noise at 2000 Hz}
|
||||
In the first usecase, a sine wave with a high frequency of 2000 Hz, which lies outside the frequency spectrum of the chirp, is used as noise signal to corrupt the target signal. The shape of the initial clean target signal is still clearly recognizeable, even if the amplitude of it is affected in the higher frequency area. The filter output in Figure \ref{fig:fig_plot_1_sine_1.png} shows a statisfying performance of the LMS algorithm, as the noise is almost completely removed from the target signal after the filter coefficients have adapted.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_1_sine_1.png}
|
||||
\caption{Corrputed target signal, noise signal and filter output of Usecase 1}
|
||||
\caption{Corrputed target signal, noise signal and filter output of simple usecase 1}
|
||||
\label{fig:fig_plot_1_sine_1.png}
|
||||
\end{figure}
|
||||
\noindent The error signal in Figure \ref{fig:fig_plot_2_sine_1.png} confirms this observation, as the signal converges basically to zero after 200 ms The evolution of the filter coefficients also indicates a quick convergence, meaning that the algorithm has adapted effectively to minimize the error over time.
|
||||
\noindent The error signal in Figure \ref{fig:fig_plot_2_sine_1.png} confirms this observation, as the signal converges basically to zero after 200 ms. The evolution of the filter coefficients also indicates a quick convergence, meaning that the algorithm has adapted effectively to minimize the error over time.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_2_sine_1.png}
|
||||
\caption{Error signal and filter coefficient evolution of Usecase 1}
|
||||
\caption{Error signal and filter coefficient evolution of simple usecase 1}
|
||||
\label{fig:fig_plot_2_sine_1.png}
|
||||
\end{figure}
|
||||
\subsubsection{Usecase 2: Sine noise with low frequency}
|
||||
The second usecase resembles the first one, but instead of a high-frequency sine wave, a low-frequency sine wave with a frequency of 500 Hz is used as noise signal. This means, that the noise signal now overlaps with the frequency spectrum of the chirp signal, making the noise cancellation task more challenging, as an osciillation beacon in the area of 500 Hz appears. The filter output in Figure \ref{fig:fig_plot_1_sine_2.png} indicates that the LMS algorithm is still able to significantly reduce the noise from the target signal,
|
||||
\subsubsection{Simple usecase 2: Sine noise at 500 Hz}
|
||||
The second usecase resembles the first one, but instead of a high-frequency sine wave, a low-frequency sine wave with a frequency of 500 Hz is used as noise signal. This means, that the noise signal now overlaps with the frequency spectrum of the chirp signal, making the noise cancellation task more challenging, as an osciillation beacon in the area of 500 Hz appears. Also, in contrary to usecase 1, the shape of the initial chirp is now far less recognizebale. The filter output in Figure \ref{fig:fig_plot_1_sine_2.png} indicates that the LMS algorithm is still able to significantly reduce the noise from the target signal,
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_1_sine_2.png}
|
||||
\caption{Corrputed target signal, noise signal and filter output of Usecase 2}
|
||||
\caption{Corrputed target signal, noise signal and filter output of simple usecase 2}
|
||||
\label{fig:fig_plot_1_sine_2.png}
|
||||
\end{figure}
|
||||
\noindent Figure \ref{fig:fig_plot_2_sine_2.png} shows a significant increase of the amplitude of the error signal compared to Usecase 1, especially around the 500 Hz frequency of the noise signal. Also the adaption of the coefficients shows far more variance compared to Usecase 1, with a complete rearrangement in the area of 500 Hz. This indicates that the LMS algorithm is struggling to adapt effectively in a scenario, where the noise signal overlaps with the target signal.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_2_sine_2.png}
|
||||
\caption{Error signal and filter coefficient evolution of Usecase 2}
|
||||
\caption{Error signal and filter coefficient evolution of simple usecase 2}
|
||||
\label{fig:fig_plot_2_sine_2.png}
|
||||
\end{figure}
|
||||
\subsubsection{Usecase 3: Gaussian white noise}
|
||||
The last on of our three simplified usecases involves the use of a gaussian white noise signal as the noise signal to corrupt the target signal. This scenario represents a more realistic and complex situation, as white noise contains a broad spectrum of frequencies, making it more challenging for the LMS algorithm to effectively generate a clean output. The filter output in Figure \ref{fig:fig_plot_1_noise.png} demonstrates that the LMS algorithm is capable of significantly reducing the noise from the target signal, although the amplitude of the filter output varies, indicating difficulties adapting due to the broad frequency spectrum of the noise.
|
||||
\subsubsection{Simple usecase 3: Gaussian white noise}
|
||||
The last on of our three simplified usecases involves the use of a gaussian white noise signal as the noise signal to corrupt the target signal. This scenario represents a more realistic and complex situation, as white noise contains a broad spectrum of frequencies, making it more challenging for the LMS algorithm to effectively generate a clean output. Nevertheless, the filter output in Figure \ref{fig:fig_plot_1_noise.png} demonstrates that the LMS algorithm is capable of significantly reducing the noise from the target signal, although the amplitude of the filter output varies, indicating difficulties adapting due to the broad frequency spectrum of the noise.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_1_noise.png}
|
||||
\caption{Corrputed target signal, noise signal and filter output of Usecase 3}
|
||||
\caption{Corrputed target signal, noise signal and filter output of simple usecase 3}
|
||||
\label{fig:fig_plot_1_noise.png}
|
||||
\end{figure}
|
||||
The error signal in Figure \ref{fig:fig_plot_2_noise.png} shows a noticeable variance compared to the previous usecases, especially at the beginning of the signal, where low frequencies dominate. The evolution of the filter coefficients show an interesting pattern, as only the coefficinet in the beginning adapts significantly, while the others remain relatively stable around zero. This suggests that the LMS algorithm is primarily focusing on adapting to the low-frequency components of the white noise, which are more dominant in the target signal.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_2_noise.png}
|
||||
\caption{Error signal and filter coefficient evolution of Usecase 3}
|
||||
\caption{Error signal and filter coefficient evolution of simple usecase 3}
|
||||
\label{fig:fig_plot_2_noise.png}
|
||||
\end{figure}
|
||||
\subsection{Intermediate LMS usecases}
|
||||
\subsection{Realisitic LMS usecases}
|
||||
\subsection{Intermediate LMS usecase}
|
||||
After the general functionality of the LMS algorithm has been verified with the above simple and artificial usecases, a more complex and intermediate scenario is now introduced. In this usecase, a real-world audio track of a person speaking on TV (see Figure \ref{fig:fig_target_signal_intermediate.png}) is used as the clean target signal, which is then corrupted with a dominant breathing noise as the noise signal. This scenario represents a more realistic application of the LMS algorithm, as it involves complex audio signals with varying frequency components and relatively high dynamics, but still keeps the advantage of having the clean signal available for performance evaluation. Also, the transfer functions of the signals are kept static and identical.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_target_signal_intermediate.png}
|
||||
\caption{Audio track of a person speaking on TV used as clean target signal in the intermediate LMS usecase}
|
||||
\label{fig:fig_target_signal_intermediate.png}
|
||||
\end{figure}
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_1_wav.png}
|
||||
\caption{Corrputed target signal, noise signal and filter output of the intermediate LMS usecase}
|
||||
\label{fig:fig_plot_1_wav.png}
|
||||
\end{figure}
|
||||
\noindent The filter output in Figure \ref{fig:fig_plot_1_wav.png} indicates already graphically, that the audio track of the person speaking is significantly more intelligible after the application of the LMS algorithm - the prominent breathing noise is clearly reduced in the filter output compared to the corrupted target signal.
|
||||
\begin{figure}[H]
|
||||
\centering
|
||||
\includegraphics[width=1.0\linewidth]{Bilder/fig_plot_2_wav.png}
|
||||
\caption{Error signal and filter coefficient evolution of the intermediate LMS usecase}
|
||||
\label{fig:fig_plot_2_wav.png}
|
||||
\end{figure}
|
||||
\noindent The error signal in Figure \ref{fig:fig_plot_2_wav.png} confirms the function of the algorithm and shows peaks corresponding to the spikes in the breathing noise, indicating the the moments, when the LMS algorithm is setting its coeffcients again to adapt to the changing noise characteristics. It makes sense, that the adaption of the filter coefficients causes repeating spikes in the error signal, as the noise signal now is not static or periodic, but rather dynamic and changing over time.
|
||||
\subsection{Realisitic LMS usecase}
|
||||
To close the topic of high-level simulations of the LMS algorithm, a more complex and realistic usecase is finally introduced. In this scenario, the same two audio tracks of the previous usecase are used - but now they pass different transfer functions. Now, an analitical solution is not possible anymore, as the transfer functions affect the signals in different ways, making it impossible to simply subtract the noise signal from the corrupted target signal. This scenario represents a more realistic application of the LMS algorithm, as it involves complex audio signals with varying frequency components and dynamics, as well as different transfer functions affecting the signals.\\ \\
|
||||
A time-varying transfer function fulfills the purpose of simulating a more realistic acoustic environment, where the signals are affected by the changing surroundings (like a noise source moving away from the microphone). In the case of a static transfer function, they represent the reality of a sensor with a specific frequency response characteristic - this case is especially important, as later a fixed set of filter coefficients shall take care of the predictable part of the signal to reduce the computing power of the DSP.\\
|
||||
Therefor, the audio tracks from the previous example are now convolved with different transfer functions, which mimic the case, that the breathing noise moving away from the microphone, while the microphoe, which records the corrputed target signal, shows another frequency response characteristic.
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
\relax
|
||||
\@writefile{toc}{\contentsline {section}{\numberline {4}Hardware and low-level simulation of different algorithm approaches}{32}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.1}Hardware description}{32}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.2}System setup}{32}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.3}Low-level simulations of different algorithm approaches}{32}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {section}{\numberline {4}Hardware setup and low level simulations}{35}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.1}Description of the low-power DSP}{35}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.2}Implementation of the ANR algorithm on the DSP}{36}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.3}First optimization approach: algorithm implementation}{36}{}\protected@file@percent }
|
||||
\@writefile{toc}{\contentsline {subsection}{\numberline {4.4}Second optimization approach: hybrid ANR algorithm}{36}{}\protected@file@percent }
|
||||
\@setckpt{chapter_04}{
|
||||
\setcounter{page}{33}
|
||||
\setcounter{page}{37}
|
||||
\setcounter{equation}{21}
|
||||
\setcounter{enumi}{0}
|
||||
\setcounter{enumii}{0}
|
||||
@@ -14,11 +15,11 @@
|
||||
\setcounter{mpfootnote}{0}
|
||||
\setcounter{part}{0}
|
||||
\setcounter{section}{4}
|
||||
\setcounter{subsection}{3}
|
||||
\setcounter{subsection}{4}
|
||||
\setcounter{subsubsection}{0}
|
||||
\setcounter{paragraph}{0}
|
||||
\setcounter{subparagraph}{0}
|
||||
\setcounter{figure}{25}
|
||||
\setcounter{figure}{29}
|
||||
\setcounter{table}{0}
|
||||
\setcounter{float@type}{16}
|
||||
\setcounter{tabx@nest}{0}
|
||||
@@ -139,7 +140,7 @@
|
||||
\setcounter{lstnumber}{21}
|
||||
\setcounter{FancyVerbLine}{0}
|
||||
\setcounter{linenumber}{1}
|
||||
\setcounter{LN@truepage}{32}
|
||||
\setcounter{LN@truepage}{36}
|
||||
\setcounter{FancyVerbWriteLine}{0}
|
||||
\setcounter{FancyVerbBufferLine}{0}
|
||||
\setcounter{FV@TrueTabGroupLevel}{0}
|
||||
|
||||
@@ -1,5 +1,16 @@
|
||||
\section{Hardware and low-level simulation of different algorithm approaches}
|
||||
\subsection{Hardware description}
|
||||
\subsection{System setup}
|
||||
\subsection{Low-level simulations of different algorithm approaches}
|
||||
\section{Hardware setup and low level simulations}
|
||||
This section aims to be the main part of this thesis. The first subchapters describes the hardware, on which the ANR algorithm is implemented. The following subchapter describes the basic implementation of the ANR algorithm on the hardware itself and shall provide the reader with a basic understanding of its efficiency, which shall serve as a baseline for the following optimiziations.\\
|
||||
During the third chapter, this initial implementation is further optimized in order to achieve an improved real-time performance on the DSP. The last subchapter picks the final optimizations of the ANR algorithm itself as a central theme, especially with respect to the capabilites of a hybrid ANR approach.
|
||||
\subsection{Description of the low-power DSP}
|
||||
The DSP used for the implementation is a 32-bit fixed-point processor primarily designed for audio signal-processing applications in low-power embedded systems. It is developed using a retargetable processor design methodology and is typically programmed in C. Its highly efficient C compiler produces optimized assembly code that is comparable in performance and quality to hand-written assembly.\\ \\
|
||||
The processor is equipped with load/store architecture, meaning that, initially all operands need to be moved from the memory to the registers, before any operation can be performed. After this task is performed, the execution units (Arithmetic Logic Units (ALUs) and multiplier) can perform their oeprations on the data and write back the results into the registers. Finally, the results need to be explicitly moved back to the memory.\\ \\
|
||||
The DSP includes a three stage pipeline consisting of fetch, decode, and execute stages, aloowing for overlapping instruction execution and improved throughput.
|
||||
The architecture is optimized for high cycle efficiency when executing computationally intensive signal-processing workloads. It features a dual Harvard load store architecture and two seperate ALUs, which enables the execution of two multiply-accumulate (MAC) operations, two memory operations (load/store) and two pointer updates in a single prcoessor cycle.\\ \\
|
||||
The DSP includes a set of registers, including
|
||||
|
||||
|
||||
Advanced addressing modes — such as cyclic and bit-reversed addressing — facilitate efficient implementation of common DSP algorithms. Additional architectural features include hardware-supported zero-overhead looping, nested loop structures, interrupt handling, power-management mechanisms, and on-chip debugging capabilities such as JTAG, breakpoints, and watchpoints. Overall, the architecture is designed to support both control-flow operations and high-throughput signal-processing tasks within low-power embedded environments.
|
||||
\subsection{Implementation of the ANR algorithm on the DSP}
|
||||
\subsection{First optimization approach: algorithm implementation}
|
||||
\subsection{Second optimization approach: hybrid ANR algorithm}
|
||||
|
||||
|
||||