# On the Feasibility of Wireless Multimedia Sensor Networks over IEEE 802.15.5 Mesh Topologies
## 5 Performance Evaluation
### Peak Signal-to-Noise Ratio  
The most widespread method to determine the quality of a video sequence is the _Peak Signal-to-Noise Ratio_ (PSNR), which represents the ratio between the maximum possible power of a signal and the power of the distorting noise that affects the fidelity of its representation. Because many signals have a wide dynamic range, PSNR values are usually expressed in logarithmic scale. In order to compute the PSNR, the _Mean Squared Error_ (MSE) of each frame must first be obtained. The MSE represents the cumulative squared error between the compressed frame and the original frame. For a monochrome image, it is calculated as:  
\[MSE=\frac{1}{M*N}\sum_{i=0}^{M-1}\sum_{j=0}^{N-1}\parallel I\left(i,j\right)-K \left(i,j\right)\parallel^{2} \tag{7}\]  
where \(I\left(i,j\right)\) corresponds to the value of the \(\left(i,j\right)\) pixel of the transmitted frame and \(K\left(i,j\right)\) is the value of the same pixel in the received frame. The PSNR is defined as:  
\[PSNR=10*\log_{10}\left(\frac{MAX^{2}}{MSE}\right)=20*\log_{10}\left(\frac{MAX} {\sqrt{MSE}}\right) \tag{8}\]  
where \(MAX\) denotes the maximum possible pixel value of the image. If B bits are used per pixel (luminance component), \(MAX=2^{\text{B}}-1\). Considering a video sequence composed of a series of frames, the MSE and PSNR are calculated for each of the frames and the PSNR of the complete video sequence is the mean value of the PNSR of the frames. Figure 15: Lifetime metric for the different scenarios. EvalVid uses the PSNR as an evaluation metric of the quality of compressed videos. When the difference between the frames of an original video sequence and the frames of the received and decoded video sequence is high, the PSNR is low. Therefore, higher values of PSNR denote better quality of the video. Acceptable values for wireless communication systems are considered to be about 20 dB to 25 dB. On the other hand, for the subjective evaluation of video quality, the MOS (_Mean Opinion Score_) [36] is usually employed. This technique is based on the perceived quality from the users' perspective of the received video (or any other kind of signal), giving a score to video sequences from 1 (worst) to 5 (best). In [37] a possible mapping between PNSR and MOS values is provided. The conversion between the two metrics can be seen in Table 7.  
Above, in Figure 16, the results of the PSNR for each of the simulated scenarios are shown. In view of the presented results, a degradation in the quality of the video can be observed as the network grows. Besides, the values of WO seem to have some impact for larger networks, \(5\times 5\) and \(6\times 6\), but not for small networks. In particular, the PSNR value deteriorates for lower WO values due to the hidden terminal problem. With fixed AO values and therefore fixed _active duration_ and contention for medium access, the only reason for this drop in performance is packet loss in the _inactive duration_. Since there is no contention for medium access during this period, packet loss is due to the hidden terminal problem. More particularly, only secondary collisions from hidden nodes' transmissions can take place, whereas primary collisions cannot happen because of the slot reservation process performed in the _active duration_. As a consequence of the above-mentioned, the size of the network has to be taken into account for the appropriate selection of the WO, finding a balance between the quality of the video and throughput (high WO values reduce the throughput considerably). With respect to the AO parameter, the worst PSNR values are obtained for AO = 1 and AO = 2, since the large amount of packet losses distorts the quality of the decoded video. For \(3\leqslant\text{AO}<\text{WO}\) there is little variation in the PSNR, implying a good or excellent video reproduction. Figure 16: PSNR metric for the different scenarios. Comparing the three different video sequences, it can be easily deduced that, regardless of the network size, the PSNR gets worse for sequences with higher motion.