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

Cluster root nodes #32

Merged
merged 183 commits into from
Sep 8, 2023
Merged

Cluster root nodes #32

merged 183 commits into from
Sep 8, 2023

Conversation

stefanhahmann
Copy link
Collaborator

@stefanhahmann stefanhahmann commented Jul 11, 2023

Resolves #25

Already added:

  • UI dialog for parameter selection
  • Find all roots starting from the selected start timepoint
  • Compute the similarity matrix
  • Derive hierarchical clustering from the similarity matrix (average linkage)
  • Derive the selected number of classes from the similarity matrix
  • Create tagset from the computed classes.
  • Assign a tag to each spot between start end endtimepoint
  • Normalized and Average Zhang edit distance
  • Unit tests
  • Checkbox to select show dendrogram yes/no
  • Handling of exceptions and proper feedback to ui
    • More classes than leaves
    • Negative start/end/number of classes/min cell divisions
    • Start >= End
  • Parameter explanations in dialog
  • Persist Input parameters
  • Crop criterion start/end number of cells
  • Show selected parameters in dendrogram title
  • Ensure UI dialog is not opened again, when already open, but brought to front again
  • Investigate small differences dendrograms (python/java) -> seems that java average linkage is giving correct results
  • Adapt number of roots, if crop start > 0

* Contains methods to derive classes from hierarchical clustering based on threshold or based on class count
* weka-dev is a machine learning library that is able to perform hierarchical clustering amongst others
…Tree

* if first timepoint of given branchspot is greater than given endtimepoint
* if given branchSpot is null
…lassCount

* The dendrogram contains the cutoff line
maarzt
maarzt previously approved these changes Sep 5, 2023
@sonarcloud
Copy link

sonarcloud bot commented Sep 7, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

80.9% 80.9% Coverage
0.0% 0.0% Duplication

warning The version of Java (11.0.20) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 17.
Read more here

@stefanhahmann
Copy link
Collaborator Author

The plugin works, but:

* The threshold line is drawn in the wrong place in the dendrogram view.

* The ClusterRootNodesView is not large enough when first shown such that the "create tag set) button is hidden. (This is a bug in scijava-ui-swing)

* The ClusterRootNodesView does not appear in the task bar. (Bug in scijava-ui-swing)

Thanks for the advices.

  • I changed the place of the threshold.
  • The button not being visible seems to be a bug of scijava-ui-swing in Unix based Systems. It does not occur on a Windows machine
  • The task bar issue is not something that can be resolved in this issue.

For the sake of completeness I made a another comparison between the Python based results in the results in this Java implementation. It looks fairly similar now (apart from the order of the clusters, which differs, but is not really relevant):

grafik

@stefanhahmann stefanhahmann merged commit 3563660 into master Sep 8, 2023
4 checks passed
@stefanhahmann stefanhahmann deleted the cluster_root_nodes branch September 8, 2023 09:38
@stefanhahmann stefanhahmann self-assigned this Jan 24, 2024
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.

Create TagSet from root nodes based on tree similarity
2 participants