This repo is a toolbox of personal Python utilities for media management and downloading. It is not a single package; each script is meant to be run directly and does one focused job. The workspace contains top-level music utilities plus two subprojects for video watermarking and YouTube downloads.
Folder Layout
ai_music_organizer.pymusic_Organizer.pymusic_organizer_old.pyrename_songs.pyduplicate_file_deleter.pyVideo-watermark/Youtube-dl-py/
What Each Script Does Top-level scripts:
ai_music_organizer.py
Organizes.mp3and.m4afiles in a target folder into language or style categories using Gemini AI when available, with a fallback keyword matcher. It only scans the top level (no recursive search), previews the planned moves in batches, and asks for confirmation before moving files. Categories: English, Hindi, Arabic, Bengali, Remix, Unplugged, Jhankar, Unknown.music_Organizer.py
A similar AI organizer with smaller batches and.mp3-only scanning. It uses Gemini for classification when configured, otherwise falls back to keyword matching.music_organizer_old.py
Older AI organizer variant with larger batches and a stricter rate-limit pause strategy.rename_songs.py
Renames.mp3and.m4afiles from metadata tags usingTinyTag, strips promo junk from tags, keeps only the first artist if multiple are listed, and appends a postfix like- songs.SumanOnline.Com. It avoids overwriting by adding(1),(2), etc.duplicate_file_deleter.py
Deletes duplicate files that follow thename (1).extpattern after a confirmation prompt.
Video-watermark project:
Video-watermark/watermark.py
Advanced watermarking tool that can apply text, logo, or both. It processes each frame using OpenCV, uses FFmpeg to preserve audio, and writes output toVideo-watermark/watermarked_videos/.Video-watermark/watermark.png
Sample logo file used by the watermark script.
YouTube-dl-py project:
Youtube-dl-py/yt-dlp.py
Full-featured downloader usingyt-dlpwith audio/video modes, thumbnail download, FFmpeg conversion, and MP3 metadata embedding viamutagen.Youtube-dl-py/yt_downloader.py
Simpler audio or video downloader with a quality selection menu.Youtube-dl-py/yt-video-dl.py
Video-only downloader with quality selection.Youtube-dl-py/video_based.py
Downloads media and adds a watermark to videos using FFmpegdrawtext. Also embeds metadata for audio.Youtube-dl-py/with_photo.py
Downloader that embeds thumbnails into MP3 files usingmutagen.Youtube-dl-py/add-watermark-videos.py
Batch watermarking for local videos with audio preserved viamoviepy. Outputs toYoutube-dl-py/watermarked_videos/.Youtube-dl-py/add-watermark-videos-no-audio.py
Watermarking without audio preservation, implemented purely with OpenCV.Youtube-dl-py/watermark.py
Interactive watermark tool similar to the one inVideo-watermark/, using OpenCV and FFmpeg.Youtube-dl-py/test.py
Test downloader script for videos.Youtube-dl-py/watermark.pngandYoutube-dl-py/arial.ttf
Assets used by watermarking and text rendering tools.
Requirements Python 3.9+ is recommended. Install only what you need for the scripts you run.
AI music organizers:
python -m pip install google-genaiMusic renamer:
python -m pip install tinytag tqdmVideo watermarking:
python -m pip install opencv-python numpy tqdm moviepyYouTube downloaders:
python -m pip install yt-dlp mutagen requestsSystem tools:
- FFmpeg must be installed and available on your
PATHfor scripts that convert media or preserve audio.
How To Run AI music organizer:
python ai_music_organizer.py "D:\Music\ToSort"Fallback organizer:
python music_Organizer.py "D:\Music\ToSort"Rename files by tags:
python rename_songs.pyDelete duplicates:
python duplicate_file_deleter.pyVideo watermarking:
cd Video-watermark
python watermark.pyYouTube downloads:
cd Youtube-dl-py
python yt-dlp.pyOutputs
Video-watermark/watermarked_videos/stores processed videos.Youtube-dl-py/downloads/stores downloaded audio and video files.Youtube-dl-py/watermarked_videos/stores watermarked outputs for local batch processing.- Temporary folders like
temp_watermark/are created during processing and cleaned up automatically.
Safety Notes
duplicate_file_deleter.pydeletes files permanently after confirmation. Use it on a backup or verify the target folder first.- The organizer scripts move files to category folders. They preview each batch and require confirmation before moving.
Security Notes Some organizer scripts currently hardcode a Gemini API key. It is safer to move that key to an environment variable or config file and remove it from the script before sharing or committing.