dicom_to_cnn.tools.export_segmentation package

Submodules

dicom_to_cnn.tools.export_segmentation.generate_dict module

dicom_to_cnn.tools.export_segmentation.generate_dict.generate_dict(number_of_roi: int, name: str, serie_description: str, body_part: str, roi_name: dict, interpreted_type: Optional[dict] = None) dict

a function to generate a dict with informations to generate DICOM SEG or DICOM RTSTRUCT file ! no more than 16 characters for each informations !

Args:

number_of_roi ([int]): [Total number of ROI in dicom file ] mode ([str]): [‘rtstruct’ or ‘dicomseg’]

Returns:

[dict]: [return dict with informations about ROI in it ]

dicom_to_cnn.tools.export_segmentation.generate_dict.save_dict_as_json(results: dict, directory: str) str

a function to save the dict generated by ‘generate_dict’ function above

Args:

results ([dict]): [Dictionnary generated by ‘generate_dict’ function ] directory ([str]): [Name of directory to save the dict as json file ]

Returns:

[str]: [return the path name of the json file]

Module contents