aboutsummaryrefslogtreecommitdiff
path: root/report
diff options
context:
space:
mode:
authornunzip <np.scarh@gmail.com>2019-02-12 17:58:25 +0000
committernunzip <np.scarh@gmail.com>2019-02-12 17:58:25 +0000
commit46a277bf740ca2631255a7344ef8736a6c7ba34b (patch)
tree9ee7889104ae57c8d240b7e82e779d77d4ae724e /report
parent72d0a8f45a08088d0f2b490d2458982079320f61 (diff)
downloade4-vision-46a277bf740ca2631255a7344ef8736a6c7ba34b.tar.gz
e4-vision-46a277bf740ca2631255a7344ef8736a6c7ba34b.tar.bz2
e4-vision-46a277bf740ca2631255a7344ef8736a6c7ba34b.zip
Fix histogram figures
Diffstat (limited to 'report')
-rw-r--r--report/fig/testhist.pdfbin0 -> 28694 bytes
-rw-r--r--report/fig/trainhist.pdfbin0 -> 23744 bytes
-rw-r--r--report/paper.md17
3 files changed, 4 insertions, 13 deletions
diff --git a/report/fig/testhist.pdf b/report/fig/testhist.pdf
new file mode 100644
index 0000000..271ee29
--- /dev/null
+++ b/report/fig/testhist.pdf
Binary files differ
diff --git a/report/fig/trainhist.pdf b/report/fig/trainhist.pdf
new file mode 100644
index 0000000..3872951
--- /dev/null
+++ b/report/fig/trainhist.pdf
Binary files differ
diff --git a/report/paper.md b/report/paper.md
index e8d9709..439ab37 100644
--- a/report/paper.md
+++ b/report/paper.md
@@ -15,7 +15,7 @@ The number of clusters or the number of centroids determines the vocabulary size
## Bag-of-words histogram quantisation of descriptor vectors
-An example histogram for training image shown on figure \ref{fig:histo_tr}, computed with a vocubulary size of 100. A corresponding testing image of the same class is shown in figure \ref{fig:histo_te}. The histograms appear to have similar counts for the same words, demonstrating they had a descriptors which matched the *keywowrds* in similar proportions. We later look at the effect of the vocubalary size (as determined by the number of K-mean centroids) on the classificaiton accuracy in figure \ref{fig:km_vocsize}. A small vocabulary size turns out to misrepresent the information contained in the different patches, resulting in poor classification accuracy. When the vocabulary size gets too big (too many k-mean centroids), the result is instead overfitting. Figure \ref{fig:km_vocsize} shows a plateau after 60 cluster centers.
+An example histograms for training and testing images is shown on figure \ref{fig:histo_tr}, computed with a vocubulary size of 100. The histograms appear to have similar counts for the same words, demonstrating they had a descriptors which matched the *keywowrds* in similar proportions. We later look at the effect of the vocubalary size (as determined by the number of K-mean centroids) on the classificaiton accuracy in figure \ref{fig:km_vocsize}. A small vocabulary size turns out to misrepresent the information contained in the different patches, resulting in poor classification accuracy. When the vocabulary size gets too big (too many k-mean centroids), the result is instead overfitting. Figure \ref{fig:km_vocsize} shows a plateau after 60 cluster centers.
The time complexity of quantisation with a K-means codebooks is $O(n^{dk+1})$ , where n is the number of entities to be clustered, d is the dimension and k is the cluster count @cite[km-complexity]. As the computation time is high, the tests we use a subsample of descriptors to compute the centroids. An alternative method we tried is applying PCA to the descriptors vecotrs to improve time performance. However in this case the descriptors' size is relatively small, and for such reason we opted to avoid PCA for further training.
@@ -27,22 +27,13 @@ this coursework, only leading to an increase in execution time.
\begin{figure}[H]
\begin{center}
-\includegraphics[height=4em]{fig/hist_test.jpg}
-\includegraphics[width=20em]{fig/km-histogram.pdf}
-\caption{Bag-of-words Training histogram}
+\includegraphics[width=12em]{fig/trainhist.pdf}
+\includegraphics[width=12em]{fig/testhist.pdf}
+\caption{Bag-of-words histograms; Training left, Testing right}
\label{fig:histo_tr}
\end{center}
\end{figure}
-\begin{figure}[H]
-\begin{center}
-\includegraphics[height=4em]{fig/hist_train.jpg}
-\includegraphics[width=20em]{fig/km-histtest.pdf}
-\caption{Bag-of-words Testing histogram}
-\label{fig:histo_te}
-\end{center}
-\end{figure}
-
# RF classifier
## Hyperparameters tuning