We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4523a0d commit 2cc43ebCopy full SHA for 2cc43eb
ads/opctl/operator/lowcode/forecast/model_evaluator.py
@@ -233,6 +233,13 @@ def find_best_model(
233
nonempty_metrics = {
234
model: metric for model, metric in metrics.items() if metric != {}
235
}
236
+ if not nonempty_metrics:
237
+ model = SupportedModels.Prophet
238
+ logger.warning(
239
+ f"No valid metrics calculated for any model. Defaulting to {model}."
240
+ )
241
+ return model
242
+
243
avg_backtests_metric = {
244
model: sum(value.values()) / len(value.values())
245
for model, value in nonempty_metrics.items()
0 commit comments