scanpy
scanpy copied to clipboard
AttributeError: module 'scanpy.preprocessing' has no attribute 'scrublet'
Please make sure these conditions are met
- [X] I have checked that this issue has not already been reported.
- [X] I have confirmed this bug exists on the latest version of scanpy.
- [X] (optional) I have confirmed this bug exists on the main branch of scanpy.
What happened?
Hi,
Thanks a lot for helping! I was following this tutorial (https://scanpy.readthedocs.io/en/stable/tutorials/basics/clustering.html) and get the error in this step: sc.pp.scrublet(adata, batch_key="sample") AttributeError: module 'scanpy.preprocessing' has no attribute 'scrublet'
Can you help with this? Thanks!
Best, B
Minimal code sample
sc.pp.scrublet(adata, batch_key="lib_prep")
Error output
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
/tmp/ipykernel_54187/3500521297.py in <module>
----> 1 sc.pp.scrublet(adata, batch_key="lib_prep")
AttributeError: module 'scanpy.preprocessing' has no attribute 'scrublet'
Versions
-----
anndata 0.10.3
scanpy 1.9.6
-----
PIL 10.1.0
backcall 0.2.0
cffi 1.14.6
cycler 0.12.1
cython_runtime NA
dateutil 2.8.2
decorator 5.0.9
defusedxml 0.7.1
exceptiongroup 1.2.0
get_annotations NA
google NA
h5py 3.10.0
importlib_resources NA
ipykernel 6.2.0
ipython_genutils 0.2.0
ipywidgets 7.6.3
jedi 0.18.0
joblib 1.3.2
kiwisolver 1.4.5
llvmlite 0.41.1
matplotlib 3.8.2
matplotlib_inline NA
mpl_toolkits NA
mudata 0.2.3
muon 0.1.6
natsort 8.4.0
numba 0.58.1
numpy 1.26.2
packaging 21.0
pandas 2.1.3
parso 0.8.2
patsy 0.5.3
pexpect 4.8.0
pickleshare 0.7.5
pkg_resources NA
prompt_toolkit 3.0.19
ptyprocess 0.7.0
pycparser 2.20
pyexpat NA
pygments 2.10.0
pynndescent 0.5.11
pyparsing 2.4.7
pytz 2023.3.post1
scipy 1.11.4
scrublet NA
seaborn 0.12.2
session_info 1.0.0
setuptools 65.5.1
six 1.16.0
sklearn 1.3.2
statsmodels 0.14.0
storemagic NA
threadpoolctl 3.2.0
torch 1.12.1+cu102
tornado 6.1
tqdm 4.66.1
traitlets 5.0.5
typing_extensions NA
umap 0.5.5
wcwidth 0.2.5
yaml 6.0.1
zipp NA
zmq 22.2.1
-----
IPython 7.26.0
jupyter_client 6.1.12
jupyter_core 4.7.1
notebook 6.4.3
-----
Python 3.9.0 (default, Oct 6 2020, 11:01:41) [GCC 4.8.5 20150623 (Red Hat 4.8.5-36)]
Linux-3.10.0-1160.108.1.el7.x86_64-x86_64-with-glibc2.17
-----
Session information updated at 2024-04-23 14:43
I think this is not a bug. You have to update to latest version of scanpy
@bingy007 please report back if you can reproduce this with the latest scanpy versions.
It works when I update the scanpy version from 1.9.8 to 1.10.1