aertslab / SCENICprotocol

A scalable SCENIC workflow for single-cell gene regulatory network analysis
GNU General Public License v3.0
141 stars 62 forks source link

AUCell - AttributeError: 'Series' object has no attribute 'iteritems' #71

Open shrutikhare-git opened 1 year ago

shrutikhare-git commented 1 year ago

I get the following error while trying to run AUCell step from the tutorial (http://htmlpreview.github.io/?https://github.com/aertslab/SCENICprotocol/blob/master/notebooks/PBMC10k_SCENIC-protocol-CLI.html)

/home/xx/.local/bin/pyscenic aucell filtered_scenic.loom reg.csv --output pyscenic_output.loom --num_workers 4

2023-05-03 15:40:13,037 - pyscenic.cli.pyscenic - INFO - Loading expression matrix.

2023-05-03 15:40:14,208 - pyscenic.cli.pyscenic - INFO - Loading gene signatures. Create regulons from a dataframe of enriched features. Additional columns saved: []

2023-05-03 15:40:14,746 - pyscenic.cli.pyscenic - INFO - Calculating cellular enrichment.

2023-05-03 15:40:22,311 - pyscenic.cli.pyscenic - INFO - Writing results to file. Traceback (most recent call last): File "/home/xx/.local/bin/pyscenic", line 8, in sys.exit(main()) File "/home/xx/.local/lib/python3.10/site-packages/pyscenic/cli/pyscenic.py", line 713, in main args.func(args) File "/home/xx/.local/lib/python3.10/site-packages/pyscenic/cli/pyscenic.py", line 296, in aucell_command append_auc_mtx( File "/home/xx/.local/lib/python3.10/site-packages/pyscenic/cli/utils.py", line 347, in append_auc_mtx for name, threshold in auc_thresholds.iteritems() File "/home/xx/.local/lib/python3.10/site-packages/pandas/core/generic.py", line 5989, in getattr return object.getattribute(self, name) AttributeError: 'Series' object has no attribute 'iteritems'

I tried running this from CLI as well as notebook but get the same error

system info - anndata 0.9.1 scanpy 1.9.3

MulticoreTSNE NA PIL 9.5.0 asttokens NA backcall 0.2.0 cffi 1.15.1 cloudpickle 2.2.1 colorama 0.4.6 comm 0.1.3 cycler 0.10.0 cython_runtime NA cytoolz 0.12.1 dask 2023.4.0 dateutil 2.8.2 debugpy 1.6.7 decorator 5.1.1 defusedxml 0.7.1 executing 1.2.0 h5py 3.8.0 igraph 0.10.4 ipykernel 6.22.0 ipython_genutils 0.2.0 jedi 0.18.2 jinja2 3.1.2 joblib 1.2.0 kiwisolver 1.4.4 llvmlite 0.39.1 loompy 3.0.7 louvain 0.8.0 lz4 4.3.2 markupsafe 2.1.2 matplotlib 3.7.1 mpl_toolkits NA natsort 8.3.1 nt NA ntsecuritycon NA numba 0.56.4 numexpr 2.8.4 numpy 1.23.5 numpy_groupies 0.9.20 packaging 23.1 pandas 2.0.1 parso 0.8.3 pickleshare 0.7.5 pkg_resources NA platformdirs 3.3.0 prompt_toolkit 3.0.38 psutil 5.9.5 pure_eval 0.2.2 pyarrow 11.0.0 pycparser 2.21 pydev_ipython NA pydevconsole NA pydevd 2.9.5 pydevd_file_utils NA pydevd_plugins NA pydevd_tracing NA pygments 2.15.1 pyparsing 3.0.9 pythoncom NA pytz 2023.3 pywin32_bootstrap NA pywin32_system32 NA pywintypes NA scipy 1.10.1 seaborn 0.12.2 session_info 1.0.0 setuptools 67.7.2 six 1.16.0 sklearn 1.2.2 stack_data 0.6.2 statsmodels 0.13.5 tblib 1.7.0 texttable 1.6.7 threadpoolctl 3.1.0 tlz 0.12.1 toolz 0.12.0 tornado 6.3.1 traitlets 5.9.0 wcwidth 0.2.6 win32api NA win32com NA win32security NA yaml 6.0 zipp NA zmq 25.0.2 zoneinfo NA

IPython 8.12.0 jupyter_client 8.2.0 jupyter_core 5.3.0 notebook 6.5.4

Python 3.10.10 | packaged by conda-forge | (main, Mar 24 2023, 20:00:38) [MSC v.1934 64 bit (AMD64)] Windows-10-10.0.19044-SP0

Dingpw commented 6 months ago

I have the same problems with pandas 2.0.3.