View Source Evision.Quality.QualityBRISQUE (Evision v0.1.38)

Summary

Types

t()

Type that represents an Quality.QualityBRISQUE struct.

Functions

Computes BRISQUE quality score for input image

static method for computing quality

static method for computing image features used by the BRISQUE algorithm

static method for computing image features used by the BRISQUE algorithm

Variant 1:

Create an object which calculates quality

Types

@type t() :: %Evision.Quality.QualityBRISQUE{ref: reference()}

Type that represents an Quality.QualityBRISQUE struct.

  • ref. reference()

    The underlying erlang resource variable.

Functions

@spec compute(t(), Evision.Mat.maybe_mat_in()) ::
  {number()}
  | {number(), number()}
  | {number(), number(), number()}
  | {number(), number(), number(), number()}
  | {:error, String.t()}

Computes BRISQUE quality score for input image

Positional Arguments
  • self: Evision.Quality.QualityBRISQUE.t()

  • img: Evision.Mat.t().

    Image for which to compute quality

Return
  • retval: cv::Scalar

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

Python prototype (for reference only):

compute(img) -> retval
Link to this function

compute(self, img, model_file_path, range_file_path)

View Source
@spec compute(t(), Evision.Mat.maybe_mat_in(), binary(), binary()) ::
  {number()}
  | {number(), number()}
  | {number(), number(), number()}
  | {number(), number(), number(), number()}
  | {:error, String.t()}

static method for computing quality

Positional Arguments
  • self: Evision.Quality.QualityBRISQUE.t()

  • img: Evision.Mat.t().

    image for which to compute quality

  • model_file_path: String.

    cv::String which contains a path to the BRISQUE model data, eg. /path/to/brisque_model_live.yml

  • range_file_path: String.

    cv::String which contains a path to the BRISQUE range data, eg. /path/to/brisque_range_live.yml

Return
  • retval: cv::Scalar

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

Python prototype (for reference only):

compute(img, model_file_path, range_file_path) -> retval
@spec computeFeatures(Evision.Mat.maybe_mat_in()) ::
  Evision.Mat.t() | {:error, String.t()}

static method for computing image features used by the BRISQUE algorithm

Positional Arguments
  • img: Evision.Mat.t().

    image (BGR(A) or grayscale) for which to compute features

Return
  • features: Evision.Mat.t().

    output row vector of features to cv::Mat or cv::UMat

Python prototype (for reference only):

computeFeatures(img[, features]) -> features
Link to this function

computeFeatures(img, opts)

View Source
@spec computeFeatures(Evision.Mat.maybe_mat_in(), [{atom(), term()}, ...] | nil) ::
  Evision.Mat.t() | {:error, String.t()}

static method for computing image features used by the BRISQUE algorithm

Positional Arguments
  • img: Evision.Mat.t().

    image (BGR(A) or grayscale) for which to compute features

Return
  • features: Evision.Mat.t().

    output row vector of features to cv::Mat or cv::UMat

Python prototype (for reference only):

computeFeatures(img[, features]) -> features
@spec create(Evision.ML.SVM.t(), Evision.Mat.maybe_mat_in()) ::
  t() | {:error, String.t()}
@spec create(binary(), binary()) :: t() | {:error, String.t()}

Variant 1:

Create an object which calculates quality

Positional Arguments
  • model: ml::SVM.

    cv::Ptr<cv::ml::SVM> which contains a loaded BRISQUE model

  • range: Evision.Mat.t().

    cv::Mat which contains BRISQUE range data

Return
  • retval: QualityBRISQUE

Python prototype (for reference only):

create(model, range) -> retval

Variant 2:

Create an object which calculates quality

Positional Arguments
  • model_file_path: String.

    cv::String which contains a path to the BRISQUE model data, eg. /path/to/brisque_model_live.yml

  • range_file_path: String.

    cv::String which contains a path to the BRISQUE range data, eg. /path/to/brisque_range_live.yml

Return
  • retval: QualityBRISQUE

Python prototype (for reference only):

create(model_file_path, range_file_path) -> retval