From 38792c07da131aed3170242224d712955c8b923b Mon Sep 17 00:00:00 2001 From: elyz081 Date: Fri, 20 Feb 2026 15:32:16 -0500 Subject: [PATCH 1/2] fix associate_ROI to_image --- MEDiml/wrangling/DataManager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MEDiml/wrangling/DataManager.py b/MEDiml/wrangling/DataManager.py index a8f0035..9d276d7 100644 --- a/MEDiml/wrangling/DataManager.py +++ b/MEDiml/wrangling/DataManager.py @@ -456,7 +456,7 @@ def load_mask(_id, file, medscan): path_roi_data = self.paths._path_to_niftis for file in self.__nifti.stack_path_roi: - _id = image_file.name.split("(")[0] if ("(") in image_file.name else image_file.name # id is PatientID__ImagingScanName + _id = file.name.split("(")[0] if ("(") in file.name else file.name # id is PatientID__ImagingScanName load_mask(_id, file, medscan) roi_index += 1 else: From 52ef3e094671dd40b64faa5a9f9ba24282f8295b Mon Sep 17 00:00:00 2001 From: elyz081 Date: Fri, 20 Feb 2026 15:34:22 -0500 Subject: [PATCH 2/2] medimage -> mediml --- notebooks/tutorial/DataManager-Tutorial.ipynb | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/notebooks/tutorial/DataManager-Tutorial.ipynb b/notebooks/tutorial/DataManager-Tutorial.ipynb index 817e0fc..7a60c55 100644 --- a/notebooks/tutorial/DataManager-Tutorial.ipynb +++ b/notebooks/tutorial/DataManager-Tutorial.ipynb @@ -31,7 +31,7 @@ "## Introduction\n", "\n", "\n", - "This notebook is a tutorial for the *DataManager* class to give a detailed introduction & explanation on how to use this Python class. The *DataManager* class is the main object used in the *MEDimage* package when it comes to processing raw data in NIfTI and DICOM formats. This class can:\n", + "This notebook is a tutorial for the *DataManager* class to give a detailed introduction & explanation on how to use this Python class. The *DataManager* class is the main object used in the *MEDiml* package when it comes to processing raw data in NIfTI and DICOM formats. This class can:\n", " - Create ``MEDscan`` class objects from the raw data and makes the manipulation of these objects easy.\n", " - Help find the proper dimension and re-segmentation ranges options for radiomics analysis by running some pre-computation checks.\n", "\n", @@ -43,7 +43,7 @@ "id": "95b2b171", "metadata": {}, "source": [ - "The ``DataManager`` class is one of the first operation done in the radiomics analysis workflow, because it helps create the ``MEDscan`` class objects which is the main asset used in the *MEDimage* package.\n", + "The ``DataManager`` class is one of the first operation done in the radiomics analysis workflow, because it helps create the ``MEDscan`` class objects which is the main asset used in the *MEDiml* package.\n", "\n", "\n", "\n", @@ -66,7 +66,7 @@ }, { "cell_type": "code", - "execution_count": 1, + "execution_count": null, "id": "af05f061", "metadata": {}, "outputs": [ @@ -81,11 +81,7 @@ "source": [ "import os\n", "import sys\n", - "\n", - "MODULE_DIR = os.path.dirname(os.path.abspath('../MEDimage/'))\n", - "sys.path.append(os.path.dirname(MODULE_DIR))\n", - "\n", - "import MEDimage" + "import MEDiml" ] }, { @@ -591,7 +587,7 @@ }, { "cell_type": "code", - "execution_count": 5, + "execution_count": null, "id": "235fa073", "metadata": {}, "outputs": [], @@ -599,7 +595,7 @@ "path_dicoms_data = Path(os.getcwd()) / \"data\" / \"DICOM-STS\"\n", "path_save = Path(os.getcwd()) / \"data\" / \"npy\"\n", "path_save.mkdir() if not path_save.exists() else path_save\n", - "dm = MEDimage.wrangling.DataManager(path_to_dicoms=path_dicoms_data,\n", + "dm = MEDiml.wrangling.DataManager(path_to_dicoms=path_dicoms_data,\n", " path_save=path_save,\n", " path_csv=path_csv,\n", " n_batch=2)"