This is a Python script that creates a video from a set of images and adds a random audio clip to each video.
To use this script, you'll need to have Python 3.x installed on your system along with the following libraries:
- cv2
- numpy
- glob
- random
- moviepy
You can install these libraries using the following command:
pip install opencv-python numpy glob3 pydub random moviepy
- Clone or download the script to your computer.
- Add your images to the "images" folder. The script reads all PNG files in each subfolder of the "images" folder and creates a video for each subfolder.
- Add your audio files to the "audio" folder. The script selects a random audio file from this folder and adds it to the video.
- Run the script using the following command:
- The script will create a video for each subfolder in the "images" folder and save it in the "output" folder.
python main.py
- If you want to add more image or audio files, simply add them to the "images" or "audio" folder, respectively.
This script is licensed under the MIT License. Feel free to modify and use it for your own projects.