安装pytorch时出现以下错误
pip install http://download.pytorch.org/whl/cu80/torch-0.1.11.post5-cp27-none-linux_x86_64.whl
Collecting torch==0.1.11.post5 from http://download.pytorch.org/whl/cu80/torch-0.1.11.post5-cp27-none-linux_x86_64.whl
Downloading http://download.pytorch.org/whl/cu80/torch-0.1.11.post5-cp27-none-linux_x86_64.whl (475.7MB)
100% |████████████████████████████████| 475.7MB 3.5MB/s
以下错误
Exception:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/usr/local/lib/python2.7/dist-packages/pip/commands/install.py", line 335, in run
wb.build(autobuilding=True)
File "/usr/local/lib/python2.7/dist-packages/pip/wheel.py", line 749, in build
self.requirement_set.prepare_files(self.finder)
File "/usr/local/lib/python2.7/dist-packages/pip/req/req_set.py", line 380, in prepare_files
ignore_dependencies=self.ignore_dependencies))
File "/usr/local/lib/python2.7/dist-packages/pip/req/req_set.py", line 620, in _prepare_file
session=self.session, hashes=hashes)
File "/usr/local/lib/python2.7/dist-packages/pip/download.py", line 821, in unpack_url
hashes=hashes
File "/usr/local/lib/python2.7/dist-packages/pip/download.py", line 663, in unpack_http_url
unpack_file(from_path, location, content_type, link)
File "/usr/local/lib/python2.7/dist-packages/pip/utils/__init__.py", line 599, in unpack_file
flatten=not filename.endswith('.whl')
File "/usr/local/lib/python2.7/dist-packages/pip/utils/__init__.py", line 501, in unzip_file
fp.write(data)
IOError: [Errno 28] No space left on device
你怎么了?我不明白错误来自/python2.7/dist-packages/pip/
3条答案
按热度按时间vsikbqxv1#
在我的情况下,系统
/tmp
用完了空间,因此尽管安装路径有足够的空间,但仍然存在错误。export TMPDIR=/where/you/have/enough/space/left
为我解决了这个问题。uelo1irk2#
面对并解决了同样的问题,当我
pip uninstall pipenv
,然后没有错误发生,也许你应该卸载一些python包。y3bcpkx13#
for me@user495285 answer made the trick(
export TMPDIR=/where/you/have/enough/space/left
)请注意,我跟踪了该特定位置上使用的pytorch安装空间,在高峰期,它需要7.1GB在2023年9月安装以下dist包: