{"id":15717162,"url":"https://github.com/gituser12981u2/audio_visualizer","last_synced_at":"2026-02-21T19:03:16.418Z","repository":{"id":240175937,"uuid":"801875345","full_name":"gituser12981u2/audio_visualizer","owner":"gituser12981u2","description":"A janky, yet charming terminal-based audio visualizer","archived":false,"fork":false,"pushed_at":"2024-07-07T20:09:47.000Z","size":83472,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-11T01:23:01.289Z","etag":null,"topics":["audio-processing","audio-visualizer","fft","linux","live-music-visualizer","macosx","music-visualization","music-visualizer","windows"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gituser12981u2.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","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":"2024-05-17T04:58:03.000Z","updated_at":"2024-07-07T20:06:03.000Z","dependencies_parsed_at":null,"dependency_job_id":"c7f7e801-cf94-494a-86ac-c1cc3e81688e","html_url":"https://github.com/gituser12981u2/audio_visualizer","commit_stats":null,"previous_names":["gituser12981u2/audio_visualizer"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gituser12981u2%2Faudio_visualizer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gituser12981u2%2Faudio_visualizer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gituser12981u2%2Faudio_visualizer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gituser12981u2%2Faudio_visualizer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gituser12981u2","download_url":"https://codeload.github.com/gituser12981u2/audio_visualizer/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241104475,"owners_count":19910450,"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":["audio-processing","audio-visualizer","fft","linux","live-music-visualizer","macosx","music-visualization","music-visualizer","windows"],"created_at":"2024-10-03T21:48:55.013Z","updated_at":"2025-10-17T06:27:52.709Z","avatar_url":"https://github.com/gituser12981u2.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Audio Visualizer\n\n![Visualizer Demo](/lib/output.gif)\n\nA simple, janky, yet charming terminal-based audio visualizer written in Python. It can visualize audio data from a microphone or any other audio input device.\n\nSee `/image_gallery` to see the program in action.\n\n## Features\n\n- Visualize audio data in vertical or horizontal bar charts.\n- Adjustable parameters such as smoothing factor, buffer size, sampling rate, and number of bars.\n- Theme support for customizing the visual output.\n- Works on Linux, macOS, and Windows.\n- Works best in VSC terminal, kitty, and alacritty.\n\n## Installation\n\n### Install an audio loopback library\n\n#### Linux\n\n```bash\nsudo apt-get install -y portaudio19-dev\n```\n\n#### macOS\n\nSetup a loopback device.\n\n```bash\nbrew install blackhole-2ch\n```\n\n1. Open the \"Audio MIDI Setup\" app.\n2. Create an \"Aggregate Device\" with the default input device and \"BlackHole 2ch\".\n3. Set this Aggregate Device as the input device\n\n#### Windows\n\nOn Windows, audio routing can be tricky. If you want to visualize audio from your speakers or headphones instead of just the microphone, you will need to use a virtual audio cable. Follow these steps:\n\n1. Download and install a virtual audio cable from [VB-Audio](\u003chttps://vb-audio.com/Cable/\u003e)\n2. Set your playback device to the virtual audio cable.\n3. In your recording devices, set the virtual audio cable as the default recording device.\n4. Route the audio through your headphones or speakers.\n\nThis will allow for the program to render the audio that is being outputted on the device as well as continue to have the user be able to hear the same audio.\n\n### Install audio_visualizer\n\n#### Homebrew (macOS/linux)\n\n```bash\nbrew install audio_visualizer\n```\n\n#### Other package managers\n\nWill add to other package managers (like winget, AUR, etc) if asked.\n\n### Install the Python Package via Source code\n\n1. Clone the repository:\n\n    ```bash\n    git clone https://github.com/gituser12981u2/audio_visualizer\n    ```\n\n2. Set up a virtual environment:\n\n    ```bash\n    python3 -m venv .venv\n    ```\n\n    ```bash\n    source .venv/bin/activate  \n    # On Windows, use '.venv\\Scripts\\activate'\n    ```\n\n3. Install the package:\n\n    ```bash\n    pip install .\n    ```\n\n### Optional GPU Acceleration\n\nIf your system has a compatible Nvidia or AMD GPU, you can enable GPU acceleration by installing an additional dependency:\n\n#### For source code\n\n```bash\npip install .[gpu]\n```\n\n#### For install\n\n```bash\n\u003cpackage manager install\u003e audio_visualizer --with-gpu\n```\n\n**Note**: GPU acceleration is not recommended if your system supports AMX, as native operations are more efficient for this program.\n\nThen follow these [instructions](https://docs.cupy.dev/en/stable/install.html#using-cupy-on-amd-gpu-experimental) to install the CUDA––for Nvidia––or ROCm––for AMD––toolkit.\n\n## Usage\n\n### Running the Visualizer\n\nTo Start the visualizer, use the following command:\n\n```bash\naudio-visualizer\n```\n\nOr run this command for the same outcome:\n\n```bash\naudio-visualizer --mode vertical\n```\n\nOr to run in horizontal mode:\n\n```bash\naudio-visualizer --mode horizontal-ltr\n```\n\n**Note**: there are two horizontal modes. One that draws bars from left to right (ltr) and one that draws bars from right to left (rtl)\n\n### Configuration File\n\nModify `config.lua` to change default settings and key bindings. This file controls various aspects of the Audio Visualizer's behavior, including the visual mode, hotkeys, and audio processing parameters.\n\n#### Config File Location\n\n- **Linux/macOS**: Place your `config.lua` in `~/.config/audio_visualizer/`. This is the recommended location as it follows the standard configuration directory structure on Unix-like systems.\n- **Windows**: Place your `config.lua` in `%APPDATA%\\audio-visualizer\\`. This location is recommended for Windows users as it aligns with the typical application data storage.\n\nIf a `config.lua` file is not found in these locations, the program will attempt to load it from the directory where the `audio-visualizer` command is executed.\n\n### Hotkey mode switcher\n\nSwitch visualization modes dynamically with configured hotkeys.\nFor example, the default keybindings are:\n\n- 'ctrl+h': horizontal ltr mode\n- 'ctrl+l': horizontal rtl mode\n- 'ctrl+j': vertical mode\n\n### Themes\n\nThemes allow you to customize the visual appearance of the audio visualizer:\n\n- **background_color**: Set to a 'RGB' value like '255;0;0' for red, or 'default to use the terminal's default color.\n- **bar_color**: Set to a 'RGB' value or 'default' to use the terminal's default color.\n\n### Command Line Options\n\n- `--mode`: Visualization mode('vertical or horizontal). Default is `vertical`. That is if you put no `--mode` option.\n- `--alpha`: Smoothing factor for FFT. Default is `0.4`.\n- `--chunk`: Number of frames per buffer. Default is `2048`.\n- `--rate`: Sampling rate Default is `44100`.\n\nExample:\n\n```bash\naudio-visualizer --mode horizontal-rtl --alpha 0.3 --chunk 1024 --rate 48000\n```\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n\n## Contributors\n\nThis project is inspired by cava.\n\nThank you to the follow people for their contributions to this project:\n\n-[@ohksith](https://github.com/ohksith) - Provided fix for the terminal to clean it self after visualization stopped\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgituser12981u2%2Faudio_visualizer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgituser12981u2%2Faudio_visualizer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgituser12981u2%2Faudio_visualizer/lists"}