Closed WeilerP closed 2 years ago
In scvelo/preprocessing/neighbors.py::_get_rep, the variable rep is referenced before assigned when not entering the if-else clause.
scvelo/preprocessing/neighbors.py::_get_rep
rep
import scvelo as scv from scvelo.preprocessing.neighbors import _get_rep adata = scv.datasets.pancreas() use_rep = _get_rep(adata, use_rep="random", n_pcs=None)
Closed via #797.
Description
In
scvelo/preprocessing/neighbors.py::_get_rep
, the variablerep
is referenced before assigned when not entering the if-else clause.Error output
```pytb --------------------------------------------------------------------------- UnboundLocalError Traceback (most recent call last)Versions
```pytb scvelo==0.2.5.dev56+g9ff8098.d20211206 scanpy==1.7.2 anndata==0.7.6 loompy==3.0.6 numpy==1.20.3 scipy==1.6.3 matplotlib==3.4.2 sklearn==0.24.2 pandas==1.2.4 ```