"X, but Y, every time Z" Jan 15, 2017 Michael Benimovich, Gabriel Caniglia, and Akash Borde

Remember the meme "Bee Movie, but every time they say Bee it gets faster?"

This project lets you do that with any video you want!

Our project is a website takes in a video link and a keyword and returns a new video, sped up every time the keyword is said in the video.

We wrote an HTML page that has a simple user interface: an address bar to enter any youtube URL, and another address bar to take in any keyword.

Our HTML page links to a Python application which does work on the video. We download the video from youtube using a pafy's API, then scrape the closed captioning from that video using an XML scraper. These comments are then saved into a text file, which we opened with a Java IDE called "Processing".

In this Java application, we wrote an algorithm that takes the textfile and searches for all the instances of the keyword and maps them to their corresponding timestamps in the video when that keyword was said. We then stored these in a 2-D array. These timestamps were converted to milliseconds, and our "SPEEDING UP" factor was taken into account. Because we sped up the video every time the video had the keyword, we had to modify all of our timestamps to ensure we sped up the video at the correct time, adjusted for sped-up play.

For example, if the word "Bee" was mentioned at 16,000millis, 32,000 millis, and 48,000millis, and we sped up the video 2x every time, we had to edit the timestamp data to 16,000, 24,000, and 28,000 millis.

We then sped up the video in the Processing IDE correspondingly, and downloaded the new video. Finally, we exported the new video, which was just the original video, but sped up every time the keyword was mentioned. Happy meme creating!

Share this project:
×

Updates