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

Caching the velocity graph fails #19

Open
Marius1311 opened this issue Jul 20, 2019 · 2 comments
Open

Caching the velocity graph fails #19

Marius1311 opened this issue Jul 20, 2019 · 2 comments
Assignees

Comments

@Marius1311
Copy link
Owner

I try to run cache.velocity_graph(adata, force=False)
and I get the error:

Computing values.
computing velocity graph
    finished (0:00:19) --> added 
    'velocity_graph', sparse matrix with cosine correlations (adata.uns)
Traceback (most recent call last):
  File "/projects/utility_functions/utils.py", line 227, in helper
    _get_val(getattr(adata, attr), key)) for attr, key in map(lambda a_k: (a_k[0], _convert_key(*a_k)), zip(attrs, keys))]
  File "/projects/utility_functions/utils.py", line 227, in <listcomp>
    _get_val(getattr(adata, attr), key)) for attr, key in map(lambda a_k: (a_k[0], _convert_key(*a_k)), zip(attrs, keys))]
  File "/projects/utility_functions/utils.py", line 199, in _get_val
    obj = obj[k]
KeyError: '.+_graph$'

---------------------------------------------------------------------------
AssertionError                            Traceback (most recent call last)
<ipython-input-67-d60a68fc16e1> in <module>
----> 1 cache.velocity_graph(adata, force=False)

/projects/utility_functions/utils.py in _run(*args, **kwargs)
    360                 res = callback(*args, **kwargs)
    361                 ret = cache_fn(res if copy else adata, fname, True, verbose=False)
--> 362                 assert ret, 'Caching failed.'
    363 
    364                 return res

AssertionError: Caching failed.

I don't get this error with any other caching functions, all the others work fine

@michalk8
Copy link
Collaborator

Strange, thought I fixed it (I reran the notebook on server and have no issues). Are you sure you have the latest version?

@Marius1311
Copy link
Owner Author

I will have to check that out.

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

2 participants