VTT到SRT字幕转换包

vtt-to-srt的Python项目详细描述


vtt_to_srt.py

python 2.7的有用python脚本

将所有VTT文件转换为SRT字幕格式

终端使用:

	vtt_to_srt.py pathname [-r]

	pathname - a file or directory with files to be converted 

	-r       - walk path recursively                          

作为库:

安装:

	pip install --user vtt_to_srt

用法:

	# convert vtt file

	from vtt_to_srt import vtt_to_srt
	path = '/path/to/file.vtt'
	vtt_to_srt(path)


	# recursively convert all vtt files in directory

	from vtt_to_srt import vtts_to_srt
	path = '/path/to/directory'
	vtts_to_srt(path, rec = True)

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java如何单独突出显示   java在hibernate中添加共享主键和主键   java Android。如何克隆可编辑文件   线程“awteventque0”java中出现3d异常。我的vector3类中的lang.NullPointerException   调用restTemplate时发生java错误。交换法   java解析命令行   datetime如何以yyyyMMdd HH:mm:ss格式存储日期,而不必更改Java中日期的数据类型?   java访问raspberry pi端口   java Android:用于设置NestedScrollView的最大高度的自定义类不起作用(没有滚动条)   java删除一个链接如何从链表中删除一个节点?   java如何在方法中引用抽象类的方法   Java 安卓 glide调整照片大小   Enounciate的XmlJavaTypeAdapter和JavaXML客户端模块的java问题   Spring无版本xsd的java Intellij错误xsd验证   java我需要关于Proguard的帮助