Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

image_viewer: Fix error after image load #2168

Merged
merged 2 commits into from
Jul 20, 2022

Conversation

ndevenish
Copy link
Member

If loading images by pressing the "Load Image" button, or remotely via the ZeroMQ API, these didn't have the detector projection precalculated, so threw an AttributeError when trying to navigate:

Traceback (most recent call last):
  File "/dls/science/users/mep23677/dist/modules/dials/src/dials/util/image_viewer/spotfinder_frame.py", line 2759, in OnDispersionThresholdDebug
    self.GetParent().GetParent().show_filters()
  File "/dls/science/users/mep23677/dist/modules/dials/src/dials/util/image_viewer/spotfinder_frame.py", line 1214, in show_filters
    self.pyslip.tiles.set_image_data(image_data, show_saturated)
  File "/dls/science/users/mep23677/dist/modules/dials/src/dials/util/image_viewer/slip_viewer/tile_generation.py", line 96, in set_image_data
    self.flex_image = get_flex_image_multipanel(
  File "/dls/science/users/mep23677/dist/modules/dials/src/dials/util/image_viewer/slip_viewer/flex_image.py", line 131, in get_flex_image_multipanel
    origin_2d, fast_2d, slow_2d = detector.projection_2d_axes
AttributeError: 'Detector' object has no attribute 'projection_2d_axes'

Reproducible by opening one image via command line, then a second with "Load image", and trying to navigate between them.

ndevenish and others added 2 commits July 13, 2022 21:01
If loading images by pressing the "Load Image"
button, or remotely via the ZeroMQ API, these
didn't have the detector projection precalculated,
so threw an AttributeError when trying to navigate.
@ndevenish ndevenish merged commit eb2d5f9 into dials:main Jul 20, 2022
@ndevenish ndevenish deleted the fix_iv_projection branch July 20, 2022 10:41
ndevenish added a commit that referenced this pull request Jul 22, 2022
If loading images by pressing the "Load Image"
button, or remotely via the ZeroMQ API, these
didn't have the detector projection precalculated,
so threw an AttributeError when trying to navigate.
ndevenish added a commit that referenced this pull request Jul 22, 2022
If loading images by pressing the "Load Image"
button, or remotely via the ZeroMQ API, these
didn't have the detector projection precalculated,
so threw an AttributeError when trying to navigate.
ndevenish added a commit that referenced this pull request Jul 22, 2022
If loading images by pressing the "Load Image"
button, or remotely via the ZeroMQ API, these
didn't have the detector projection precalculated,
so threw an AttributeError when trying to navigate.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants