A Report On Making Youtube Video Downloader Using Python With GUI.
A Report On Making Youtube Video Downloader Using Python With GUI.
Individual project
Coventry University
Intake:
September 2022
Firstly, I would like to thank Softwarica College, for giving me the excellent chance
to work on my project report, which is focused on creating a tool to illegally
download videos from YouTube. I would like to express my appreciation and
recognition to my module teacher for generously offering his/her precious time,
invaluable guidance, and constructive suggestions towards the improvement of
my program and to allow me to do this project as a form of awareness against
piracy in cyber world. Finally, to my friends who helped me with pitching ideas for
program and betterment of my report, I am grateful to all of them.
Abstract
This report presents a Youtube video downloader tool developed using Python, designed to
help users easily download videos from Youtube. While the tool was developed with good
intentions, it is important to acknowledge the issue of online piracy and the potential misuse of
such tools. The internet is highly vulnerable to piracy, and tools like this downloader can be
used to illegally download copyrighted content. The report emphasizes the importance of
responsible online behavior and encourages users to respect copyright laws and the rights of
content creators. Additionally, the report provides insights on the impact of online piracy and
the steps that can be taken to address this issue.
1.1. Background
The analysis, which examined online traffic from January to August 2022, said that piracy had surged
across all business sectors, with cinema piracy seeing the largest increase of 49.1%. The rise in music
was the smallest at 3.87%. In terms of distributing this illegal content, unlicensed streaming sites receive
53.9% of traffic, compared to unlicensed download sites' 46.1% (which includes torrents and cyber
lockers).[ Butts, T. (2022)]. Here I have made a Youtube video downloader tool using python
programming language.
This tool will take accept link of a video as input, and download it in highest possible download
resolution. This tool is illegal in itself as it promotes piracy but this time, I have created it as a method of
raising awareness against it. Back in the time of http, extensions for web browser were created which
could listen between devices and internet server in network. This caused awareness among public about
how open their sensitive information was, and https came to be. Currently the condition of piracy is
same; it takes no time to download any content from internet illegally. This tool is imple one of many
that will be responsible for raising awareness.
1.3. Objectives
1. Develop a user-friendly Youtube video downloader tool in Python.
2. Emphasize responsible online behavior and raise awareness against piracy.
3. Provide insights on the impact of piracy and the importance of respecting copyright laws.
4. Educate users on legal ways to access and use online content.
5. Encourage legitimate use of the program while discouraging misuse.
6. Promote responsible and ethical online behavior and combat online piracy.
2. Block Diagram:
3. Methodology:
3.1. The Algorithm
1. Import the required modules 'tkinter' and 'pytube'.
2. Create a tkinter window.
3. Set the dimensions of the window to 500x300 and make it non-resizable.
4. Set the title of the window as "YouTube Video Downloader".
5. Create a tkinter Label widget with the text "YouTube Video Downloader" and pack it onto the
window.
6. Create a tkinter StringVar object 'link' to store the user-entered link.
7. Create a tkinter Label widget with the text "Paste Link Here:" and place it onto the window.
8. Create a tkinter Entry widget to allow the user to enter the link and associate it with the 'link'
StringVar.
9. Define a function ‘Downloader ()' to download the video from the provided link.
10. Get the link entered by the user using the ‘get ()' method of the 'link' StringVar.
11. Create a 'YouTube' object with the provided link.
12. Get the highest resolution stream of the video using the 'get_highest_resolution ()' method.
13. Download the video using the ‘download ()' method.
14. Create a tkinter Label widget with the text "DOWNLOADED" and place it onto the window.
15. Create a tkinter Button widget with the text "DOWNLOAD" and associate it with the
‘Downloader ()' function.
16. Place the Button widget onto the window.
17. Start the tkinter event loop using the ‘mainloop ()' method of the tkinter window object.
Github: https://github.com/Spandan-Bhattarai/Python-projects/blob/main/ytdownloader
3.3. Procedure
i. Import
This imports the required modules 'tkinter' and 'pytube' for the program to work properly.
ii. Window
This creates a tkinter window and sets the dimensions to 500x300 pixels, makes the window non-
resizable, and sets the title of the window as "Youtube Video Downloader".
iii. Label
This creates a Label widget and places it onto the window. The label has the text "Youtube Video
Downloader" and is set with a font size of 20 and bold font style. The ‘pack ()' method is used to add the
widget to the window.
iv. Link
This creates a StringVar object 'link' to store the user-entered link. Then, a Label widget is created with
the text "Paste Link Here:" and placed onto the window. The label has a font size of 15 and bold font
style. An Entry box/widget is also created to allow the user to enter the link, and is associated with the
'link' StringVar object. The entry box has a width of 70 and is positioned at (x=32, y=90).
v. Downloader function
This defines a function ‘Downloader ()' that downloads the video from the provided link. The function
first gets the link entered by the user using the ‘get ()' method of the 'link' StringVar. Then, it creates a
'YouTube' object with the provided link. It gets the highest resolution stream of the video using the
'get_highest_resolution ()' method, and downloads the video using the ‘download ()' method. Finally, a
Label widget is created with the text "DOWNLOADED" and placed onto the window at position (x=180,
y=210).
This creates a Button widget with the text "DOWNLOAD" and associates it with the 'Downloader ()'
function. The button has a font size of 15, a background color of 'pale violet red', and a padding of 2
pixels. The button is positioned at (x=180, y=150).
vii. Start
This starts the tkinter event loop which listens for events and updates the GUI accordingly. This is
necessary to ensure that the window remains open until the user closes it or quits the program.
4. Output/Result
Conclusion:
In conclusion, this program demonstrates a simple implementation of tkinter and pytube library in
python programming language. The program prompts the user to enter a link to a video, reads the
References:
Anand, A. (n.d.). Digital piracy - An overview. Analytics Steps - A leading source of Technical &
Financial content. https://www.analyticssteps.com/blogs/digital-piracy-overview
Butts, T. (2022, October 17). Report: Film piracy up nearly 50% in 2022.
TVTechnology. https://www.tvtechnology.com/news/report-film-piracy-up-nearly-50-in-2022