{"id":1003335,"date":"2024-12-27T10:16:24","date_gmt":"2024-12-27T02:16:24","guid":{"rendered":""},"modified":"2024-12-27T10:16:26","modified_gmt":"2024-12-27T02:16:26","slug":"python%e4%b8%ad%e5%a6%82%e4%bd%95%e4%bf%9d%e5%ad%98%e8%a7%86%e9%a2%91","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1003335.html","title":{"rendered":"python\u4e2d\u5982\u4f55\u4fdd\u5b58\u89c6\u9891"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25080730\/39cf5561-283e-4a3e-b679-aa129efb3f26.webp\" alt=\"python\u4e2d\u5982\u4f55\u4fdd\u5b58\u89c6\u9891\" \/><\/p>\n<p><p> \u5728Python\u4e2d\u4fdd\u5b58\u89c6\u9891\uff0c\u53ef\u4ee5\u4f7f\u7528\u591a\u79cd\u5e93\u548c\u65b9\u6cd5\uff0c<strong>\u5e38\u7528\u7684\u6709OpenCV\u3001MoviePy\u3001imageio<\/strong>\u3002\u8fd9\u4e9b\u5e93\u63d0\u4f9b\u4e86\u7075\u6d3b\u548c\u5f3a\u5927\u7684\u529f\u80fd\u6765\u5904\u7406\u89c6\u9891\u3002\u672c\u6587\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u5982\u4f55\u4f7f\u7528\u8fd9\u51e0\u4e2a\u5e93\u6765\u4fdd\u5b58\u89c6\u9891\uff0c\u5e76\u4ee5OpenCV\u4e3a\u91cd\u70b9\u8fdb\u884c\u6df1\u5165\u63a2\u8ba8\u3002<\/p>\n<\/p>\n<p><h3>\u4e00\u3001\u4f7f\u7528OPENCV\u4fdd\u5b58\u89c6\u9891<\/h3>\n<\/p>\n<p><p><strong>OpenCV<\/strong>\u662f\u4e00\u4e2a\u975e\u5e38\u6d41\u884c\u7684\u8ba1\u7b97\u673a\u89c6\u89c9\u5e93\uff0c\u652f\u6301\u591a\u79cd\u56fe\u50cf\u548c\u89c6\u9891\u5904\u7406\u529f\u80fd\u3002\u4f7f\u7528OpenCV\u4fdd\u5b58\u89c6\u9891\u901a\u5e38\u6d89\u53ca\u8bfb\u53d6\u5e27\u3001\u5904\u7406\u5e27\u3001\u5e76\u5c06\u5176\u5199\u5165\u5230\u89c6\u9891\u6587\u4ef6\u4e2d\u3002<\/p>\n<\/p>\n<p><h4>1. \u5b89\u88c5OpenCV<\/h4>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u786e\u4fdd\u4f60\u7684Python\u73af\u5883\u4e2d\u5b89\u88c5\u4e86OpenCV\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u901a\u8fc7pip\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install opencv-python<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>2. \u4f7f\u7528VideoWriter\u4fdd\u5b58\u89c6\u9891<\/h4>\n<\/p>\n<p><p>OpenCV\u63d0\u4f9b\u4e86<code>VideoWriter<\/code>\u7c7b\u6765\u5199\u5165\u89c6\u9891\u6587\u4ef6\u3002\u4e0b\u9762\u662f\u4e00\u4e2a\u7b80\u5355\u7684\u793a\u4f8b\uff0c\u5c55\u793a\u4e86\u5982\u4f55\u4f7f\u7528OpenCV\u4fdd\u5b58\u89c6\u9891\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import cv2<\/p>\n<h2><strong>\u521b\u5efaVideoCapture\u5bf9\u8c61\uff0c0\u8868\u793a\u7b2c\u4e00\u4e2a\u6444\u50cf\u5934<\/strong><\/h2>\n<p>cap = cv2.VideoCapture(0)<\/p>\n<h2><strong>\u5b9a\u4e49\u89c6\u9891\u6587\u4ef6\u7684\u7f16\u7801\u548c\u521b\u5efaVideoWriter\u5bf9\u8c61<\/strong><\/h2>\n<p>fourcc = cv2.VideoWriter_fourcc(*&#39;XVID&#39;)  # \u9009\u62e9\u7f16\u7801\u683c\u5f0f<\/p>\n<p>out = cv2.VideoWriter(&#39;output.avi&#39;, fourcc, 20.0, (640, 480))<\/p>\n<p>while cap.isOpened():<\/p>\n<p>    ret, frame = cap.read()<\/p>\n<p>    if ret:<\/p>\n<p>        # \u5728\u8fd9\u91cc\u53ef\u4ee5\u5bf9\u5e27\u8fdb\u884c\u5904\u7406\uff08\u5982\u679c\u9700\u8981\uff09<\/p>\n<p>        # \u5199\u5165\u5e27\u5230\u89c6\u9891\u6587\u4ef6<\/p>\n<p>        out.write(frame)<\/p>\n<p>        # \u663e\u793a\u5e27<\/p>\n<p>        cv2.imshow(&#39;frame&#39;, frame)<\/p>\n<p>        # \u6309q\u952e\u9000\u51fa<\/p>\n<p>        if cv2.w<a href=\"https:\/\/docs.pingcode.com\/blog\/59162.html\" target=\"_blank\">AI<\/a>tKey(1) &amp; 0xFF == ord(&#39;q&#39;):<\/p>\n<p>            break<\/p>\n<p>    else:<\/p>\n<p>        break<\/p>\n<h2><strong>\u91ca\u653e\u8d44\u6e90<\/strong><\/h2>\n<p>cap.release()<\/p>\n<p>out.release()<\/p>\n<p>cv2.destroyAllWindows()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u4f7f\u7528\u4e86<code>VideoCapture<\/code>\u6765\u6355\u83b7\u89c6\u9891\u8f93\u5165\uff0c\u5e76\u4f7f\u7528<code>VideoWriter<\/code>\u6765\u4fdd\u5b58\u8f93\u51fa\u89c6\u9891\u3002\u4f60\u53ef\u4ee5\u901a\u8fc7\u4fee\u6539<code>fourcc<\/code>\u7f16\u7801\u548c\u5176\u4ed6\u53c2\u6570\u6765\u66f4\u6539\u89c6\u9891\u683c\u5f0f\u548c\u8d28\u91cf\u3002<\/p>\n<\/p>\n<p><h4>3. \u5904\u7406\u5e27<\/h4>\n<\/p>\n<p><p>\u5728\u4fdd\u5b58\u89c6\u9891\u4e4b\u524d\uff0c\u4f60\u53ef\u80fd\u9700\u8981\u5bf9\u6bcf\u4e00\u5e27\u8fdb\u884c\u5904\u7406\u3002\u8fd9\u53ef\u4ee5\u5305\u62ec\u56fe\u50cf\u589e\u5f3a\u3001\u6ee4\u6ce2\u3001\u6dfb\u52a0\u6c34\u5370\u7b49\u3002OpenCV\u63d0\u4f9b\u4e86\u4e30\u5bcc\u7684\u56fe\u50cf\u5904\u7406\u529f\u80fd\uff0c\u53ef\u4ee5\u5728\u6bcf\u4e00\u5e27\u4e0a\u5e94\u7528\u8fd9\u4e9b\u64cd\u4f5c\u3002<\/p>\n<\/p>\n<p><h3>\u4e8c\u3001\u4f7f\u7528MOVIEPY\u4fdd\u5b58\u89c6\u9891<\/h3>\n<\/p>\n<p><p><strong>MoviePy<\/strong>\u662f\u4e00\u4e2a\u7528\u4e8e\u89c6\u9891\u7f16\u8f91\u7684\u5e93\uff0c\u63d0\u4f9b\u4e86\u7b80\u5355\u800c\u5f3a\u5927\u7684\u529f\u80fd\u6765\u5904\u7406\u548c\u521b\u5efa\u89c6\u9891\u3002<\/p>\n<\/p>\n<p><h4>1. \u5b89\u88c5MoviePy<\/h4>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u5b89\u88c5MoviePy\uff0c\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install moviepy<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>2. \u4f7f\u7528MoviePy\u4fdd\u5b58\u89c6\u9891<\/h4>\n<\/p>\n<p><p>MoviePy\u4f7f\u5f97\u4fdd\u5b58\u89c6\u9891\u53d8\u5f97\u975e\u5e38\u7b80\u5355\u3002\u4ee5\u4e0b\u662f\u4e00\u4e2a\u4f7f\u7528MoviePy\u4fdd\u5b58\u89c6\u9891\u7684\u793a\u4f8b\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from moviepy.editor import VideoFileClip, concatenate_videoclips<\/p>\n<h2><strong>\u6253\u5f00\u4e00\u4e2a\u89c6\u9891\u6587\u4ef6<\/strong><\/h2>\n<p>clip1 = VideoFileClip(&quot;video1.mp4&quot;).subclip(0, 10)  # \u53ea\u53d6\u524d10\u79d2<\/p>\n<p>clip2 = VideoFileClip(&quot;video2.mp4&quot;).subclip(0, 10)<\/p>\n<h2><strong>\u5408\u5e76\u591a\u4e2a\u89c6\u9891\u7247\u6bb5<\/strong><\/h2>\n<p>final_clip = concatenate_videoclips([clip1, clip2])<\/p>\n<h2><strong>\u4fdd\u5b58\u6700\u7ec8\u89c6\u9891<\/strong><\/h2>\n<p>final_clip.write_videofile(&quot;output.mp4&quot;, codec=&quot;libx264&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u793a\u4f8b\u4e2d\uff0c\u6211\u4eec\u4f7f\u7528<code>VideoFileClip<\/code>\u6765\u8bfb\u53d6\u89c6\u9891\u6587\u4ef6\uff0c\u5e76\u4f7f\u7528<code>concatenate_videoclips<\/code>\u6765\u5408\u5e76\u591a\u4e2a\u89c6\u9891\u7247\u6bb5\uff0c\u6700\u540e\u4f7f\u7528<code>write_videofile<\/code>\u4fdd\u5b58\u6700\u7ec8\u89c6\u9891\u3002<\/p>\n<\/p>\n<p><h3>\u4e09\u3001\u4f7f\u7528IMAGEIO\u4fdd\u5b58\u89c6\u9891<\/h3>\n<\/p>\n<p><p><strong>imageio<\/strong>\u662f\u4e00\u4e2a\u7528\u4e8e\u8bfb\u53d6\u548c\u5199\u5165\u56fe\u50cf\u548c\u89c6\u9891\u6587\u4ef6\u7684\u5e93\uff0c\u652f\u6301\u591a\u79cd\u683c\u5f0f\u3002<\/p>\n<\/p>\n<p><h4>1. \u5b89\u88c5imageio<\/h4>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u5b89\u88c5imageio\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install imageio<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h4>2. \u4f7f\u7528imageio\u4fdd\u5b58\u89c6\u9891<\/h4>\n<\/p>\n<p><p>\u4e0b\u9762\u662f\u4e00\u4e2a\u4f7f\u7528imageio\u4fdd\u5b58\u89c6\u9891\u7684\u793a\u4f8b\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import imageio<\/p>\n<p>import numpy as np<\/p>\n<h2><strong>\u521b\u5efa\u4e00\u4e2aWriter\u5bf9\u8c61<\/strong><\/h2>\n<p>writer = imageio.get_writer(&#39;output.mp4&#39;, fps=24)<\/p>\n<h2><strong>\u751f\u6210\u4e00\u4e9b\u793a\u4f8b\u5e27\u5e76\u5199\u5165\u89c6\u9891<\/strong><\/h2>\n<p>for i in range(100):<\/p>\n<p>    # \u521b\u5efa\u4e00\u4e2a\u7b80\u5355\u7684\u6e10\u53d8\u56fe\u50cf<\/p>\n<p>    frame = np.tile(np.linspace(0, 255, 256, dtype=np.uint8), (256, 1))<\/p>\n<p>    frame = np.stack([frame, frame, frame], axis=-1)  # \u521b\u5efaRGB\u56fe\u50cf<\/p>\n<p>    writer.append_data(frame)<\/p>\n<h2><strong>\u5173\u95edWriter\u5bf9\u8c61<\/strong><\/h2>\n<p>writer.close()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u793a\u4f8b\u4e2d\uff0c\u6211\u4eec\u4f7f\u7528imageio\u751f\u6210\u4e86\u4e00\u4e9b\u793a\u4f8b\u5e27\uff0c\u5e76\u5c06\u5176\u5199\u5165\u89c6\u9891\u6587\u4ef6\u4e2d\u3002<\/p>\n<\/p>\n<p><h3>\u56db\u3001\u9009\u62e9\u5408\u9002\u7684\u5de5\u5177<\/h3>\n<\/p>\n<p><p>\u5f53\u9009\u62e9\u5de5\u5177\u65f6\uff0c\u4f60\u9700\u8981\u8003\u8651\u51e0\u4e2a\u56e0\u7d20\uff1a<\/p>\n<\/p>\n<ol>\n<li><strong>\u529f\u80fd\u9700\u6c42<\/strong>\uff1a\u5982\u679c\u4f60\u9700\u8981\u8fdb\u884c\u590d\u6742\u7684\u89c6\u9891\u7f16\u8f91\uff0cMoviePy\u53ef\u80fd\u66f4\u9002\u5408\u3002\u5982\u679c\u53ea\u662f\u7b80\u5355\u7684\u5e27\u6355\u83b7\u548c\u4fdd\u5b58\uff0cOpenCV\u53ef\u80fd\u66f4\u9ad8\u6548\u3002<\/li>\n<li><strong>\u6027\u80fd<\/strong>\uff1aOpenCV\u901a\u5e38\u5728\u5904\u7406\u5927\u91cf\u6570\u636e\u65f6\u8868\u73b0\u66f4\u597d\u3002<\/li>\n<li><strong>\u5e93\u7684\u4f9d\u8d56\u6027\u548c\u517c\u5bb9\u6027<\/strong>\uff1a\u786e\u4fdd\u6240\u9009\u5e93\u4e0e\u5176\u4ed6\u6b63\u5728\u4f7f\u7528\u7684\u5e93\u517c\u5bb9\u3002<\/li>\n<\/ol>\n<p><h3>\u4e94\u3001\u603b\u7ed3<\/h3>\n<\/p>\n<p><p>\u5728Python\u4e2d\u4fdd\u5b58\u89c6\u9891\u53ef\u4ee5\u901a\u8fc7\u591a\u79cd\u65b9\u5f0f\u5b9e\u73b0\uff0c\u9009\u62e9\u5408\u9002\u7684\u5e93\u53d6\u51b3\u4e8e\u5177\u4f53\u7684\u9700\u6c42\u548c\u4f7f\u7528\u573a\u666f\u3002<strong>OpenCV\u3001MoviePy\u3001imageio<\/strong>\u90fd\u63d0\u4f9b\u4e86\u5f3a\u5927\u7684\u529f\u80fd\u6765\u5904\u7406\u548c\u4fdd\u5b58\u89c6\u9891\u3002\u5728\u4f7f\u7528\u8fc7\u7a0b\u4e2d\uff0c\u786e\u4fdd\u4e86\u89e3\u6bcf\u4e2a\u5e93\u7684\u4f18\u52a3\uff0c\u5e76\u6839\u636e\u9879\u76ee\u9700\u6c42\u9009\u62e9\u5408\u9002\u7684\u5de5\u5177\u3002\u65e0\u8bba\u9009\u62e9\u54ea\u79cd\u65b9\u6cd5\uff0c\u7406\u89e3\u89c6\u9891\u7f16\u89e3\u7801\u7684\u57fa\u672c\u539f\u7406\u548c\u5404\u81ea\u5e93\u7684API\u662f\u6210\u529f\u5b9e\u73b0\u9879\u76ee\u7684\u5173\u952e\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5728Python\u4e2d\u4f7f\u7528OpenCV\u4fdd\u5b58\u89c6\u9891\uff1f<\/strong><br \/>\u4f7f\u7528OpenCV\u5e93\u53ef\u4ee5\u8f7b\u677e\u5730\u4fdd\u5b58\u89c6\u9891\u3002\u9996\u5148\uff0c\u786e\u4fdd\u5df2\u5b89\u88c5OpenCV\u5e93\u3002\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u4ee3\u7801\u4fdd\u5b58\u89c6\u9891\uff1a  <\/p>\n<pre><code class=\"language-python\">import cv2\n\n# \u521b\u5efa\u4e00\u4e2a\u89c6\u9891\u6355\u6349\u5bf9\u8c61\ncap = cv2.VideoCapture(0)  # 0\u4ee3\u8868\u9ed8\u8ba4\u6444\u50cf\u5934\n\n# \u5b9a\u4e49\u89c6\u9891\u7f16\u7801\u683c\u5f0f\nfourcc = cv2.VideoWriter_fourcc(*&#39;XVID&#39;)\n\n# \u521b\u5efaVideoWriter\u5bf9\u8c61\uff0c\u6307\u5b9a\u8f93\u51fa\u6587\u4ef6\u540d\u3001\u7f16\u7801\u3001\u5e27\u7387\u548c\u89c6\u9891\u5c3a\u5bf8\nout = cv2.VideoWriter(&#39;output.avi&#39;, fourcc, 20.0, (640, 480))\n\nwhile cap.isOpened():\n    ret, frame = cap.read()\n    if ret:\n        out.write(frame)  # \u5199\u5165\u5e27\u5230\u8f93\u51fa\u89c6\u9891\n        cv2.imshow(&#39;frame&#39;, frame)\n        if cv2.waitKey(1) &amp; 0xFF == ord(&#39;q&#39;):\n            break\n    else:\n        break\n\n# \u91ca\u653e\u8d44\u6e90\ncap.release()\nout.release()\ncv2.destroyAllWindows()\n<\/code><\/pre>\n<p>\u8fd9\u6bb5\u4ee3\u7801\u6355\u6349\u6765\u81ea\u6444\u50cf\u5934\u7684\u89c6\u9891\u5e76\u5c06\u5176\u4fdd\u5b58\u4e3a\u201coutput.avi\u201d\u6587\u4ef6\u3002<\/p>\n<p><strong>\u5728Python\u4e2d\u5982\u4f55\u5904\u7406\u89c6\u9891\u7684\u4e0d\u540c\u683c\u5f0f\uff1f<\/strong><br \/>Python\u652f\u6301\u591a\u79cd\u89c6\u9891\u683c\u5f0f\u7684\u4fdd\u5b58\uff0c\u4f7f\u7528\u4e0d\u540c\u7684\u7f16\u7801\u5668\u53ef\u4ee5\u5b9e\u73b0\u8fd9\u4e00\u70b9\u3002\u5e38\u89c1\u7684\u89c6\u9891\u683c\u5f0f\u5305\u62ecAVI\u3001MP4\u548cMKV\u7b49\u3002\u8981\u66f4\u6539\u4fdd\u5b58\u7684\u89c6\u9891\u683c\u5f0f\uff0c\u9700\u5728\u5b9a\u4e49VideoWriter\u5bf9\u8c61\u65f6\u6307\u5b9a\u4e0d\u540c\u7684\u6587\u4ef6\u6269\u5c55\u540d\u548c\u7f16\u7801\u683c\u5f0f\u3002\u4f8b\u5982\uff0c\u5c06\u8f93\u51fa\u6587\u4ef6\u540d\u6539\u4e3a\u201coutput.mp4\u201d\uff0c\u5e76\u4f7f\u7528<code>cv2.VideoWriter_fourcc(*&#39;mp4v&#39;)<\/code>\u4f5c\u4e3a\u7f16\u7801\u5668\u3002<\/p>\n<p><strong>\u4f7f\u7528FFmpeg\u5728Python\u4e2d\u4fdd\u5b58\u89c6\u9891\u6709\u4f55\u4f18\u52bf\uff1f<\/strong><br \/>FFmpeg\u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u591a\u5a92\u4f53\u5904\u7406\u5de5\u5177\uff0c\u53ef\u4ee5\u5728Python\u4e2d\u901a\u8fc7subprocess\u6a21\u5757\u8c03\u7528\u3002\u4f7f\u7528FFmpeg\u53ef\u4ee5\u5904\u7406\u5404\u79cd\u89c6\u9891\u683c\u5f0f\uff0c\u5e76\u652f\u6301\u66f4\u590d\u6742\u7684\u64cd\u4f5c\uff0c\u6bd4\u5982\u89c6\u9891\u526a\u8f91\u3001\u8f6c\u7801\u548c\u5408\u5e76\u7b49\u3002\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u884c\uff0c\u53ef\u4ee5\u5c06\u89c6\u9891\u6587\u4ef6\u8f6c\u6362\u4e3a\u5176\u4ed6\u683c\u5f0f\uff1a  <\/p>\n<pre><code class=\"language-python\">import subprocess\n\nsubprocess.run([&#39;ffmpeg&#39;, &#39;-i&#39;, &#39;input.mp4&#39;, &#39;output.avi&#39;])\n<\/code><\/pre>\n<p>\u8fd9\u79cd\u65b9\u5f0f\u4e0d\u4ec5\u7075\u6d3b\uff0c\u800c\u4e14\u53ef\u4ee5\u5904\u7406\u9ad8\u8d28\u91cf\u7684\u97f3\u89c6\u9891\u8f6c\u6362\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5728Python\u4e2d\u4fdd\u5b58\u89c6\u9891\uff0c\u53ef\u4ee5\u4f7f\u7528\u591a\u79cd\u5e93\u548c\u65b9\u6cd5\uff0c\u5e38\u7528\u7684\u6709OpenCV\u3001MoviePy\u3001imageio\u3002\u8fd9\u4e9b\u5e93\u63d0 [&hellip;]","protected":false},"author":3,"featured_media":1003344,"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\/1003335"}],"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=1003335"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1003335\/revisions"}],"predecessor-version":[{"id":1003348,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1003335\/revisions\/1003348"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1003344"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1003335"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1003335"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1003335"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}