Skip to content

Commit

Permalink
fix issue 115 and 120
Browse files Browse the repository at this point in the history
  • Loading branch information
zihuaihuai committed Oct 2, 2024
1 parent e71ffef commit 30d1288
Show file tree
Hide file tree
Showing 4 changed files with 238 additions and 28 deletions.
2 changes: 1 addition & 1 deletion brainspace/_version.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""BrainSpace version"""

__version__ = '0.1.10'
__version__ = '0.1.50'
1 change: 1 addition & 0 deletions brainspace/gradient/kernels.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ def _build_kernel(x, kernel, gamma=None):
if kernel in {'cosine', 'normalized_angle'}:
x = cosine_similarity(x)
if kernel == 'normalized_angle':
x = np.clip(x, -1.0, 1.0)
x = 1 - np.arccos(x, x)/np.pi
return x

Expand Down
Loading

0 comments on commit 30d1288

Please sign in to comment.