unravel.image_tools.atlas.relabel_nii module#
Use atlas_relabel
(relabel
) from UNRAVEL to convert intensities (e.g., atlas label IDs) based on a CSV.
- Inputs:
old_image.nii.gz: Lable image with original intensities.
input.csv: CSV with old IDs in column 1 and new IDs in column 2.
- Outputs:
new_image.nii.gz: Image with relabeled intensities.
relabel_nii_volume_summary_old_labels.csv: Summary of the volume for each label before the replacement.
relabel_nii_volume_summary_new_labels.csv: Summary of the volume for each label after the replacement.
Usage:#
atlas_relabel -i path/old_image.nii.gz -o path/new_image.nii.gz -ci path/input.csv [-vols] [-odt uint16] [-v]