Name: opencv-kafka-demo
Owner: Stark & Wayne
Description: null
Created: 2017-11-07 03:58:01.0
Updated: 2017-12-05 00:33:23.0
Pushed: 2017-12-08 02:28:34.0
Homepage: null
Size: 2500
Language: Go
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
install kafka librdkafka
Kafka + ZooKeeper are now running locally.
To start publishing your laptop camera to a kafka topic:
magesfromopencv-to-kafka
RA=opencv python3 app.py
To start processing the images from Kafka topic via OpenCV to do object detection, and push the resulting images onto a new Kafka topic:
bjectdetector
on3 app.py
To run a webserver that streams the resulting images to a web page:
magewatcher
corn __init__:app --reload -e CAMERA=kafka
View at http://localhost:8000
install tmux
install tmuxinator
There is a local .tmuxinator.yml
that will now start zookeeper/kafka, and then run all the different processes:
inator start demo
To exit the tmux session, use tmux command ctrl-c d
. Then to kill the session and its processes:
kill-session -t demo
To deploy all apps to Cloud Foundry:
deploy.sh
If an application fails to run and has the following in its logs, then perhaps Kafka cluster is unhealthy:
-11-10T16:44:39.16+1000 [APP/PROC/WEB/0] ERR [2017-11-10 06:44:39 +0000] [6] [CRITICAL] WORKER TIMEOUT (pid:43)
-11-10T16:44:39.16+1000 [APP/PROC/WEB/0] ERR [2017-11-10 06:44:39 +0000] [43] [INFO] Worker exiting (pid: 43)
-11-10T16:44:39.19+1000 [APP/PROC/WEB/0] ERR [2017-11-10 06:44:39 +0000] [141] [INFO] Booting worker with pid: 141