当前位置:网站首页>解决python调用 ffmpeg时 ‘ffmpeg‘ 不是内部或外部命令,也不是可运行的程序
解决python调用 ffmpeg时 ‘ffmpeg‘ 不是内部或外部命令,也不是可运行的程序
2020-11-09 08:25:00 【osc_ucqb2u3q】
解决 python 调用 ffmpeg时 ‘ffmpeg’ 不是内部或外部命令,也不是可运行的程序
在windows系统下, 我们使用windows下,使用ffmpeg库调用FFmpeg工具来提取视频的图片/读取视频信息
import ffmpeg
我们可能会遇到以下问题
'ffmpeg' 不是内部或外部命令,也不是可运行的程序
这原因是什么呢?
python 的ffmpeg 是使用subprocess.Popen()函数来调用命令行,然后得到返回的数据。就相当于python 在你系统的cmd里面输入 ffmpeg xxx xxx xxx xxx
然后系统给你报错 ‘ffmpeg’ 不是内部或外部命令,也不是可运行的程序
那么有两种原因:
- 没安装 ffmpeg
那么请参考安装 ffmpeg - 没加入环境变量
请参考:https://blog.csdn.net/tang_chuanlin/article/details/103749351
但是最快的方法就是, 当你下载好 ffmpeg
然后解压, 记下bin的路径
E://anaconda//ffmpeg-4.3.1//bin//
然后修改ffmpeg的那块代码
- 《你的python包路径 》/site-packages/ffmpeg/_probe.py
直接加上ffmpeg的路径即可
- 《你的python包路径 》/site-packages/ffmpeg/_run.py
直接加上ffmpeg的路径即可
版权声明
本文为[osc_ucqb2u3q]所创,转载请带上原文链接,感谢
https://my.oschina.net/u/4327623/blog/4708535
边栏推荐
- 程序员都应该知道的URI,一文帮你全面了解
- The vowels in the inverted string of leetcode
- 商品管理系统——整合仓库服务以及获取仓库列表
- When iperf is installed under centos7, the solution of make: * no targets specified and no makefile found. Stop
- 亚马逊的无服务器总线EventBridge支持事件溯源 - AWS
- 2. Introduction to computer hardware
- Leetcode-15: sum of three numbers
- Leetcode-11: container with the most water
- Android emulator error: x86 emulation currently requires hardware acceleration的解决方案
- Windows环境下如何进行线程Dump分析
猜你喜欢
GDI 及OPENGL的区别
Ten year itch of programmer
Three ways to operate tables in Apache iceberg
[Python from zero to one] 5. Detailed explanation of beautiful soup basic syntax of web crawler
Have you ever thought about why the transaction and refund have to be split into different tables
2.计算机硬件简介
The difference between GDI and OpenGL
商品管理系统——SPU检索功能
Tips in Android Development: requires permission android.permission write_ Settings solution
上线1周,B.Protocal已有7000ETH资产!
随机推荐
Share API on the web
2 普通模式
How does FC game console work?
Apache Iceberg 中三种操作表的方式
When iperf is installed under centos7, the solution of make: * no targets specified and no makefile found. Stop
python生日贺卡制作以及细节问题的解决最后把python项目发布为exe可执行程序过程
商品管理系统——整合仓库服务以及获取仓库列表
Several common playing methods of sub database and sub table and how to solve the problem of cross database query
This program cannot be started because msvcp120.dll is missing from your computer. Try to install the program to fix the problem
作业2020.11.7-8
服务器性能监控神器nmon使用介绍
14. Introduction to kubenetes
2. Introduction to computer hardware
[Python从零到壹] 五.网络爬虫之BeautifulSoup基础语法万字详解
leetcode之反转字符串中的元音字母
Dark网站的后端为什么选择F#? - darklang
App crashed inexplicably. At first, it thought it was the case of the name in the header. Finally, it was found that it was the fault of the container!
Start learning discrete mathematics again
20201108编程练习——练习3
Commodity management system -- the search function of SPU