[][src]Struct opencv::quality::QualityBRISQUE

pub struct QualityBRISQUE { /* fields omitted */ }

BRISQUE (Blind/Referenceless Image Spatial Quality Evaluator) is a No Reference Image Quality Assessment (NR-IQA) algorithm.

BRISQUE computes a score based on extracting Natural Scene Statistics (https://en.wikipedia.org/wiki/Scene_statistics) and calculating feature vectors. See Mittal et al. Mittal2 for original paper and original implementation Mittal2_software .

A trained model is provided in the /samples/ directory and is trained on the LIVE-R2 database Sheikh as in the original implementation. When evaluated against the TID2008 database Ponomarenko , the SROCC is -0.8424 versus the SROCC of -0.8354 in the original implementation. C++ code for the BRISQUE LIVE-R2 trainer and TID2008 evaluator are also provided in the /samples/ directory.

Implementations

impl QualityBRISQUE[src]

impl QualityBRISQUE[src]

pub fn create(
    model_file_path: &str,
    range_file_path: &str
) -> Result<Ptr<QualityBRISQUE>>
[src]

Create an object which calculates quality

Parameters

  • model_file_path: cv::String which contains a path to the BRISQUE model data, eg. /path/to/brisque_model_live.yml
  • range_file_path: cv::String which contains a path to the BRISQUE range data, eg. /path/to/brisque_range_live.yml

pub fn create_1(
    model: &Ptr<dyn SVM>,
    range: &Mat
) -> Result<Ptr<QualityBRISQUE>>
[src]

Create an object which calculates quality

Parameters

  • model: cv::Ptrcv::ml::SVM which contains a loaded BRISQUE model
  • range: cv::Mat which contains BRISQUE range data

pub fn compute(
    img: &dyn ToInputArray,
    model_file_path: &str,
    range_file_path: &str
) -> Result<Scalar>
[src]

static method for computing quality

Parameters

  • img: image for which to compute quality
  • model_file_path: cv::String which contains a path to the BRISQUE model data, eg. /path/to/brisque_model_live.yml
  • range_file_path: cv::String which contains a path to the BRISQUE range data, eg. /path/to/brisque_range_live.yml

Returns

cv::Scalar with the score in the first element. The score ranges from 0 (best quality) to 100 (worst quality)

pub fn compute_features(
    img: &dyn ToInputArray,
    features: &mut dyn ToOutputArray
) -> Result<()>
[src]

static method for computing image features used by the BRISQUE algorithm

Parameters

  • img: image (BGR(A) or grayscale) for which to compute features
  • features: output row vector of features to cv::Mat or cv::UMat

Trait Implementations

impl AlgorithmTrait for QualityBRISQUE[src]

impl Boxed for QualityBRISQUE[src]

impl Drop for QualityBRISQUE[src]

impl QualityBRISQUETrait for QualityBRISQUE[src]

impl QualityBase for QualityBRISQUE[src]

impl Send for QualityBRISQUE[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.