mednist_ddpm / scripts /__init__.py
project-monai's picture
Upload mednist_ddpm version 1.0.1
57decc6 verified
raw
history blame contribute delete
430 Bytes
from __future__ import annotations
def inv_metric_cmp_fn(current_metric: float, prev_best: float) -> bool:
"""
This inverts comparison for those metrics which reduce like loss values, such that the lower one is better.
Args:
current_metric: metric value of current round computation.
prev_best: the best metric value of previous rounds to compare with.
"""
return current_metric < prev_best