dylkot / cNMF

Code and example data for running Consensus Non-negative Matrix Factorization on single-cell RNA-Seq data
MIT License
273 stars 57 forks source link

The nmf running error on python3.7.13 version #41

Open honghh2018 opened 2 years ago

honghh2018 commented 2 years ago

Hi guys, When i running the cnmf, the error showing up lying below:

ValueError: Distance matrix 'X' must be symmetric.

miniconda environment python 3.7.13

Best

dylkot commented 2 years ago

Sorry for the slow reply! Could you provide the complete trace? That likely suggests there is an issue with the clustering in the consensus step?

honghh2018 commented 11 months ago

sorry for this lately reply Yes, it was consensus

/share/apps/miniconda3-py39/envs/cNMF-python/lib/python3.7/site-packages/cnmf/cnmf.py:56: RuntimeWarning: invalid value encountered in sqrt D = np.sqrt(D) Traceback (most recent call last): File "/share/apps/miniconda3-py39/envs/cNMF-python/bin/cnmf", line 8, in sys.exit(main()) File "/share/apps/miniconda3-py39/envs/cNMF-python/lib/python3.7/site-packages/cnmf/cnmf.py", line 949, in main close_clustergram_fig=True) File "/share/apps/miniconda3-py39/envs/cNMF-python/lib/python3.7/site-packages/cnmf/cnmf.py", line 755, in consensus cl_dist = squareform(topics_dist[cl_filter, :][:, cl_filter]) File "/share/apps/miniconda3-py39/envs/cNMF-python/lib/python3.7/site-packages/scipy/spatial/distance.py", line 2184, in squareform is_valid_dm(X, throw=True, name='X') File "/share/apps/miniconda3-py39/envs/cNMF-python/lib/python3.7/site-packages/scipy/spatial/distance.py", line 2260, in is_valid_dm 'symmetric.') % name) ValueError: Distance matrix 'X' must be symmetric. Best, hanhuihong