A tool for converting images and videos into cartoons. Tested on python 3.7.
Results:
This code is based on WhiteBox cartoonization tool from https://github.com/SystemErrorWang/White-box-Cartoonization/.
It uses pretrained models from https://github.com/experience-ml/cartoonize.
Create virtual environment
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
Set environment variable before running.
export PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
Convert image to cartoon (code replaces image in place):
python toonize.py image.jpg
Convert all jpg images in curent folder to cartoon:
python toonize.py "*.jpg"
Convert video to cartoon:
python toonize.py video.mp4