aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src
diff options
context:
space:
mode:
authorWolfgang Brehm <wolfgang.brehm@gmail.com>2019-11-14 16:06:37 +0100
committerThomas White <taw@physics.org>2019-11-15 09:41:04 +0100
commit39f9e154612cfb693a3e678d11c2ab4b9da97878 (patch)
treeb2ef74d749e425377d88801acc402fe05ac2f2ae /libcrystfel/src
parentf91016824be876639265d991f47c10c899d00813 (diff)
Add partiality model GGPM
Diffstat (limited to 'libcrystfel/src')
-rw-r--r--libcrystfel/src/geometry.c6
-rw-r--r--libcrystfel/src/geometry.h1
2 files changed, 7 insertions, 0 deletions
diff --git a/libcrystfel/src/geometry.c b/libcrystfel/src/geometry.c
index e5506334..ef75199a 100644
--- a/libcrystfel/src/geometry.c
+++ b/libcrystfel/src/geometry.c
@@ -412,6 +412,7 @@ static Reflection *check_reflection(struct image *image, Crystal *cryst,
set_lorentz(refl, 1.0);
set_symmetric_indices(refl, h, k, l);
set_redundancy(refl, 1);
+ set_partiality(refl, partiality);
return refl;
}
@@ -903,6 +904,11 @@ void calculate_partialities(Crystal *cryst, PartialityModel pmodel)
set_random_partialities(cryst);
break;
+ case PMODEL_GGPM :
+ /* Do nothing, because this is the model used for prediction,
+ * so the partialities have been set by check_reflection */
+ break;
+
default :
ERROR("Unknown partiality model %i\n", pmodel);
break;
diff --git a/libcrystfel/src/geometry.h b/libcrystfel/src/geometry.h
index 0a403a9c..dea27e02 100644
--- a/libcrystfel/src/geometry.h
+++ b/libcrystfel/src/geometry.h
@@ -61,6 +61,7 @@ typedef enum {
PMODEL_XSPHERE, /**< Flat sphere model with super-Gaussian spectrum */
PMODEL_OFFSET, /**< Ewald offset model for monochromatic beam */
PMODEL_RANDOM, /**< Randomly assigned partialities */
+ PMODEL_GGPM /**< Generalised gaussian prediction model */
} PartialityModel;