Skip to content
Snippets Groups Projects

Resolve "Image creation bugs with 0 size windows"

Closed Raphael Sturgis requested to merge 21-image-creation-bugs-with-0-size-windows into main
2 files
+ 10
12
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -18,16 +18,14 @@ def angular_dispersion(angles):
def angular_mean(angles):
x, y = angular_average_vector(angles)
theta = abs(np.arctan2(x, y))
theta = np.arctan(y/x)
if y > 0 and x > 0: # first Q
if y > 0 and x > 0:
return theta
if y > 0 >= x: # Second Q
return np.pi / 2 + theta
if y <= 0 < x: # Fourth Q
return np.pi / 2 - theta
else: # Third Q
return - theta
elif x <= 0:
return np.pi + theta
else:
return 2*np.pi + theta
def angular_std(angles):
Loading