Skip to main content

Easily cut the video by moviepy

Project description

介绍

使用python来剪辑视频!

借助moviepy这个库

github repo:

https://github.com/chunleili/cut_video

安装

你可以使用

pip install cut_video

来下载。(推荐,因为还会在你系统内安装同名的命令行工具)

或者直接clone这个repo

用法

在当前文件夹下

  1. 你需要提供mp4视频: full.mp4

  2. 你需要在to_erase.json中输入需要剪辑去掉的部分

例如

[   ["0:22", "1:14"],
    ["1:25", "1:30"],
    ["2:13", "2:25"]
]

代表我想要去掉0:22-1:14, 1:25-1:30 和2:13-2:25 这三个时间片段, 保留剩下的。

结果在 final.mp4当中

假如你使用pip的方式安装,只需要运行

cut_video

即可

其他运行方式

你还可以运行python脚本的方式来运行

python cut_video.py

或者如果你安装了jupyter,也可以运行ipython脚本

cut_video.ipynb

视频教程

请见视频教程

https://www.bilibili.com/video/BV1xG4y137WJ/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pythonlqc-0.0.123.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Pythonlqc-0.0.123-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file pythonlqc-0.0.123.tar.gz.

File metadata

  • Download URL: pythonlqc-0.0.123.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.7

File hashes

Hashes for pythonlqc-0.0.123.tar.gz
Algorithm Hash digest
SHA256 9a911c73a1472597e8e0ea5f206708d74519b84e8b7f242448fb688e1ce1dc62
MD5 56821fd0a198fce88d979d36f78507e2
BLAKE2b-256 7b5335732ed9a4fe924a9071389aa0a89396a09496f0efda8bade403e38b4a57

See more details on using hashes here.

File details

Details for the file Pythonlqc-0.0.123-py3-none-any.whl.

File metadata

  • Download URL: Pythonlqc-0.0.123-py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.7

File hashes

Hashes for Pythonlqc-0.0.123-py3-none-any.whl
Algorithm Hash digest
SHA256 4599a340773a885b758f73072b0c46b198b9ff4b853fd38aa0fc152df7b5f07c
MD5 69e15ef70275a23da520a1f3540e3e77
BLAKE2b-256 bc7539bca878ecc7d5ab3fc79eb0d0fc7f411c75eb7dd1f6bf42a2d7e8f60042

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page