Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EarlyStopper cannot deal with complex Metrics #2413

Open
priba opened this issue Aug 4, 2023 · 1 comment
Open

EarlyStopper cannot deal with complex Metrics #2413

priba opened this issue Aug 4, 2023 · 1 comment
Labels
enhancement New (engineering) enhancements, such as features or API changes.

Comments

@priba
Copy link
Contributor

priba commented Aug 4, 2023

🚀 Feature Request

EarlyStopper and ThresholdStopper cannot deal with complex Metrics such as MAP.

See:

if not torch.is_tensor(metric_val):

if not torch.is_tensor(metric_val):

This line should only convert the metric to a tensor if it is a numeric value.
For complex metrics, we should either rely on self.comp_func and some distance metric or allow some way to extract the desired value in self.monitor. Otherwise it will also crash here when checking the absolute distance.

elif self.comp_func(metric_val, self.best) and torch.abs(metric_val - self.best) > self.min_delta:

Motivation

Metrics for object detection come as a dictionary. See MAP.

@priba priba added the enhancement New (engineering) enhancements, such as features or API changes. label Aug 4, 2023
@mvpatel2000
Copy link
Contributor

Apolgoies for the delayed response. We are tracking this issue, but it is unfortunately not in our immediate roadmap. We welcome community PRs on this subject :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New (engineering) enhancements, such as features or API changes.
Projects
None yet
Development

No branches or pull requests

2 participants