我在安装Conda软件包时遇到了一些问题。与其他Conda在解决源代码时滞后的问题不同,我的Conda总是在安装了所有必要的软件后滞后(至少我是这样认为的)。下面是最近的一个例子:
(DGE_smk_minimal) [name@server DGE-co-culture-workflow]$ conda install snakemake
Fetching package metadata .............
Solving package specifications: .
Package plan for installation in environment /home/kve/.conda/envs/DGE_smk_minimal:
The following NEW packages will be INSTALLED:
aioeasywebdav: 2.4.0-py39hf3d152e_1001 conda-forge
aiohttp: 3.7.4.post0-py39h3811e60_0 conda-forge
amply: 0.1.4-py_0 conda-forge
appdirs: 1.4.4-pyh9f0ad1d_0 conda-forge
async-timeout: 3.0.1-py_1000 conda-forge
atk-1.0: 2.36.0-h3371d22_4 conda-forge
attmap: 0.13.0-pyhd8ed1ab_0 conda-forge
attrs: 21.2.0-pyhd8ed1ab_0 conda-forge
backports: 1.0-py_2 conda-forge
backports.functools_lru_cache: 1.6.4-pyhd8ed1ab_0 conda-forge
bcrypt: 3.2.0-py39h3811e60_1 conda-forge
boto3: 1.18.26-pyhd8ed1ab_0 conda-forge
botocore: 1.21.26-pyhd8ed1ab_0 conda-forge
brotlipy: 0.7.0-py39h38d8fee_1001 conda-forge
cachetools: 4.2.2-pyhd8ed1ab_0 conda-forge
cairo: 1.16.0-h6cf1ce9_1008 conda-forge
certifi: 2021.5.30-py39hf3d152e_0 conda-forge
cffi: 1.14.6-py39he32792d_0 conda-forge
chardet: 4.0.0-py39hf3d152e_1 conda-forge
charset-normalizer: 2.0.0-pyhd8ed1ab_0 conda-forge
coincbc: 2.10.5-hcee13e7_1 conda-forge
configargparse: 1.5.2-pyhd8ed1ab_0 conda-forge
connection_pool: 0.0.3-pyhd3deb0d_0 conda-forge
cryptography: 3.4.7-py39hbca0aa6_0 conda-forge
datrie: 0.8.2-py39h3811e60_2 conda-forge
decorator: 5.0.9-pyhd8ed1ab_0 conda-forge
docutils: 0.17.1-py39hf3d152e_0 conda-forge
dropbox: 10.9.0-pyhd3deb0d_0 conda-forge
filechunkio: 1.8-py_2 conda-forge
filelock: 3.0.12-pyh9f0ad1d_0 conda-forge
fontconfig: 2.13.1-hba837de_1005 conda-forge
freetype: 2.10.4-h0708190_1 conda-forge
ftputil: 5.0.1-pyhd8ed1ab_0 conda-forge
gdk-pixbuf: 2.42.6-h04a7f16_0 conda-forge
gitdb: 4.0.7-pyhd8ed1ab_0 conda-forge
gitpython: 3.1.18-pyhd8ed1ab_0 conda-forge
google-api-core: 1.31.2-pyhd8ed1ab_0 conda-forge
google-api-python-client: 2.17.0-pyhd8ed1ab_0 conda-forge
google-auth: 1.35.0-pyh6c4a22f_0 conda-forge
google-auth-httplib2: 0.1.0-pyhd8ed1ab_0 conda-forge
google-cloud-core: 1.7.2-pyh6c4a22f_0 conda-forge
google-cloud-storage: 1.42.0-pyh6c4a22f_0 conda-forge
google-crc32c: 1.1.2-py39hb81f231_0 conda-forge
google-resumable-media: 1.3.3-pyh6c4a22f_0 conda-forge
googleapis-common-protos: 1.53.0-py39hf3d152e_0 conda-forge
graphviz: 2.48.0-h85b4f2f_0 conda-forge
grpcio: 1.38.1-py39hff7568b_0 conda-forge
gtk2: 2.24.33-h539f30e_1 conda-forge
gts: 0.7.6-h64030ff_2 conda-forge
harfbuzz: 2.9.0-h83ec7ef_0 conda-forge
httplib2: 0.19.1-pyhd8ed1ab_0 conda-forge
idna: 3.1-pyhd3deb0d_0 conda-forge
imagemagick: 7.1.0_5-pl5321hb118871_0 conda-forge
importlib-metadata: 4.6.4-py39hf3d152e_0 conda-forge
iniconfig: 1.1.1-pyh9f0ad1d_0 conda-forge
ipython_genutils: 0.2.0-py_1 conda-forge
jinja2: 3.0.1-pyhd8ed1ab_0 conda-forge
jmespath: 0.10.0-pyh9f0ad1d_0 conda-forge
jsonschema: 3.2.0-pyhd8ed1ab_3 conda-forge
jupyter_core: 4.7.1-py39hf3d152e_0 conda-forge
libblas: 3.9.0-11_linux64_openblas conda-forge
libcblas: 3.9.0-11_linux64_openblas conda-forge
libgd: 2.3.2-h78a0170_0 conda-forge
libglib: 2.68.4-h3e27bee_0 conda-forge
liblapack: 3.9.0-11_linux64_openblas conda-forge
libpng: 1.6.37-hed695b0_2 conda-forge
libprotobuf: 3.17.2-h780b84a_1 conda-forge
librsvg: 2.50.7-hc3c00ef_0 conda-forge
libtiff: 4.3.0-hf544144_1 conda-forge
libwebp: 1.2.1-h3452ae3_0 conda-forge
libxcb: 1.13-h7f98852_1003 conda-forge
libxml2: 2.9.12-h72842e0_0 conda-forge
logmuse: 0.2.6-pyh8c360ce_0 conda-forge
markupsafe: 2.0.1-py39h3811e60_0 conda-forge
more-itertools: 8.8.0-pyhd8ed1ab_0 conda-forge
multidict: 5.1.0-py39h3811e60_1 conda-forge
nbformat: 5.1.3-pyhd8ed1ab_0 conda-forge
networkx: 2.5-py_0 conda-forge
numpy: 1.21.2-py39hdbf815f_0 conda-forge
oauth2client: 4.1.3-py_0 conda-forge
openjpeg: 2.4.0-hb52868f_1 conda-forge
packaging: 21.0-pyhd8ed1ab_0 conda-forge
pandas: 1.3.2-py39hde0f152_0 conda-forge
pango: 1.48.9-hb8ff022_0 conda-forge
paramiko: 2.7.2-pyh9f0ad1d_0 conda-forge
peppy: 0.31.1-pyhd8ed1ab_0 conda-forge
pip: 21.2.4-pyhd8ed1ab_0 conda-forge
pluggy: 0.13.1-py39hf3d152e_4 conda-forge
prettytable: 2.1.0-pyhd8ed1ab_0 conda-forge
protobuf: 3.17.2-py39he80948d_0 conda-forge
psutil: 5.8.0-py39h3811e60_1 conda-forge
pulp: 2.5.0-py39hf3d152e_0 conda-forge
py: 1.10.0-pyhd3deb0d_0 conda-forge
pyasn1: 0.4.8-py_0 conda-forge
pyasn1-modules: 0.2.7-py_0 conda-forge
pycparser: 2.20-pyh9f0ad1d_2 conda-forge
pygments: 2.10.0-pyhd8ed1ab_0 conda-forge
pygraphviz: 1.7-py39h78163bd_0 conda-forge
pynacl: 1.4.0-py39h3811e60_2 conda-forge
pyopenssl: 20.0.1-pyhd8ed1ab_0 conda-forge
pyparsing: 2.4.7-pyh9f0ad1d_0 conda-forge
pyrsistent: 0.17.3-py39h3811e60_2 conda-forge
pysftp: 0.2.9-py_1 conda-forge
pysocks: 1.7.1-py39hf3d152e_3 conda-forge
pytest: 6.2.4-py39hf3d152e_0 conda-forge
python: 3.9.6-h49503c6_1_cpython conda-forge
python-dateutil: 2.8.2-pyhd8ed1ab_0 conda-forge
python-irodsclient: 1.0.0-pyhd8ed1ab_0 conda-forge
python_abi: 3.9-2_cp39 conda-forge
pytz: 2021.1-pyhd8ed1ab_0 conda-forge
pyu2f: 0.1.5-pyhd8ed1ab_0 conda-forge
pyyaml: 5.4.1-py39h3811e60_1 conda-forge
ratelimiter: 1.2.0-py_1002 conda-forge
readline: 8.1-h46c0cb4_0 conda-forge
requests: 2.26.0-pyhd8ed1ab_0 conda-forge
rsa: 4.7.2-pyh44b312d_0 conda-forge
s3transfer: 0.5.0-pyhd8ed1ab_0 conda-forge
setuptools: 57.4.0-py39hf3d152e_0 conda-forge
simplejson: 3.17.4-py39h3811e60_0 conda-forge
six: 1.16.0-pyh6c4a22f_0 conda-forge
slacker: 0.14.0-py_0 conda-forge
smart_open: 5.2.0-pyhd8ed1ab_0 conda-forge
smmap: 3.0.5-pyh44b312d_0 conda-forge
snakemake: 6.7.0-hdfd78af_0 bioconda
snakemake-minimal: 6.7.0-pyhdfd78af_0 bioconda
sqlite: 3.36.0-h9cd32fc_0 conda-forge
stopit: 1.1.2-py_0 conda-forge
tabulate: 0.8.9-pyhd8ed1ab_0 conda-forge
tk: 8.6.11-h21135ba_0 conda-forge
toml: 0.10.2-pyhd8ed1ab_0 conda-forge
toposort: 1.6-pyhd8ed1ab_0 conda-forge
traitlets: 5.0.5-py_0 conda-forge
typing-extensions: 3.10.0.0-hd8ed1ab_0 conda-forge
typing_extensions: 3.10.0.0-pyha770c72_0 conda-forge
ubiquerg: 0.6.1-pyh9f0ad1d_0 conda-forge
uritemplate: 3.0.1-py_0 conda-forge
urllib3: 1.26.6-pyhd8ed1ab_0 conda-forge
veracitools: 0.1.3-py_0 conda-forge
wcwidth: 0.2.5-pyh9f0ad1d_2 conda-forge
wheel: 0.37.0-pyhd8ed1ab_1 conda-forge
wrapt: 1.12.1-py39h3811e60_3 conda-forge
xmlrunner: 1.7.7-py_0 conda-forge
xorg-libsm: 1.2.3-hd9c2040_1000 conda-forge
xorg-libx11: 1.7.2-h7f98852_0 conda-forge
xorg-libxext: 1.3.4-h7f98852_1 conda-forge
xorg-libxrender: 0.9.10-h7f98852_1003 conda-forge
xorg-libxt: 1.2.1-h7f98852_2 conda-forge
yarl: 1.5.1-py39h07f9747_0 conda-forge
zipp: 3.5.0-pyhd8ed1ab_0 conda-forge
zstd: 1.5.0-ha95c52a_0 conda-forge
Proceed ([y]/n)? y
simplejson-3.1 100% |##################################################################################################################| Time: 0:00:00 363.11 kB/s
imagemagick-7. 100% |##################################################################################################################| Time: 0:00:00 12.48 MB/s
现在它已经挂在台阶上30分钟了。有时,似乎到了列表的末尾,就像这样挂起/失败了。我已经等了30分钟了,没有任何结果,只好关闭了终端。这在上个月之前还不是问题,但现在越来越严重,已经到了失败的地步。
是否有一种方法来检查为什么会发生这种情况/一种方法来查看正在执行的子进程?作为一名科学家,我对命令行工具还是一个相对的新手。
或者,我可以运行一个清理命令使它更快吗?我真不明白为什么要花这么长时间。
您可以尝试两种方法。如果你还没有使用它,其中一个东西会改变你的性生活。
第一个简单的:有一个干净的命令你应该经常运行。conda clean -h
获取更多信息。我通常只是偶尔运行conda clean --all --yes
。
游戏改变者:使用曼巴代替conda*(实际上更多的是作为补充)。Mamba(https://github.com/mamba-org/mamba)是用c重写的conda。如果你已经习惯了conda的构建时间,那么Mamba将会让你大吃一惊。它是这样工作的:
1:你将mamba安装到conda base中(通常不允许在conda base中安装任何东西,但这是一个例外——Snakemake甚至公开鼓励使用它)。
conda install mamba -n base -c conda-forge
现在,继续前进,任何你想用'conda'的地方你都用'mamba',并得到一些你的生命回报,而不是等待conda:-)——有一个例外。你仍然需要基本的conda安装&&要激活环境,仍然需要指定conda activate和conda deactivate。最重要的是,如果你错误地(或故意地)把conda和mamba互换使用,这是没有问题的——我想你不会想要的。