Code Monkey home page Code Monkey logo

yt_downloaded_video_sequencer's Introduction

YT_Downloaded_Video_Sequencer

A simple tool to arrange the downloaded videos from any YouTube playlist into sequence. It works by adding the original sequence number of video to its prefix.

UPDATE (06 May 2022) :-

Applied Solution :-

  • I have used Levenshtein library to find similarity between title strings. It's not 100% perfect but working fine.

(1 Feb 2022) Currently in Progress. Partially working. If anyone wants to help, they are most welcome!

  • If you want to test/check the code, I have provided a dummy folder DownloadedVideos which contain empty mp4 files having same name as of a youtube playlist whose url is already added in code.

Everything is working fine. But the problem is in find() function in renamer.py.

Problem :-

  • How to check if the downloaded file is present in fetched title list(a list containing all the video's title of the playlist in original sequence)? When you download video from Videoder or any other app or website it insert various prefix or suffix or even modify some characters like changing "|" to "_" etc. So, it becomes tedious to search the file in fetched title list to get the sequential index.

Proposed Solution :-

  • I am thinking of partially checking the similarity by using startswith() or endswith() function instead of checking entire title string. It will solve the problem of extra suffix or prefix that were not in original title but added by app or website through which you have downloaded the video.

Requirements :-

  • Python3
  • Selenium
  • Chromedriver
  • Levenshtein library

How to install Requirements :-

  1. Python3 can be installed from their official site https://www.python.org/ . Or you can use anaconda environment.
  2. Selenium for Python can be installed by following command :-
python3 -m pip install selenium
  1. I have already provided Chromedriver (version: 100.0.x) .exe file But if you want to install anyways, do this from their official site :- Download Chromedriver
    Place the .exe file of chromedriver in the same folder where renamer.py file is located.
  2. Levenshtein can be installed by following command :-
pip install Levenshtein 

Getting Started :-

  • Download or clone repository.

  • Open cmd or terminal in same directory where renamer.py file is stored and then run it by followng command :-

python3 renamer.py

Expected Output :-

  • Playlist from where videos are downloaded.
    Youtube_Playlist

  • After downloading videos are stored without any order or sequence.
    Previously_Downloaded_Folder_Output

  • After running renamer.py, all files are renamed sequentially.
    New_Downloaded_Folder_Output

Dev :- Prakash Gupta

yt_downloaded_video_sequencer's People

Contributors

lunaticprakash avatar

Stargazers

 avatar

Watchers

 avatar

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.