MIA is a software that allows to anonymize medical images in DICOM format (.dcm) and convert them to NIFTI format (.nii).
The listed requirements can be installed with the command "pip install [package name]", make sure you have the latest version of pip installed.
You can upgrade pip using:
python -m pip install --upgrade pip
Software | Instalation Command |
---|---|
dicognito | pip install dicognito |
nibabel | pip install nibabel |
itk | pip install itk |
numpy | pip install numpy |
dicom-numpy | pip install dicom-numpy |
medio | pip install medio |
- Clone or download the repo.
- Enter to the folder
- Run the main.py file with the command:
python main.py [args]
Argument | Function |
---|---|
-h, --help | show a help message and exit |
-dir, --directory | Path to the folder where the images are located, by default is ./ |
-out, --output | Path to the folder where the images are located, by default is ./output/ |
-ext --extension | The extension of medical images you are looking to anonimize, by default is .dcm |
-C, --convert | Boolean value which defines if converts the images to nifti by default is False |
-A, --anonymize | Boolean value which defines if anonymize the images or not by default is False |
Supose there is a folder aside the main.py file called "images" to anonymize these image you should run either:
python main.py -A
python main.py --anonymize
Supose there is a folder in your desktop (~/usr/desktop/) called "images", which contains the images to anonymize, you should then run either:
python main.py -dir "~/usr/desktop/images" -A
python main.py -dir "~/usr/desktop/images" --anonymize
Supose there is a folder in your desktop (~/usr/desktop/) called "images", which contains the images to anonymize, and you want then to output in your documents (~/usr/documents/), you should then run either:
python main.py -dir "~/usr/desktop/images" -out "~/usr/documents/" -A
python main.py -dir "~/usr/desktop/images" -out "~/usr/documents/" --anonymize
Supose there is a folder aside the main.py file called "images" to anonymize and convert these image you should run either:
python main.py -A -C
python main.py --anonymize --convert