schwittlick / ofxDarknet

darknet neural network addon for openFrameworks
MIT License
496 stars 89 forks source link

Video streaming #31

Closed thaemes closed 6 years ago

thaemes commented 7 years ago

With the regular YOLO, it is possible to run directly on udp / rtp streams. How can I use this YOLO functionality from within ofxDarknet?

genekogan commented 7 years ago

yes, it should be able to do so. you just need to extract the pixels from each frame and send them to darknet. see example-yolo.

thaemes commented 7 years ago

Thank you @genekogan. streaming udp is already part of the functionality of darknet, as you can run somehting like: ./darknet detector demo data/voc.data cfg/yolo-voc.cfg yolo-voc.weights udp://@:5005 Would I be able to do something similar where darknet takes care of setting up the stream? Or do I need to use openFrameworks to receive the stream, and pass it to darknet like in the example-yolo ?

genekogan commented 7 years ago

this should not be too difficult to setup in openframeworks, since there are a number of addons which support UDP streaming (see ofxStreamer for example, or ofxSyphon for getting it from an already-streaming app). if you can combine these into a streaming yolo detector, this would be a very welcome contribution to this repo.