Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enable custom cluster based thresholding for non-volumic dataset #453

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

bpinsard
Copy link

@bpinsard bpinsard commented Apr 8, 2016

modified the GroupClusterThreshold to enable clustering using custom neighborhood definition (as a sparse matrix of connectivity) that can process surface based dataset for example.

from an array tris defining the triangles of the surface, connectivity can be obtained with:

scipy.sparse.coo_matrix((
            np.ones(3*tris.shape[0]),
            (np.hstack([tris[:,:2].T.ravel(),tris[:,1]]),
             np.hstack([tris[:,1:].T.ravel(),tris[:,2]]))))

I prefer to provide neighborhood than do something surface-specific as I have dataset mixing surfaces and ROIs (HCP-style).

Runs quite fast (comparable to the volume based).

Testing needed, but wanted to have feedback on the structure.

@yarikoptic
Copy link
Member

Please have a look at #395 which wip to make it work with arbitrary queryengines and extended set of measures... Would be nice to join efforts

@codecov-io
Copy link

codecov-io commented Apr 8, 2016

Codecov Report

Merging #453 into master will decrease coverage by 0.03%.
The diff coverage is 30%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #453      +/-   ##
==========================================
- Coverage   76.66%   76.63%   -0.04%     
==========================================
  Files         364      364              
  Lines       41341    41366      +25     
  Branches     6667     6672       +5     
==========================================
+ Hits        31695    31700       +5     
- Misses       7751     7770      +19     
- Partials     1895     1896       +1
Impacted Files Coverage Δ
mvpa2/algorithms/group_clusterthr.py 88.23% <30%> (-10.09%) ⬇️
mvpa2/tests/test_usecases.py 99.28% <0%> (+0.35%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 56d8861...85da1df. Read the comment docs.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.04%) to 79.682% when pulling 8f0ab92 on bpinsard:gct_custom_neigh into e22122c on PyMVPA:master.

@bpinsard
Copy link
Author

bpinsard commented Apr 8, 2016

I didn't see that it was WIP, I will follow your pull request. Thanks!

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.03%) to 79.911% when pulling 2ebaa84 on bpinsard:gct_custom_neigh into 1d11560 on PyMVPA:master.

@coveralls
Copy link

coveralls commented Jul 13, 2016

Coverage Status

Coverage decreased (-0.03%) to 79.982% when pulling 64d8124 on bpinsard:gct_custom_neigh into b036f96 on PyMVPA:master.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.05%) to 81.154% when pulling 6b9eb94 on bpinsard:gct_custom_neigh into 7e9020b on PyMVPA:master.

1 similar comment
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.05%) to 81.154% when pulling 6b9eb94 on bpinsard:gct_custom_neigh into 7e9020b on PyMVPA:master.

@coveralls
Copy link

coveralls commented Jan 4, 2017

Coverage Status

Coverage decreased (-0.04%) to 81.161% when pulling 6b9eb94 on bpinsard:gct_custom_neigh into 7e9020b on PyMVPA:master.

@coveralls
Copy link

coveralls commented Aug 24, 2017

Coverage Status

Coverage decreased (-1.5%) to 79.652% when pulling f8d1b86 on bpinsard:gct_custom_neigh into 7e9020b on PyMVPA:master.

@coveralls
Copy link

coveralls commented Oct 18, 2017

Coverage Status

Coverage decreased (-0.2%) to 79.859% when pulling 85da1df on bpinsard:gct_custom_neigh into 56d8861 on PyMVPA:master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants