syuoni / eznlp

Easy Natural Language Processing
Apache License 2.0
130 stars 21 forks source link

Can't Install eznlp version 0.2.3 #32

Closed namdh15 closed 1 year ago

namdh15 commented 1 year ago

Hi. I got this problem when I run install

pip install dist/eznlp-{version}.tar.gz

ERROR: Cannot install eznlp and eznlp==0.2.3 because these package versions have conflicting dependencies.

The conflict is caused by: eznlp 0.2.3 depends on transformers==4.3.2 allennlp 2.0.1 depends on transformers<4.3 and >=4.1

To fix this you could try to:

  1. loosen the range of package versions you've specified
  2. remove package versions to allow pip attempt to solve the dependency conflict

Can u help me? Tks

syuoni commented 1 year ago

Hi,

There do exist some dependency conflicts for version 0.2.3. You can install eznlp by following the instructions in the (current) README file.

Enwei

chuanqin8 commented 1 year ago

Hi,

There do exist some dependency conflicts for version 0.2.3. You can install eznlp by following the instructions in the (current) README file.

Enwei

似乎还有一些bug(完全按照README) $ pip install dist/eznlp-0.2.3.tar.gz --no-deps DEPRECATION: Python 3.5 reached the end of its life on September 13th, 2020. Please upgrade your Python as Python 3.5 is no longer maintained. pip 21.0 will drop support for Python 3.5 in January 2021. pip 21.0 will remove support for this functionality. Defaulting to user installation because normal site-packages is not writeable Looking in indexes: https://pypi.doubanio.com/simple Processing ./dist/eznlp-0.2.3.tar.gz ERROR: Command errored out with exit status 1: command: /usr/bin/python3.5 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-req-build-1k5kiyyo/setup.py'"'"'; file='"'"'/tmp/pip-req-build-1k5kiyyo/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-bjwg2c8l cwd: /tmp/pip-req-build-1k5kiyyo/ Complete output (5 lines): Traceback (most recent call last): File "", line 1, in File "/tmp/pip-req-build-1k5kiyyo/setup.py", line 10, in version = re.search(r'version = (["\'])([^"\']*)\1', f.read())[2] TypeError: '_sre.SRE_Match' object is not subscriptable

WARNING: Discarding file:///media4/507/MovedFromHome/507/qc/eznlp-master/dist/eznlp-0.2.3.tar.gz. Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output. ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

lanyangyang93 commented 1 year ago

使用机器型号NVIDIA RTX A6000; CUDA Version: 11.4 ;python==3.8.0 修改README第二条命令 $ conda install numpy=1.18.5 pandas=1.0.5 xlrd=1.2.0 matplotlib=3.2.2 $ conda install pytorch==1.10.0 torchvision==0.11.0 torchaudio==0.10.0 cudatoolkit=11.3 -c pytorch -c conda-forge $ pip install -r requirements.txt $ python setup.py sdist $ pip install dist/eznlp-0.2.3.tar.gz --no-deps 即可安装成功 如果运行中出现问题: pkg_resources.DistributionNotFound: The 'tqdm>=4.27' distribution was not found and is required by this application, 请执行 pip install transformers -U

wangly0276 commented 1 year ago

你好,我用该方法配置,会出现numpy的bool报错,说明是numpy在 1.20之后就不支持np.bool,要不升级要不改文件,但是改文件没有用,只要一升级版本,整个eznlp就有错了,请问最后的怎么处理的

lanyangyang93 commented 1 year ago

我并没遇见你这样的错误,我将numpy版本改到1.22.1也能执行程序,可能是你没安装好某些包

syuoni commented 1 year ago

我已经修复了依赖项问题,目前版本在我们的服务器上从头安装没有遇到问题。

请参考最新版 README,强烈建议使用 conda 虚拟环境(多数依赖项问题是 和已经安装的包版本冲突 造成的)。

lanyangyang93 commented 1 year ago

您的邮件我已经收到,谢谢