# Tracking and Registration Technology Based on Panoramic Cameras
## 4 Experiments
### Experimental Settings  
**Datasets**: The experiments in this chapter were conducted on the publicly available synthetic panoramic video dataset, PanoSUNCG [18]. This dataset is constructed from 103 indoor scenes selected from the SUNCG dataset [30], where five virtual panoramic camera trajectories are defined for each scene. RGB-D panoramic video sequences and corresponding camera pose annotations are rendered using the Unity engine, with an original image resolution of 512 \(\times\) 1024. Among these scenes, 80 are used for training and 23 for testing. To improve computational efficiency during camera pose estimation model training, all images are downsampled to a resolution of 256 \(\times\) 512 for both training and testing phases. **Training details**: During network training, the Adam optimizer [31] was employed with default momentum parameters \(\beta_{1}=0.9\) and \(\beta_{2}=0.999\). The batch size was set to 8, and the initial learning rate was fixed at 0.0001. The scene depth estimation sub-network was initialized using Xavier initialization [32], while the camera pose estimation sub-network was initialized with pre-trained weights from the ImageNet dataset [33]. Following the setup in [18], the hyperparameters of the loss function were set to \(w_{1}=0.1\) and \(w_{2}=0.01\), respectively. The entire network was trained for 100 epochs, which took approximately two days to complete. **Evaluation metrics**: For the evaluation of panoramic depth estimation, standard error and accuracy metrics proposed in depth estimation literature [34] were adopted. Error metrics include the Mean Relative Error (MRE), Mean Absolute Error (MAE), Root Mean Square Error (RMSE), and Root Mean Square Log Error (RMSElog), which measure the discrepancy between the predicted depth \(d\) and the ground truth depth \(g\). Accuracy metrics are defined as the percentage of pixels for which the ratio between the predicted depth and ground truth depth is below a certain threshold, specifically \(\delta<1.25\), \(\delta<1.25^{2}\), and \(\delta<1.25^{3}\). The evaluation metrics are computed as follows:\[\text{MRE}=\frac{1}{N}\sum_{i=1}^{N}\frac{|d_{i}-g_{i}|}{g_{i}} \tag{8}\]  
\[\text{MAE}=\frac{1}{N}\sum_{i=1}^{N}|d_{i}-g_{i}| \tag{9}\]  
\[\text{RMSE}=\sqrt{\frac{1}{N}\sum_{i=1}^{N}(d_{i}-g_{i})^{2}} \tag{10}\]  
\[\text{RMSElog}=\sqrt{\frac{1}{N}\sum_{i=1}^{N}(\log_{10}d_{i}-\log_{10}g_{i}) ^{2}} \tag{11}\]  
\[\delta=\text{max}\bigg{(}\frac{d_{i}}{g_{i}},\frac{g_{i}}{d_{i}}\bigg{)}<t,t \in\left\{1.25,1.25^{2},1.25^{3}\right\} \tag{12}\]  
where \(N\) denotes the number of valid depth values in the ground truth depth map \(g\). Additionally, since the entire network is trained in an unsupervised manner, the predicted depth maps lack an absolute scale. Therefore, prior to evaluation, the predicted depth is aligned with the ground truth depth using median scaling, defined as:  
\[\hat{d}=d\cdot\frac{median(g)}{median(d)} \tag{13}\]  
where the \(median(\cdot)\) function is used to compute the median of valid depth values in the depth map, and \(\hat{d}\) denotes the predicted depth map after median scaling. For camera pose estimation, the Relative Pose Error (RPE) [35] is adopted as the evaluation metric. RPE measures the accuracy of the relative motion between two camera poses separated by a fixed time interval \(\Delta\). The relative pose error for the \(i\)-th frame is defined as:  
\[RPE_{i}=\bigg{(}Q_{i}^{-1}Q_{i+\Delta}\bigg{)}^{-1}\bigg{(}P_{i}^{-1}P_{i+ \Delta}\bigg{)} \tag{14}\]  
where \(Q\) and \(P\) denote the ground truth and estimated camera poses, respectively. Given a sequence of \(n\) camera frames, a total of \(m=n-\Delta\) relative pose errors can be computed. The RMSE of all relative pose errors is then calculated.