Skip to content

Commit

Permalink
update to numpy bool_ output
Browse files Browse the repository at this point in the history
  • Loading branch information
tianluyuan committed Jun 18, 2024
1 parent 3f6b986 commit b4997bf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sphere/distribution/distribution.py
Original file line number Diff line number Diff line change
Expand Up @@ -605,8 +605,8 @@ def normalize(self, return_num_iterations=False):
>>> gamma2 = np.array([0.0, 1.0, 0.0])
>>> gamma3 = np.array([0.0, 0.0, 1.0])
>>> tiny = FB8Distribution.minimum_value_for_kappa
>>> abs(fb82(gamma1, gamma2, gamma3, tiny, 0.0).normalize() - 4*np.pi) < 4*np.pi*1E-12
True
>>> np.abs(fb82(gamma1, gamma2, gamma3, tiny, 0.0).normalize() - 4*np.pi) < 4*np.pi*1E-12
np.True_
>>> for kappa in [0.01, 0.1, 0.2, 0.5, 2, 4, 8, 16]:
... print(np.abs(fb82(gamma1, gamma2, gamma3, kappa, 0.0).normalize() - 4*np.pi*np.sinh(kappa)/kappa) < 1E-15*4*np.pi*np.sinh(kappa)/kappa, end=' ')
...
Expand Down

0 comments on commit b4997bf

Please sign in to comment.