bil9148 / LyricDiffusion

LyricDiffusion is a versatile application that transforms song lyrics into visually stunning images and then those images into a slideshow.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LyricDiffusion

LyricDiffusion is a versatile application that transforms song lyrics into visually stunning images and then those images can be combined into a slideshow with the wanted speed. By leveraging the Genius API, it seamlessly retrieves lyrics based on the artist and song entered by the user. The application provides a user-friendly interface with various customization options, allowing you to generate images tailored to your preferences.

Image generation examples

As I walk through the valley of the shadow of death

3

'Cause I've been blastin' and laughin' so long that

5

Video generation examples

Gangsta's paradise - Coolio - LykonDreamShaper

ezgif com-optimize

Features

Genius API Integration: Automatically fetches lyrics for the specified artist and song.

Customizable Inference: Choose the number of inference steps (1-100) to fine-tune the generated images.

Extra Prompt: Enhance the generated images with an extra prompt, enabling specific styles (e.g., dark ambience, extremely detailed).

Model Selection: Select a language model from Hugging Face's collection (e.g., dataautogpt3/OpenDalleV1.1).

Skip Irrelevant Verses: Exclude empty or non-lyrical verses fetched from the Genius API.

Output Path Configuration: Change the output path where the images and videos will be saved.

Video FPS: Choose how fast the slideshow should move.

Video Format: Choose in which format the video should be generated.

Usage

Clone the repository

git clone https://github.com/bil9148/LyricDiffusion

Install Dependencies:

pip install -r requirements.txt

PyTorch - 12.1 (https://pytorch.org/get-started/locally/)

pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121

Run the Application:

python main.py

Follow the on-screen instructions to enter the artist name, song name, and customize other options.

Contributing

If you'd like to contribute to LyricDiffusion, feel free to fork the repository, make your enhancements, and submit a pull request.

Limitations

The image generation works only on NVIDIA GPUs.

Build

Can't build with Nuitka since OpenCV was added to the project or rather can build but get the "OpenCV recursion error" and can't run the app.

Nuitka - 1.9.6

Python - 3.10

OpenCV - ?

Issues

Encountered a bug or have a suggestion? Open an issue on the repository to help improve LyricDiffusion.

About

LyricDiffusion is a versatile application that transforms song lyrics into visually stunning images and then those images into a slideshow.

License:MIT License


Languages

Language:Python 100.0%