question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

UnboundLocalError in dyn.ext.ddhodge

See original GitHub issue

Hi, there is a error when I run ddhodge as below:

dyn.ext.ddhodge(adata, basis='pca')
~/.local/lib/python3.8/site-packages/anndata/_core/anndata.py:1095: FutureWarning: The `inplace` parameter in pandas.Categorical.remove_unused_categories is deprecated and will be removed in a future version.
  df_sub[k].cat.remove_unused_categories(inplace=True)
|-----------> not all cells are used, set diag to 1...
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "~/.local/lib/python3.8/site-packages/dynamo/external/hodge.py", line 214, in ddhodge
    k = nbrs_idx.shape[1]
UnboundLocalError: local variable 'nbrs_idx' referenced before assignment

I don’t know how to solve it.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:16 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
lh12565commented, Mar 1, 2022

Hi @lh12565 ,

Yes the issue was confirmed. We fixed it and it should work now. Please try

source activate dynamonew
pip uninstall dynamo
pip install git+https://github.com/dummyindex/dynamo-release.git@fix-issue-289

Or you can wait the #291 to be merged soon. Sorry for the glitches and thanks for your report. Please let us know if this fixes the problem.

Thanks! It works! You are the most efficient person I have ever met.

0reactions
dummyindexcommented, Feb 28, 2022

Hi @lh12565 ,

Yes the issue was confirmed. We fixed it and it should work now. Please try

source activate dynamonew
pip uninstall dynamo
pip install git+https://github.com/dummyindex/dynamo-release.git@fix-issue-289

Or you can wait the #291 to be merged soon. Sorry for the glitches and thanks for your report. Please let us know if this fixes the problem.

Read more comments on GitHub >

github_iconTop Results From Across the Web

kazumits/ddhodge: Modeling Latent Flow Structure ... - GitHub
The goal of ddhodge is to be a toolkit to analyse underlying “flow” structure (e.g., time or causal relations) in the hodge-podge collection...
Read more >
Not generating .hdf5 file - Quantumlib/OpenFermion - IssueHint
Ability to install multiple packages with one command, 1, 2022-05-12, 2022-08-09. UnboundLocalError in dyn.ext.ddhodge, 16, 2022-02-27, 2022-08-04.
Read more >
Exclude tests from code coverage numbers, since we don't care ...
Issue Title, Created Date, Comment Count, Updated Date. UnboundLocalError in dyn.ext.ddhodge, 16, 2022-02-27, 2022-09-22.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found