# Development of Height Indicators using Omnidirectional Images and Global Appearance Descriptors
## 3 Development of Height Indicators Using Global Appearance Descriptors
### Method 2: 2D-DFT Vertical Phase  
This method is based on the use of the 2D-DFT and the shift theorem presented in Section 2.2.2. Traditionally, this method has been used to estimate the relative orientation of the robot with respect to the vertical axis when its movement is contained in the ground plane [26]. In this case, a change in the orientation of the robot produces a circular shift of the columns of the panoramic image which can be estimated through the shift theorem (Equation (2)). Besides, this descriptor can also be used to estimate relative height since a vertical displacement of the robot will produce a shift of the rows of the panoramic image that can also be estimated through the shift theorem. However, the use of the theorem in this case is not direct because, unlike a rotation around the vertical axis, a vertical movement does not produce a circular shift of rows and the information in the scene is thus modified; after the vertical displacement some rows of the original image will go out and new rows will appear. Taking this fact into account, the magnitudes matrix of the transformed image will experience some changes hence the shift theorem is not exactly met. Despite the issues described above, the preliminary experiments showed that the great majority of the visual information remains after a vertical displacement therefore a circular shift of the image's rows will be assumed when using this method. For this reason, in order to estimate topologically the vertical displacement between the reference and the test images, we use the arguments matrices of their 2D-DFT, \(\Theta_{R}\) and \(\Theta_{T}\), where only the \(k_{1}\times k_{2}\) first components have been retained. We consider \(k_{1}=k_{2}=N_{F}\). As stated before, a vertical movement in the spatial domain produces a change in the phase of the coefficients in the frequency domain. Our approach simulates different shifts on the matrix \(\Theta_{R}\) (using Equation (2)), compares each shifted matrix with \(\Theta_{T}\) and retains the shift that produces the best match. A circular shift of \(S\) deg of the rows of the reference image produces a change on its arguments matrix \(\Theta_{R}\in\mathbb{R}^{N_{F}\times N_{F}}\) that can be simulated through the next expression:  
\[\Theta_{R}^{rotated}=\Theta_{R}+S\cdot VRM, \tag{7}\]  
Figure 6: Euclidean distance between the magnitudes matrices of the reference image cells and the test image central cell versus \(d\). where \(VRM\) is the Vertical Rotation Matrix, defined as:  
\[VRM=\left( \begin{array}{cccc}0&0&\cdots&0\\ 1&1&\cdots&1\\ 2&2&\cdots&2\\ \vdots&\vdots&\ddots&\vdots\\ N_{F}-1&N_{F}-1&\cdots&N_{F}-1\end{array} \right)_{N_{F}\times N_{F}}. \tag{8}\]  
To illustrate this property we consider a sample panoramic image \(im_{R}\in\mathbb{R}^{M\times N}\), where \(M=500\) and \(N=2000\). From it, a new image \(int_{R}^{rotated}\) with the same size is generated, considering a circular shift of \(N_{R}=25\) rows (the displacement is towards the top of the image). This is equivalent to generating a shift \(S=N_{R}\cdot 360/M=18\) deg. The original and the shifted images are shown in Figure 7a,b respectively. Using these two images, the next sequence of operations is carried out. First, the 2D-DFT of both images is calculated, resulting the matrices \(IM_{R}\) and \(IM_{R}^{rotated}\). Second, the magnitudes and the arguments matrices of both transforms are obtained and just the first \(N_{F}=4\) rows and columns are retained. Equation (9) shows the two magnitudes matrices and Equation (10) the two arguments matrices, expressed in the range \([-180,+180]\) deg. \[A_{R}=\left( \begin{array}{cccc}149,3&5,7&8,8&2,4\\ 24,6&10,0&5,5&5,9\\ 10,3&7,8&4,6&1,7\\ 9,5&4,5&3,1&1,3\end{array} \right)\cdot 10^{6};\;\;\;A_{R}^{rotated}= \left( \begin{array}{cccc}149,3&5,7&8,8&2,4\\ 24,6&10,0&5,5&5,9\\ 10,3&7,8&4,6&1,7\\ 9,5&4,5&3,1&1,3\end{array} \right)\cdot 10^{6}. \tag{9}\]  
\[\Theta_{R}=\left(