Skip to content

Commit

Permalink
Do not invert for Pilatus 4 (#663)
Browse files Browse the repository at this point in the history
* Do not invert for Pilatus 4

* Rename newsfragments/XXX.bugfix to newsfragments/663.bugfix

---------

Co-authored-by: DiamondLightSource-build-server <[email protected]>
  • Loading branch information
1 parent 4ad0ce5 commit 05b7806
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions newsfragments/663.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Pilatus 4: do not invert module size (is written correctly in master file)

4 changes: 3 additions & 1 deletion src/dxtbx/format/FormatNXmxEigerFilewriter.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,10 @@ def _get_nxmx(self, fh: h5py.File):
# data_size is reversed - we should probably be more specific in when
# we do this, i.e. check data_size is in a list of known reversed
# values
known_safe = [(1082,1035),]
for module in nxdetector.modules:
module.data_size = module.data_size[::-1]
if not tuple(module.data_size) in known_safe:
module.data_size = module.data_size[::-1]
return nxmx_obj

def get_raw_data(self, index):
Expand Down

0 comments on commit 05b7806

Please sign in to comment.