반응형 preprocessing2 DICOM preprocessing [python code] # # Loop over the image files and store everything into a list. # def load_scan(path): slices = [dicom.read_file(path + '/' + s) for s in os.listdir(path)] slices.sort(key = lambda x: int(x.InstanceNumber)) try: slice_thickness = np.abs(slices[0].ImagePositionPatient[2] - slices[1].ImagePositionPatient[2]) except: slice_thickness = np.abs(slices[0].SliceLocation - slices[1].SliceLo.. 2022. 2. 14. DICOM meta data 사용한 속성 정리 1. Instance Number Attribute TagTypeKeywordValue MultiplicityValue RepresentationExample Values (0020,0013) Required, Empty if Unknown (2) InstanceNumber 1 Integer String (IS) 1 2 41 A number that identifies this image. Note This Attribute was named Image Number in earlier versions of this Standard. 2. Image Position (Patient) Attribute TagTypeKeywordValue MultiplicityValue RepresentationExample.. 2022. 2. 14. 이전 1 다음 728x90 반응형