-
Notifications
You must be signed in to change notification settings - Fork 9
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
No metrics property on the comparer/collection #356
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly good, but we need to do something about the handling of default metrics for directional data.
How about defining a property on Comparer and Collection:
@property
def _default_metrics(self):
default_metrics = [mtr.c_bias, mtr.c_rmse, mtr.c_urmse, mtr.c_max_error] if self.quantity.is_directional else None
return default_metrics
and then do this in skill() and similar methods:
metrics = _parse_metric(metrics, default_metrics=self.default_metrics, return_list=True)
Or maybe passing is_directional to the _parse_metric function. I think we should have a better solution in the long run - maybe we should have a ms.options.metrics.list_directional along side with the current ms.options.metrics.list 🤔 |
See update... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Almost there, just need to allow user to define default metrics like this (see the failing notebook):
ms.options.metrics.list = ["kge", "cc"]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now fixed
The only drawback is the need to explicitly set metrics on directional data (for now).