ASVR is a simple and lightweight Python program to render optimized MP4
musicvideos with a stillimage automatically. It was first designed by me to supply demands of a music-based YouTube channel.If you run into whatever bugs or glitches within the code or just wanna leave any suggestions, feel free to email me. Thanks for the attention!
- First off, clone this repository;
- Download and install all the dependencies listed here.
When you're all set, drag an audio and an image file (check the list of supported file types) into the IO folder inside your directory and, finally, run the main.py file.
It's highly recommended to run it within mediums that offer standard user input from the keyboard, otherwise you'll be limited to not being able to properly select which files you want to work with.
If you insert exactly an image and an audio file into the IO folder, the video will be automatically generated by simply running the main.py file. Otherwise (i.e. you threw multiple audio/image files inside of it), you're gonna be prompted for audio and image select. In this case, choose the desired files by typing, in the terminal, the index associated with the filename shown and press the ENTER/RETURN key afterwards.
If everything goes well, an MP4 video will be generated inside the IO folder, alongside the audio + image files. If it doesn't, don't panic and try to understand what's being said and what actually happened. Send me an email if you have any questions about the program functioning.
After, and only after installing Python and FFmpeg properly, you need to install those Python packages in order to properly execute the script:
- Audioread:
pip install audioread
- FFmpeg for Python:
pip install ffmpeg-python
- Headless OpenCV:
pip install opencv-python-headless
- NumPy:
pip install numpy
Apparently, pip install
isn't working properly to install Python packages in some machines, so keep in mind the commands above might not work in some environments (especially if you recently installed Python). In this case, try swapping pip install
for python -m pip install
, python3 -m pip install
or even py -m pip install
if the usual pip command doesn't work.
MP3 (.mp3)
FLAC (.flac)
WAVE (.wav)
OPUS (.opus)
JPG (.jpg)
PNG (.png)
- Do not modify the directory structure apart from the inside of the IO folder unless you know exactly what you're doing;
- Make sure you correctly installed all the dependencies listed above in your machine before running the script. They're all vital for the proper code functioning.