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

Add probe to phil params and make probe in .expt human readable #654

Merged

Conversation

toastisme
Copy link
Contributor

  • Adds Probe to phil params in beam.py
  • Changes the Probe in .expt files to be human readable.
  • Exposes empty PolychromaticBeam constructor at Python level
  • Few extra typehints

dagewa and others added 27 commits July 21, 2023 15:36
So now, can do

from dxtbx.model.beam import Probe
Note the value is uninitialized!
>>> from dxtbx.model.beam import Beam
>>> b=Beam()
>>> b.get_probe()
dxtbx_model_ext.Probe.xray
Now this works:

>>> from dxtbx.model.beam import Beam
>>> b=Beam()
>>> b.get_probe()
dxtbx_model_ext.Probe.xray
>>> from dxtbx.model.beam import Probe
>>> b.set_probe(Probe.neutron)
>>> b.get_probe()
dxtbx_model_ext.Probe.neutron
returned for each of the defined probe values
When setting panels by PHIL, merge multiple definitions first by id. This fixes cctbx#299.
Previously, a size (3,) array would have erroneously converted
to a 0x3 length vec3.

This is now explicitly forbidden; you must pass at least a (0, 3)
multidimensional array.

Fixes cctbx#439.
Partial support for Rigaku Oxford Diffraction format images.
---------

Co-authored-by: Takanori Nakane <nakane.t@gmail.com>
Co-authored-by: Nicholas Devenish <ndevenish@gmail.com>
This was previously done implicitly, but only when dials_regression
was present. This makes the test explicit, and works with
dials-data (so that it will work on e.g. CI with restricted access
to test cases).
Without this, slices sometimes needed to be indexed by their original
image index, even inside the slice.

The previous workaround in 67aab2 (cctbx#485) for negative offset was
reacting to the erroneous behaviour introduced by including batch
offsets in imagesequence slicing.
Without this, dxtbx did not work as a subdirectory in
a larger CMakeLists project.
The E-32-0017 Eiger moved to P13 on 2021-5-22, where the goniometer axis no
longer needs overriding.

Check for that date in the MiniCBF, and check for the serial matching the date
range.

Co-authored-by: Christian Becke <christian.becke@fu-berlin.de>
Co-authored-by: Nicholas Devenish <ndevenish@gmail.com>
Add new Beam class "PolychromaticBeam" for polychromatic/multi-wavelength/wide bandpass experiments.

---------

Co-authored-by: DiamondLightSource-build-server <DiamondLightSource-build-server@users.noreply.github.com>
Co-authored-by: Nicholas Devenish <ndevenish@gmail.com>
…anged Probe in .expt files to be human readable.
…ructor at the Python level. Fixed typo in Beam.from_dict.
@codecov
Copy link

codecov bot commented Aug 3, 2023

Codecov Report

Merging #654 (dfdbc0a) into 575-beam-model-should-state-probe-type (1625cfa) will decrease coverage by 0.24%.
The diff coverage is 31.02%.

❗ Current head dfdbc0a differs from pull request most recent head 4312daf. Consider uploading reports for the commit 4312daf to get more accurate results

Additional details and impacted files
@@                            Coverage Diff                             @@
##           575-beam-model-should-state-probe-type     #654      +/-   ##
==========================================================================
- Coverage                                   39.39%   39.15%   -0.24%     
==========================================================================
  Files                                         178      179       +1     
  Lines                                       15519    15789     +270     
  Branches                                     2996     3053      +57     
==========================================================================
+ Hits                                         6113     6182      +69     
- Misses                                       8827     9026     +199     
- Partials                                      579      581       +2     

Copy link
Member

@dagewa dagewa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! The additions look good and I have confirmed that all tests pass with this and dials/dials#2482 in place. I aim to merge tomorrow.

@dagewa
Copy link
Member

dagewa commented Aug 3, 2023

Well, can merge this one in now, and the PR into dxtbx tomorrow

@dagewa dagewa merged commit 35a312c into cctbx:575-beam-model-should-state-probe-type Aug 3, 2023
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants