{ "info": { "author": "CryptidVulpes", "author_email": "\"CryptidVulpes\" ", "bugtrack_url": null, "classifiers": [], "description": "Copyright (c) 2018 CryptidVulpes \n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\nDescription: # youtube-metrics\n Gather network metrics about YouTube videos\n \n Supported Python versions:\n * 3.4\n * 3.5\n * 3.6\n * 3.7\n \n ## Installation\n ```\n python3 -m pip install youtube-metrics\n ```\n \n ## Usage\n ```\n usage: youtube_metrics [-h] {analyze,es} ...\n \n Gather metrics about a video download.\n \n positional arguments:\n {analyze,es}\n analyze Analyze video\n es Print ES template\n \n optional arguments:\n -h, --help show this help message and exit\n ```\n \n ```\n usage: youtube_metrics es [-h]\n \n optional arguments:\n -h, --help show this help message and exit\n ```\n \n ```\n usage: youtube_metrics analyze [-h] [--chunk-size CHUNK_SIZE]\n [--download-limit DOWNLOAD_LIMIT]\n [--output-file OUTPUT_FILE]\n [--output-format OUTPUT_FORMAT]\n video_url [video_url ...]\n \n positional arguments:\n video_url The target video to download. Supports same services\n as youtube_dl.\n \n optional arguments:\n -h, --help show this help message and exit\n --chunk-size CHUNK_SIZE, -c CHUNK_SIZE\n Bytesize of each downloaded chunks (each chunk is\n timed). Default: 1024\n --download-limit DOWNLOAD_LIMIT, -l DOWNLOAD_LIMIT\n Bytesize of the maximum download before stopping\n measurements. Default: 41943040\n --output-file OUTPUT_FILE, -of OUTPUT_FILE\n Filepath for output. Output will be appended to the\n file. If not defined, stdout is used\n --output-format OUTPUT_FORMAT, -o OUTPUT_FORMAT\n Format for output. Valid values: json, csv. Default:\n json\n ```\n ### Results\n * Time: milliseconds\n * Distances: kilometers\n * Data: bytes\n * Throughput: bytes per second\n \n Results are printed to `stdout`. Logging is printed to `stderr`\n \n ### Example\n To pretty-print results, you can use `jq` or `python -m json.tool`:\n \n ```json\n $ youtube_metrics analyze -c 1 -l 1 \"https://www.youtube.com/watch?v=dQw4w9WgXcQ\" 2>/dev/null | jq\n {\n \"me\": {\n \"ip\": \"0.0.0.0\",\n \"coords\": {\n \"lat\": 7.2,\n \"long\": 5.6\n }\n },\n \"videos\": [\n {\n \"metadata\": {\n \"id\": \"dQw4w9WgXcQ\",\n \"uploader\": \"RickAstleyVEVO\",\n \"title\": \"Rick Astley - Never Gonna Give You Up (Video)\",\n \"duration\": 212000,\n \"webpage_url\": \"https://www.youtube.com/watch?v=dQw4w9WgXcQ\",\n \"view_count\": 487059212,\n \"url\": \"https://r4---sn-qo5-9a4e.googlevideo.com/videoplayback?gir=yes&itag=248&clen=48318078&ei=EErHW9KKFeWE7ASyhaLAAQ&pl=21&fvip=6&ms=au%2Crdu&mv=m&source=youtube&lmt=1537435386492907&ip=95.175.104.81&key=yt6&expire=1539808880&id=o-ANjlPe_raUhixlzpWPPw982Me7AlJYBdMOBjf3yaVaud&dur=212.040&mn=sn-qo5-9a4e%2Csn-5go7yn7z&mm=31%2C29&keepalive=yes&requiressl=yes&ipbits=0&sparams=aitags%2Cclen%2Cdur%2Cei%2Cgcr%2Cgir%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Ckeepalive%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cpl%2Crequiressl%2Csource%2Cexpire&mt=1539787173&initcwndbps=1157500&gcr=fi&c=WEB&aitags=133%2C134%2C135%2C136%2C137%2C160%2C242%2C243%2C244%2C247%2C248%2C278%2C394%2C395%2C396%2C397%2C398&mime=video%2Fwebm&signature=B96E93FF93CAE8866FF5DAF6BCFAA613730A7A83.1C827D982E985AD3CC87B3F1EED9324CC3993063&ratebypass=yes\",\n \"ext\": \"webm\",\n \"height\": 1080,\n \"format_note\": \"1080p\",\n \"filesize\": 48318078,\n \"width\": 1920,\n \"error\": \"\"\n },\n \"statistics\": {\n \"cache_url\": \"r4---sn-qo5-9a4e.googlevideo.com\",\n \"ping\": {\n \"min\": 1.505,\n \"avg\": 1.981,\n \"max\": 1.679,\n \"mdev\": 0.503,\n \"ip\": \"62.115.64.87\"\n },\n \"processing_time\": {\n \"dns_a_time\": 1.0,\n \"ping_time\": 1.0,\n \"dns_aaaa_time\": 1.0,\n \"ping6_time\": 1.0\n },\n \"distance\": {\n \"ip\": \"62.115.64.87\",\n \"coordinates\": {\n \"lat\": 42.43,\n \"long\": -72.64\n },\n \"distance\": 1\n },\n \"download\": {\n \"downloaded\": 2048,\n \"throughput\": 61394.828157497876,\n \"processing_time\": {\n \"request_time\": 0.0,\n \"response_time\": 0.0\n },\n \"format\": \"webm_1080p\"\n }\n }\n }\n ]\n }\n ```\nPlatform: UNKNOWN\nClassifier: Development Status :: 3 - Alpha\nClassifier: License :: OSI Approved :: MIT License\nClassifier: Programming Language :: Python :: 3.4\nClassifier: Programming Language :: Python :: 3.5\nClassifier: Programming Language :: Python :: 3.6\nClassifier: Programming Language :: Python :: 3.7\nClassifier: Environment :: Console\nClassifier: Intended Audience :: Science/Research\nClassifier: Operating System :: POSIX :: Linux\nClassifier: Operating System :: Microsoft :: Windows :: Windows 10\nDescription-Content-Type: text/markdown\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://gitlab.com/CryptidVulpes/youtube-metrics/", "keywords": "", "license": "MIT License", "maintainer": "", "maintainer_email": "", "name": "youtube-metrics", "package_url": "https://pypi.org/project/youtube-metrics/", "platform": "", "project_url": "https://pypi.org/project/youtube-metrics/", "project_urls": { "Homepage": "https://gitlab.com/CryptidVulpes/youtube-metrics/" }, "release_url": "https://pypi.org/project/youtube-metrics/0.3.0/", "requires_dist": [ "geoip2", "geopy", "requests", "dnspython", "youtube-dl", "humanize" ], "requires_python": "", "summary": "YouTube Metrics - Calculate Delivery Time of Videos", "version": "0.3.0" }, "last_serial": 4393180, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "82e08b8e5b528ff1594a463c0dda2519", "sha256": "083f04c3f18239cd0b1f3850749aaf665769f019d241676c4b16db6c77ba8e4d" }, "downloads": -1, "filename": "youtube_metrics-0.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "82e08b8e5b528ff1594a463c0dda2519", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26873311, "upload_time": "2018-10-14T10:09:08", "url": "https://files.pythonhosted.org/packages/bf/d2/581aea6a5adee62b972657c13348ec9d2083741516d4cb4c290f0e7991f2/youtube_metrics-0.0.1-py3-none-any.whl" } ], "0.1.0": [ { "comment_text": "", "digests": { "md5": "867eed321fbc3f57414e3af33eb5b9ac", "sha256": "96c5519520babfa2c88e57e86da73f1c8d6d339d32b5251cedbfb8c6941108d7" }, "downloads": -1, "filename": "youtube_metrics-0.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "867eed321fbc3f57414e3af33eb5b9ac", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26877125, "upload_time": "2018-10-17T12:35:42", "url": "https://files.pythonhosted.org/packages/18/8a/c50805ede0661af4ccfb65aa73ee4d7f6846c67fae4146df6745b9485a28/youtube_metrics-0.1.0-py3-none-any.whl" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "ea8fd3f144eab4c71045e57b78c03672", "sha256": "779fb7e5a2a2c56938d86956a881e11e09184b1f4e3a6ee161b1b963a95d7200" }, "downloads": -1, "filename": "youtube_metrics-0.2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "ea8fd3f144eab4c71045e57b78c03672", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26876727, "upload_time": "2018-10-17T18:32:28", "url": "https://files.pythonhosted.org/packages/3d/4b/91645a97b6ae023d62cbc9c207b146654b288963396673f1eb6bc02ef3c1/youtube_metrics-0.2.0-py3-none-any.whl" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "c08daeab10c5f8c07d5c872b76264dd6", "sha256": "c81817291626c70540227b0830e0ad83b45cf2991cd3b1d7674a1893365ffb28" }, "downloads": -1, "filename": "youtube_metrics-0.2.1-py3-none-any.whl", "has_sig": false, "md5_digest": "c08daeab10c5f8c07d5c872b76264dd6", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26876795, "upload_time": "2018-10-17T19:41:56", "url": "https://files.pythonhosted.org/packages/f4/94/46510d56baf89773d997e3855316eea583adb8cd1af0d44fae7b1032acaf/youtube_metrics-0.2.1-py3-none-any.whl" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "b7b03f3de5bb87e64ebd826f4e083d0e", "sha256": "e31a168331d6b9d0b282944970c5a700c872ca323bed930168c4011ae7f72050" }, "downloads": -1, "filename": "youtube_metrics-0.3.0-py3-none-any.whl", "has_sig": false, "md5_digest": "b7b03f3de5bb87e64ebd826f4e083d0e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26877011, "upload_time": "2018-10-19T07:35:10", "url": "https://files.pythonhosted.org/packages/80/81/13b7049d43c4492b8119351302181be91ad8536b3d981ffadc974b768833/youtube_metrics-0.3.0-py3-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b7b03f3de5bb87e64ebd826f4e083d0e", "sha256": "e31a168331d6b9d0b282944970c5a700c872ca323bed930168c4011ae7f72050" }, "downloads": -1, "filename": "youtube_metrics-0.3.0-py3-none-any.whl", "has_sig": false, "md5_digest": "b7b03f3de5bb87e64ebd826f4e083d0e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26877011, "upload_time": "2018-10-19T07:35:10", "url": "https://files.pythonhosted.org/packages/80/81/13b7049d43c4492b8119351302181be91ad8536b3d981ffadc974b768833/youtube_metrics-0.3.0-py3-none-any.whl" } ] }