Skip to content

Commit 934ce3b

Browse files
committed
Merge pull request #2251 from clunietp:quality_issue_2226
2 parents b72dc5e + ea84c59 commit 934ce3b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/quality/src/qualitybrisque.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ namespace
230230

231231
cv::Mat result;
232232
model->predict(feat_mat, result);
233-
return result.at<float>(0);
233+
return std::min( std::max( result.at<float>(0), 0.f ), 100.f ); // clamp to [0-100]
234234
}
235235

236236
// computes score for a single frame

0 commit comments

Comments
 (0)