-
Notifications
You must be signed in to change notification settings - Fork 18
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 type to the Beam model #647
Add probe type to the Beam model #647
Conversation
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
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #647 +/- ##
==========================================
- Coverage 39.39% 39.09% -0.30%
==========================================
Files 178 179 +1
Lines 15519 15819 +300
Branches 2996 3057 +61
==========================================
+ Hits 6113 6185 +72
- Misses 8827 9052 +225
- Partials 579 582 +3 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This all looks fine to me, and should be quite useful.
@toastisme I've made the changes to hopefully get |
…anged Probe in .expt files to be human readable.
…ructor at the Python level. Fixed typo in Beam.from_dict.
Had a look and looks good. I realised |
Add probe to phil params and make probe in .expt human readable
…type 575 beam model should state probe type
Co-authored-by: Nicholas Devenish <[email protected]>
Co-authored-by: Nicholas Devenish <[email protected]>
At the moment this just adds the additional datum and allows serialisation etc. Old experiment files where this is not set are interpreted as having Probe.xray. Some electron diffraction format classes are updated here to record Probe.electron. Co-authored-by: davidmcdonagh <[email protected]>
Fixes #575.
This PR adds a
Probe
enum
toBeam
. In future this could be used to alter behaviour of algorithms, such as the QE and parallax corrections. At the moment this just adds the additional datum and allows serialisation etc. Old experiment files where this is not set are interpreted as havingProbe.xray
. Some electron diffraction format classes are updated here to recordProbe.electron
.A DIALS PR will be required following this. Currently the only DIALS tests that fail are those for
dials.show
.