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

Problem with the find_cluster function #9

Open
joachimpoutaraud opened this issue Jul 13, 2023 · 0 comments
Open

Problem with the find_cluster function #9

joachimpoutaraud opened this issue Jul 13, 2023 · 0 comments

Comments

@joachimpoutaraud
Copy link

joachimpoutaraud commented Jul 13, 2023

I have found a problem related to the find_cluster function. When finding the cluster for each categories separately, the function test if the number of ROIs is higher than 2 and if not it converts all the dataframe columns to noise:

  if len(df_single_categories) < 3:
      df_cluster["cluster_number"] = -1 # noise
      df_cluster["auto_label"] = 0 # noise

This is problematic as it converts all the dataframe to noise even if some categories were containing more than 3 ROIs before. Consequently, it is needed to modify the lines 304 and 305 with the following lines of code:

  if len(df_single_categories) < 3:
      df_cluster.loc[df_cluster["categories"] == categories, "cluster_number"] = int(-1) # noise
      df_cluster.loc[df_cluster["categories"] == categories, "auto_label"] = int(0) # noise
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

No branches or pull requests

1 participant