Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 28 additions & 21 deletions preprocessing/preprocessing_tutorial.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,13 @@
"source": [
"\n",
"### Setup Colab environment\n",
"If you installed the packages and requirements on your own machine, you can skip this section and start from the import section. Otherwise you can follow and execute the tutorial on your browser. In order to start working on the notebook, click on the following button, this will open this page in the Colab environment and you will be able to execute the code on your own.\n",
"If you installed the packages and requirements on your own machine, you can skip this section and start from the import section. Otherwise, you can follow and execute the tutorial on your browser. In order to start working on the notebook, click on the following button, this will open this page in the Colab environment and you will be able to execute the code on your own.\n",
"\n",
"<a target=\"_blank\" href=\"https://colab.research.google.com/github/BrainLesion/tutorials/blob/main/preprocessing/preprocessing_tutorial.ipynb\">\n",
" <img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/>\n",
"</a>\n",
"\n",
"Now that you are visualizing the notebook in Colab, run the next cell to install the packages we will use. There are few things you should follow in order to properly set the notebook up:\n",
"Now that you are visualizing the notebook in Colab, run the next cell to install the packages we will use. There are a few things you should follow in order to properly set the notebook up:\n",
"1. Warning: This notebook was not authored by Google. Click on 'Run anyway'.\n",
"1. When the installation commands are done, there might be \"Restart runtime\" button at the end of the output. Please, click it.\n"
]
Expand Down Expand Up @@ -178,31 +178,38 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"### Imports"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Raw Input data\n",
"TODO describe raw input data. Two exams from TCIA/TCGA with T1, T1c, T2, T2-FLAIR with skull etc.\n",
"TODO visualize it"
"## Import raw input data\n",
"\n",
"Raw input data require\n",
"- exam with skull and 4 sequences (T1, T1c, T2, T2-FLAIR), only one file each (in total 4 files) \n",
" - file names must end with \"*t1.nii.gz\", \"*t1c.nii.gz\", \"*t2.nii.gz\" and \"*fla.nii.gz\"\n",
" - [Nifti \".nii.gz\"](https://brainder.org/2012/09/23/the-nifti-file-format/) file type \n",
"- Each exam (4 files) needs to be placed in an individual folder within the data folder \n",
"```<this repository>/preprocessing/data/```. \n",
"\n",
"The structure is shown using two example exams:\n",
"```\n",
"preprocessing\n",
"├── data\n",
"│ ├── TCGA-DU-7294\n",
"│ │ ├── *_t1c.nii.gz\n",
"│ │ ├── *_t1.nii.gz\n",
"│ │ ├── *_t2.nii.gz\n",
"│ │ ├── *_fla.nii.gz\n",
"│ ├── OtherEXampleFromTCIA\n",
"│ │ ├── *_t1c.nii.gz\n",
"│ │ ├── *_t1.nii.gz\n",
"│ │ ├── *_t2.nii.gz\n",
"│ │ ├── *_fla.nii.gz\n",
"```\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Preprocessing\n",
"BraTS challenge algorithms expect co-registered, skullstripped files in SRI-24 space, to achieve this preprocessing is required.\n",
"BraTS challenge algorithms expect co-registered, skull-stripped files in SRI-24 space, to achieve this preprocessing is required.\n",
"Instead of using the vanilla preprocessing pipeline from BraTS Toolkit, we recommend using the new [BrainLes preprocessing package](https://github.com/BrainLesion/preprocessing/tree/main/brainles_preprocessing).\n",
"\n",
"<!-- For more details about preprocessing see the dedicated tutorial at TODO -->"
Expand All @@ -212,7 +219,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"First, we define a function that procoesses an exam."
"First, we define a function that processes an exam."
]
},
{
Expand Down