Actions
Bug #1850
closedSprint #1835: Sprint20210825
Sprint #1836: Autoregistration
Sprint #1837: Bug Fixing
SPRINT20210825 - Update_Views Throws Error
Status:
Closed
Priority:
Normal
Assignee:
-
Description
Summary¶
The program crashes after the user selects a 'Change Window' from the dropdown menu.
Steps to Reproduce¶
- Open Program
- Select Patient Image
- Change Window
Expected Results¶
Change the Window of the images.
Actual Results¶
Program crashes.
Additional Information¶
Source Code can be found here
https://github.com/Alamancy/OnkoDICOM/blob/PQ-branch/src/View/mainpage/MainPage.py
This code was implemented after implementation of image fusion.
def update_views(self):
"""
This function is a slot for signals to request the updating of the DICOM View and DVH tabs in order to reflect
changes made by other components of the main window (for example, when a structure in the structures tab is
selected, this method needs to be called in order for the DICOM view window to be updated to show the new
region of interest.
"""
self.image_fusion_view_single_view.update_view(color=True)
self.image_fusion_view_view_axial.update_view(color=True)
self.image_fusion_view_view_coronal.update_view(color=True)
self.image_fusion_view_view_sagittal.update_view(color=True)
Files
Updated by Peter Qian almost 4 years ago
Updated by Peter Qian almost 4 years ago
Output Results
(venv) E:\Coding Projects\OnkoDICOM-Alamancy-20-8>python main.py
E:\Coding Projects\OnkoDICOM-Alamancy-20-8\venv\lib\site-packages\fuzzywuzzy\fuzz.py:11: UserWarning: Using slow pure-python SequenceMatcher. Install python-Levenshtein to remove this warning
warnings.warn('Using slow pure-python SequenceMatcher. Install python-Levenshtein to remove this warning')
PDPI: 93.29868532778966
Multithreading with maximum 8 threads
QCoreApplication::exec: The event loop is already running
<class 'AttributeError'> 'MainWindow' object has no attribute 'image_fusion_view_single_view' <traceback object at 0x0000024893BFFC80>
Traceback (most recent call last):
File "E:\Coding Projects\OnkoDICOM-Alamancy-20-8\src\Controller\ActionHandler.py", line 243, in handler
self.windowing_handler(state, text_)
File "E:\Coding Projects\OnkoDICOM-Alamancy-20-8\src\Controller\ActionHandler.py", line 309, in windowing_handler
self.__main_page.update_views()
File "E:\Coding Projects\OnkoDICOM-Alamancy-20-8\src\View\mainpage\MainPage.py", line 218, in update_views
self.image_fusion_view_single_view.update_view(color=True)
AttributeError: 'MainWindow' object has no attribute 'image_fusion_view_single_view'
Updated by Joshua Thomas almost 4 years ago
Windowing has not been implemented for image fusion yet
Updated by Joshua Thomas almost 4 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
These fixes are on Jt-branch, but for specific fixes
line 239-243
# self.image_fusion_view_single_view.update_view(color=True)
if hasattr(self, 'image_fusion_view'):
self.image_fusion_view_axial.update_view(color=True)
self.image_fusion_view_coronal.update_view(color=True)
self.image_fusion_view_sagittal.update_view(color=True)
Actions