ConsensusCluster doesn't seem to use consensus matrix for clustering

オープン
#25 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

  • #29 @sharifhsn による — マージされずにクローズ

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
python

調査の方向性

The problem is in fit_predict() in src/flowsom/models/consensus_cluster.py (around lines 105-109), which clusters the raw data and never uses the consensus matrix built by fit(). Read fit() to see how self.Mk is produced, then check how the ConsensusCluster class builds its precomputed-distance clustering. Done means fit_predict() clusters on the consensus-derived distances (or exposes that as an option) and the output differs from the raw-data path on a small test dataset.

索引モデルが issue の本文から書いたものです。

説明

bug
Report

When reviewing the ConsensusCluster implementation (src/flowsom/models/consensus_cluster.py, v0.2.2), it seems that fit_predict() ignores the fit() function that does the consensus clustering and just runs AgglomerativeClustering once on raw data (lines 105-109):

    if self.z_score:
        data = self._z_score(data)
    return self.cluster(n_clusters=self.n_clusters, linkage=self.linkage).fit_predict(data)

Based on the consensus clustering paper and the R FlowSOM implementation, it seems that fit_predict() should:

  1. Build consensus matrix using fit()
  2. Convert to distance matrix: distance_matrix = 1 - self.Mk
  3. Cluster using consensus distances (or at least have an option to cluster on the matrix or data, as in the ConsensusCluster class: AgglomerativeClustering(n_clusters=k, metric='precomputed').fit_predict(distance_matrix)
Versions
v0.2.2
主要言語
Python
スター
36
フォーク
7
平均マージ
23分
マージ済み PR(30日)
3

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

saeyslab/FlowSOM_Python のほかの issue

saeyslab/FlowSOM_Python の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。