diff --git a/GANDLF/metrics/segmentation_panoptica.py b/GANDLF/metrics/segmentation_panoptica.py index c41deea6f..8979dc7cf 100644 --- a/GANDLF/metrics/segmentation_panoptica.py +++ b/GANDLF/metrics/segmentation_panoptica.py @@ -1,4 +1,5 @@ from pathlib import Path +import os from typing import Optional import numpy as np @@ -19,12 +20,15 @@ def generate_instance_segmentation( prediction (np.ndarray): The input prediction containing objects. label_path (str): The path to the reference label. target (np.ndarray): The input target containing objects. + parameters (dict): The GaNDLF parameters from which panoptica config is to be extracted. panoptica_config_path (str): The path to the Panoptica configuration file. Returns: dict: The evaluation results. """ + os.environ["PANOPTICA_CITATION_REMINDER"] = "False" + # the parameters dict takes precedence over the panoptica_config_path evaluator = parameters.get("panoptica_config", None) if evaluator is None: diff --git a/GANDLF/version.py b/GANDLF/version.py index 5888063de..6247f9bd5 100644 --- a/GANDLF/version.py +++ b/GANDLF/version.py @@ -2,4 +2,4 @@ # -*- coding: UTF-8 -*- # check GaNDLF wiki for versioning and release guidelines: https://github.com/mlcommons/GaNDLF/wiki -__version__ = "0.1.4-dev" +__version__ = "0.1.4" diff --git a/samples/config_all_options.yaml b/samples/config_all_options.yaml index c832adec2..192148e20 100644 --- a/samples/config_all_options.yaml +++ b/samples/config_all_options.yaml @@ -1,8 +1,8 @@ # affix version version: { - minimum: 0.1.4-dev, - maximum: 0.1.4-dev # this should NOT be made a variable, but should be tested after every tag is created + minimum: 0.1.4, + maximum: 0.1.4 # this should NOT be made a variable, but should be tested after every tag is created } ## Choose the model parameters here model: diff --git a/samples/config_classification.yaml b/samples/config_classification.yaml index 8b23f9075..fcc01f70f 100644 --- a/samples/config_classification.yaml +++ b/samples/config_classification.yaml @@ -1,8 +1,8 @@ # affix version version: { - minimum: 0.1.4-dev, - maximum: 0.1.4-dev # this should NOT be made a variable, but should be tested after every tag is created + minimum: 0.1.4, + maximum: 0.1.4 # this should NOT be made a variable, but should be tested after every tag is created } # Choose the model parameters here model: diff --git a/samples/config_getting_started_classification_histo2d.yaml b/samples/config_getting_started_classification_histo2d.yaml index 48883e087..f86c17af9 100644 --- a/samples/config_getting_started_classification_histo2d.yaml +++ b/samples/config_getting_started_classification_histo2d.yaml @@ -94,6 +94,6 @@ scheduler: track_memory_usage: false verbose: false version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: true diff --git a/samples/config_getting_started_classification_rad3d.yaml b/samples/config_getting_started_classification_rad3d.yaml index 3653fa48c..e187f485f 100644 --- a/samples/config_getting_started_classification_rad3d.yaml +++ b/samples/config_getting_started_classification_rad3d.yaml @@ -99,6 +99,6 @@ scheduler: track_memory_usage: false verbose: false version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: true diff --git a/samples/config_getting_started_regression_histo2d.yaml b/samples/config_getting_started_regression_histo2d.yaml index b540c4791..a211b850e 100644 --- a/samples/config_getting_started_regression_histo2d.yaml +++ b/samples/config_getting_started_regression_histo2d.yaml @@ -59,6 +59,6 @@ scheduler: track_memory_usage: false verbose: false version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: true diff --git a/samples/config_getting_started_regression_rad3d.yaml b/samples/config_getting_started_regression_rad3d.yaml index d3e517877..fa566c47f 100644 --- a/samples/config_getting_started_regression_rad3d.yaml +++ b/samples/config_getting_started_regression_rad3d.yaml @@ -62,6 +62,6 @@ scheduler: track_memory_usage: false verbose: false version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: false diff --git a/samples/config_getting_started_segmentation_histo2d.yaml b/samples/config_getting_started_segmentation_histo2d.yaml index e1e43226a..79f40e787 100644 --- a/samples/config_getting_started_segmentation_histo2d.yaml +++ b/samples/config_getting_started_segmentation_histo2d.yaml @@ -66,6 +66,6 @@ scheduler: track_memory_usage: false verbose: true version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: true diff --git a/samples/config_regression.yaml b/samples/config_regression.yaml index 149b01869..f8534d658 100644 --- a/samples/config_regression.yaml +++ b/samples/config_regression.yaml @@ -1,8 +1,8 @@ # affix version version: { - minimum: 0.1.4-dev, - maximum: 0.1.4-dev # this should NOT be made a variable, but should be tested after every tag is created + minimum: 0.1.4, + maximum: 0.1.4 # this should NOT be made a variable, but should be tested after every tag is created } # Choose the model parameters here model: diff --git a/samples/config_segmentation_brats.yaml b/samples/config_segmentation_brats.yaml index 05e2b4c6c..54cfe0b06 100644 --- a/samples/config_segmentation_brats.yaml +++ b/samples/config_segmentation_brats.yaml @@ -1,8 +1,8 @@ # affix version version: { - minimum: 0.1.4-dev, - maximum: 0.1.4-dev # this should NOT be made a variable, but should be tested after every tag is created + minimum: 0.1.4, + maximum: 0.1.4 # this should NOT be made a variable, but should be tested after every tag is created } # Choose the model parameters here model: diff --git a/samples/config_segmentation_histology.yaml b/samples/config_segmentation_histology.yaml index 64cb3bd51..b999b5f83 100644 --- a/samples/config_segmentation_histology.yaml +++ b/samples/config_segmentation_histology.yaml @@ -1,8 +1,8 @@ # affix version version: { - minimum: 0.1.4-dev, - maximum: 0.1.4-dev # this should NOT be made a variable, but should be tested after every tag is created + minimum: 0.1.4, + maximum: 0.1.4 # this should NOT be made a variable, but should be tested after every tag is created } # Choose the model parameters here model: diff --git a/samples/config_segmentation_metrics_brats_default.yaml b/samples/config_segmentation_metrics_brats_default.yaml index b7f25eba9..474737946 100644 --- a/samples/config_segmentation_metrics_brats_default.yaml +++ b/samples/config_segmentation_metrics_brats_default.yaml @@ -144,18 +144,21 @@ panoptica_config: !Panoptica_Evaluator save_group_times: false segmentation_class_groups: !SegmentationClassGroups groups: - ed: !LabelGroup + snfh: !LabelGroup single_instance: false value_labels: [2] et: !LabelGroup single_instance: false value_labels: [3] - net: !LabelGroup + netc: !LabelGroup single_instance: false value_labels: [1] + rc: !LabelGroup + single_instance: false + value_labels: [4] tc: !LabelMergeGroup single_instance: false - value_labels: [1, 3] + value_labels: [1, 3, 4] wt: !LabelMergeGroup single_instance: false value_labels: [1, 2, 3, 4] diff --git a/testing/config_classification.yaml b/testing/config_classification.yaml index b935f83e4..a11a802f4 100644 --- a/testing/config_classification.yaml +++ b/testing/config_classification.yaml @@ -55,7 +55,7 @@ save_output: false scaling_factor: 1 scheduler: triangle version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: True diff --git a/testing/config_regression.yaml b/testing/config_regression.yaml index 3784c1c33..209a6656b 100644 --- a/testing/config_regression.yaml +++ b/testing/config_regression.yaml @@ -38,7 +38,7 @@ save_output: false scaling_factor: 1 scheduler: triangle version: - maximum: 0.1.4-dev + maximum: 0.1.4 minimum: 0.0.14 weighted_loss: false diff --git a/testing/config_segmentation.yaml b/testing/config_segmentation.yaml index 8b4726388..8f96b93bf 100644 --- a/testing/config_segmentation.yaml +++ b/testing/config_segmentation.yaml @@ -3,7 +3,7 @@ version: { minimum: 0.0.14, - maximum: 0.1.4-dev + maximum: 0.1.4 } model: {