{"id":24998918,"url":"https://github.com/thiswillbeyourgithub/mediadurationrecursivechecker","last_synced_at":"2025-03-29T18:11:57.410Z","repository":{"id":271009157,"uuid":"912137006","full_name":"thiswillbeyourgithub/MediaDurationRecursiveChecker","owner":"thiswillbeyourgithub","description":"MediaDurationRecursiveChecker is a Python script to calculate the total duration and size of media files (video/audio) in a directory, supporting formats like `.mp3`, `.mp4`, `.avi`, `.mkv`, `.mov`, `.wav`, and `.flac`, with recursive scanning, progress bar, and JSON output.","archived":false,"fork":false,"pushed_at":"2025-01-08T11:42:03.000Z","size":344,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-29T18:11:53.469Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thiswillbeyourgithub.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-04T17:50:42.000Z","updated_at":"2025-01-08T18:17:49.000Z","dependencies_parsed_at":"2025-02-04T18:52:27.952Z","dependency_job_id":"327b4e55-85a9-4a77-b547-df348072ff7f","html_url":"https://github.com/thiswillbeyourgithub/MediaDurationRecursiveChecker","commit_stats":null,"previous_names":["thiswillbeyourgithub/filesizetreechecker","thiswillbeyourgithub/mediadurationrecursivechecker"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thiswillbeyourgithub%2FMediaDurationRecursiveChecker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thiswillbeyourgithub%2FMediaDurationRecursiveChecker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thiswillbeyourgithub%2FMediaDurationRecursiveChecker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thiswillbeyourgithub%2FMediaDurationRecursiveChecker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thiswillbeyourgithub","download_url":"https://codeload.github.com/thiswillbeyourgithub/MediaDurationRecursiveChecker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246223331,"owners_count":20743167,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-02-04T18:52:18.818Z","updated_at":"2025-03-29T18:11:57.405Z","avatar_url":"https://github.com/thiswillbeyourgithub.png","language":"Python","readme":"# MediaDurationRecursiveChecker\n\n\u003e Une version française de ce fichier README est disponible : [README_fr.md](README_fr.md)  \n\u003e A French version of this README is available: [README_fr.md](README_fr.md)\n\n![Screenshot of the GUI](gui.png)\n\n# MediaDurationRecursiveChecker\n\nThis Python script calculates the total duration of media files (video/audio) in a directory and estimates the total processing time. It was created to help estimate the total duration of daily/rush footage on a hard drive. The project was renamed from FileSizeTreeChecker to MediaDurationRecursiveChecker to better reflect its purpose.\n\n## Features\n\n- Supports common media formats: `.mp3`, `.mp4`, `.avi`, `.mkv`, `.mov`, `.wav`, `.flac`\n- Recursively scans directories\n- Excludes hidden files (those starting with '.')\n- Provides:\n  - Total number of media files\n  - Total size in GB\n  - Total duration of all files (and estimation every 10 files)\n  - Verbose output with individual file durations\n  - Results optionally saved to JSON file\n\n## Requirements\n\n- Python 3.6+ (only tested on 3.8 and 3.11)\n- `moviepy` (for media duration extraction)\n- `pyperclip` (to handle copying and pasting the path)\n\n## Installation and Usage\n\nYou have two options to run MediaDurationRecursiveChecker:\n\n### 1. Run from Source (GUI)\n1. Install required Python packages:\n```bash\n# On macOS:\nsudo python3 -m pip install moviepy pyperclip\n\n# On other platforms:\npip install moviepy pyperclip\n```\n2. Ensure `ffmpeg` is installed on your system\n3. Run the script:\n```bash\npython MediaDurationRecursiveChecker.py\n```\n4. Use the graphical interface to select folders and process files\n\n### 2. Build Your Own Executable\nIf you prefer to build it yourself:\n1. Install PyInstaller:\n```bash\npip install pyinstaller\n```\n2. Build the executable:\n```bash\npyinstaller --onefile --name MediaDurationRecursiveChecker MediaDurationRecursiveChecker.py --noconsole --hidden-import=imageio_ffmpeg\n```\n3. The executable will be in the `dist` directory\n\nNote: This has been tested to work on macOS 11 when using the command:\n```bash\nsudo pyinstaller --onefile --windowed --name MediaDurationRecursiveChecker MediaDurationRecursiveChecker.py --clean\n```\n\nA pre-compiled .app for macOS is available in the 1.0.1 release.\n\n## Output Example\n\n```\nFound 1234 media files (456.78 GB)\nProcessing files: 100%|████████████████████| 1234/1234 [12:34\u003c00:00,  1.23it/s]\nCurrent: 12h 34m | Estimated total: 15h 30m\n\nTotal duration: 15h 30m\nResults saved to media_durations.json\n```\n\n## JSON Output Format\n\nThe output JSON file contains:\n```json\n{\n  \"/path/to/file.mp4\": {\n    \"duration\": 3600,  // in seconds\n    \"size\": 1048576   // in bytes\n  },\n  ...\n}\n```\n\n## Notes\n\n- Files are processed in random order to provide better time estimates\n- The script handles errors gracefully, skipping files it can't process\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthiswillbeyourgithub%2Fmediadurationrecursivechecker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthiswillbeyourgithub%2Fmediadurationrecursivechecker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthiswillbeyourgithub%2Fmediadurationrecursivechecker/lists"}