From 3561357e9c80f4699acea9cfd207441dab83f3bf Mon Sep 17 00:00:00 2001 From: Benjamin Kiessling Date: Mon, 30 Sep 2024 14:26:34 +0200 Subject: [PATCH] typo in min cost selection --- kraken/lib/train/segmentation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kraken/lib/train/segmentation.py b/kraken/lib/train/segmentation.py index 4dfa610e..48b3e30c 100644 --- a/kraken/lib/train/segmentation.py +++ b/kraken/lib/train/segmentation.py @@ -279,7 +279,7 @@ def validation_step(self, batch, batch_idx): if pred_curves: pred_curves = torch.stack(pred_curves) cost_curves = torch.cdist(pred_curves, target_curves, p=1).cpu() - costs = cost_curves = [linear_sum_assignment(cost_curves)] + costs = cost_curves[linear_sum_assignment(cost_curves)] # num of predictions differs from target -> take n best # predictions and add error penalty term for the rest. if diff := abs(len(pred_curves) - len(target_curves)):