{ "info": { "author": "SeparateRecords", "author_email": "me@rob.ac", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Environment :: Console", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Multimedia :: Sound/Audio", "Topic :: Multimedia :: Sound/Audio :: Conversion" ], "description": "
\n\n

Nightcore - Easily modify speed/pitch

\n\n

\nA focused CLI and API for changing the pitch and speed of audio. Requires FFmpeg.\n

\n\n[![Latest release](https://img.shields.io/pypi/v/nightcore?color=blue)](https://pypi.org/project/nightcore)\n[![Supported Python versions](https://img.shields.io/pypi/pyversions/nightcore?color=364ed6)](https://python.org)\n[![Requires FFmpeg](https://img.shields.io/badge/requires-FFmpeg-721d78)](https://ffmpeg.org)\n[![MIT License](https://img.shields.io/pypi/l/nightcore?color=460611)](https://github.com/SeparateRecords/nightcore/blob/master/LICENSE)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000.svg)](https://github.com/psf/black)\n\n

\n \n Installation | CLI Usage | API Usage\n \n

\n\n
\n\n> I had the idea for this a long time ago, and wanted to make it to prove a point. This program is not intended for, nor should it be used for, copyright infringement and piracy. [**Nightcore is not, and has never been, fair use**](https://www.avvo.com/legal-answers/does-making-a--nightcore--version-of-a-song--speed-2438914.html).\n\n\n\n## Installation\n\n**FFmpeg is a required dependency** - [see here](https://github.com/jiaaro/pydub#getting-ffmpeg-set-up) for instructions on how to set it up!\n\nWith FFmpeg installed, you can use `pip` to install `nightcore` (although [pipx](https://pipxproject.github.io/pipx/) is recommended when only installing the CLI)\n\n```sh\npip install nightcore\n```\n\n### Building from source\n\n`nightcore` is built using [Poetry](https://poetry.eustace.io).\n\n```sh\n$ git clone https://github.com/SeparateRecords/nightcore\n$ poetry install\n$ poetry build\n```\n\n\n\n## CLI Usage\n\n`nightcore` is predictable and ensures there is no unexpected behaviour. As nightcore relies on FFmpeg under the hood, any format supported by FFmpeg is supported by the CLI.\n\n### Speed/pitch\n\nSpeeding up a track is super easy. By default, it will increase the pitch by 1 tone.\n\n```console\n$ nightcore music.mp3 > out.mp3\n```\n\nYou can manually set the speed increase by passing a number after the file. Without specifying a type, the increase will be in semitones.\n\n```console\n$ nightcore music.mp3 +3 > out.mp3\n```\n\n### Types\n\nYou can change the type of speed increase by providing it after the number. At the moment, nightcore can take any of `semitones`, `tones`, `octaves` or `percent`.\n\n```console\n$ nightcore music.mp3 +3 tones > out.mp3\n```\n\nWhen using percentages, `100 percent` means no change, `150 percent` is 1.5x speed, `80 percent` is 0.8x speed, etc.\n\n```console\n$ nightcore music.mp3 150 percent > out.mp3\n```\n\n### Format & Codec\n\nIf file's format cannot be inferred from its extension, you can specify it manually with `--format` (`-f`).\n\n```console\n$ nightcore --format ogg badly_named_file > out.mp3\n```\n\nThe codec can be manually set using `--codec` (`-c`).\n\n### Output\n\nIf the output cannot be redirected, you can specify an output file with `--output` (`-o`). The format will be guessed from the extension.\n\n```console\n$ nightcore music.mp3 --output out.mp3\n```\n\nTo manually set the output format (useful if redirecting), use `--output-format` (`-x`).\n\n```console\n$ nightcore music.mp3 --output-format ogg > music_nc.ogg\n```\n\nIf this option is not provided, the output format will be guessed in this order, defaulting to MP3 if all fail:\n\n1. Output option file extension (`--output example.wav`)\n2. Explicit input file type (`--format ogg`)\n3. Input file extension (`music.ogg`)\n\n### EQ\n\nTo compensate for a pitch increase, the output track will have a default +2db bass boost and -1db treble reduction applied. **To disable this**, pass in `--no-eq`. Note that if the speed is decreased, there will be no automatic EQ.\n\n```console\n$ nightcore music.mp3 --no-eq > out.mp3\n```\n\n\n\n## API Usage\n\nThe nightcore API is built using [pydub](http://pydub.com), a high level audio processing library. It's worth reading a bit of its documentation ([or at least the section on exporting](https://github.com/jiaaro/pydub/blob/master/API.markdown#audiosegmentexport)), but you'll get by with only having read the examples below.\n\nThe API itself performs no equalization, unlike the CLI - see [nightcore/cli.py](nightcore/cli.py) for the implementation (search \"parameters\").\n\nAs the word `nightcore` is long, it's recommended to import the module as `nc`.\n\n### Quickstart\n\nYou can use any of `Octaves`, `Tones`, `Semitones`, or `Percent` to change speed. These are all subclasses of the base `RelativeChange` class.\n\nUsing the @ operator with one of the above classes is the most convenient way to nightcore a path-like object or `AudioSegment`.\n\n```python\nimport nightcore as nc\n\nnc_audio = \"tests/test.mp3\" @ nc.Tones(1)\n\nnc_audio.export(\"tests/test_nc.mp3\")\n```\n\n### Advanced Usage\n\n> **nightcore**(*audio_or_path*, *amount*, \\*\\**kwargs*) -> *AudioSegment*\n\nThe @ operator is shorthand for the `nightcore` function. The function only needs to be called manually if:\n\n- You need to provide additional keyword arguments to `AudioSegment.from_file`\n- The operator is less readable in context\n- You need to use a function\n\nThere is also an equivalent async function in its own namespace (`nightcore.aio`).\n\n```python\nimport nightcore as nc\n\n# Additional keyword args are passed to AudioSegment.from_file\naudio = nc.nightcore(\"/tmp/badly_named_audio\", nc.Semitones(2), format=\"ogg\")\n```\n\n## Contributing\n\nContributions, feedback, and feature requests are all welcome and greatly appreciated, no matter how small.\n\n## License\n\nThis project is licensed under the MIT license.\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/SeparateRecords/nightcore", "keywords": "nightcore,cli,audio,pitch,speed", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "nightcore", "package_url": "https://pypi.org/project/nightcore/", "platform": "", "project_url": "https://pypi.org/project/nightcore/", "project_urls": { "Homepage": "https://github.com/SeparateRecords/nightcore" }, "release_url": "https://pypi.org/project/nightcore/1.1.0/", "requires_dist": [ "pydub (>=0.23.1,<0.24.0)", "click (>=7.0,<8.0)" ], "requires_python": ">=3.7,<4.0", "summary": "Intuitive CLI and API for modifying the speed/pitch of audio", "version": "1.1.0", "yanked": false, "yanked_reason": null }, "last_serial": 6033164, "releases": { "0.5.4": [ { "comment_text": "", "digests": { "md5": "346bf14ac5c94216ad964f466d3a9cda", "sha256": "83183893fa2b5d65ea4b20cb4e8ca015746db9c577dea43baceceac628f9c856" }, "downloads": -1, "filename": "nightcore-0.5.4-py3-none-any.whl", "has_sig": false, "md5_digest": "346bf14ac5c94216ad964f466d3a9cda", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 4436, "upload_time": "2019-09-21T15:49:57", "upload_time_iso_8601": "2019-09-21T15:49:57.059709Z", "url": "https://files.pythonhosted.org/packages/e7/8f/2887d79c921047fe4e311681f7b23cf313243f4114f59a19e3eeb1e2d8fc/nightcore-0.5.4-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "e55699fc5dd95825a0478a22ecddad31", "sha256": "ef47b91e0f8ce23774c2e85a920426843bf62b9189cf425ed2a0cd8c3d8794a3" }, "downloads": -1, "filename": "nightcore-0.5.4.tar.gz", "has_sig": false, "md5_digest": "e55699fc5dd95825a0478a22ecddad31", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 4206, "upload_time": "2019-09-21T15:49:59", "upload_time_iso_8601": "2019-09-21T15:49:59.835718Z", "url": "https://files.pythonhosted.org/packages/a4/6b/c2401af848f014bf95950cb93d6af8bd3ec2157877fe4d9c830866e51dd4/nightcore-0.5.4.tar.gz", "yanked": false, "yanked_reason": null } ], "0.5.5": [ { "comment_text": "", "digests": { "md5": "9195f97bae6ae2a1cdc6511713a7bce4", "sha256": "bcf1e99aedd21aa8504989e8d129a2bcc91e3ff35c5a16b5e0fbcf2d8de4d354" }, "downloads": -1, "filename": "nightcore-0.5.5-py3-none-any.whl", "has_sig": false, "md5_digest": "9195f97bae6ae2a1cdc6511713a7bce4", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 4666, "upload_time": "2019-09-22T01:34:09", "upload_time_iso_8601": "2019-09-22T01:34:09.483349Z", "url": "https://files.pythonhosted.org/packages/f9/44/35eb333add87d9a7a4fd3857e1139c49c5c12bb8904a6ce825826e92b9d1/nightcore-0.5.5-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "7e9c3776ba25d2724b1fa582edfbfd80", "sha256": "cf44d8eebd16877d69eb6023796c31419ecfb5acfd509f9680b12e0bffc33128" }, "downloads": -1, "filename": "nightcore-0.5.5.tar.gz", "has_sig": false, "md5_digest": "7e9c3776ba25d2724b1fa582edfbfd80", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 4462, "upload_time": "2019-09-22T01:34:11", "upload_time_iso_8601": "2019-09-22T01:34:11.422781Z", "url": "https://files.pythonhosted.org/packages/40/f1/1bcbb426091b3a66f45c88c03780213ab5ec7d9d8bc778f2269a15c722de/nightcore-0.5.5.tar.gz", "yanked": false, "yanked_reason": null } ], "0.5.6": [ { "comment_text": "", "digests": { "md5": "b3dc90c6f3632eee2befef491b8350d4", "sha256": "cb4d4e7125469ef3fd5f82d03e4b1e293dcacd9fdb06d4d254d34e2f7327d19d" }, "downloads": -1, "filename": "nightcore-0.5.6-py3-none-any.whl", "has_sig": false, "md5_digest": "b3dc90c6f3632eee2befef491b8350d4", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 4838, "upload_time": "2019-09-26T09:27:52", "upload_time_iso_8601": "2019-09-26T09:27:52.130914Z", "url": "https://files.pythonhosted.org/packages/ad/0d/ddaa98f1ff661141ab40dc3a6f5d796003eaecbeb83d0edaa167ab380b76/nightcore-0.5.6-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "3f00108076c784ab617fb95346840921", "sha256": "7e4d9efea742b694ec140d49289788a8229495df15134c4ac1781edda6855691" }, "downloads": -1, "filename": "nightcore-0.5.6.tar.gz", "has_sig": false, "md5_digest": "3f00108076c784ab617fb95346840921", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 4640, "upload_time": "2019-09-26T09:27:54", "upload_time_iso_8601": "2019-09-26T09:27:54.006703Z", "url": "https://files.pythonhosted.org/packages/74/18/8aeb2bb3a97e61676b869366e2a1fb9c48580b0e3d1a03a5d2a9309ede9a/nightcore-0.5.6.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.0": [ { "comment_text": "", "digests": { "md5": "a01221377ed3fd891f0a801bf21670f3", "sha256": "a02387392ec3b4635b90097353c0d82c8af90e757a43db5cf11999e1d2f04c63" }, "downloads": -1, "filename": "nightcore-1.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "a01221377ed3fd891f0a801bf21670f3", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 8562, "upload_time": "2019-10-13T13:32:07", "upload_time_iso_8601": "2019-10-13T13:32:07.976968Z", "url": "https://files.pythonhosted.org/packages/ee/c2/458e579135c01007f815b8c27dcdee1f0d9a58d730ad7780eaba7e30627c/nightcore-1.0.0-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "c2bd7fc1d545bd467498f866095c02e4", "sha256": "cf350ba1214ac67ddd3af98dcb0360612921ab00016741aee83242331f08137d" }, "downloads": -1, "filename": "nightcore-1.0.0.tar.gz", "has_sig": false, "md5_digest": "c2bd7fc1d545bd467498f866095c02e4", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 8336, "upload_time": "2019-10-13T13:32:10", "upload_time_iso_8601": "2019-10-13T13:32:10.643038Z", "url": "https://files.pythonhosted.org/packages/19/38/801bb028ee95c5703a9049e72959b365e7a414298c06a53dd192128ba08f/nightcore-1.0.0.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "a8526cf095b46ebf1d59a4a04ff62faa", "sha256": "b5d30a582eab76576a781b3eb31f0ce4cf08105a9b2d0e4290fcceb8c5819351" }, "downloads": -1, "filename": "nightcore-1.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "a8526cf095b46ebf1d59a4a04ff62faa", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 8801, "upload_time": "2019-10-13T15:02:06", "upload_time_iso_8601": "2019-10-13T15:02:06.834809Z", "url": "https://files.pythonhosted.org/packages/d9/30/ff18e1254b027fe55b32dfa20d0803d7e2c89df238869243f5b9154ae372/nightcore-1.0.1-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "80227a6e69386ffcf3fc4e945a4c3299", "sha256": "961aa5c21213609cfdafd70ccdb82d26723de56e076f0faabedb16d58452527b" }, "downloads": -1, "filename": "nightcore-1.0.1.tar.gz", "has_sig": false, "md5_digest": "80227a6e69386ffcf3fc4e945a4c3299", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 8608, "upload_time": "2019-10-13T15:02:08", "upload_time_iso_8601": "2019-10-13T15:02:08.654791Z", "url": "https://files.pythonhosted.org/packages/62/51/eb84edb025b74e24fd743091c7d7eb775327e3045faabb78e9525047c648/nightcore-1.0.1.tar.gz", "yanked": false, "yanked_reason": null } ], "1.1.0": [ { "comment_text": "", "digests": { "md5": "7045591d88cdc334fc8126f273b56132", "sha256": "8a8c2097af4b13fe981cf3f0f18e7169be0c3a11bc5f0301186e15d9ec5655c9" }, "downloads": -1, "filename": "nightcore-1.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "7045591d88cdc334fc8126f273b56132", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 9912, "upload_time": "2019-10-26T07:47:45", "upload_time_iso_8601": "2019-10-26T07:47:45.479384Z", "url": "https://files.pythonhosted.org/packages/20/4d/fc97e2fffa1bd3874b3a9e81108378e6a07fd665e62ee56f052b179b49c7/nightcore-1.1.0-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "71cf641ae802ec20dd8fa3b631384656", "sha256": "cf4e04c0c8c1a039efefc051411495efa1e0bac085b6c1f6bee8b49053823cd1" }, "downloads": -1, "filename": "nightcore-1.1.0.tar.gz", "has_sig": false, "md5_digest": "71cf641ae802ec20dd8fa3b631384656", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 9162, "upload_time": "2019-10-26T07:47:47", "upload_time_iso_8601": "2019-10-26T07:47:47.092529Z", "url": "https://files.pythonhosted.org/packages/49/3b/227ce394961ccc3b7a72f5b0cded6a106eed683a71579ea03d4873d51148/nightcore-1.1.0.tar.gz", "yanked": false, "yanked_reason": null } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "7045591d88cdc334fc8126f273b56132", "sha256": "8a8c2097af4b13fe981cf3f0f18e7169be0c3a11bc5f0301186e15d9ec5655c9" }, "downloads": -1, "filename": "nightcore-1.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "7045591d88cdc334fc8126f273b56132", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.7,<4.0", "size": 9912, "upload_time": "2019-10-26T07:47:45", "upload_time_iso_8601": "2019-10-26T07:47:45.479384Z", "url": "https://files.pythonhosted.org/packages/20/4d/fc97e2fffa1bd3874b3a9e81108378e6a07fd665e62ee56f052b179b49c7/nightcore-1.1.0-py3-none-any.whl", "yanked": false, "yanked_reason": null }, { "comment_text": "", "digests": { "md5": "71cf641ae802ec20dd8fa3b631384656", "sha256": "cf4e04c0c8c1a039efefc051411495efa1e0bac085b6c1f6bee8b49053823cd1" }, "downloads": -1, "filename": "nightcore-1.1.0.tar.gz", "has_sig": false, "md5_digest": "71cf641ae802ec20dd8fa3b631384656", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.7,<4.0", "size": 9162, "upload_time": "2019-10-26T07:47:47", "upload_time_iso_8601": "2019-10-26T07:47:47.092529Z", "url": "https://files.pythonhosted.org/packages/49/3b/227ce394961ccc3b7a72f5b0cded6a106eed683a71579ea03d4873d51148/nightcore-1.1.0.tar.gz", "yanked": false, "yanked_reason": null } ], "vulnerabilities": [] }