What is the requirement of opinionScores for fitbrisque?

In the example:
the opinionScores is set to random numbers in the range of [0 100], no problem. However, when modifing this to any identical values in the range [0 100], such as
opinionScores = 50*ones(1,size(imds.Files,1))
it showed error:
model = fitbrisque(imds,opinionScores')
Error using brisqueModel
Expected Alpha to be nonempty.
Error in brisqueModel>validateAlpha (line 298)
validateattributes(Alpha,images.internal.iptnumerictypes,{'nonempty','real', 'column' ...
Error in brisqueModel (line 135)
validateAlpha(Alpha);
Error in brisqueModel.computeBRISQUEModel (line 222)
obj = brisqueModel(svrmdl.Alpha, svrmdl.Bias, svrmdl.SupportVectors, svrmdl.KernelParameters.Scale);
Error in fitbrisque (line 87)
model = brisqueModel.computeBRISQUEModel(options.IMDS, options.SCORES);
How to implement the opinionScores values other than random?
Thanks.

回答 (1 件)

Walter Roberson
Walter Roberson 2024 年 2 月 29 日

0 投票

It looks to me as if that should only happen if imds is empty.

6 件のコメント

John
John 2024 年 2 月 29 日
imds is not empty. As soon as the opinionScores changes back to
opinionScores = 100*rand(1,size(imds.Files,1))
everything works fine.
Walter Roberson
Walter Roberson 2024 年 2 月 29 日
It would help to have the content of imds to test with.
John
John 2024 年 3 月 2 日
移動済み: Walter Roberson 2024 年 3 月 2 日
MatLab example, link in the question.
Walter Roberson
Walter Roberson 2024 年 3 月 2 日
classreg.learning.svmutils.cpu.solve is a built-in function, and is returning alpha all 0 for the case of opinionScores being all the same.
A step in SVMImpl eliminates the alpha that are 0. With all the alpha having been returned as 0, that results in all the alpha being removed.
After that, brisqueModel complains that the alpha is empty.
Unfortunately, we cannot chase classreg.learning.svmutils.cpu.solve further.
John
John 2024 年 3 月 2 日
In this case, how to set the values other than random?
Walter Roberson
Walter Roberson 2024 年 3 月 2 日
If even one of the opinionScores is set differently by at least 0.25 then it works.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeHolidays / Seasons についてさらに検索

製品

リリース

R2021b

質問済み:

2024 年 2 月 23 日

コメント済み:

2024 年 3 月 2 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by