123456789101112131415161718 |
- from autosub import DEFAULT_CONCURRENCY
- from autosub import DEFAULT_SUBTITLE_FORMAT
- from pytranscriber.control.ctr_main import Ctr_Main
- from pytranscriber.control.ctr_autosub import Ctr_Autosub
- import multiprocessing
- def listener_progress(string, percent):
- True
- if __name__ == '__main__':
- Ctr_Autosub.init()
- Ctr_Autosub.generate_subtitles('in.mp4','zh',
- listener_progress,
- output='out.txt',
- concurrency=DEFAULT_CONCURRENCY,
- subtitle_file_format=DEFAULT_SUBTITLE_FORMAT)
|