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

WIP: Assign streamlines to an existing cluster map via QuickBundles #723

Closed
wants to merge 5 commits into
base: master
from

Conversation

Projects
None yet
2 participants
@MarcCote
Contributor

MarcCote commented Oct 1, 2015

When there are just too many streamlines, you might want to only cluster a subset of those then assign the rest to their nearest cluster. To do so, we needed a way to assign streamlines to an existing cluster_map object (i.e. what QuickBundles.cluster returns).

@Garyfallidis

This comment has been minimized.

Member

Garyfallidis commented Oct 7, 2015

Hi @MarcCote can you please add an option for the assignments to be direct? Without updating the centroids? And/or update the centroids only at the end (if you think that this is useful)?

@MarcCote

This comment has been minimized.

Contributor

MarcCote commented Oct 9, 2015

@Garyfallidis we have some decisions to make regarding this PR.

  • should streamlines assignation modifies the clusters i.e. updates the centroids?
  • when assigning streamlines to some clusters should we modified the ClusterMap object in-place?

I don't like the way streamlines assignation is done right now.

qb = QuickBundles(threshold=12)
clusters = qb.cluster(streamlines)

# Use existing clusters to group `other_streamlines`
# Note: `new_clusters` won't contain any element from `streamlines`.
new_clusters = qb.assign(clusters, other_streamlines)

Maybe something like this, would be more user-friendly?

qb = QuickBundles(threshold=12, metric=some_metric)
clusters = qb.cluster(streamlines)

# Use existing clusters to assign `other_streamlines` to existing `clusters`.
# Note: `new_clusters` *will* contain all elements from both `streamlines` and `other_streamlines`.
clusters.assign(streamlines, metric=some_metric)
@Garyfallidis

This comment has been minimized.

Member

Garyfallidis commented Oct 9, 2015

Let's go for option 1 and have an option to include initial streamlines or not.

@Garyfallidis

This comment has been minimized.

Member

Garyfallidis commented Nov 13, 2015

This PR is not necessary any more. There will be a new PR which speeds up QB a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment