给定分辨率/fps 和比特率,确定视频的感知/“体验”质量的最佳逻辑公式?

问题描述 投票:0回答:1

我正在寻找一个公式,可以为我提供一个相对不错的视频播放质量近似值,可以根据四个指标计算:宽度、高度、fps 和比特率(位/秒)。或者,我也可以使用 FFMPEG 或类似工具来计算视频的播放质量,如果这些工具中的任何一个提供了我在这里寻找的东西。

视频在我的问题中可能是什么样子的示例如下:

interface Video {
  /** The width of the Video (in pixels). */
  width: number
  /** The height of the Video (in pixels). */
  height: number
  /** The frame rate of the Video (frames per second). */
  fps: number
  /** The bitrate of the video, in bits per second (e.g. 5_000_000 = 5Mbit/sec) */
  bitrate: number
}

我想出了以下函数来计算每秒任何给定像素可用的平均位数:

const computeVideoQualityScalar = (video: Video): number => {
  // The amount of pixels pushed to the display, per frame.
  const pixelsPerFrame = video.width * video.height
  
  // The amount of pixels pushed to the display, per second.
  const pixelsPerSecond = pixelsPerFrame * video.fps
  
  // The average amount of bits used by each pixel, each second,
  // to convey all data relevant to that pixel (e.g. color data, etc)
  const bitsPerPixelPerSecond = video.bitrate / pixelsPerSecond
  
  return bitsPerPixelPerSecond
}

虽然我的公式确实可以很好地为任何给定视频提供或多或少的“标准化”数学质量评估,但当我尝试使用它来比较不同分辨率的视频时,它就不够用了。例如,一个比特率为 10Mbit/sec 的 1080p60fps 视频比比特率为 9Mbit/sec 的 720p30fps 视频具有更高的视觉保真度(至少,主观上,对我来说是这样),但我的公式会对 720p30fps 视频进行显着评分高于 1080p60fps 视频,因为 720p 视频每像素每秒的可用位数比 1080p 视频多。

我正在努力想出关于如何想出不同的方法来计算给定视频的“主观视频质量”,或者扩展我现有想法的想法。

video ffmpeg video-processing video-encoding videoquality
1个回答
0
投票

视频质量感知是一个非常专业的主题领域,我认为您会发现很难想出一个看起来像您所针对的那样简单的模型。

包括编码方案、内容类型、配色方案等在内的许多因素都会影响质量,并且它会因场景甚至逐帧而异。

该领域有很多现有信息,新兴的 AI/ML 技术可能会提供更好(如果更复杂)的模型来提高预测准确性。

即使您可以逐帧分析视频,无论是与已知质量的原始参考视频进行比较还是没有参考,最好的数学模型通常都不如主观测量,尤其是 MOS(https://en. wikipedia.org/wiki/Mean_opinion_score).

我猜你会发现此时大多数技术都在朝着 AI/ML 方向发展。许多编码器也使用 AI/ML 模型来确定如何对内容中的不同场景或部分进行编码。

我认为您最好的起点可能是查看有关该主题的一些最新研究论文,因为它正在快速发展-例如https://www.mdpi.com/2079-9292/10/22/2851

© www.soinside.com 2019 - 2024. All rights reserved.