Commit b2ea39287527fe984e18df481588043d1b55d9aa
1 parent
e7d8f798
Exists in
master
and in
68 other branches
FIX: Change function name of GetZSpacing to UpdateZSpacing, and fixed bug open dicom
Showing
1 changed file
with
5 additions
and
5 deletions
Show diff stats
invesalius/reader/dicom_grouper.py
| ... | ... | @@ -92,7 +92,7 @@ class DicomGroup: |
| 92 | 92 | list_ = sorted(list_, key = lambda dicom:dicom.image.position[axis]) |
| 93 | 93 | return list_ |
| 94 | 94 | |
| 95 | - def GetZSpacing(self): | |
| 95 | + def UpdateZSpacing(self): | |
| 96 | 96 | list_ = self.GetSortedList() |
| 97 | 97 | |
| 98 | 98 | if (len(list_) > 1): |
| ... | ... | @@ -145,8 +145,8 @@ class PatientGroup: |
| 145 | 145 | # TODO: Optimize recursion |
| 146 | 146 | self.AddFile(dicom, index+1) |
| 147 | 147 | |
| 148 | - #Getting the spacing in the Z axis | |
| 149 | - group.GetZSpacing() | |
| 148 | + #Getting the spacing in the Z axis | |
| 149 | + group.UpdateZSpacing() | |
| 150 | 150 | |
| 151 | 151 | def Update(self): |
| 152 | 152 | # Ideally, AddFile would be sufficient for splitting DICOM |
| ... | ... | @@ -237,14 +237,14 @@ class PatientGroup: |
| 237 | 237 | group.AddSlice(current) |
| 238 | 238 | dict_final[group_counter] = group |
| 239 | 239 | #Getting the spacing in the Z axis |
| 240 | - group.GetZSpacing() | |
| 240 | + group.UpdateZSpacing() | |
| 241 | 241 | else: |
| 242 | 242 | group_counter +=1 |
| 243 | 243 | group = DicomGroup() |
| 244 | 244 | group.AddSlice(current) |
| 245 | 245 | dict_final[group_counter] = group |
| 246 | 246 | #Getting the spacing in the Z axis |
| 247 | - group.GetZSpacing() | |
| 247 | + group.UpdateZSpacing() | |
| 248 | 248 | |
| 249 | 249 | |
| 250 | 250 | return dict_final | ... | ... |