Tool for extracting hard subtitles from videos.
Project description
rapid_videocr Package
1. Install package by pypi.
$ pip install rapid_videocr
2. Run by script.
- RapidVideOCR has the default
out_format
, which is one of['srt', 'txt', 'all']
, the default value isall
. - 📌
2.mp4
source: link
from rapid_videocr import RapidVideOCR
extractor = RapidVideOCR()
mp4_path = '2.mp4'
ocr_result = extractor(mp4_path, out_format='srt')
print(ocr_result)
3. Run by command line.
- Usage:
$ rapid_videocr -h usage: rapid_videocr [-h] [-mp4 MP4_PATH] [-o {srt,txt,all}] optional arguments: -h, --help show this help message and exit -mp4 MP4_PATH, --mp4_path MP4_PATH The full path of mp4 video. -o {srt,txt,all}, --out_format {srt,txt,all} Output file format. Default is "all"
- Example:
$ rapid_videocr -o srt -mp4 2.mp4
4. Result.
- Return value.
[ [0, '00:00:00,041', '00:00:00,416', '空间里面他绝对赢不了的'], [10, '00:00:00,458', '00:00:01,166', '我进去帮他'], [37, '00:00:01,583', '00:00:02,541', '你们接着善后'] ]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for rapid_videocr-1.1.11-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 35460295eefcc4f46c2fb3ebd4c3ff033d385db4c2955880a9ba15232f82163d |
|
MD5 | 64ba13e86bc99155bd58db8ad93be5c6 |
|
BLAKE2b-256 | 229639360fda62fb6eedbabb1e0d91aa39d711ef047c08457b58770ae503f4f2 |