GithubHelp home page GithubHelp logo

aws-samples / aws-transcribe-captioning-tools Goto Github PK

View Code? Open in Web Editor NEW
94.0 10.0 28.0 63 KB

Convert AWS Transcribe output into multiple caption formats.

License: MIT No Attribution

Python 97.30% Batchfile 2.70%

aws-transcribe-captioning-tools's Issues

getPhrasesFromTranscript leaves out phrase

the getPhrasesFromTranscript function will leave out the last partial phrase if the number of words in the transcript is not divisible by 10. As a result the vtt file will be missing the last 1-9 words from the transcript.

note: bug might also exist in getPhrasesFromTranslation function

get_time_code function error

The get_time_code function sometimes delivers the microseconds incorrectly causing the following caption to appear before the previous caption is removed.

I corrected the issue by overriding the function with the code below:

Format and return a string that contains the converted number of seconds into WebVTT format

def get_time_code( aws_timecode ):
timedelta = datetime.timedelta(seconds=float(aws_timecode))

hours = (timedelta.seconds // 3600) % 24
minutes = (timedelta.seconds // 60) % 60
seconds = timedelta.seconds % 60
microseconds = timedelta.microseconds / 1000
return str( "%02d:%02d:%02d.%03d" % (hours, minutes, seconds, microseconds ))	   

Cannot find vtt.py file

Thank you for sharing the code. But I cannot find vtt.py file to convert json to vtt file. Any idea?

Can't find srt.py

Hi! I'm interested in using these tools, but I don't see the srt.py file mentioned in the README.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.