User Tools

Site Tools


wiki:statmux_priorities

StatMux Priorities



This information comes from an Envivio document, there is no listed author so I am unable to credit or reference anyone.

In a Stat Mux system, all channels get the same priority, there is no way from the GUI to change the priority of a channel (to give it more bits ultimately). There is an Advanced Parameter that can help, but it is quite limited.


Context


In the Statmux context, channel’s priority should help preserving the video quality of several channels. This user story aims at implementing and testing a short term version of the statmux priorities, i.e. with a limited number of priorities and without supporting advanced features like mix of codec.

According to [1], priorities can be implemented easily without completely modified the source code. Indeed, just by weighting channel complexity, we could provide a simple priority management.


Specifications


In this first version, the priority will be set only by mpeg4.cfg by specifying for each channel the prioritized level (1 or 0), using the following line:

<serviceName>.<profileName>.vid<videoId>.statmuxPriority=1. With <videoId> starting from 0.

Example:



To set a priority to this channel:

Service1.Profile 1-1.vid0.statmuxPriority=1

By default, all channels will set to un-prioritized.

The expected behaviour is that a prioritized channel will have a better average objective video quality than without being prioritized. It could be checked by comparing in the same pool the same channel with and without priority.

The improved VQ will be achieved by allocating more bitrate to prioritized channels compared to others. However, a prioritized channel could have in particular cases, a lower bitrate and so a lower VQ compared to non-prioritized channel.

The maximal increase of bitrate, i.e. by comparing a channel bitrate with a VERY HIGH PRIORITY and the same channel with a normal priority, could be changed by mpeg4.cfg using the following parameter:

statmux.m_smxPriorityRateFactor=0.5.

The default value is 0.2. The overridden value is clipped between 0.05 and 1.


3 Priorities design


Five priority levels have been planned. However, in the current state, only two priorities are used (VERY_HIGH and NORMAL):

  •  SMX_PRIORITY_VERY_HIGH = 5
  •  SMX_PRIORITY_HIGH = 4
  •  SMX_PRIORITY_NORMAL = 3
  •  SMX_PRIORITY_LOW = 2
  •  SMX_PRIORITY_VERY_LOW = 1



According to the maximal increase of bitrate , priorities factor are:



Once the priority factor is computed, the statmux algorithm weights the complexity (STC) with each priority in order to balance the channel bit rate. Priorities are computed each time a channel is added or removed from the pool.


4 Priorities and distortion control


The distortion control aims at weighting channel’s complexity according to their MSE. Bigger the channel’s MSE, bigger the distortion factor is. Factors are computed every four statmux iterations (around twice a second). Factors are clipped between 0.5 and 2.

However, when priorities are enabled, the distortion control could in some cases nullify the priority. Indeed, as distortion factors can inferior to 1, it could nullify the impact of prioritizing a channel. To avoid such cases, factors are clipped according to the channel’s complexity:

  •  1.00 < F < 2.0 with a very high priority
  •  0.75 < F < 2.0 with a high complexity
  •  0.50 < F < 2.0 with a normal priority
  •  0.50 < F < 1.5 with a low priority
  •  0.50 < F < 1.0 with a very low complexity.



wiki/statmux_priorities.txt · Last modified: 2023/03/09 22:35 by 127.0.0.1