From 89157b668360cbbbbdac6c65b771e1d8e202c509 Mon Sep 17 00:00:00 2001 From: toni Date: Tue, 28 Jan 2020 14:52:31 +0100 Subject: [PATCH] fixed graphics in experiments using subfig package --- code/CMakeLists.txt | 3 ++- code/Settings.h | 2 +- code/main.cpp | 6 +++++- code/main.h | 2 ++ tex/bare_conf.tex | 3 ++- tex/chapters/2_relatedwork.tex | 9 +++++++- tex/chapters/8_experiments.tex | 39 ++++++++++++---------------------- 7 files changed, 34 insertions(+), 30 deletions(-) diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt index b2fe97b..9c57830 100644 --- a/code/CMakeLists.txt +++ b/code/CMakeLists.txt @@ -50,9 +50,10 @@ FILE(GLOB SOURCES main.cpp mainTrilat.cpp mainProb.cpp + mainPlotting.cpp Eval.cpp FtmKalman.cpp - trilateration.cpp + trilateration.cpp ) diff --git a/code/Settings.h b/code/Settings.h index 1b61ed6..5c4f1b9 100644 --- a/code/Settings.h +++ b/code/Settings.h @@ -16,7 +16,7 @@ namespace Settings { const bool PlotToPng = false; const bool UseKalman = false; - const bool UseRSSI = false; + const bool UseRSSI = true; /** describes one dataset (map, training, parameter-estimation, ...) */ diff --git a/code/main.cpp b/code/main.cpp index f8b1030..77b5b94 100644 --- a/code/main.cpp +++ b/code/main.cpp @@ -333,7 +333,6 @@ static CombinedStats run(Settings::DataSetup setup, int walkIdx, std::str { plot.addCircle(10000 + nucConfig.second.ID, nucConfig.second.position.xy(), 0.1); } - plot.plot(); // particle-filter const int numParticles = 5000; @@ -716,6 +715,11 @@ int main(int argc, char** argv) std::cout << "Trilateration" << "\n"; return mainTrilat(argc, argv); } + else if (args.hasFlag("plot")) + { + std::cout << "Plotting" << "\n"; + return mainPlotting(argc, argv); + } CombinedStats statsAVG; CombinedStats statsMedian; diff --git a/code/main.h b/code/main.h index 09e4b6c..aebb91e 100644 --- a/code/main.h +++ b/code/main.h @@ -3,3 +3,5 @@ int mainTrilat(int argc, char** argv); int mainProp(int argc, char** argv); + +int mainPlotting(int argc, char** argv); diff --git a/tex/bare_conf.tex b/tex/bare_conf.tex index 3066310..5aeccb0 100644 --- a/tex/bare_conf.tex +++ b/tex/bare_conf.tex @@ -16,7 +16,6 @@ \usepackage{color, colortbl} \usepackage{graphicx} -\usepackage{subcaption} \interdisplaylinepenalty=2500 @@ -29,6 +28,8 @@ \usepackage{array} \usepackage{multirow} \usepackage{xfrac} +\usepackage{mwe} +\usepackage{subfig} %\updates{yes} % If there is an update available, un-comment this line diff --git a/tex/chapters/2_relatedwork.tex b/tex/chapters/2_relatedwork.tex index 26010cc..70b06f6 100644 --- a/tex/chapters/2_relatedwork.tex +++ b/tex/chapters/2_relatedwork.tex @@ -19,4 +19,11 @@ \etal{Ibrahim} lays the required groundwork to use the still experimental FTM standard and verifies the general accuracy \cite{ibrahim2018verification}. \etal{Yu} present a system using FTM measurements and multisensor multi-pattern-based dead reckoning based on a Unscented Kalman filter sensor fusion \cite{yu2019robust}. -\etal{Xu} \cite{xu2019locating}. \ No newline at end of file +\etal{Xu} \cite{xu2019locating}. + +Compared to the above state of the art our work... +\begin{itemize} + \item szenario realistischer und nicht nur quadrate die man läuft + \item direkter vergleich mit RSSI + \item in der praxis erprobte verfahren darauf laufen lassen. +\end{itemize} diff --git a/tex/chapters/8_experiments.tex b/tex/chapters/8_experiments.tex index 13378a5..6117377 100644 --- a/tex/chapters/8_experiments.tex +++ b/tex/chapters/8_experiments.tex @@ -97,34 +97,23 @@ The geometry and properties of the internal antenna are unknown. % Erkenntnis 4: Unterschied zwischen Pixel 2 und 3 ist nicht erkennbar - - \begin{figure}[ht] -\begin{minipage}[t]{0.48\textwidth} - \centering - \includegraphics[width=1\textwidth]{DistMeasMean.png} - \caption{Mean distance per WiFi card} -\end{minipage} -\begin{minipage}[t]{0.48\textwidth} - \centering - \includegraphics[width=1\textwidth]{DistMeasMeanPerPixel.png} - \caption{Mean distance per Pixel} -\end{minipage} -\begin{minipage}[t]{1.0\textwidth} - \centering - \includegraphics[width=1\textwidth]{DistMeasCDF.png} - \caption{Dist. Meas CDF} -\end{minipage} + +\begin{minipage}{.5\textwidth} +\centering +\subfloat[]{\label{main:a}\includegraphics[width=\textwidth]{DistMeasMean.png}} +\end{minipage}% +\begin{minipage}{.5\textwidth} +\centering +\subfloat[]{\label{main:b}\includegraphics[width=\textwidth]{DistMeasMeanPerPixel.png}} +\end{minipage}\par\medskip +\centering +\subfloat[CDF of error]{\label{main:c}\includegraphics[width=\textwidth]{DistMeasCDF.png}} + +\caption{my fig} +\label{fig:main} \end{figure} - -\subsection{Localization performance} -\begin{itemize} - \item Location error per method (multilateration, prob, particle filter) - \item Wie gut geht der PF? Parameter und Szenarien - \item RSSI vs FTM; wo ist FTM besser wo schlechter?; Verhält es sich ähnlich? -\end{itemize} - \subsection{Results for Multilateration} zunächst wird das einfachste und nahliegendste verfahren untersucht um die performance von ftm und rssi gegenüberzustellen.