danmacnish / cartoonify
- пятница, 6 июля 2018 г. в 06:46:28
Python
python app to turn a photograph into a cartoon
Draw This is a polaroid camera that draws cartoons. You point, and shoot - and out pops a cartoon; the camera's best interpretation of what it saw. The camera is a mash up of a neural network for object recognition, the google quickdraw dataset, a thermal printer, and a raspberry pi.
The software can run both on a desktop environment (OSX, Linux) such as a laptop, or an embedded environment on a raspberry pi.
pip install -r requirements.txt
from the cartoonify
subdirectory.pip install .
from within the cartoonify
directorycartoonify
cartoonify --gui
The following wiring diagram will get you started with a shutter button and a status LED. If the software is working correctly, the status LED should light up for 2-3 seconds when the shutter is pressed while the raspi is processing an image. If the light stays on, something has gone wrong (most likely the camera is unplugged).
requirements:
install docker on the raspi by running: curl -sSL https://get.docker.com | sh
set up and enable the raspi camera through raspi-config
clone the source code from this repo
run ./raspi-build.sh
. This will download the google quickdraw dataset and tensorflow model,
then build the required docker image.
run ./raspi-run.sh
. This will start the docker image.
cartoonify/logs
folder for any error messages.cartoonify/images
.