From 869c0b3ee6791419c309f90de1002cbee06d7218 Mon Sep 17 00:00:00 2001 From: Mihir Patel Date: Mon, 27 Feb 2023 17:48:52 -0800 Subject: [PATCH 1/2] add fix --- examples/medical_image_segmentation.ipynb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/medical_image_segmentation.ipynb b/examples/medical_image_segmentation.ipynb index 820979f523..6249821ee8 100644 --- a/examples/medical_image_segmentation.ipynb +++ b/examples/medical_image_segmentation.ipynb @@ -579,7 +579,7 @@ "\n", " def get_metrics(self, is_train: bool = False):\n", " if self.is_train:\n", - " return {'BCEWithLogitsLoss', self.train_loss}\n", + " return {'BCEWithLogitsLoss': self.train_loss}\n", " else:\n", " return {'BCEWithLogitsLoss': self.val_loss, 'Dice': self.dice}" ] From ec1e06ff443dac990b2c7d6efe19b58588407448 Mon Sep 17 00:00:00 2001 From: Mihir Patel Date: Mon, 27 Feb 2023 17:49:11 -0800 Subject: [PATCH 2/2] add fix --- examples/medical_image_segmentation.ipynb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/medical_image_segmentation.ipynb b/examples/medical_image_segmentation.ipynb index 6249821ee8..25b3bb15cd 100644 --- a/examples/medical_image_segmentation.ipynb +++ b/examples/medical_image_segmentation.ipynb @@ -578,7 +578,7 @@ " return self.criterion(outputs, targets)\n", "\n", " def get_metrics(self, is_train: bool = False):\n", - " if self.is_train:\n", + " if is_train:\n", " return {'BCEWithLogitsLoss': self.train_loss}\n", " else:\n", " return {'BCEWithLogitsLoss': self.val_loss, 'Dice': self.dice}"