我试图将picamera安装到我的python 3.5上的Windows 10带有PIP 9。
另外,我在网上看,知道我需要安装Pyyaml,而且我做到了。这真的很奇怪,一些建议是,PIP需要与setup.py相同的位置?这更令人困惑。无论如何,下面是我所做的,希望它有帮助。
concuted命令:
pip install --user picamera
命令输出:
Collecting picamera
Using cached picamera-1.13.tar.gz
Building wheels for collected packages: picamera
Running setup.py bdist_wheel for picamera: started
Running setup.py bdist_wheel for picamera: finished with status 'error'
Complete output from command C:UsersDellAppDataLocalProgramsPythonPython35python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\Dell\AppData\Local\Temp\pycharm-packaging\picamera\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('rn', 'n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:UsersDellAppDataLocalTemptmpfj3othpnpip-wheel- --python-tag cp35:
running bdist_wheel
running build
running build_py
creating build
creating buildlib
creating buildlibpicamera
copying picameraarray.py -> buildlibpicamera
copying picamerabcm_host.py -> buildlibpicamera
copying picameracamera.py -> buildlibpicamera
copying picameracolor.py -> buildlibpicamera
copying picameradisplay.py -> buildlibpicamera
copying picameraencoders.py -> buildlibpicamera
copying picameraexc.py -> buildlibpicamera
copying picameraframes.py -> buildlibpicamera
copying picamerammal.py -> buildlibpicamera
copying picamerammalobj.py -> buildlibpicamera
copying picamerarenderers.py -> buildlibpicamera
copying picamerastreams.py -> buildlibpicamera
copying picamera__init__.py -> buildlibpicamera
running egg_info
writing picamera.egg-infoPKG-INFO
writing requirements to picamera.egg-inforequires.txt
writing dependency_links to picamera.egg-infodependency_links.txt
writing top-level names to picamera.egg-infotop_level.txt
warning: manifest_maker: standard file '-c' not found
reading manifest file 'picamera.egg-infoSOURCES.txt'
reading manifest template 'MANIFEST.in'
no previously-included directories found matching 'debian'
no previously-included directories found matching 'docs'
writing manifest file 'picamera.egg-infoSOURCES.txt'
warning: build_py: byte-compiling is disabled, skipping.
installing to buildbdist.win-amd64wheel
running install
Traceback (most recent call last):
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 101, in run
with io.open('/proc/cpuinfo', 'r') as cpuinfo:
FileNotFoundError: [Errno 2] No such file or directory: '/proc/cpuinfo'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 145, in <module>
main()
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 140, in main
cmdclass = {'install': CustomInstallCommand},
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilscore.py", line 148, in setup
dist.run_commands()
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilsdist.py", line 955, in run_commands
self.run_command(cmd)
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilsdist.py", line 974, in run_command
cmd_obj.run()
File "C:UsersDellAppDataRoamingPythonPython35site-packageswheelbdist_wheel.py", line 240, in run
self.run_command('install')
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilscmd.py", line 313, in run_command
self.distribution.run_command(command)
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilsdist.py", line 974, in run_command
cmd_obj.run()
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 113, in run
raise ValueError('Unable to open /proc/cpuinfo')
ValueError: Unable to open /proc/cpuinfo
----------------------------------------
Running setup.py clean for picamera
Failed to build picamera
Installing collected packages: picamera
Running setup.py install for picamera: started
Running setup.py install for picamera: finished with status 'error'
Complete output from command C:UsersDellAppDataLocalProgramsPythonPython35python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\Dell\AppData\Local\Temp\pycharm-packaging\picamera\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('rn', 'n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:UsersDellAppDataLocalTemppip-x3ancwkq-recordinstall-record.txt --single-version-externally-managed --compile --user --prefix=:
running install
Traceback (most recent call last):
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 101, in run
with io.open('/proc/cpuinfo', 'r') as cpuinfo:
FileNotFoundError: [Errno 2] No such file or directory: '/proc/cpuinfo'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 145, in <module>
main()
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 140, in main
cmdclass = {'install': CustomInstallCommand},
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilscore.py", line 148, in setup
dist.run_commands()
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilsdist.py", line 955, in run_commands
self.run_command(cmd)
File "C:UsersDellAppDataLocalProgramsPythonPython35libdistutilsdist.py", line 974, in run_command
cmd_obj.run()
File "C:UsersDellAppDataLocalTemppycharm-packagingpicamerasetup.py", line 113, in run
raise ValueError('Unable to open /proc/cpuinfo')
ValueError: Unable to open /proc/cpuinfo
----------------------------------------
Failed building wheel for picamera
Command "C:UsersDellAppDataLocalProgramsPythonPython35python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\Dell\AppData\Local\Temp\pycharm-packaging\picamera\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('rn', 'n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:UsersDellAppDataLocalTemppip-x3ancwkq-recordinstall-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in C:UsersDellAppDataLocalTemppycharm-packagingpicamera
发生错误:
FileNotFoundError: [Errno 2] No such file or directory: '/proc/cpuinfo'
尝试使用Pycharm安装它,但仍然没有运气
filenotfounderror:[errno 2]没有这样的文件或目录:'/proc/cpuinfo'
导致该文件仅存在于Linux或Unix型系统中,而不在Windows系统或Mac系统中。这就是为什么您无法成功插入。
我与Kivy和Python合作时遇到了同样的问题
出现一个错误,说"找到名为picamera的模块"
解决方案有助于我解决:
pip install opencv-python
是的。!它帮助我,可能对您有用。
编辑:我在Python 3.7(OS:Windows 10)上尝试了此
虽然它旧,但对于遇到同一问题的任何人可能都是有用的。步骤。
- 开放终端(如果您有虚拟env,请激活它)
- type'设置readthedocs = true&quot'
- pip安装picamera或者4.PIP安装PICAMERA [array]