Skip to content

C++ implementation of Bjontegaard Delta SNR and Delta Rate metric

License

Notifications You must be signed in to change notification settings

tbr/bjontegaard_cpp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bjontegaard Metric implementation for C++17 (or later).

Description:

This project contains an implementation of the Bjontegaard metric to calculate Delta SNR and Delta Rate, using arbitrary number of data points. The calculated results comply with VCEG-M33 when using 4 data points. This code relies on the Eigen3 library to perform the polynomial fitting of curves.

The library provides two functions (see bdcpp.h for type details):

value_type bdsnr(const curve_data_type& curveA, const curve_data_type& curveB, const int polyOrder = 3);

value_type bdbr(const curve_data_type& curveA, const curve_data_type& curveB, const int polyOrder = 3);

Normally, curve fitting is done using a 3rd order polynomial, however this code can also do higher order approximations to improve precision.

Note: This code is a port of the original VBA implementation (see Bjontegaard ETRO project) to C++.

Building:

No special steps are required.

The example build uses Conan and CMake. Create a build folder and from there issue:

conan install <path_to_source_root> -s build_type=Release
conan install <path_to_source_root> -s build_type=Debug
cmake <path_to_source_root>

Author:

Tim Bruylants

License:

MIT license, see included LICENSE.txt file.

References:

[1] G. Bjontegaard, Calculation of average PSNR differences between RD-curves (VCEG-M33)

Copyright (C) 2022 Tim Bruylants.

About

C++ implementation of Bjontegaard Delta SNR and Delta Rate metric

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published