{"id":958150,"date":"2024-12-27T03:16:34","date_gmt":"2024-12-26T19:16:34","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/958150.html"},"modified":"2024-12-27T03:16:36","modified_gmt":"2024-12-26T19:16:36","slug":"%e5%a6%82%e4%bd%95%e5%af%bc%e5%87%bapython%e4%b8%ba%e8%a7%86%e9%a2%91","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/958150.html","title":{"rendered":"\u5982\u4f55\u5bfc\u51fapython\u4e3a\u89c6\u9891"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25101234\/de190b67-a8b3-4089-bd5a-10b527458d34.webp\" alt=\"\u5982\u4f55\u5bfc\u51fapython\u4e3a\u89c6\u9891\" \/><\/p>\n<p><p> \u5bfc\u51faPython\u4e3a\u89c6\u9891\u7684\u8fc7\u7a0b\u6d89\u53ca<strong>\u9009\u62e9\u5408\u9002\u7684\u5e93\u3001\u7f16\u5199\u811a\u672c\u751f\u6210\u56fe\u50cf\u5e27\u3001\u4f7f\u7528\u89c6\u9891\u7f16\u5199\u5de5\u5177\u5c06\u5e27\u5408\u6210\u4e3a\u89c6\u9891<\/strong>\u3002\u5176\u4e2d\uff0c\u9009\u62e9\u5408\u9002\u7684\u5e93\u662f\u5173\u952e\u7684\u4e00\u6b65\uff0c\u56e0\u4e3a\u4e0d\u540c\u7684\u5e93\u63d0\u4f9b\u7684\u529f\u80fd\u548c\u6613\u7528\u6027\u5404\u4e0d\u76f8\u540c\u3002\u672c\u6587\u5c06\u8be6\u7ec6\u63a2\u8ba8\u5982\u4f55\u5bfc\u51faPython\u4e3a\u89c6\u9891\u7684\u6b65\u9aa4\u4ee5\u53ca\u6bcf\u4e2a\u6b65\u9aa4\u4e2d\u53ef\u80fd\u9047\u5230\u7684\u6311\u6218\u548c\u89e3\u51b3\u65b9\u6848\u3002<\/p>\n<\/p>\n<p><h3>\u4e00\u3001\u9009\u62e9\u5408\u9002\u7684\u5e93<\/h3>\n<\/p>\n<p><p>Python\u4e2d\u6709\u591a\u4e2a\u5e93\u53ef\u4ee5\u7528\u4e8e\u5bfc\u51fa\u89c6\u9891\uff0c\u5305\u62ecOpenCV\u3001MoviePy\u3001matplotlib\u7b49\u3002\u6bcf\u4e2a\u5e93\u90fd\u6709\u5176\u72ec\u7279\u7684\u529f\u80fd\u548c\u9002\u7528\u573a\u666f\u3002<\/p>\n<\/p>\n<p><h4>1. OpenCV<\/h4>\n<\/p>\n<p><p>OpenCV\u662f\u4e00\u4e2a\u529f\u80fd\u5f3a\u5927\u7684\u8ba1\u7b97\u673a\u89c6\u89c9\u5e93\uff0c\u5e7f\u6cdb\u7528\u4e8e\u56fe\u50cf\u5904\u7406\u548c\u89c6\u9891\u64cd\u4f5c\u3002\u5b83\u63d0\u4f9b\u4e86\u4e30\u5bcc\u7684\u5de5\u5177\uff0c\u53ef\u4ee5\u8f7b\u677e\u5c06\u56fe\u50cf\u5e27\u5408\u6210\u4e3a\u89c6\u9891\u3002<\/p>\n<\/p>\n<ul>\n<li><strong>\u4f18\u70b9<\/strong>\uff1a\u652f\u6301\u591a\u79cd\u89c6\u9891\u683c\u5f0f\uff0c\u5904\u7406\u901f\u5ea6\u5feb\uff0c\u529f\u80fd\u5f3a\u5927\u3002<\/li>\n<li><strong>\u7f3a\u70b9<\/strong>\uff1a\u53ef\u80fd\u9700\u8981\u6df1\u5165\u5b66\u4e60\u5176API\uff0c\u5bf9\u4e8e\u521d\u5b66\u8005\u53ef\u80fd\u663e\u5f97\u590d\u6742\u3002<\/li>\n<\/ul>\n<p><h4>2. MoviePy<\/h4>\n<\/p>\n<p><p>MoviePy\u662f\u4e00\u4e2a\u975e\u5e38\u7075\u6d3b\u7684Python\u5e93\uff0c\u4e13\u95e8\u7528\u4e8e\u89c6\u9891\u7f16\u8f91\u548c\u5904\u7406\u3002\u5b83\u53ef\u4ee5\u8f7b\u677e\u5b9e\u73b0\u89c6\u9891\u5408\u6210\u3001\u526a\u8f91\u3001\u6548\u679c\u6dfb\u52a0\u7b49\u529f\u80fd\u3002<\/p>\n<\/p>\n<ul>\n<li><strong>\u4f18\u70b9<\/strong>\uff1a\u6613\u4e8e\u4e0a\u624b\uff0c\u529f\u80fd\u4e30\u5bcc\uff0c\u652f\u6301\u591a\u79cd\u89c6\u9891\u7f16\u8f91\u4efb\u52a1\u3002<\/li>\n<li><strong>\u7f3a\u70b9<\/strong>\uff1a\u5904\u7406\u901f\u5ea6\u53ef\u80fd\u4e0d\u5982OpenCV\u3002<\/li>\n<\/ul>\n<p><h4>3. Matplotlib<\/h4>\n<\/p>\n<p><p>Matplotlib\u662f\u4e00\u4e2a\u7528\u4e8e\u7ed8\u5236\u9759\u6001\u3001\u52a8\u6001\u548c\u4ea4\u4e92\u5f0f\u56fe\u5f62\u7684Python 2D\u7ed8\u56fe\u5e93\u3002\u867d\u7136\u4e3b\u8981\u7528\u4e8e\u7ed8\u56fe\uff0c\u4f46\u4e5f\u53ef\u4ee5\u5c06\u56fe\u50cf\u5e27\u5bfc\u51fa\u4e3a\u89c6\u9891\u3002<\/p>\n<\/p>\n<ul>\n<li><strong>\u4f18\u70b9<\/strong>\uff1a\u7b80\u5355\u6613\u7528\uff0c\u9002\u5408\u7528\u4e8e\u751f\u6210\u52a8\u6001\u56fe\u8868\u3002<\/li>\n<li><strong>\u7f3a\u70b9<\/strong>\uff1a\u4e3b\u8981\u7528\u4e8e\u7ed8\u56fe\uff0c\u529f\u80fd\u76f8\u5bf9\u6709\u9650\u3002<\/li>\n<\/ul>\n<p><h3>\u4e8c\u3001\u7f16\u5199\u811a\u672c\u751f\u6210\u56fe\u50cf\u5e27<\/h3>\n<\/p>\n<p><p>\u751f\u6210\u56fe\u50cf\u5e27\u662f\u5bfc\u51fa\u89c6\u9891\u7684\u57fa\u7840\u6b65\u9aa4\u3002\u4f60\u9700\u8981\u7f16\u5199\u4e00\u4e2aPython\u811a\u672c\uff0c\u901a\u8fc7\u7ed8\u5236\u56fe\u5f62\u6216\u5904\u7406\u56fe\u50cf\u751f\u6210\u8fde\u7eed\u7684\u56fe\u50cf\u5e27\u3002<\/p>\n<\/p>\n<p><h4>1. \u751f\u6210\u52a8\u6001\u56fe\u8868<\/h4>\n<\/p>\n<p><p>\u5982\u679c\u4f60\u9700\u8981\u5c06\u52a8\u6001\u56fe\u8868\u5bfc\u51fa\u4e3a\u89c6\u9891\uff0cMatplotlib\u662f\u4e00\u4e2a\u4e0d\u9519\u7684\u9009\u62e9\u3002\u4f60\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u6b65\u9aa4\u751f\u6210\u52a8\u6001\u56fe\u8868\uff1a<\/p>\n<\/p>\n<ul>\n<li><strong>\u521d\u59cb\u5316\u56fe\u5f62<\/strong>\uff1a\u4f7f\u7528<code>matplotlib.pyplot<\/code>\u521d\u59cb\u5316\u56fe\u5f62\u7a97\u53e3\u3002<\/li>\n<li><strong>\u66f4\u65b0\u6570\u636e<\/strong>\uff1a\u5728\u4e00\u4e2a\u5faa\u73af\u4e2d\u66f4\u65b0\u56fe\u8868\u6570\u636e\u3002<\/li>\n<li><strong>\u4fdd\u5b58\u5e27<\/strong>\uff1a\u4f7f\u7528Matplotlib\u7684<code>savefig<\/code>\u529f\u80fd\u4fdd\u5b58\u6bcf\u4e00\u5e27\u3002<\/li>\n<\/ul>\n<p><p>\u793a\u4f8b\u4ee3\u7801\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import matplotlib.pyplot as plt<\/p>\n<p>import numpy as np<\/p>\n<h2><strong>\u6570\u636e\u751f\u6210<\/strong><\/h2>\n<p>x = np.linspace(0, 2 * np.pi, 100)<\/p>\n<p>y = np.sin(x)<\/p>\n<h2><strong>\u521d\u59cb\u5316\u56fe\u5f62<\/strong><\/h2>\n<p>fig, ax = plt.subplots()<\/p>\n<p>line, = ax.plot(x, y)<\/p>\n<h2><strong>\u66f4\u65b0\u6570\u636e\u5e76\u4fdd\u5b58\u5e27<\/strong><\/h2>\n<p>for i in range(100):<\/p>\n<p>    line.set_ydata(np.sin(x + i \/ 10.0))<\/p>\n<p>    plt.savefig(f&#39;frame_{i}.png&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>2. \u56fe\u50cf\u5904\u7406<\/h4>\n<\/p>\n<p><p>\u5982\u679c\u4f60\u9700\u8981\u5904\u7406\u56fe\u50cf\u5e76\u5bfc\u51fa\u4e3a\u89c6\u9891\uff0c\u53ef\u4ee5\u4f7f\u7528OpenCV\u8bfb\u53d6\u5e76\u5904\u7406\u56fe\u50cf\uff0c\u7136\u540e\u5c06\u5904\u7406\u540e\u7684\u56fe\u50cf\u4fdd\u5b58\u4e3a\u5e27\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<h2><strong>\u6253\u5f00\u89c6\u9891\u6587\u4ef6\u6216\u6444\u50cf\u5934<\/strong><\/h2>\n<p>cap = cv2.VideoCapture(&#39;input.mp4&#39;)<\/p>\n<p>frame_number = 0<\/p>\n<p>while cap.isOpened():<\/p>\n<p>    ret, frame = cap.read()<\/p>\n<p>    if not ret:<\/p>\n<p>        break<\/p>\n<p>    # \u5bf9\u5e27\u8fdb\u884c\u5904\u7406<\/p>\n<p>    processed_frame = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)<\/p>\n<p>    # \u4fdd\u5b58\u5e27<\/p>\n<p>    cv2.imwrite(f&#39;frame_{frame_number}.png&#39;, processed_frame)<\/p>\n<p>    frame_number += 1<\/p>\n<p>cap.release()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u4e09\u3001\u4f7f\u7528\u89c6\u9891\u7f16\u5199\u5de5\u5177\u5c06\u5e27\u5408\u6210\u4e3a\u89c6\u9891<\/h3>\n<\/p>\n<p><p>\u5728\u751f\u6210\u56fe\u50cf\u5e27\u540e\uff0c\u4e0b\u4e00\u6b65\u662f\u5c06\u8fd9\u4e9b\u5e27\u5408\u6210\u4e3a\u89c6\u9891\u3002\u53ef\u4ee5\u4f7f\u7528OpenCV\u6216MoviePy\u6765\u5b9e\u73b0\u3002<\/p>\n<\/p>\n<p><h4>1. \u4f7f\u7528OpenCV\u5408\u6210\u89c6\u9891<\/h4>\n<\/p>\n<p><p>OpenCV\u53ef\u4ee5\u5c06\u56fe\u50cf\u5e27\u5408\u6210\u4e3a\u89c6\u9891\u6587\u4ef6\uff0c\u5e76\u652f\u6301\u591a\u79cd\u89c6\u9891\u683c\u5f0f\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<p>import glob<\/p>\n<h2><strong>\u83b7\u53d6\u6240\u6709\u5e27\u7684\u8def\u5f84<\/strong><\/h2>\n<p>frame_files = glob.glob(&#39;frame_*.png&#39;)<\/p>\n<p>frame_files.sort()<\/p>\n<h2><strong>\u83b7\u53d6\u5e27\u7684\u5c3a\u5bf8<\/strong><\/h2>\n<p>frame = cv2.imread(frame_files[0])<\/p>\n<p>height, width, layers = frame.shape<\/p>\n<h2><strong>\u521d\u59cb\u5316\u89c6\u9891\u7f16\u5199\u5668<\/strong><\/h2>\n<p>video = cv2.VideoWriter(&#39;output.avi&#39;, cv2.VideoWriter_fourcc(*&#39;DIVX&#39;), 30, (width, height))<\/p>\n<h2><strong>\u6dfb\u52a0\u6bcf\u4e00\u5e27\u5230\u89c6\u9891<\/strong><\/h2>\n<p>for frame_file in frame_files:<\/p>\n<p>    frame = cv2.imread(frame_file)<\/p>\n<p>    video.write(frame)<\/p>\n<p>video.release()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>2. \u4f7f\u7528MoviePy\u5408\u6210\u89c6\u9891<\/h4>\n<\/p>\n<p><p>MoviePy\u63d0\u4f9b\u4e86\u4e00\u79cd\u66f4\u9ad8\u5c42\u6b21\u7684\u63a5\u53e3\u6765\u5408\u6210\u89c6\u9891\uff0c\u5c24\u5176\u9002\u5408\u9700\u8981\u6dfb\u52a0\u7279\u6548\u6216\u7f16\u8f91\u7684\u573a\u666f\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from moviepy.editor import ImageSequenceClip<\/p>\n<h2><strong>\u83b7\u53d6\u6240\u6709\u5e27\u7684\u8def\u5f84<\/strong><\/h2>\n<p>frame_files = glob.glob(&#39;frame_*.png&#39;)<\/p>\n<p>frame_files.sort()<\/p>\n<h2><strong>\u521b\u5efa\u89c6\u9891\u526a\u8f91<\/strong><\/h2>\n<p>clip = ImageSequenceClip(frame_files, fps=30)<\/p>\n<h2><strong>\u5199\u5165\u89c6\u9891\u6587\u4ef6<\/strong><\/h2>\n<p>clip.write_videofile(&#39;output.mp4&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u56db\u3001\u4f18\u5316\u5bfc\u51fa\u89c6\u9891\u7684\u8d28\u91cf\u548c\u6548\u7387<\/h3>\n<\/p>\n<p><p>\u5728\u5bfc\u51fa\u89c6\u9891\u7684\u8fc7\u7a0b\u4e2d\uff0c\u53ef\u80fd\u4f1a\u9047\u5230\u8d28\u91cf\u548c\u6548\u7387\u7684\u95ee\u9898\u3002\u4f18\u5316\u8fd9\u4e9b\u95ee\u9898\u53ef\u4ee5\u63d0\u9ad8\u89c6\u9891\u7684\u8f93\u51fa\u6548\u679c\u3002<\/p>\n<\/p>\n<p><h4>1. \u4f18\u5316\u56fe\u50cf\u5e27\u8d28\u91cf<\/h4>\n<\/p>\n<p><p>\u786e\u4fdd\u751f\u6210\u7684\u56fe\u50cf\u5e27\u8d28\u91cf\u9ad8\uff0c\u907f\u514d\u5728\u4fdd\u5b58\u5e27\u65f6\u4f7f\u7528\u8fc7\u4f4e\u7684\u538b\u7f29\u7387\u3002<\/p>\n<\/p>\n<ul>\n<li>\u4f7f\u7528\u66f4\u9ad8\u7684\u5206\u8fa8\u7387\u4fdd\u5b58\u5e27\u3002<\/li>\n<li>\u9009\u62e9\u5408\u9002\u7684\u6587\u4ef6\u683c\u5f0f\uff08\u5982PNG\u800c\u975eJPEG\uff09\u4ee5\u51cf\u5c11\u538b\u7f29\u635f\u5931\u3002<\/li>\n<\/ul>\n<p><h4>2. \u63d0\u9ad8\u89c6\u9891\u5408\u6210\u6548\u7387<\/h4>\n<\/p>\n<p><p>\u9009\u62e9\u5408\u9002\u7684\u7f16\u7801\u5668\u548c\u53c2\u6570\uff0c\u53ef\u4ee5\u63d0\u9ad8\u89c6\u9891\u5408\u6210\u7684\u6548\u7387\u3002<\/p>\n<\/p>\n<ul>\n<li><strong>\u9009\u62e9\u5408\u9002\u7684\u7f16\u7801\u5668<\/strong>\uff1a\u5982H.264\u6216HEVC\uff0c\u8fd9\u4e9b\u7f16\u7801\u5668\u901a\u5e38\u63d0\u4f9b\u66f4\u597d\u7684\u538b\u7f29\u6548\u7387\u3002<\/li>\n<li><strong>\u8c03\u6574\u6bd4\u7279\u7387<\/strong>\uff1a\u9ad8\u6bd4\u7279\u7387\u4f1a\u63d0\u4f9b\u66f4\u597d\u7684\u8d28\u91cf\uff0c\u4f46\u6587\u4ef6\u5927\u5c0f\u4e5f\u4f1a\u589e\u52a0\u3002<\/li>\n<\/ul>\n<p><p>\u901a\u8fc7\u4ee5\u4e0a\u6b65\u9aa4\uff0c\u4f60\u53ef\u4ee5\u6210\u529f\u5730\u5c06Python\u7a0b\u5e8f\u751f\u6210\u7684\u5185\u5bb9\u5bfc\u51fa\u4e3a\u89c6\u9891\u6587\u4ef6\u3002\u4e0d\u540c\u7684\u5e93\u63d0\u4f9b\u4e86\u4e0d\u540c\u7684\u529f\u80fd\u548c\u7075\u6d3b\u6027\uff0c\u9009\u62e9\u5408\u9002\u7684\u5e93\u548c\u65b9\u6cd5\u53ef\u4ee5\u5e2e\u52a9\u4f60\u66f4\u6709\u6548\u5730\u5b8c\u6210\u8fd9\u4e00\u4efb\u52a1\u3002\u5e0c\u671b\u672c\u6587\u80fd\u4e3a\u4f60\u63d0\u4f9b\u6709\u4ef7\u503c\u7684\u6307\u5bfc\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5c06Python\u751f\u6210\u7684\u56fe\u50cf\u5e8f\u5217\u8f6c\u6362\u4e3a\u89c6\u9891\uff1f<\/strong><br \/>\u8981\u5c06Python\u751f\u6210\u7684\u56fe\u50cf\u5e8f\u5217\u8f6c\u6362\u4e3a\u89c6\u9891\uff0c\u53ef\u4ee5\u4f7f\u7528OpenCV\u5e93\u3002\u9996\u5148\uff0c\u786e\u4fdd\u4f60\u5df2\u5b89\u88c5OpenCV\u3002\u63a5\u4e0b\u6765\uff0c\u4f7f\u7528cv2.VideoWriter()\u521b\u5efa\u4e00\u4e2a\u89c6\u9891\u5199\u5165\u5bf9\u8c61\uff0c\u5e76\u5faa\u73af\u904d\u5386\u56fe\u50cf\u5e8f\u5217\uff0c\u5c06\u6bcf\u4e00\u5e27\u6dfb\u52a0\u5230\u89c6\u9891\u4e2d\u3002\u4ee5\u4e0b\u662f\u4e00\u4e2a\u7b80\u5355\u793a\u4f8b\uff1a  <\/p>\n<pre><code class=\"language-python\">import cv2\nimport os\n\nimage_folder = &#39;path_to_images&#39;\nvideo_name = &#39;output_video.avi&#39;\n\nimages = [img for img in os.listdir(image_folder) if img.endswith(&quot;.png&quot;)]\nimages.sort()  # \u786e\u4fdd\u6309\u987a\u5e8f\u6392\u5217\n\nframe = cv2.imread(os.path.join(image_folder, images[0]))\nheight, width, layers = frame.shape\n\nvideo = cv2.VideoWriter(video_name, cv2.VideoWriter_fourcc(*&#39;DIVX&#39;), 30, (width, height))\n\nfor image in images:\n    video.write(cv2.imread(os.path.join(image_folder, image)))\n\nvideo.release()\ncv2.destroyAllWindows()\n<\/code><\/pre>\n<p>\u8fd0\u884c\u6b64\u4ee3\u7801\u540e\uff0c\u4f60\u5c06\u83b7\u5f97\u4e00\u4e2a\u540d\u4e3aoutput_video.avi\u7684\u89c6\u9891\u6587\u4ef6\u3002<\/p>\n<p><strong>\u5728Python\u4e2d\u53ef\u4ee5\u4f7f\u7528\u54ea\u4e9b\u5e93\u6765\u5904\u7406\u89c6\u9891\u6587\u4ef6\uff1f<\/strong><br \/>Python\u6709\u591a\u4e2a\u5e93\u53ef\u4ee5\u5904\u7406\u89c6\u9891\u6587\u4ef6\uff0c\u5176\u4e2d\u6700\u5e38\u7528\u7684\u5305\u62ecOpenCV\u3001MoviePy\u548cFFmpeg\u3002\u8fd9\u4e9b\u5e93\u63d0\u4f9b\u4e86\u5f3a\u5927\u7684\u529f\u80fd\uff0c\u5141\u8bb8\u7528\u6237\u8fdb\u884c\u89c6\u9891\u7f16\u8f91\u3001\u8f6c\u6362\u683c\u5f0f\u3001\u6dfb\u52a0\u7279\u6548\u7b49\u64cd\u4f5c\u3002OpenCV\u9002\u5408\u56fe\u50cf\u548c\u89c6\u9891\u5904\u7406\uff0cMoviePy\u66f4\u9002\u5408\u7f16\u8f91\u548c\u5408\u6210\u89c6\u9891\uff0c\u800cFFmpeg\u5219\u63d0\u4f9b\u4e86\u547d\u4ee4\u884c\u5de5\u5177\u6765\u5904\u7406\u51e0\u4e4e\u6240\u6709\u7684\u89c6\u9891\u683c\u5f0f\u3002<\/p>\n<p><strong>\u5982\u4f55\u63d0\u9ad8Python\u751f\u6210\u89c6\u9891\u7684\u8d28\u91cf\uff1f<\/strong><br \/>\u63d0\u5347Python\u751f\u6210\u89c6\u9891\u8d28\u91cf\u7684\u65b9\u5f0f\u6709\u591a\u4e2a\u3002\u9996\u5148\uff0c\u786e\u4fdd\u8f93\u5165\u56fe\u50cf\u7684\u5206\u8fa8\u7387\u548c\u8d28\u91cf\u8f83\u9ad8\u3002\u5176\u6b21\uff0c\u5728\u4f7f\u7528cv2.VideoWriter\u65f6\uff0c\u9009\u62e9\u5408\u9002\u7684\u7f16\u7801\u5668\u548c\u5e27\u7387\u3002\u4f7f\u7528\u66f4\u9ad8\u6bd4\u7279\u7387\u548c\u66f4\u5148\u8fdb\u7684\u7f16\u7801\u683c\u5f0f\uff08\u5982H.264\uff09\u53ef\u4ee5\u663e\u8457\u63d0\u5347\u89c6\u9891\u8d28\u91cf\u3002\u6b64\u5916\uff0c\u540e\u671f\u5904\u7406\u6280\u672f\uff0c\u5982\u53bb\u566a\u548c\u589e\u5f3a\u5bf9\u6bd4\u5ea6\u7b49\uff0c\u4e5f\u53ef\u4ee5\u6539\u5584\u6700\u7ec8\u89c6\u9891\u7684\u89c6\u89c9\u6548\u679c\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5bfc\u51faPython\u4e3a\u89c6\u9891\u7684\u8fc7\u7a0b\u6d89\u53ca\u9009\u62e9\u5408\u9002\u7684\u5e93\u3001\u7f16\u5199\u811a\u672c\u751f\u6210\u56fe\u50cf\u5e27\u3001\u4f7f\u7528\u89c6\u9891\u7f16\u5199\u5de5\u5177\u5c06\u5e27\u5408\u6210\u4e3a\u89c6\u9891\u3002\u5176\u4e2d\uff0c\u9009\u62e9\u5408 [&hellip;]","protected":false},"author":3,"featured_media":958154,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/958150"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=958150"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/958150\/revisions"}],"predecessor-version":[{"id":958156,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/958150\/revisions\/958156"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/958154"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=958150"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=958150"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=958150"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}