From 2bcf66604b30dcde98565854d5f36026c19f580a Mon Sep 17 00:00:00 2001 From: RicardoRei Date: Mon, 8 Jan 2024 14:08:04 +0000 Subject: [PATCH] Fix attribute error and multigpu inference (#177, #178) --- comet/models/predict_writer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comet/models/predict_writer.py b/comet/models/predict_writer.py index 7adde1c..7d95989 100644 --- a/comet/models/predict_writer.py +++ b/comet/models/predict_writer.py @@ -86,7 +86,7 @@ def flatten(list): def flatten_predictions(predictions): flatten_pred = Prediction( - scores=torch.cat([pred.scores for pred in predictions], dim=0) + scores=torch.cat([pred["scores"] for pred in predictions], dim=0) ) if "metadata" in predictions[0]: flatten_pred["metadata"] = flatten_metadata(