Giter Club home page Giter Club logo

Comments (4)

multitalk avatar multitalk commented on August 17, 2024 1

I didn't meet the problem by following the installation guide.

(scDeepSort) shaoxin@krypton-7820T:~/workspace/scDeepSort$ pip install scDeepSort-v1.0-cpu.tar.gz
Processing ./scDeepSort-v1.0-cpu.tar.gz
Collecting numpy>=1.17.2
  Using cached numpy-1.21.2-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (15.7 MB)
Collecting scipy>=1.3.1
  Using cached scipy-1.7.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl (28.5 MB)
Collecting pandas>=0.25.1
  Using cached pandas-1.3.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (11.3 MB)
Collecting tqdm>=4.60.0
  Using cached tqdm-4.62.3-py2.py3-none-any.whl (76 kB)
Collecting torch==1.6.0
  Downloading torch-1.6.0-cp37-cp37m-manylinux1_x86_64.whl (748.8 MB)
     |████████████████████████████████| 748.8 MB 22 kB/s
Collecting scikit_learn>=0.22.2
  Downloading scikit_learn-0.24.2-cp37-cp37m-manylinux2010_x86_64.whl (22.3 MB)
     |████████████████████████████████| 22.3 MB 3.5 MB/s
Collecting dgl==0.4.3
  Downloading dgl-0.4.3-cp37-cp37m-manylinux1_x86_64.whl (3.0 MB)
     |████████████████████████████████| 3.0 MB 4.3 MB/s
Collecting xlrd==1.2.0
  Using cached xlrd-1.2.0-py2.py3-none-any.whl (103 kB)
Collecting networkx>=2.1
  Downloading networkx-2.6.3-py3-none-any.whl (1.9 MB)
     |████████████████████████████████| 1.9 MB 5.1 MB/s
Collecting requests>=2.19.0
  Using cached requests-2.26.0-py2.py3-none-any.whl (62 kB)
Collecting future
  Downloading future-0.18.2.tar.gz (829 kB)
     |████████████████████████████████| 829 kB 4.9 MB/s
Collecting python-dateutil>=2.7.3
  Using cached python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Collecting pytz>=2017.3
  Using cached pytz-2021.1-py2.py3-none-any.whl (510 kB)
Collecting six>=1.5
  Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting idna<4,>=2.5
  Using cached idna-3.2-py3-none-any.whl (59 kB)
Collecting charset-normalizer~=2.0.0
  Downloading charset_normalizer-2.0.6-py3-none-any.whl (37 kB)
Collecting urllib3<1.27,>=1.21.1
  Downloading urllib3-1.26.7-py2.py3-none-any.whl (138 kB)
     |████████████████████████████████| 138 kB 4.8 MB/s
Requirement already satisfied: certifi>=2017.4.17 in /home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages (from requests>=2.19.0->dgl==0.4.3->deepsort==1.0) (2021.5.30)
Collecting threadpoolctl>=2.0.0
  Downloading threadpoolctl-2.2.0-py3-none-any.whl (12 kB)
Collecting joblib>=0.11
  Using cached joblib-1.0.1-py3-none-any.whl (303 kB)
Building wheels for collected packages: deepsort, future
  Building wheel for deepsort (setup.py) ... done
  Created wheel for deepsort: filename=deepsort-1.0-py3-none-any.whl size=974205126 sha256=2c293acf8974cbdc6b0d8b657fd27e0918f0dfcb7998c899806cca89116c6505
  Stored in directory: /home/shaoxin/.cache/pip/wheels/dc/c2/92/46869404f84e22017324ea8ef5ced686f65e12c960db8508c6
  Building wheel for future (setup.py) ... done
  Created wheel for future: filename=future-0.18.2-py3-none-any.whl size=491070 sha256=10a0534a8da42e90956d04ff3647c9e4d55e00c25b92ad8cb30f0932fac3d435
  Stored in directory: /home/shaoxin/.cache/pip/wheels/56/b0/fe/4410d17b32f1f0c3cf54cdfb2bc04d7b4b8f4ae377e2229ba0
Successfully built deepsort future
Installing collected packages: urllib3, six, numpy, idna, charset-normalizer, threadpoolctl,scipy, requests, pytz, python-dateutil, networkx, joblib, future, xlrd, tqdm, torch, scikit-learn, pandas, dgl, deepsort
Successfully installed charset-normalizer-2.0.6 deepsort-1.0 dgl-0.4.3 future-0.18.2 idna-3.2 joblib-1.0.1 networkx-2.6.3 numpy-1.21.2 pandas-1.3.3 python-dateutil-2.8.2 pytz-2021.1 requests-2.26.0 scikit-learn-0.24.2 scipy-1.7.1 six-1.16.0 threadpoolctl-2.2.0 torch-1.6.0 tqdm-4.62.3 urllib3-1.26.7 xlrd-1.2.0
(scDeepSort) shaoxin@krypton-7820T:~/workspace/scDeepSort$ python
Python 3.7.11 (default, Jul 27 2021, 14:32:16)
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import deepsort
DGL does not detect a valid backend option. Which backend would you like to work with?
Backend choice (pytorch, mxnet or tensorflow): pytorch
Set the default backend to "pytorch". You can change it in the ~/.dgl/config.json file or export the DGLBACKEND environment variable.
>>> import deepsort
>>> deepsort.demo()
Start to test built-in demo file.
The build graph contains 20428 gene nodes with 12 labels supported.
demo_file.csv -> Nonzero Ratio: 8.56%
Totally 28 cells in demo_file.csv
Time Consumed: 0.26 seconds.
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/deepsort/demo.py", line 9, in demo
    result = predictor.predict(demo_file)
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/deepsort/predict.py", line 51, in predict
    df = self.__get_result_dataframe(input_file, pred, test_dict['origin_id'][input_file])
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/deepsort/predict.py", line 96, in __get_result_dataframe
    names=['species', 'old_type', 'new_type', 'new_subtype'])
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/pandas/util/_decorators.py", line 311, in wrapper
    return func(*args, **kwargs)
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/pandas/io/excel/_base.py", line 364, in read_excel
    io = ExcelFile(io, storage_options=storage_options, engine=engine)
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/pandas/io/excel/_base.py", line 1233, in __init__
    self._reader = self._engines[engine](self._io, storage_options=storage_options)
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/pandas/io/excel/_openpyxl.py", line 521, in __init__
    import_optional_dependency("openpyxl")
  File "/home/shaoxin/anaconda3/envs/scDeepSort/lib/python3.7/site-packages/pandas/compat/_optional.py", line 118, in import_optional_dependency
    raise ImportError(msg) from None
ImportError: Missing optional dependency 'openpyxl'.  Use pip or conda to install openpyxl.
>>> quit()
(scDeepSort) shaoxin@krypton-7820T:~/workspace/scDeepSort$ pip install openpyxl
Collecting openpyxl
  Downloading openpyxl-3.0.9-py2.py3-none-any.whl (242 kB)
     |████████████████████████████████| 242 kB 754 kB/s
Collecting et-xmlfile
  Downloading et_xmlfile-1.1.0-py3-none-any.whl (4.7 kB)
Installing collected packages: et-xmlfile, openpyxl
Successfully installed et-xmlfile-1.1.0 openpyxl-3.0.9
(scDeepSort) shaoxin@krypton-7820T:~/workspace/scDeepSort$ python
Python 3.7.11 (default, Jul 27 2021, 14:32:16)
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import deepsort
>>> deepsort.demo()
Start to test built-in demo file.
The build graph contains 20428 gene nodes with 12 labels supported.
demo_file.csv -> Nonzero Ratio: 8.56%
Totally 28 cells in demo_file.csv
Time Consumed: 0.23 seconds.
Test successfully!
   index    cell_type cell_subtype
0    C_1  Paneth cell          N/A
1    C_2  Paneth cell          N/A
2    C_3  Paneth cell          N/A
3    C_4  Paneth cell          N/A
4    C_5  Paneth cell          N/A
5    C_6  Paneth cell          N/A
6    C_7  Paneth cell          N/A
7    C_8  Paneth cell          N/A
8    C_9  Paneth cell          N/A
9   C_10  Paneth cell          N/A
10  C_11  Paneth cell          N/A
11  C_12  Paneth cell          N/A
12  C_13  Paneth cell          N/A
13  C_14  Paneth cell          N/A
14  C_15  Paneth cell          N/A
15  C_16  Paneth cell          N/A
16  C_17  Paneth cell          N/A
17  C_18  Paneth cell          N/A
18  C_19  Paneth cell          N/A
19  C_20  Paneth cell          N/A
20  C_21  Paneth cell          N/A
21  C_22  Paneth cell          N/A
22  C_23  Paneth cell          N/A
23  C_24  Paneth cell          N/A
24  C_25  Paneth cell          N/A
25  C_26  Paneth cell          N/A
26  C_27  Paneth cell          N/A
27  C_28  Paneth cell          N/A

from scdeepsort.

RamonYeung avatar RamonYeung commented on August 17, 2024

Please reinstall dependencies and see if it works out. I can not reproduce this issue for now.

Thanks for your attention.

from scdeepsort.

zh-zhang1984 avatar zh-zhang1984 commented on August 17, 2024

Thank you for your suggestions; I reinstall the package, but this time I have another error:

(base) zhangzhongheng@zhangzhhengsMBP ~ % pip install scDeepSort-v1.0-cpu.tar.gz 
Processing ./scDeepSort-v1.0-cpu.tar.gz
Requirement already satisfied: numpy>=1.17.2 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (1.20.3)
Requirement already satisfied: scipy>=1.3.1 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (1.7.1)
Requirement already satisfied: pandas>=0.25.1 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (1.3.3)
Requirement already satisfied: tqdm>=4.60.0 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (4.62.3)
Requirement already satisfied: torch==1.6.0 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (1.6.0)
Requirement already satisfied: scikit_learn>=0.22.2 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (1.0)
Requirement already satisfied: dgl==0.4.3 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (0.4.3)
Requirement already satisfied: xlrd==1.2.0 in ./opt/anaconda3/lib/python3.8/site-packages (from deepsort==1.0) (1.2.0)
Requirement already satisfied: requests>=2.19.0 in ./opt/anaconda3/lib/python3.8/site-packages (from dgl==0.4.3->deepsort==1.0) (2.26.0)
Requirement already satisfied: networkx>=2.1 in ./opt/anaconda3/lib/python3.8/site-packages (from dgl==0.4.3->deepsort==1.0) (2.6.3)
Requirement already satisfied: future in ./opt/anaconda3/lib/python3.8/site-packages (from torch==1.6.0->deepsort==1.0) (0.18.2)
Requirement already satisfied: pytz>=2017.3 in ./opt/anaconda3/lib/python3.8/site-packages (from pandas>=0.25.1->deepsort==1.0) (2021.3)
Requirement already satisfied: python-dateutil>=2.7.3 in ./opt/anaconda3/lib/python3.8/site-packages (from pandas>=0.25.1->deepsort==1.0) (2.8.2)
Requirement already satisfied: six>=1.5 in ./opt/anaconda3/lib/python3.8/site-packages (from python-dateutil>=2.7.3->pandas>=0.25.1->deepsort==1.0) (1.16.0)
Requirement already satisfied: certifi>=2017.4.17 in ./opt/anaconda3/lib/python3.8/site-packages (from requests>=2.19.0->dgl==0.4.3->deepsort==1.0) (2021.5.30)
Requirement already satisfied: urllib3<1.27,>=1.21.1 in ./opt/anaconda3/lib/python3.8/site-packages (from requests>=2.19.0->dgl==0.4.3->deepsort==1.0) (1.26.7)
Requirement already satisfied: charset-normalizer~=2.0.0 in ./opt/anaconda3/lib/python3.8/site-packages (from requests>=2.19.0->dgl==0.4.3->deepsort==1.0) (2.0.6)
Requirement already satisfied: idna<4,>=2.5 in ./opt/anaconda3/lib/python3.8/site-packages (from requests>=2.19.0->dgl==0.4.3->deepsort==1.0) (3.2)
Requirement already satisfied: threadpoolctl>=2.0.0 in ./opt/anaconda3/lib/python3.8/site-packages (from scikit_learn>=0.22.2->deepsort==1.0) (3.0.0)
Requirement already satisfied: joblib>=0.11 in ./opt/anaconda3/lib/python3.8/site-packages (from scikit_learn>=0.22.2->deepsort==1.0) (1.0.1)
DEPRECATION: Source distribution is being reinstalled despite an installed package having the same name and version as the installed package. pip 21.1 will remove support for this functionality. A possible replacement is use --force-reinstall. You can find discussion regarding this at https://github.com/pypa/pip/issues/8711.
Building wheels for collected packages: deepsort
  Building wheel for deepsort (setup.py) ... done
  Created wheel for deepsort: filename=deepsort-1.0-py3-none-any.whl size=974205126 sha256=18ac5c35c9b79d1189d80d984bab3c2f40818f98370a15990a1b04a7a0952f6f
  Stored in directory: /Users/zhangzhongheng/Library/Caches/pip/wheels/c7/5d/c0/03e201b4cbe07bf78136bb3420caeaf283cd190469f0bf46f6
Successfully built deepsort
Installing collected packages: deepsort
  Attempting uninstall: deepsort
    Found existing installation: deepsort 1.0
    Uninstalling deepsort-1.0:
      Successfully uninstalled deepsort-1.0
Successfully installed deepsort-1.0
(base) zhangzhongheng@zhangzhhengsMBP ~ % python
Python 3.8.8 (default, Apr 13 2021, 12:59:45) 
[Clang 10.0.0 ] :: Anaconda, Inc. on darwin
Type "help", "copyright", "credits" or "license" for more information.
> deepsort$demo()
Error in py_call_impl(callable, dots$args, dots$keywords) : 
  ValueError: Expecting a string device name. Got <class 'torch.device'>(cpu)

Detailed traceback:
  File "/Users/zhangzhongheng/.virtualenvs/r-reticulate/lib/python3.8/site-packages/deepsort/demo.py", line 9, in demo
    result = predictor.predict(demo_file)
  File "/Users/zhangzhongheng/.virtualenvs/r-reticulate/lib/python3.8/site-packages/deepsort/predict.py", line 46, in predict
    test_dict = self.__load_test_data(input_files)
  File "/Users/zhangzhongheng/.virtualenvs/r-reticulate/lib/python3.8/site-packages/deepsort/predict.py", line 219, in __load_test_data
    test_graph_dict[test_file].add_nodes(self.__num_cells, {'id': cell_ids})
  File "/Users/zhangzhongheng/.virtualenvs/r-reticulate/lib/python3.8/site-packages/dgl/graph.py", line 810, in inner
    func(g, *args, **kwargs)
  File "/Users/zhangzhongheng/.virtualenvs/r-reticulate/lib/python3.8/site-packages/dgl/graph.py", line 1097, in add_nodes
    self._node_frame.append(data)
  File "/Users/zhangzhongheng/.virtuale

from scdeepsort.

multitalk avatar multitalk commented on August 17, 2024

Backend choice (pytorch, mxnet or tensorflow): pytorch

from scdeepsort.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.