File tree Expand file tree Collapse file tree 1 file changed +1
-12
lines changed
src/dials/algorithms/refinement Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -99,26 +99,15 @@ def calculate_weights(self, reflections):
99
99
100
100
101
101
class TOFWeightingStrategy (StatisticalWeightingStrategy ):
102
- """Defines a single method that provides a ReflectionManager with a strategy
103
- for calculating weights for refinement. This version uses statistical weights
104
- for X and Y and a fixed constant for the delta Psi part, defaulting to 1000000"""
105
-
106
102
def __init__ (self ):
107
103
pass
108
104
109
105
def calculate_weights (self , reflections ):
110
- """Include weights for DeltaPsi"""
111
106
112
- # call parent class method to set X and Y weights
113
107
reflections = super ().calculate_weights (reflections )
114
108
115
109
wx , wy , _ = reflections ["xyzobs.mm.weights" ].parts ()
116
- wavelength_var = (
117
- reflections ["wavelength" ]
118
- - sum (reflections ["wavelength" ]) / len (reflections )
119
- ) ** 2
120
- wz = 1 / wavelength_var
121
- wz = wy * 1260000
110
+ wz = flex .sqrt (wx * wx + wy * wy ) * 1e7
122
111
reflections ["xyzobs.mm.weights" ] = flex .vec3_double (wx , wy , wz )
123
112
124
113
return reflections
You can’t perform that action at this time.
0 commit comments