fix(scripts): improve MSE logging in release tests
This commit is contained in:
parent
34493e7968
commit
8df6ec231f
|
@ -476,11 +476,12 @@ def run_test(
|
||||||
ref = Image.open(ref_name) if path.exists(ref_name) else None
|
ref = Image.open(ref_name) if path.exists(ref_name) else None
|
||||||
|
|
||||||
mse = find_mse(result, ref)
|
mse = find_mse(result, ref)
|
||||||
|
threshold = test.mse_threshold * mse_mult
|
||||||
|
|
||||||
if mse < (test.mse_threshold * mse_mult):
|
if mse < threshold:
|
||||||
logger.info("MSE within threshold: %.5f < %.5f", mse, test.mse_threshold)
|
logger.info("MSE within threshold: %.5f < %.5f", mse, threshold)
|
||||||
else:
|
else:
|
||||||
logger.warning("MSE above threshold: %.5f > %.5f", mse, test.mse_threshold)
|
logger.warning("MSE above threshold: %.5f > %.5f", mse, threshold)
|
||||||
passed = False
|
passed = False
|
||||||
|
|
||||||
return passed
|
return passed
|
||||||
|
|
Loading…
Reference in New Issue