Open Sankar-Gollapudi opened 3 days ago
Are you trying to use a development install of this library, or do you just want to have it installed?
The install instructions on pypi are only for dev installs, which may have some other issues.
Could you please:
pip install "cellxgene-census[experimental]"
conda list
in that environmentThis is the result of conda list:
cellxgene-census does not appear in conda list, however this is the result of pip list:
The traceback for the error is: ModuleNotFoundError Traceback (most recent call last) Cell In[1], line 1 ----> 1 import cellxgene_census 2 import pandas as pd
ModuleNotFoundError: No module named 'cellxgene_census'
Edit: I also forgot to mention that I just want to have it installed to use in a notebook script.
Could you paste in the full output of both of those list commands? It looks like they might be different environments, but it's hard to tell from these screenshots.
Did you try doing a non-development install as suggested?
Yes, I had previously tried just doing pip install as described here: https://chanzuckerberg.github.io/cellxgene-census/cellxgene_census_docsite_installation.html.
Here is the full pasted list of each command:
Edit: I also tried the pip install command you suggested. This output is the result after attempting.
Hmm. That definitely looks like pip and conda are seeing different sets of packages. What does which pip
return?
Is this a fresh conda environment? I would try this all from scratch in a fresh conda environment. I'd also make sure that pip
is up to date in that environment before using it to install anything.
FWIW, I can't reproduce this issue. Here's what I did:
This is strange, I created a new conda environment, downloaded pandas, and then attempted the pip install line you gave and it doesn't seem to be working. Perhaps this is due to a problem with some packages I already have installed in pip.
(base) sgollap@Sankars-MacBook-Pro GTResearch % conda activate censusconda (censusconda) sgollap@Sankars-MacBook-Pro GTResearch % pip list Package Version
accumulation-tree 0.6.2 aiobotocore 2.13.1 aiohttp 3.9.5 aioitertools 0.11.0 aiosignal 1.3.1 anndata 0.10.8 anyio 4.3.0 appnope 0.1.4 argon2-cffi 23.1.0 argon2-cffi-bindings 21.2.0 array_api_compat 1.7.1 arrow 1.3.0 asttokens 2.4.1 async-lru 2.0.4 attrs 23.2.0 Babel 2.15.0 beautifulsoup4 4.12.3 bleach 6.1.0 botocore 1.34.131 certifi 2024.2.2 cffi 1.16.0 charset-normalizer 3.3.2 comm 0.2.2 contourpy 1.2.1 cycler 0.12.1 datasets 2.19.2 debugpy 1.8.1 decorator 5.1.1 defusedxml 0.7.1 dill 0.3.8 executing 2.0.1 fastjsonschema 2.19.1 filelock 3.15.4 fonttools 4.53.0 fqdn 1.5.1 frozenlist 1.4.1 fsspec 2024.3.1 h11 0.14.0 h5py 3.11.0 httpcore 1.0.5 httpx 0.27.0 huggingface-hub 0.23.4 idna 3.7 ipykernel 6.29.4 ipython 8.24.0 ipywidgets 8.1.2 isoduration 20.11.0 jedi 0.19.1 Jinja2 3.1.4 jmespath 1.0.1 joblib 1.4.2 json5 0.9.25 jsonpointer 2.4 jsonschema 4.22.0 jsonschema-specifications 2023.12.1 jupyter 1.0.0 jupyter_client 8.6.2 jupyter-console 6.6.3 jupyter_core 5.7.2 jupyter-events 0.10.0 jupyter-lsp 2.2.5 jupyter_server 2.14.0 jupyter_server_terminals 0.5.3 jupyterlab 4.2.1 jupyterlab_pygments 0.3.0 jupyterlab_server 2.27.2 jupyterlab_widgets 3.0.10 kiwisolver 1.4.5 legacy-api-wrap 1.4 llvmlite 0.43.0 MarkupSafe 2.1.5 matplotlib 3.9.0 matplotlib-inline 0.1.7 mistune 3.0.2 mpmath 1.3.0 multidict 6.0.5 multiprocess 0.70.16 natsort 8.4.0 nbclient 0.10.0 nbconvert 7.16.4 nbformat 5.10.4 networkx 3.3 notebook 7.2.0 notebook_shim 0.2.4 numba 0.60.0 numpy 1.26.2 overrides 7.7.0 packaging 24.0 pandas 2.2.2 pandocfilters 1.5.1 parso 0.8.4 patsy 0.5.6 pexpect 4.9.0 pillow 10.4.0 pip 24.0 platformdirs 4.2.2 prometheus_client 0.20.0 prompt-toolkit 3.0.43 psutil 5.9.8 ptyprocess 0.7.0 pure-eval 0.2.2 pyarrow 12.0.1 pyarrow-hotfix 0.6 pycparser 2.22 Pygments 2.18.0 pynndescent 0.5.13 pyparsing 3.1.2 python-dateutil 2.9.0.post0 python-json-logger 2.0.7 pytz 2024.1 pyudorandom 1.0.0 PyYAML 6.0.1 pyzmq 26.0.3 qtconsole 5.5.2 QtPy 2.4.1 referencing 0.35.1 requests 2.32.2 rfc3339-validator 0.1.4 rfc3986-validator 0.1.1 rpds-py 0.18.1 s3fs 2024.3.1 scanpy 1.10.2 scikit-learn 1.5.0 scikit-misc 0.3.1 scipy 1.14.0 seaborn 0.13.2 Send2Trash 1.8.3 session-info 1.0.0 setuptools 65.5.0 six 1.16.0 sniffio 1.3.1 somacore 1.0.11 soupsieve 2.5 stack-data 0.6.3 statsmodels 0.14.2 stdlib-list 0.10.0 sympy 1.12.1 tdigest 0.5.2.2 terminado 0.18.1 threadpoolctl 3.5.0 tiledb 0.29.1 tiledbsoma 1.11.4 tinycss2 1.3.0 torch 2.3.1 torchdata 0.7.1 tornado 6.4 tqdm 4.66.4 traitlets 5.14.3 types-python-dateutil 2.9.0.20240316 typing_extensions 4.11.0 tzdata 2024.1 umap-learn 0.5.6 uri-template 1.3.0 urllib3 2.2.1 wcwidth 0.2.13 webcolors 1.13 webencodings 0.5.1 websocket-client 1.8.0 wheel 0.43.0 widgetsnbextension 4.0.10 wrapt 1.16.0 xxhash 3.4.1 yarl 1.9.4
[notice] A new release of pip is available: 24.0 -> 24.1.1 [notice] To update, run: pip install --upgrade pip (censusconda) sgollap@Sankars-MacBook-Pro GTResearch % conda install pandas Channels:
environment location: /usr/local/Caskroom/miniforge/base/envs/censusconda
added / updated specs:
The following packages will be downloaded:
package | build
---------------------------|-----------------
bottleneck-1.3.7 | py311hb3a5e46_0 152 KB
libcxx-14.0.6 | h9765a3e_0 968 KB
libgfortran-5.0.0 |11_3_0_hecd8cb5_28 142 KB
libgfortran5-11.3.0 | h9dfd629_28 1.4 MB
libopenblas-0.3.21 | h54e7dc3_0 4.9 MB
llvm-openmp-14.0.6 | h0dcd299_0 288 KB
numexpr-2.8.7 | py311h91b6869_0 162 KB
numpy-1.26.4 | py311h91b6869_0 12 KB
numpy-base-1.26.4 | py311hb3ec012_0 7.8 MB
pandas-2.2.2 | py311he327ffe_0 14.9 MB
python-dateutil-2.9.0post0 | py311hecd8cb5_2 322 KB
pytz-2024.1 | py311hecd8cb5_0 224 KB
------------------------------------------------------------
Total: 31.3 MB
The following NEW packages will be INSTALLED:
blas pkgs/main/osx-64::blas-1.0-openblas bottleneck pkgs/main/osx-64::bottleneck-1.3.7-py311hb3a5e46_0 libcxx pkgs/main/osx-64::libcxx-14.0.6-h9765a3e_0 libgfortran pkgs/main/osx-64::libgfortran-5.0.0-11_3_0_hecd8cb5_28 libgfortran5 pkgs/main/osx-64::libgfortran5-11.3.0-h9dfd629_28 libopenblas pkgs/main/osx-64::libopenblas-0.3.21-h54e7dc3_0 llvm-openmp pkgs/main/osx-64::llvm-openmp-14.0.6-h0dcd299_0 numexpr pkgs/main/osx-64::numexpr-2.8.7-py311h91b6869_0 numpy pkgs/main/osx-64::numpy-1.26.4-py311h91b6869_0 numpy-base pkgs/main/osx-64::numpy-base-1.26.4-py311hb3ec012_0 pandas pkgs/main/osx-64::pandas-2.2.2-py311he327ffe_0 python-dateutil pkgs/main/osx-64::python-dateutil-2.9.0post0-py311hecd8cb5_2 python-tzdata pkgs/main/noarch::python-tzdata-2023.3-pyhd3eb1b0_0 pytz pkgs/main/osx-64::pytz-2024.1-py311hecd8cb5_0 six pkgs/main/noarch::six-1.16.0-pyhd3eb1b0_1
Proceed ([y]/n)? y
Downloading and Extracting Packages:
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(censusconda) sgollap@Sankars-MacBook-Pro GTResearch % pip install -e 'api/python/cellxgene_census[experimental]'
ERROR: api/python/cellxgene_census[experimental] is not a valid editable requirement. It should either be a path to a local project or a VCS URL (beginning with bzr+http, bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, hg+ssh, hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file).
[notice] A new release of pip is available: 24.0 -> 24.1.1 [notice] To update, run: pip install --upgrade pip (censusconda) sgollap@Sankars-MacBook-Pro GTResearch %
Yeah, that definitely looks like the pip
you are calling is not the right pip
for the conda environment. If censusconda
is a fresh environment, you shouldn't see so many packages when you do pip list
.
I'm afraid I can't say why that would be happening, as it would have to do with the configuration of your particular machine. When you're in your conda environment you should be able to access a pip that is specific to that environment. I check that like this:
$ conda activate test-env-3.11
$ which pip
/home/ubuntu/miniforge3/envs/test-env-3.11/bin/pip
I had an issue when trying to download census in my conda environment. I followed the installation instructions on PyPI, but for some reason when using the conda environment in my jupyter notebook, the import statement throws an error. I was wondering if perhaps there are any additional dependencies I need to install or if there could be an issue with my environment setup.
The specific error was "Import 'cellxgene_census' could not be resolved"